The Problem
You're running AI agents in production — coding assistants, data pipelines, customer support bots, trading bots, content generators. Each one makes autonomous decisions, but:
- No visibility → Agent fails at 3 AM, you find out Monday
- No memory → Same agent rediscovers the same bug every session
- No coordination → 5 agents, 5 silos, zero shared knowledge
The Solution
AgentOS gives your AI fleet a command center — real-time monitoring, persistent knowledge that survives across sessions, and usage-based billing that scales with you.
Your Agent Fleet → AgentOS SDK → Dashboard
├── Coding Assistant 3 lines 📊 Real-time status
├── Data Pipeline of code 🧠 Shared knowledge
├── Support Bot 📈 Usage analytics
└── Content Generator 🔑 API key management
Quick Start
1. Install
npm install stoic-agentos-sdk
2. Get Your API Key
Sign up at stoicagentos.com → Dashboard → Settings → Generate Key
3. Monitor Your First Agent
import { AgentOS } from 'stoic-agentos-sdk';
const os = new AgentOS({
apiKey: 'sk_live_your_key_here',
workspace: 'my-project',
});
// Wrap any function → auto-captures start, success, and errors
const myAgent = os.wrapAgent('invoice-processor', async (input) => {
const result = await processInvoice(input);
return result;
});
// Run it — AgentOS tracks everything
await myAgent({ invoiceId: 'INV-001' });
4. Capture Decisions & Knowledge
// Capture important observations
os.capture({
type: 'decision',
title: 'Switched to GPT-4o-mini for summarization',
content: 'Reduced cost by 40% with no quality loss on BLEU benchmark',
});
// Persist knowledge across sessions
os.capture({
type: 'architecture',
title: 'Payment service uses idempotency keys',
content: 'Always include X-Idempotency-Key header to prevent double charges',
});
Features
| Feature | Description |
|---|---|
| 🤖 Agent Monitoring | Real-time status, heartbeats, error tracking for your entire fleet |
| 🧠 Three-Tier Memory | Persistent memory across restarts: Working memory, episodic memory, and semantic triples. |
| 🔍 Vector Cosine Similarity | Built-in semantic search on episodic memories using pgvector and optimized HNSW index. |
| 🔄 autoRecall Prompt Injection | Automatically search memory database for past context and inject it into system prompts. |
| 🛡️ Active Shields & HITL | Human-in-the-Loop approval loops. Suspend critical tool executions (e.g. database edits) until verified. |
| 📊 Usage Analytics | Observations/month, agent runs, error rates, and token cost tracking |
| ⚡ Auto-Capture SDK | wrapAgent() and client instrumentation auto-capture full OpenAI and Anthropic traces. |
| 🔒 Row-Level Security | Full multi-tenant isolation on Supabase — your data is isolated per organization |
| 🧠 Claude-Powered Insights | Auto-summarize logs (Haiku 4.5) and diagnose failing agents (Sonnet 4.6 + thinking) |
Built for LLMOps
Stoic AgentOS is designed to integrate with the modern LLMOps stack:
- 🔬 OpenTelemetry-native — Emit OTLP spans from every agent run. Compatible with Jaeger, Datadog, Grafana, and any OTLP backend. (Shipping Q3 2026)
- 🔗 Langfuse adapter — Drop-in
@stoic/langfusepackage to auto-instrument Stoic agents as Langfuse traces. (Shipping Q3 2026) - 📊 Trace-level observability — Every agent execution captures inputs, outputs, latency, token counts, and error traces.
- 🧠 Memory Layer — Unlike pure observability tools, AgentOS persists agent decisions and architectural knowledge across sessions.
- 🛡️ Active Defense — Server-side active circuit breakers and Human-In-The-Loop approval loops prevent rogue agent loops and unauthorized operations.
Where we fit: Stoic AgentOS occupies the Active Memory & Governance niche in the LLMOps stack — complementing tracing tools like Langfuse and Helicone with an active layer that makes agents smarter over time and protects your budget.
Why AgentOS?
| Stoic AgentOS | Langfuse | Helicone | Phoenix (Arize) | AgentOps | CrewAI | |
|---|---|---|---|---|---|---|
| LLM tracing & observability | ✅ | ✅ | ✅ | ✅ | ✅ | ⚠️ Orchestration only |
| Persistent Memory | ✅ Three-tier | ❌ | ❌ | ❌ | ❌ | ❌ |
| Semantic Vector Search | ✅ pgvector/HNSW | ❌ | ❌ | ❌ | ❌ | ❌ |
| autoRecall Prompt Injection | ✅ SDK level | ❌ | ❌ | ❌ | ❌ | ❌ |
| Active Shield (HITL approvals) | ✅ Server-side | ❌ | ❌ | ❌ | ❌ | ❌ |
| Docker Self-host | ✅ | ✅ | ❌ | ✅ | ❌ | ✅ |
| Open-source core | ✅ MIT | ✅ MIT | ❌ | ✅ Apache-2 | Partial | ✅ |
| Setup time | 3 min | 10 min | 2 min | 5 min | 5 min | 30 min |
Pricing
| Free | Pro — $29/mo | Team — $79/mo | Enterprise | |
|---|---|---|---|---|
| Workspaces | 2 | 10 | Unlimited | Unlimited |
| Agents | 5 | 25 | 100 | Unlimited |
| Observations/mo | 10,000 | 100,000 | Unlimited | Unlimited |
| Knowledge items | 5 | 25 | Unlimited | Unlimited |
| Members | 1 | 5 | 15 | Unlimited |
Architecture
┌────────────────────────────────┐
│ Your Application │
│ ├── Agent 1 │
│ ├── Agent 2 │─── stoic-agentos-sdk (npm)
│ └── Agent N │ │
└────────────────────────────────┘ │
▼
┌──────────────────────────────────────────────────┐
│ AgentOS API (Railway) │
│ ├── Auth (Supabase JWT + API Keys) │
│ ├── Observations → /api/v1/observations │
│ ├── Agents → /api/v1/agents │
│ ├── Knowledge → /api/v1/knowledge-items │
│ ├── Billing → /api/v1/billing (Stripe) │
│ └── Webhooks → /webhooks/stripe, /webhooks/git │
└──────────────────────────────────────────────────┘
│ │
▼ ▼
┌─────────────┐ ┌─────────────────┐
│ Supabase │ │ Stripe │
│ (Postgres) │ │ (Billing) │
│ 8 tables │ │ Checkout + │
│ RLS on all │ │ Portal + │
│ │ │ Webhooks │
└─────────────┘ └─────────────────┘
API Reference
| Method | Endpoint | Auth | Description |
|---|---|---|---|
POST |
/api/v1/observations |
API Key | Create observation |
GET |
/api/v1/observations |
API Key | List observations |
POST |
/api/v1/agents |
API Key | Register agent |
GET |
/api/v1/agents |
API Key | List agents |
POST |
/api/v1/agents/heartbeat |
API Key | Agent heartbeat (upsert) |
POST |
/api/v1/knowledge-items |
API Key | Create knowledge item |
POST |
/api/v1/workspaces |
API Key | Create workspace |
GET |
/api/v1/stats |
API Key | Dashboard stats |
POST |
/api/v1/api-keys |
JWT | Generate API key |
DELETE |
/api/v1/api-keys/:id |
JWT | Revoke API key |
POST |
/api/v1/billing/checkout |
JWT | Start Stripe checkout |
POST |
/api/v1/billing/portal |
JWT | Open customer portal |
SDK Reference
import { AgentOS } from 'stoic-agentos-sdk';
// Initialize
const os = new AgentOS({ apiKey: 'sk_live_xxx', workspace: 'my-app' });
// Core methods
os.capture({ type, title, content, metadata }) // Log observation
os.wrapAgent(name, fn) // Auto-monitor function
os.getObservations({ limit, type }) // Query observations
os.getStats() // Dashboard stats
// Claude-powered insights (v2.1+)
await os.summarize({ hours: 168 }) // AI briefing of recent activity
await os.analyzeAgent(agentId) // Diagnose an agent's health
await os.ask('Why did the email-agent fail?') // Free-form Q&A
Claude Integration
AgentOS uses Anthropic Claude for AI-powered insights — summarizing observations, diagnosing agent failures, answering free-form questions about your fleet.
Models: Haiku 4.5 for fast summaries, Sonnet 4 with adaptive thinking for deep diagnosis.
Three surfaces:
- API:
POST /insights/{summarize,analyze-agent,ask}— see API Reference - SDK:
os.summarize(),os.analyzeAgent(id),os.ask(q)(above) - MCP server:
agentos_summarize_observations,agentos_analyze_agent,agentos_asktools
BYOK (Bring Your Own Key): Customers can route inference through their own Anthropic account from Settings → Anthropic API Key. Keys are stored encrypted in Supabase Vault (vault.secrets, pgsodium at rest) and accessed only by the API's service role. When no per-org key is set, the platform falls back to the ANTHROPIC_API_KEY env var.
Cost tracking: Every Claude call is logged to anthropic_usage with token counts and cache hits. The Settings tab shows call count, token usage, and estimated cost over a 7/30/90-day window.
Caching: All requests use cache_control: { type: 'ephemeral' } so repeated system prompts hit the prefix cache at ~10% of input cost.
🌍 Used By
Stoic AgentOS is trusted by modern engineering teams to monitor, persist, and orchestrate their autonomous systems.
- Autonomous DevOps: Auto-monitoring CI/CD triage agents running 24/7.
- Enterprise Support Fleets: Coordinating multi-agent support flows across 10k+ dynamic observations/mo.
- Dynamic Content Pipelines: Tracking memory preservation for long-running creative video generation.
🐳 Self-Hosting
Run Stoic AgentOS on your own infrastructure with 3 commands. You'll need a Supabase project (free tier works).
# 1. Clone and configure
git clone https://github.com/benjaminkernbaum-ux/stoic-agentos.git
cd stoic-agentos
cp .env.selfhost.example .env.selfhost
# Edit .env.selfhost with your Supabase URL + service key
# 2. Run all migrations in Supabase SQL editor
# (api/migrations/002_*.sql through 015_*.sql)
# 3. Start the API
docker compose -f docker-compose.selfhost.yml up -d
What you get:
- 🔌 API Server (Express + TypeScript) →
http://localhost:4444 - 🛡️ Non-root container, health checks, auto-restart
- 📦 512MB memory limit, optimized for single-instance
- 🔑 Optional: Stripe billing, Anthropic AI, Upstash Redis
For the dashboard frontend, run npm run dev in the project root or deploy to Vercel/Netlify.
See self-hosting docs for Kubernetes and Terraform guides.
Contributing
We welcome contributions! See CONTRIBUTING.md for guidelines.
# Clone the repo
git clone https://github.com/benjaminkernbaum-ux/stoic-agentos.git
cd stoic-agentos
# Install dependencies
npm install
# Start dev server
npm run dev
License
MIT © 2026 Benjamin Kernbaum
📈 Star History
🌍 Community
- 💬 Discussions — Ask questions, share ideas, get support
- 🐛 Issues — Report bugs, request features
- ⭐ Star this repo — Help us reach more developers
- 📋 Contributing — Help us build AgentOS
- 🗺️ Roadmap — See what's coming next
- 📝 Changelog — See what shipped recently
No comments yet
Be the first to share your take.