Gemma 4 Captioning is an efficient video-captioning agent designed for AMD Developer Hackathon Track 2. It uses Gemma 4 exclusively throughout the inference pipeline, avoiding expensive multi-model ensembles while maintaining consistent visual reasoning and caption style. For each video, the agent uses FFmpeg to extract 24 representative frames at a controlled resolution. Gemma 4 analyses these frames through small parallel requests, identifying visible subjects, actions, objects, environments, lighting, and motion. These observations are consolidated into a grounded evidence record before any caption is written. The same Gemma 4 model generates all four required English caption styles: formal, sarcastic, humorous tech, and humorous non-tech. Dedicated rewriting stages strengthen both humorous variants, while a final grounding review checks every caption against the visual evidence and removes unsupported claims without discarding useful scene details. Using a single multimodal model family makes the architecture simpler, faster, and more cost-efficient for production deployment. It reduces provider dependencies, avoids cross-model inconsistencies, and allows frame analysis to run concurrently. The architecture is also prepared to benefit from Gemma 4 MTP or diffusion-based serving variants, where available and validated, to further reduce generation latency and inference cost. The container follows the required Track 2 contract: it reads tasks from /input/tasks.json, generates every requested style, validates the output structure, and writes valid JSON to /output/results.json. The published image targets public Linux amd64 environments and supports concurrent processing of multiple videos.
Category tags: