Build multi-modal AI applications using our new open-source Vision AI SDK.

Build a Gemini 3 Flash-Powered AI App in Python

2 min read
Amos G.
Amos G.
Published January 20, 2026

In this YouTube Short, we use the model to build a vision AI app in under five minutes that watches your camera feed in real time and answers questions about objects and surroundings.

Let's look at how to create a similar experience with Gemini Python plugin in Vision Ageents, an open-source platform for voice/video AI apps.

Overview of the Agent

In a short time, you will create a digital system that has vision capabilities. It can be used for object detection, scene understanding, and activity recognition. The entire voice system uses:

Step 1: Begin With Vision Agents Python Project

bash
1
2
3
4
5
uv init gemini-vision-agent cd gemini-vision-agent uv add vision-agents uv add "vision-agents[getstream, gemini, inworld, deepgram, smart-turn]"

Step 2: Store These in the Python Project

Create a .env file in your project's root and add these API credentials.

bash
1
2
3
4
5
6
7
8
touch .env GOOGLE_API_KEY=... INWORLD_API_KEY=... DEEPGRAM_API_KEY=... STREAM_API_KEY=... STREAM_API_SECRET=... EXAMPLE_BASE_URL=https://pronto-staging.getstream.io

Step 3: Fill Out main.py

Substitute the generated Python project's main.py with this sample code.

python
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import asyncio import os from vision_agents import Agent, register from vision_agents.llm import GeminiLLM from vision_agents.tts import InworldTTS from vision_agents.stt import DeepgramSTT from vision_agents.turn_detection import SmartTurn from vision_agents.stream import StreamVideoCall async def main(): # 1. Gemini 3 Flash as the multimodal brain llm = GeminiLLM( model="gemini-3-flash-preview", api_key=os.getenv("GOOGLE_API_KEY") ) # 2. Voice pipeline tts = InworldTTS(api_key=os.getenv("INWORLD_API_KEY")) stt = DeepgramSTT(api_key=os.getenv("DEEPGRAM_API_KEY")) turn_detector = SmartTurn() # 3. Create the vision agent agent = Agent( llm=llm, tts=tts, stt=stt, turn_detector=turn_detector, name="Vision Assistant", system_prompt=""" You are an expert vision AI assistant. Analyze the live camera feed in real time. Describe objects clearly, notice when they change, and answer questions accurately. Be concise, helpful, and speak naturally. """ ) register(agent) # 4. Launch real-time video call call = StreamVideoCall( api_key=os.getenv("STREAM_API_KEY"), api_secret=os.getenv("STREAM_API_SECRET"), call_type="default", call_id="gemini-vision-demo" ) await call.join() print("Vision AI app ready! Open this URL in your browser:") print(call.url) # 5. Run the agent await agent.run(call) if __name__ == "__main__": asyncio.run(main())

This script builds a voice/vision assistant you can speak with in realtime for camera feed analysis and environmental objects detection. Enjoy .

Scaling WebRTC Video to 100,000 Participants
View Stream's latest Video API benchmark and the architecture that powers performance at scale.