Question presented to candidate: "Models like the current GPT, Claude and Gemini families accept screenshots, photos and audio, not just text. How does a model that was built around text tokens actually take in an image or a sound clip, and what does that mean for us when we build features on it?"
What a strong answer should cover:
- Non-text inputs are turned into sequences of vectors in the same embedding space as text tokens: an image is cut into patches and run through a vision encoder (ViT-style), then a projector maps those features to the LLM width; the LLM then attends over image and text positions together
- Audio follows the same pattern: resample, turn into a spectrogram (Whisper uses 80-channel log-Mel frames in 30-second windows), encode, project; or a pipeline of speech-to-text then a text model
- Architectural options: adapter on a pretrained LLM (LLaVA-style projector), cross-attention into a frozen LM, or natively multimodal training; trade-offs in cost and quality
- Practical consequences: images and audio cost tokens (each provider publishes a formula: tiles, patches or per-second rates), resolution settings trade detail for cost, large images are downscaled
- Limitations and risks: small text and counting errors, hallucinated visual details, and prompt injection hidden inside images or audio
Code / implementation expected: Optional โ turning a small image into patch vectors, or estimating image and audio token counts from published rules, shows real understanding.