Open-source observability, cost tracking, and governance for AI agents
Project description
🔭 AgentWatch
Open-source observability, cost tracking, and governance for AI agents
OpenAI · Anthropic · LangChain · CrewAI · AutoGen · LlamaIndex
Quickstart · Self-Hosting · Dashboard · Docs · Contributing
⚠️ Alpha: Core SDK and self-hosting work. Human approval workflows and full dashboard are in active development. See the roadmap.
Why AgentWatch?
Organizations deploy AI agents in production every day — customer support, code generation, document processing, and more. But once deployed, nobody can answer: What did the agent do? How much did it cost? Did it get approval before taking action?
AgentWatch is the missing observability layer. Unlike closed-source alternatives:
- 🏠 Fully self-hostable — the entire stack (SDK + API + dashboard) runs on your infra. Not just the SDK — everything.
- 📡 OpenTelemetry-native — no proprietary event format. Your data stays portable.
- ⚖️ MIT licensed — no AGPL copyleft triggers. Enterprise-friendly from day one.
- 🛡️ Human approval workflows — built into the core, not gated behind an Enterprise tier.
- 🔌 Framework-agnostic — one SDK works with OpenAI, Anthropic, LangChain, CrewAI, AutoGen, and LlamaIndex.
⚡ Quickstart
pip install agentwatch
OpenAI
import agentwatch
import openai
agentwatch.init(api_key="aw_your_key") # That's it. All OpenAI calls are now traced.
client = openai.OpenAI()
response = client.chat.completions.create(
model="gpt-4o",
messages=[{"role": "user", "content": "Hello!"}]
)
LangChain
import agentwatch
agentwatch.init(api_key="aw_your_key")
from langchain_openai import ChatOpenAI
llm = ChatOpenAI(model="gpt-4o")
result = llm.invoke("Explain quantum computing")
CrewAI
import agentwatch
agentwatch.init(api_key="aw_your_key")
from crewai import Crew, Agent, Task
crew = Crew(agents=[...], tasks=[...])
result = crew.kickoff() # Automatically traced
Custom Instrumentation
@agentwatch.session
def my_agent_pipeline():
result = research()
return summarize(result)
@agentwatch.tool
def research():
return search_web("latest AI news")
🏠 Self-Hosting
Deploy the entire AgentWatch stack in under 5 minutes:
git clone https://github.com/mukktinaadh/agentwatch
cd agentwatch
cp .env.example .env # Edit with your secrets
docker compose up -d # That's it.
Dashboard: http://localhost · API: http://localhost:8000/docs
Point your SDK to your self-hosted instance:
agentwatch.init(
api_key="aw_your_key",
endpoint_url="http://your-server:8000"
)
📊 Dashboard
AgentWatch ships with a production-ready dashboard:
- Sessions View — All agent runs with status, cost, duration, error count
- Trace Waterfall — OTel-style span visualization with timing bars
- Cost Analytics — Spend by day, model, and agent with trend charts
- Alerts — Configure cost overrun and failure threshold alerts
- Approvals — Human-in-the-loop approval workflows with real-time polling
- Settings — API key management and self-hosting configuration
🏗️ Architecture
┌─────────────────┐ OTel Spans ┌──────────────────┐
│ Your Agent │ ──────────────────▶ │ AgentWatch API │
│ + SDK (pip) │ │ (FastAPI) │
└─────────────────┘ └────────┬─────────┘
│
┌────────────┼────────────┐
▼ ▼ ▼
┌──────────┐ ┌──────────┐ ┌──────────┐
│ PostgreSQL│ │ Redis │ │ Dashboard│
│ (data) │ │ (buffer) │ │ (React) │
└──────────┘ └──────────┘ └──────────┘
Approval Flow:
Agent ──▶ SDK blocks ──▶ API ──▶ Dashboard (human review) ──▶ Agent resumes
🆚 Comparison
| Feature | AgentWatch | AgentOps.ai | Langfuse | LangSmith |
|---|---|---|---|---|
| Fully self-hostable (entire stack) | ✅ | ❌ | ✅ | ❌ |
| Open source (MIT) | ✅ | ⚠️ SDK only | ✅ | ❌ |
| OpenTelemetry-native | ✅ | ❌ | ⚠️ | ❌ |
| Human approval workflows | ✅ | ❌ | ❌ | ❌ |
| Cost analytics | ✅ | ✅ | ⚠️ | ⚠️ |
| Framework-agnostic | ✅ | ✅ | ✅ | ❌ |
| Compliance in open tier | ✅ | ❌ | ✅ | ❌ |
🗺️ Roadmap
See our GitHub Projects board for the full roadmap.
Phase 1 (MVP): ✅ OTel traces · ✅ Cost analytics · ✅ Self-hosting · ✅ Dashboard Phase 2: ✅ Human approval workflows · Cross-run analysis · Alert webhooks (Slack) Phase 3: Compliance reporting · Memory management · Enterprise SSO/RBAC · AgentWatch Cloud
🤝 Contributing
We welcome contributions! See CONTRIBUTING.md for details.
# Local development
make dev # Start Postgres + Redis
cd api && uvicorn agentwatch_api.main:app --reload
cd dashboard && npm run dev
📄 License
MIT — see LICENSE. Use it however you want. No AGPL, no copyleft triggers.
Built by MukktiNaadh Raghavarapu · Star ⭐ if this is useful
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file agentwatch_core-0.1.0.tar.gz.
File metadata
- Download URL: agentwatch_core-0.1.0.tar.gz
- Upload date:
- Size: 95.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d4958b7c50dd04a74df55943c89429fb646299c42348ee990d7273f8b2129a2d
|
|
| MD5 |
5b941321415cb46aa532a08182f3b395
|
|
| BLAKE2b-256 |
2ebd213638d1c1ce0591c8e627b076066375f0d659caabb4642799e4178221bc
|
File details
Details for the file agentwatch_core-0.1.0-py3-none-any.whl.
File metadata
- Download URL: agentwatch_core-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
033332eb27d8494ac6a4376cfc7854389d35e53ff08fd9bd000420f05b262380
|
|
| MD5 |
46b588bb1bd0200ddcc0cdb6eb827e87
|
|
| BLAKE2b-256 |
fd9a3d7f2407317e90c98bf85d14338cdf2752429e0d7a127d2e80dd1b7fd44b
|