PandaAGI provides a simple, intuitive API for building general AI agents in just a few lines of code
# 🐼 PandaAGI SDK - An SDK for AGI (Agentic General Intelligence)
[](https://pypi.org/project/panda-agi/)
[](https://discord.gg/KYKj9F2FRH)
[](https://pepy.tech/project/panda-agi)
[](https://opensource.org/licenses/MIT)
[](https://colab.research.google.com/drive/1XEbeTeOgqUKKWsujgkDLKz23FPTPEmjM?usp=sharing)
The PandaAGI SDK provides a simple, intuitive API for building general AI agents in just a few lines of code. It abstracts away the complexity of Agentic Loops and provides a powerful interface for you to build autonomous agents.
Each agent can be configured to run in a custom environment, interacting with the web, your file system, writing code, and running shell commands.
## Installation
```bash
pip install panda-agi
```
Or with uv:
```bash
uv add panda-agi
```
## 🔧 Getting started
First of all, make sure you have a API key. You can get one for free [here](https://agi.pandas-ai.com/).
Make sure to set it as an environment variable:
```bash
export PANDA_AGI_KEY=your_api_key
```
or set it in the .env file:
```bash
PANDA_AGI_KEY=your_api_key
```
Once you have the API key, you can start using the SDK:
```python
import asyncio
from panda_agi import Agent
from panda_agi.envs import LocalEnv
async def main():
# Create a custom environment for the agent
agent_env = LocalEnv("./my_agent_workspace")
# Create the agent
agent = Agent(environment=agent_env)
# Run the agent with a task
response = agent.run("Tell me a joke about pandas")
print(response.output)
# Other possible tasks
response = agent.run("Make a report of the real estate market in Germany")
Agent that generates comprehensive documentation, API references, architecture diagrams, and developer onboarding guides from existing code.
Agent configuration for systematic bug investigation that traces issues from error logs through the codebase to root cause with suggested fixes.
Agent for integrating third-party APIs including SDK setup, type generation, error handling, retry logic, and rate limit management.
Cursor's built-in autonomous coding agent that can make multi-file edits, run terminal commands, search the codebase, and iteratively build features with minimal human intervention.
Cloud-based autonomous coding agent that runs in the background on remote sandboxed environments, handling complex multi-step tasks while you continue working.
Cursor's multi-file editing agent within Composer mode that can create, edit, and delete files across your entire project in a single conversation.