{"id":49021032,"url":"https://github.com/aegra/aegra","last_synced_at":"2026-04-19T04:01:18.961Z","repository":{"id":306752048,"uuid":"1023243010","full_name":"aegra/aegra","owner":"aegra","description":"Open source alternative to LangGraph Platform (now LangSmith Deployments) - Self-hosted AI agent backend with FastAPI and PostgreSQL. Zero vendor lock-in, full control over your agent infrastructure.","archived":false,"fork":false,"pushed_at":"2026-04-15T20:45:27.000Z","size":3640,"stargazers_count":791,"open_issues_count":33,"forks_count":152,"subscribers_count":13,"default_branch":"main","last_synced_at":"2026-04-15T22:16:55.194Z","etag":null,"topics":["fastapi","langchain","langggraph","langgraph-agents","langgraph-platform-alternative","opensource-langgraph-platform","postgres","python"],"latest_commit_sha":null,"homepage":"https://aegra.dev","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aegra.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null},"funding":{"github":null,"patreon":"aegra","open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"lfx_crowdfunding":null,"polar":null,"buy_me_a_coffee":null,"thanks_dev":null,"custom":null}},"created_at":"2025-07-20T20:31:23.000Z","updated_at":"2026-04-15T20:43:02.000Z","dependencies_parsed_at":"2025-07-27T12:32:32.890Z","dependency_job_id":"4416bf8a-97e4-47c6-992f-32b84936b2a1","html_url":"https://github.com/aegra/aegra","commit_stats":null,"previous_names":["ibbybuilds/langgraph-agent-server","ibbybuilds/aegra","ibbybuilds/agent-protocol-server","aegra/aegra"],"tags_count":30,"template":false,"template_full_name":null,"purl":"pkg:github/aegra/aegra","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aegra%2Faegra","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aegra%2Faegra/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aegra%2Faegra/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aegra%2Faegra/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aegra","download_url":"https://codeload.github.com/aegra/aegra/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aegra%2Faegra/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31994010,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T20:23:30.271Z","status":"online","status_checked_at":"2026-04-19T02:00:07.110Z","response_time":55,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fastapi","langchain","langggraph","langgraph-agents","langgraph-platform-alternative","opensource-langgraph-platform","postgres","python"],"created_at":"2026-04-19T04:01:17.015Z","updated_at":"2026-04-19T04:01:18.949Z","avatar_url":"https://github.com/aegra.png","language":"Python","readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"docs/images/banner.png\" alt=\"Aegra banner\" /\u003e\n\u003c/p\u003e\n\n\u003ch1 align=\"center\"\u003eAegra\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eSelf-hosted LangSmith Deployments alternative. Your infrastructure, your rules.\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://pypi.org/project/aegra-api/\"\u003e\u003cimg src=\"https://img.shields.io/pypi/v/aegra-api?label=aegra-api\u0026color=blue\" alt=\"PyPI API\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://pypi.org/project/aegra-cli/\"\u003e\u003cimg src=\"https://img.shields.io/pypi/v/aegra-cli?label=aegra-cli\u0026color=blue\" alt=\"PyPI CLI\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://github.com/aegra/aegra/actions/workflows/ci.yml\"\u003e\u003cimg src=\"https://github.com/aegra/aegra/actions/workflows/ci.yml/badge.svg\" alt=\"CI\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://app.codecov.io/gh/aegra/aegra\"\u003e\u003cimg src=\"https://codecov.io/gh/aegra/aegra/graph/badge.svg\" alt=\"Codecov\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/aegra/aegra/stargazers\"\u003e\u003cimg src=\"https://img.shields.io/github/stars/aegra/aegra\" alt=\"GitHub stars\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://github.com/aegra/aegra/blob/main/LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/github/license/aegra/aegra\" alt=\"License\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://discord.com/invite/D5M3ZPS25e\"\u003e\u003cimg src=\"https://img.shields.io/badge/Discord-Join-7289DA?logo=discord\u0026logoColor=white\" alt=\"Discord\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://patreon.com/aegra\"\u003e\u003cimg src=\"https://img.shields.io/badge/Sponsor-EA4AAA?logo=github-sponsors\u0026logoColor=white\" alt=\"Sponsor\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n---\n\nAegra is a drop-in replacement for LangSmith Deployments. Use the same LangGraph SDK, same APIs, but run it on your own infrastructure with PostgreSQL persistence.\n\n**Works with:** [Agent Chat UI](https://github.com/langchain-ai/agent-chat-ui) | [LangGraph Studio](https://github.com/langchain-ai/langgraph-studio) | [AG-UI / CopilotKit](https://github.com/CopilotKit/CopilotKit)\n\n## 🚀 Quick Start\n\n### Using the CLI (Recommended)\n\n**Prerequisites:** Python 3.12+, Docker (for PostgreSQL)\n\n```bash\npip install aegra-cli\n\n# Initialize a new project — prompts for location, template, and name\naegra init\n\n# Follow the printed next steps:\ncd \u003cyour-project\u003e\ncp .env.example .env     # Add your OPENAI_API_KEY to .env\nuv sync                  # Install dependencies\nuv run aegra dev         # Start PostgreSQL + dev server\n```\n\n\u003e **Note:** Always install `aegra-cli` directly — not the `aegra` meta-package. The `aegra` package on PyPI is a convenience wrapper that does not support version pinning.\n\n### From Source\n\n```bash\ngit clone https://github.com/aegra/aegra.git\ncd aegra\ncp .env.example .env\n# Add your OPENAI_API_KEY to .env\n\ndocker compose up\n```\n\nOpen [http://localhost:2026/docs](http://localhost:2026/docs) to explore the API.\n\nYour existing LangGraph code works without changes:\n\n```python\nfrom langgraph_sdk import get_client\n\nclient = get_client(url=\"http://localhost:2026\")\n\nassistant = await client.assistants.create(graph_id=\"agent\")\nthread = await client.threads.create()\n\nasync for chunk in client.runs.stream(\n    thread_id=thread[\"thread_id\"],\n    assistant_id=assistant[\"assistant_id\"],\n    input={\"messages\": [{\"type\": \"human\", \"content\": \"Hello!\"}]},\n):\n    print(chunk)\n```\n\n## 🔥 Why Aegra?\n\n*Based on [LangChain pricing](https://www.langchain.com/pricing) as of February 2026. An enterprise tier with self-hosting is also available at custom pricing.*\n\n| | LangSmith Deployments | Aegra |\n|:--|:--|:--|\n| **Deploy agents** | Local dev only (Free), paid cloud (Plus) | Free, unlimited |\n| **Custom auth** | Not available (Free), available (Plus) | Python handlers (JWT/OAuth/Firebase) |\n| **Self-hosted** | Enterprise only (license key required) | Always (Apache 2.0) |\n| **Own database** | Managed only (Free/Plus), bring your own (Enterprise) | Bring your own Postgres |\n| **Tracing** | LangSmith only | Any OTLP backend (Langfuse, Phoenix, etc.) |\n| **Data residency** | LangChain cloud (Free/Plus), your infrastructure (Enterprise) | Your infrastructure |\n| **SDK** | LangGraph SDK | Same LangGraph SDK |\n\n## ✨ Features\n\n- **[Agent Protocol](https://github.com/langchain-ai/agent-protocol) compliant** - Works with Agent Chat UI, LangGraph Studio, CopilotKit\n- **[Worker architecture](https://docs.aegra.dev/guides/worker-architecture)** - Redis job queue with 30 concurrent runs per instance, lease-based crash recovery, and horizontal scaling across multiple instances\n- **[Human-in-the-loop](https://docs.aegra.dev/guides/human-in-the-loop)** - Approval gates and user intervention points\n- **[Streaming](https://docs.aegra.dev/guides/streaming)** - Real-time SSE streaming with cross-instance pub/sub and automatic reconnection with event replay\n- **[Persistent state](https://docs.aegra.dev/guides/threads-and-state)** - PostgreSQL checkpoints via LangGraph\n- **[Configurable auth](https://docs.aegra.dev/guides/authentication)** - JWT, OAuth, Firebase, or none\n- **[Unified Observability](https://docs.aegra.dev/guides/observability)** - Fan-out tracing support via OpenTelemetry\n- **[Semantic store](https://docs.aegra.dev/guides/semantic-store)** - Vector embeddings with pgvector\n- **[Custom routes](https://docs.aegra.dev/guides/custom-routes)** - Add your own FastAPI endpoints\n\n## 🛠️ CLI Commands\n\n```bash\naegra init              # Interactive — asks for location, template, and name\naegra init ./my-agent   # Create at path (still prompts for template)\n\naegra dev               # Start development server (hot reload + auto PostgreSQL)\naegra serve             # Start production server (no reload)\naegra up                # Build and start all Docker services\naegra down              # Stop Docker services\n\naegra version           # Show version info\n```\n\n## 📚 Documentation\n\n**[docs.aegra.dev](https://docs.aegra.dev)** — Full documentation with guides, API reference, and configuration.\n\n| Topic | Description |\n|-------|-------------|\n| [Quickstart](https://docs.aegra.dev/quickstart) | Get a running server in under 5 minutes |\n| [Configuration](https://docs.aegra.dev/reference/configuration) | aegra.json format and all options |\n| [Authentication](https://docs.aegra.dev/guides/authentication) | JWT, OAuth, Firebase, or custom auth handlers |\n| [Worker Architecture](https://docs.aegra.dev/guides/worker-architecture) | Redis job queue, crash recovery, horizontal scaling |\n| [Streaming](https://docs.aegra.dev/guides/streaming) | 8 SSE stream modes with reconnection |\n| [Store](https://docs.aegra.dev/guides/store) | Key-value and semantic search storage |\n| [Observability](https://docs.aegra.dev/guides/observability) | Fan-out tracing to Langfuse, Phoenix, or any OTLP backend |\n| [Deployment](https://docs.aegra.dev/guides/deployment) | Docker, PaaS, and Kubernetes deployment |\n| [Migration](https://docs.aegra.dev/migration) | Migrate from LangSmith Deployments |\n\n## 💬 Community \u0026 Support\n\n- **[Discord](https://discord.com/invite/D5M3ZPS25e)** - Chat with the community\n- **[GitHub Discussions](https://github.com/aegra/aegra/discussions)** - Ask questions, share ideas\n- **[GitHub Issues](https://github.com/aegra/aegra/issues)** - Report bugs\n\n## 🏗️ Built With\n\n- [FastAPI](https://fastapi.tiangolo.com/) - HTTP layer\n- [LangGraph](https://github.com/langchain-ai/langgraph) - State management \u0026 graph execution\n- [PostgreSQL](https://www.postgresql.org/) - Persistence \u0026 checkpoints\n- [Redis](https://redis.io/) - Job queue, SSE pub/sub, crash recovery\n- [OpenTelemetry](https://opentelemetry.io/) - Observability standard\n- [pgvector](https://github.com/pgvector/pgvector) - Vector embeddings\n\n## 🤝 Contributing\n\nWe welcome contributions! See [Contributing guide](https://docs.aegra.dev/guides/contributing) and check out [good first issues](https://github.com/aegra/aegra/labels/good%20first%20issue).\n\n## 💖 Support the Project\n\nThe best contribution is code, PRs, and bug reports - that's what makes open source thrive.\n\nFor those who want to support Aegra financially, whether you're using it in production or just believe in what we're building, you can [become a sponsor](https://patreon.com/aegra). Sponsorships help keep development active and the project healthy.\n\n## 📄 License\n\nApache 2.0 - see [LICENSE](LICENSE).\n\n---\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003e⭐ Star us if Aegra helps you escape vendor lock-in ⭐\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003ca href=\"https://www.star-history.com/#aegra/aegra\u0026Date\"\u003e\n  \u003cpicture\u003e\n    \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://api.star-history.com/svg?repos=aegra/aegra\u0026type=Date\u0026theme=dark\" /\u003e\n    \u003csource media=\"(prefers-color-scheme: light)\" srcset=\"https://api.star-history.com/svg?repos=aegra/aegra\u0026type=Date\" /\u003e\n    \u003cimg alt=\"Star History Chart\" src=\"https://api.star-history.com/svg?repos=aegra/aegra\u0026type=Date\" /\u003e\n  \u003c/picture\u003e\n\u003c/a\u003e\n","funding_links":["https://patreon.com/aegra"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faegra%2Faegra","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faegra%2Faegra","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faegra%2Faegra/lists"}