Abstract
Visual In-Context Learning (VICL) enables models to solve new tasks using a few input-output examples. However, conventional VICL is limited by the assumption that prompt and target tasks must be identical. We present T2T-VICL, a framework designed to bridge the gap between disparate visual tasks through implicit textual descriptions. By utilizing a teacher-student VLM pipeline, we generate descriptions of underlying pixel-level transformations that connect different domains (e.g., deraining to dehazing). Our approach enables zero-shot cross-task generalization without explicit retraining. Evaluations across 12 low-level vision tasks and 21 cross-task scenarios show that T2T-VICL significantly enhances semantic preservation and perceptual quality.
1. Introduction
Visual In-Context Learning (VICL) allows models to adapt to new tasks on the fly by observing a few examples. Despite its success, a major limitation persists: models struggle when the prompt task (e.g., denoising) differs from the query task (e.g., deraining). Many low-level vision problems share underlying mathematical structures, yet current models cannot easily transfer knowledge between them. T2T-VICL addresses this by using language as a latent bridge, describing the mechanics of a transformation rather than just the task label.
2. Methodology
The T2T-VICL pipeline consists of three collaborative stages designed to extract and apply latent task relationships.
2.1 Automated Implicit Relationship Generation
A large "teacher" model (Qwen2.5-VL-32B) analyzes pairs of images from two different tasks. It is prompted to describe the visual changes and differences implicitly, avoiding explicit task names. This forces the model to articulate pixel-level mechanics—such as artifact removal or texture restoration—creating a more generalizable linguistic "bridge" between domains.
2.2 Knowledge Transfer and Inference
To ensure efficiency, the reasoning capabilities of the teacher are distilled into a smaller student VLM (sVLM). During inference, the sVLM generates a text prompt based on the provided visual examples. This prompt guides a high-performance generator (Gemini-2.5-Flash) to produce the final image. A Score-Based Reasoning step using VIEScore is employed to select the best candidate output based on semantic and perceptual consistency.
3. Datasets and Evaluation
The framework was tested on 12 representative low-level vision tasks, including restoration (deblurring, denoising, deraining), removal (reflection, shadow), and enhancement (low-light, style transfer). The authors introduced the T2T-VICL dataset, containing 2,000 diverse implicit descriptions per task pair, to facilitate this cross-task reasoning.
4. Key Results and Insights
T2T-VICL was evaluated across 21 cross-task scenarios, demonstrating several key advantages:
- Cross-Task Generalization: In 12 "top-tier" scenarios, such as Deblurring → Dehazing, the model significantly outperformed fixed-prompt baselines in PSNR, SSIM, and VIEScore.
- Semantic Preservation: The model maintains spatial layout and identity fidelity even when tasks are semantically distant, such as using denoising examples to guide light enhancement.
- Perceptual Coherence: Higher VIEScores indicate that the generated images are more semantically and perceptually coherent than those from standard VICL methods, even when pixel-level metrics are comparable.
5. Conclusion
T2T-VICL demonstrates that language can serve as a universal interface for connecting disparate visual domains. By focusing on implicit pixel-level transformations rather than explicit task labels, the framework unlocks new possibilities for cross-task visual in-context learning. Future work will focus on balancing semantic preservation with exact pixel recovery in highly complex compositional scenarios.
Summary updated