Skip to content

DeepFlowAI/OpenAgent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

openagent

Open-source LLM agent platform — knowledge bases, multi-channel agents, conversation flows, tool calling, embedding & semantic search.

Docker Hub · Self-hosting · Issues

License Docker pulls (api) Docker pulls (web) Latest release GitHub stars

English 简体中文

✨ Features

  • LLM-agnostic — built on LiteLLM; bring keys for OpenAI, Aliyun Bailian, Moonshot, Zhipu, Minimax, OpenRouter, or any OpenAI-compatible endpoint.
  • Knowledge bases with semantic search — Git-backed document ingestion, pgvector-powered retrieval, BGE embedding + reranker out of the box.
  • Visual agent builder — define tools, prompts, and conversation flows in the admin UI.
  • Multi-channel chat — embed agents on websites, help centers, or via API.
  • Help center hosting — Markdown-driven public documentation site, multi-tab navigation.
  • Multi-tenant ready — single-tenant out of the box; the Enterprise edition adds platform-level tenant management.
  • OpenTelemetry observability — vendor-neutral OTLP traces & logs (works with SigNoz, Honeycomb, Tempo, Grafana Cloud).

🚀 Quick Start

git clone https://github.com/DeepFlowAI/OpenAgent.git
cd openagent/docker
cp .env.example .env
python -c "import secrets; print('SECRET_KEY=' + secrets.token_hex(32))" >> .env

docker compose up -d        # bundles PostgreSQL (pgvector) + Redis by default

Open http://localhost:3000 and sign in:

Field Default
Tenant default
Username admin
Password Admin123456

⚠️ Change the password immediately after first login in any non-local deployment.

You'll also want to set at least one LLM provider API key in .env (e.g. OPENROUTER_API_KEY=sk-...) and SILICONFLOW_API_KEY=... for the knowledge-base embedding/reranker.

Bring your own database / Redis

Edit COMPOSE_PROFILES= in .env to drop the bundled service(s), then set DATABASE_URL / REDIS_URL. The command stays docker compose up -d. Full deployment guide → docker/README.md.

External PostgreSQL must have the pgvector extension installed (used for semantic search).

🛠️ Local Development

# Backend
cd server && python -m venv venv && source venv/bin/activate
pip install -r requirements.txt
cp .env.example .env.dev   # set DATABASE_URL / REDIS_URL / LLM_API_KEY etc.
uvicorn app.main:app --reload --port 5001

# Frontend
cd web && npm install
cp .env.example .env.dev
npm run dev
Service URL
Frontend http://localhost:3000
Backend API http://localhost:5001
API docs (Swagger) http://localhost:5001/docs

🧩 Architecture

┌─────────────────────────┐    ┌─────────────────────────┐
│  Next.js + React        │◄──►│   FastAPI + LiteLLM     │
│  (web)                  │    │   (api)                 │
└─────────────────────────┘    └────────────┬────────────┘
                                            │
                          ┌─────────────────┼─────────────────┐
                          ▼                 ▼                 ▼
                  ┌──────────────┐  ┌──────────────┐  ┌──────────────┐
                  │  pgvector    │  │   Redis 7    │  │ Object store │
                  │ (vectors+RDS)│  │ (cache+queue)│  │ (uploads)    │
                  └──────────────┘  └──────────────┘  └──────────────┘

Backend follows a strict Router → Service → Repository → Model layering with Pydantic schemas for I/O. Closed-source extensions (e.g. multi-tenant management) plug in via a convention-based loader at app/extensions/.

🏢 Editions

Edition Tenants Tenant management API
Community Single auto-provisioned default
Enterprise Multi-tenant /api/v1/tenants (closed)

The Community edition (this repository) is feature-complete for single-organization deployments. The Enterprise extension adds the platform-level tenant CRUD API for SaaS operators.

🤝 Contributing

Issues, discussions, and pull requests are welcome. Before opening a PR please make sure tests pass:

cd server && pytest

📜 License

openagent is released under the GNU Affero General Public License v3.0.

About

An open source enterprise intelligence platform that supports agent orchestration, tool invocation, knowledge base and observability.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors