> ## Documentation Index
> Fetch the complete documentation index at: https://agno-v2-service-account.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Gemini 3 Pro

> Run Gemini 3 Pro with web search tools, SQLite session storage, and chat history.

```python gemini_3_pro.py theme={null}
"""
Async example using Gemini with tool calls.
"""

import asyncio

from agno.agent import Agent
from agno.db.sqlite.sqlite import SqliteDb
from agno.models.google import Gemini
from agno.tools.websearch import WebSearchTools

# ---------------------------------------------------------------------------
# Create Agent
# ---------------------------------------------------------------------------

agent = Agent(
    model=Gemini(id="gemini-3-pro-preview"),
    db=SqliteDb(db_file="tmp/data.db"),
    tools=[WebSearchTools()],
    markdown=True,
    add_history_to_context=True,
)

asyncio.run(agent.aprint_response("Whats the current news in France?", stream=True))

# Non-streaming response
asyncio.run(
    agent.aprint_response(
        "Write a 2 sentence story the biggest news highlight in our conversation."
    )
)

# ---------------------------------------------------------------------------
# Run Agent
# ---------------------------------------------------------------------------

if __name__ == "__main__":
    pass
```

## Run the Example

<Steps>
  <Snippet file="create-venv-step.mdx" />

  <Step title="Install dependencies">
    ```bash theme={null}
    uv pip install -U agno ddgs google-genai sqlalchemy
    ```
  </Step>

  <Step title="Export your Google API key">
    <CodeGroup>
      ```bash Mac/Linux theme={null}
      export GOOGLE_API_KEY="your_google_api_key_here"
      ```

      ```bash Windows theme={null}
      $Env:GOOGLE_API_KEY="your_google_api_key_here"
      ```
    </CodeGroup>
  </Step>

  <Step title="Run the example">
    Save the code above as `gemini_3_pro.py`, then run:

    ```bash theme={null}
    python gemini_3_pro.py
    ```
  </Step>
</Steps>

Full source: [cookbook/90\_models/google/gemini/gemini\_3\_pro.py](https://github.com/agno-agi/agno/blob/main/cookbook/90_models/google/gemini/gemini_3_pro.py)
