Lune

NeurIPS2023Top-tier venue

In-Context Learning Unlocked for Diffusion Models

Zhendong Wang, Yifan Jiang, Yadong Lu, Yelong Shen, Pengcheng He, Weizhu Chen, Zhangyang (Atlas) Wang, Mingyuan Zhou

Abstract

We present Prompt Diffusion, a framework for enabling in-context learning in diffusion-based generative models. Given a pair of task-specific example images, such as depth from/to image and scribble from/to image, and a text guidance, our model automatically understands the underlying task and performs the same task on a new query image following the text guidance. To achieve this, we propose a vision-language prompt that can model a wide range of vision-language tasks and a diffusion model that takes it as input. The diffusion model is trained jointly over six different tasks using these prompts. The resulting Prompt Diffusion model is the first diffusion-based vision-language foundation model capable of in-context learning. It demonstrates high-quality in-context generation on the trained tasks and generalizes effectively to new, unseen vision tasks with their respective prompts. Our model also shows compelling text-guided image editing results. Our framework aims to facilitate research into in-context learning for computer vision. We share our code and pre-trained models at https://github.com/Zhendong-Wang/Prompt-Diffusion.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

37 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • UniControl: A Unified Diffusion Model for Controllable Visual Generation In the Wild cites Diffusion Models Beat GANs on Image Synthesis
  • UniControl: A Unified Diffusion Model for Controllable Visual Generation In the Wild cites Learning Transferable Visual Models From Natural Language Supervision
  • UniControl: A Unified Diffusion Model for Controllable Visual Generation In the Wild cites Denoising Diffusion Probabilistic Models
  • Towards Global Optimal Visual In-Context Learning Prompt Selection cites Language Models are Few-Shot Learners
  • Towards Global Optimal Visual In-Context Learning Prompt Selection cites Learning Transferable Visual Models From Natural Language Supervision
  • OMG-LLaVA: Bridging Image-level, Object-level, Pixel-level Reasoning and Understanding cites Language Models are Few-Shot Learners
  • OMG-LLaVA: Bridging Image-level, Object-level, Pixel-level Reasoning and Understanding cites Learning Transferable Visual Models From Natural Language Supervision
  • Diffusion Models Beat GANs on Image Synthesis cites Language Models are Few-Shot Learners
  • Diffusion Models Beat GANs on Image Synthesis cites Learning Transferable Visual Models From Natural Language Supervision
  • Diffusion Models Beat GANs on Image Synthesis cites Denoising Diffusion Probabilistic Models
  • ImageRAG: Dynamic Image Retrieval for Reference-Guided Image Generation cites Diffusion Models Beat GANs on Image Synthesis
  • ImageRAG: Dynamic Image Retrieval for Reference-Guided Image Generation cites Language Models are Few-Shot Learners
  • ImageRAG: Dynamic Image Retrieval for Reference-Guided Image Generation cites Learning Transferable Visual Models From Natural Language Supervision
  • ImageRAG: Dynamic Image Retrieval for Reference-Guided Image Generation cites Denoising Diffusion Probabilistic Models
  • ImageRAG: Dynamic Image Retrieval for Reference-Guided Image Generation cites Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
  • Learning Transferable Visual Models From Natural Language Supervision cites Language Models are Few-Shot Learners
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers37

  1. UniControl: A Unified Diffusion Model for Controllable Visual Generation In the WildCan Qin, Shu Zhang, Ning Yu, Yihao Feng et al.NeurIPS 2023 · 250 citations
  2. OMG-LLaVA: Bridging Image-level, Object-level, Pixel-level Reasoning and UnderstandingTao Zhang, Xiangtai Li, Hao Fei, Haobo Yuan et al.NeurIPS 2024 · 186 citations
  3. ImageRAG: Dynamic Image Retrieval for Reference-Guided Image GenerationRotem Shalev-Arkushin, Rinon Gal, Amit Bermano, Ohad FriedICLR 2026 · 25 citations
  4. Towards Global Optimal Visual In-Context Learning Prompt SelectionChengming Xu, Chen Liu, Yikai Wang, Yuan Yao et al.NeurIPS 2024 · 19 citations
  5. CoDi-2: In-Context, Interleaved, and Interactive Any-to-Any GenerationZineng Tang, Ziyi Yang, Mahmoud Khademi, Yang Liu et al.CVPR 2024 · 15 citations

Builds on38

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
  2. Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh et al.ICML 2021 · 47,906 citations
  3. Denoising Diffusion Probabilistic ModelsJonathan Ho, Ajay Jain, Pieter AbbeelNeurIPS 2020 · 35,902 citations
  4. Chain-of-Thought Prompting Elicits Reasoning in Large Language ModelsJason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma et al.NeurIPS 2022 · 22,562 citations
  5. Diffusion Models Beat GANs on Image SynthesisPrafulla Dhariwal, Alexander Quinn NicholNeurIPS 2021 · 13,211 citations

Related papers

  1. Unleashing Text-to-Image Diffusion Models for Visual PerceptionWenliang Zhao, Yongming Rao, Zuyan Liu, Benlin Liu et al.ICCV 2023 · 327 citations
  2. InstructCV: Instruction-Tuned Text-to-Image Diffusion Models as Vision GeneralistsYulu Gan, Sungwoo Park, Alexander Schubert, Anthony Philippakis et al.ICLR 2024 · 34 citations
  3. Diffusion Guided Chain-of-Vision for Large Autoregressive Vision ModelsXinyang Wang, Kecheng Zheng, Minfeng Zhu, Wei Wu et al.CVPR 2026
  4. Stable Diffusion Models Are Secretly Good at Visual In-Context LearningTrevine Oorloff, Vishwanath Sindagi, Wele Gedara Chaminda Bandara, Ali Shafahi et al.ICCV 2025 · 11 citations
  5. Instruct-Imagen: Image Generation with Multi-modal InstructionHexiang Hu, Kelvin C. K. Chan, Yu-Chuan Su, Wenhu Chen et al.CVPR 2024
Dusk over the sea between two cliffs drawn in fine vertical lines