google-antigravity/antigravity-sdk-python
A Python library for building AI agents that leverage the full power of Google Antigravity.
What it solves
The Google Antigravity SDK simplifies the development of AI agents by providing a secure, scalable, and stateful infrastructure layer. It abstracts the complex "agentic loop"—the process of managing model interactions, tool execution, and state—so developers can focus on building agent functionality rather than managing low-level execution details.
How it works
The SDK uses a three-layer architecture: a high-level Agent class for quick setup, a Conversation layer for stateful session management, and a Connection layer for backend abstraction. It manages binary discovery, tool wiring, and hook registration automatically. You can interact with agents via simple chat methods, stream responses in real-time, or define custom policies and tools to control how the agent interacts with your environment.
Who it’s for
This SDK is for Python developers building AI agents who want a robust, production-ready framework that supports both cloud-based Gemini models (via Vertex AI) and local, offline models (via LiteRT-LM).
Highlights
- Flexible Deployment: Supports both cloud-based Gemini Enterprise Agent Platform and fully offline local models.
- Multimodal Support: Easily ingest images, audio, video, and documents alongside text prompts.
- Declarative Security: Use a policy system to explicitly allow, deny, or require user confirmation for specific tool executions.
- Extensible Tooling: Register custom Python functions as tools or connect to external Model Context Protocol (MCP) servers.
- Real-time Streaming: Native support for streaming text tokens, model reasoning/thinking, and tool call events.
- Event-Driven: Includes a trigger system to run background tasks that push messages into the agent.
Related
- Project
- Dispatch
- Project
- Project
- Project