{"slug": "show-hn-nerve-self-hosted-runtime-for-ai-agents", "title": "Show HN: Nerve – self hosted runtime for AI agents", "summary": "A developer has released Nerve, a self-hosted runtime for AI agents built on the Claude Agent SDK that provides persistent memory, scheduled execution, and task management. The open-source tool allows users to deploy personal assistants that remember preferences and develop personality, or worker agents that monitor CI systems and fix flaky tests with human approval. Nerve handles all dependencies and setup through a single installer command, offering web UI, Telegram bot, and autonomous cron job capabilities without requiring an API key.", "body_md": "**A home for your agents.**\n\nSelf-hosted AI agent runtime — personal assistants, autonomous workers, and everything in between.\n\n[Setup Guide](/ClickHouse/nerve/blob/main/docs/setup.md) ·\n[Architecture](/ClickHouse/nerve/blob/main/docs/architecture.md) ·\n[Configuration](/ClickHouse/nerve/blob/main/docs/config.md) ·\n[Worker Guide](/ClickHouse/nerve/blob/main/docs/worker-guide.md) ·\n[API Reference](/ClickHouse/nerve/blob/main/docs/api.md)\n\nNerve is a self-hosted runtime for AI agents, built around the [Claude Agent SDK](https://github.com/anthropics/claude-agent-sdk). It gives agents everything they need to be useful long-term: persistent memory, scheduled execution, task management, learnable skills, and channels to reach you through — web UI, Telegram, or autonomous cron jobs.\n\nShip a **personal assistant** that develops a personality, remembers your preferences, and manages your inbox. Or deploy a **worker agent** that monitors your CI, reviews PRs, and fixes flaky tests — all plan-driven with human approval. Same engine, different mission.\n\n```\ncurl -fsSL https://raw.githubusercontent.com/ClickHouse/nerve/main/install.sh | bash\n```\n\nThe installer handles everything — installs dependencies (Python, Node.js, uv), clones the repo, builds the web UI, and launches the interactive setup wizard.\n\n```\nnerve upgrade\nnerve restart\n```\n\nRuns `git pull`\n\n, reinstalls Python deps, and rebuilds the web UI in one shot. Use `--no-pull`\n\n, `--no-deps`\n\n, or `--no-frontend`\n\nto skip steps. For Docker deployments, rebuild the image instead: `git pull && docker compose build && docker compose up -d`\n\n.\n\n**No API key?** Use your Claude subscription instead\n\nA full-featured assistant for one human. Syncs your email, remembers your preferences, develops personality over time. Comes with a web UI, Telegram bot, memory, cron jobs, and notifications out of the box.\n\n\"You're not a chatbot. You're becoming someone.\"— from the Personal SOUL template\n\n- Workspace files define personality (\n`SOUL.md`\n\n), identity (`IDENTITY.md`\n\n), and user context (`USER.md`\n\n) - Memory categories are life-oriented: relationships, finances, travel, health, work\n- Default crons: inbox processor, task planner, memory maintenance\n- The agent develops opinions, follows up on past conversations, and gets better the longer you use it\n\nA task-focused autonomous agent for teams or programmatic deployment. Monitors something, proposes fixes, implements after approval. Plan-driven with a full audit trail.\n\n\"You're a specialist, not a script.\"— from the Worker SOUL template\n\n**Self-configuring**: give it a plain-English task description and it researches, writes its own`TASK.md`\n\n, creates skills, sets up cron jobs, and starts working- Memory categories are operational: patterns, procedures, decisions, approvals, infrastructure\n- No\n`IDENTITY.md`\n\nor`USER.md`\n\n— workers execute a mission, not build a relationship - Built for reliability: plan before acting, verify after executing, log everything\n\n```\n# Spin up a worker that monitors CI and fixes flaky tests\nnerve init --mode worker\n# → Wizard asks for a task description\n# → Agent onboards itself on first boot\n```\n\n🧠 Memory that persists |\nDual-layer memory: curated hot memory loaded every session + semantic search over your entire history. Agents remember context, preferences, and lessons learned — permanently. |\n🔧 Self-evolving skills |\nAgents watch for repeated workflows and propose reusable skills automatically. Skills are plain Markdown — agents read, create, and improve their own procedures over time. |\n📋 Autonomous task planning |\nA background planner explores open tasks, researches codebases, and proposes implementation plans — without being asked. You review and approve; the agent executes. |\n📡 Multi-source awareness |\nGmail, GitHub, and Telegram flow into a unified inbox with Kafka-style cursors. Multiple consumers process the same data independently — inbox triage, digest generation, task extraction. |\n⚡ Single process, zero ops |\nNo Docker required, no message queues, no service mesh. FastAPI + uvicorn + asyncio. Runs on a Raspberry Pi. |\n🔑 No API key required |\nOptional OAuth proxy routes through your Claude Max/Pro subscription. Zero API costs. |\n🔄 Session persistence |\nSessions survive server restarts. Fork conversations, resume from any point, run up to 4 concurrent agent sessions. |\n🛡️ Human-in-the-loop |\nAgents can pause mid-turn to ask questions via any channel. Plans require approval before execution. Destructive actions need explicit consent. |\n\nEvery channel shares the same agent engine, memory, and tools.\n\nFull React + Vite + TailwindCSS frontend served by FastAPI. Real-time streaming over WebSocket.\n\n- Chat with session history, branching, and resume\n- Inline diff viewer for file changes (no git required)\n- Task manager, memory browser, skill editor\n- Source inbox, notification center, cron logs\n- Plan review with approval/decline/revision workflow\n- JWT auth, self-signed HTTPS via mkcert\n\nPowered by `python-telegram-bot`\n\nv21+.\n\n- Streaming responses via edit-in-place\n- Inline keyboard buttons for interactive tool questions\n`/reply`\n\ncommand for free-text answers- Configurable DM policy (\n`open`\n\nor`pairing`\n\n)\n\nScheduled AI sessions via APScheduler. Three session modes:\n\n| Mode | Behavior |\n|---|---|\nIsolated |\nFresh session per run. No prior context. Best for briefings, cleanup, reports. |\nPersistent |\nAccumulates context across runs. Optional rotation to manage token usage. Reminder mode for lightweight follow-ups. |\nMain |\nRuns inside the user's primary conversation — full context access. |\n\nBuilt-in crons (personal mode): `skill-extractor`\n\n(12h), `skill-reviser`\n\n(weekly), `inbox-processor`\n\n(15min), `task-planner`\n\n(4h). Worker mode ships with `skill-reviser`\n\n, `skill-extractor`\n\n, and `task-planner`\n\nby default; additional crons are configured during onboarding.\n\nCursor-based data ingestion pipeline. Each source runs as an independent APScheduler job.\n\n**Telegram**— Telethon user-account API (`updates.getDifference`\n\n)**Gmail**—`gog`\n\nCLI with 2-step fetch and LLM condensation**GitHub Notifications**—`gh api`\n\nenriched with PR/issue content**GitHub Events**— Pushes, PRs, reviews, comments\n\nMultiple independent consumers read the same inbox at their own pace. Content is prefixed with untrusted-data warnings to prevent prompt injection.\n\nTwo layers, one seamless experience.\n\n**L1 — Hot Memory (MEMORY.md)**\nCurated facts injected into every system prompt. Active projects, current deadlines, operational lessons. Tagged with dates, automatically evicted when stale.\n\n**L2 — Deep Memory (memU)**\nSemantic search over everything — conversations, facts, preferences, events. SQLite-persisted. Uses vector embeddings when an OpenAI key is configured, or LLM-based ranking with Anthropic models only.\n\n- Four memory types:\n`profile`\n\n,`event`\n\n,`knowledge`\n\n,`behavior`\n\n- Automatic conversation indexing on session close\n- Pre-recall: relevant memories injected into system prompt when sessions start\n- 3-level quality filtering prevents generic facts from polluting memory\n- Semantic deduplication (cosine similarity 0.85 threshold)\n- Full audit log of all mutations\n\nMemory categories adapt to mode — personal agents track relationships, health, and finances; workers track patterns, procedures, and approvals.\n\nMarkdown files backed by SQLite FTS5 full-text search.\n\n- Statuses:\n`pending`\n\n→`in_progress`\n\n→`done`\n\n/`deferred`\n\n- Duplicate detection: exact URL match + fuzzy FTS fallback\n- Escalation reminders: deadline → +30min follow-up → +2h URGENT (respects quiet hours)\n- Full markdown editor in the web UI\n\nThe agent's procedural knowledge. Pure Markdown files that agents read, create, and update themselves.\n\n```\nworkspace/skills/\n└── my-skill/\n    ├── SKILL.md          # Instructions (YAML frontmatter + markdown)\n    ├── references/       # On-demand documentation\n    ├── scripts/          # Executable code (30s timeout)\n    └── assets/           # Supporting files\n```\n\n- Progressive disclosure: only name + description in system prompt; full content loaded on demand\n`skill-extractor`\n\ncron proposes new skills from repeated workflows`skill-reviser`\n\ncron reviews existing skills for accuracy- Usage statistics tracked per skill\n\nProactive task planning with human-in-the-loop approval.\n\n- Planner cron picks open tasks autonomously\n- Agent explores codebase, researches approaches, proposes implementation plan\n- User reviews → approves / declines / requests revision\n- Approved plans spawn implementation sessions automatically\n\nRevisions happen in the same persistent planner session — full context preserved.\n\nAsync communication between agent and human, delivered to both web UI and Telegram.\n\n— Fire-and-forget alerts (status updates, completions, reminders)`notify`\n\n— Questions with predefined options, rendered as buttons`ask_user`\n\n- Priority levels:\n`urgent`\n\n,`high`\n\n,`normal`\n\n,`low`\n\n```\nnerve (single Python process)\n│\n├── Gateway (FastAPI)\n│   ├── REST API — sessions, tasks, memory, plans, sources, diagnostics\n│   ├── WebSocket — real-time streaming, answer routing\n│   └── Static files — serves the React web UI\n│\n├── Agent Engine (Claude Agent SDK)\n│   ├── ~30 custom MCP tools (tasks, memory, skills, sources, notifications)\n│   ├── Interactive mid-turn pausing (AskUserQuestion, plan approval)\n│   ├── File snapshot hooks → session-scoped diffs without git\n│   ├── Session lifecycle: created → active → idle → stopped → archived\n│   └── Up to 4 concurrent sessions (configurable)\n│\n├── Channels\n│   ├── Web — passive WebSocket channel\n│   └── Telegram — bot with streaming + inline keyboards\n│\n├── Cron (APScheduler)\n│   ├── AI jobs (isolated / persistent / main session modes)\n│   └── Source sync jobs (Telegram, Gmail, GitHub)\n│\n├── Memory\n│   ├── File-based hot memory (L1)\n│   └── memU semantic index (L2, SQLite + embeddings)\n│\n├── Tasks — Markdown + SQLite FTS5\n├── Skills — Filesystem + DB index + usage tracking\n├── Plans — SQLite with approval workflow\n├── Notifications — Multi-channel delivery\n└── Proxy (optional) — Claude OAuth, no API key needed\n```\n\nTwo config files:\n\n`config.yaml`\n\n— Template settings (committed)`config.local.yaml`\n\n— Secrets and overrides (gitignored)\n\nSee [docs/config.md](/ClickHouse/nerve/blob/main/docs/config.md) for all options.\n\n[Python](https://www.python.org/)3.13+[uv](https://docs.astral.sh/uv/)(recommended package manager)[Node.js](https://nodejs.org/)18+ (for web UI build)[Claude Code CLI](https://docs.anthropic.com/en/docs/agents-and-tools/claude-code/overview)(bundled with`claude-agent-sdk`\n\n)- Anthropic API key\n**or** Claude subscription via[CLIProxyAPI](https://github.com/router-for-me/CLIProxyAPI)proxy - Optional: OpenAI API key (for vector-based memory search — without it, LLM-based recall is used), Telegram bot token,\n[gog](https://github.com/googleworkspace/cli)CLI,[gh](https://cli.github.com/)CLI\n\n| Doc | Description |\n|---|---|\n|\n\n[Setup](/ClickHouse/nerve/blob/main/docs/setup.md)[Config](/ClickHouse/nerve/blob/main/docs/config.md)[Worker Guide](/ClickHouse/nerve/blob/main/docs/worker-guide.md)[API Reference](/ClickHouse/nerve/blob/main/docs/api.md)[SDK Sessions](/ClickHouse/nerve/blob/main/docs/sdk-sessions.md)[Sources](/ClickHouse/nerve/blob/main/docs/sources.md)[Tasks](/ClickHouse/nerve/blob/main/docs/tasks.md)[Memory](/ClickHouse/nerve/blob/main/docs/memory.md)[Cron](/ClickHouse/nerve/blob/main/docs/cron.md)[Plans](/ClickHouse/nerve/blob/main/docs/plans.md)[Web UI](/ClickHouse/nerve/blob/main/docs/web-ui.md)\n\n```\npytest tests/ -v\n```\n\nMIT", "url": "https://wpnews.pro/news/show-hn-nerve-self-hosted-runtime-for-ai-agents", "canonical_source": "https://github.com/ClickHouse/nerve", "published_at": "2026-05-25 22:46:43+00:00", "updated_at": "2026-05-25 23:07:28.036065+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "ai-infrastructure", "ai-products", "ai-startups"], "entities": ["Nerve", "Claude Agent SDK", "ClickHouse", "Anthropic"], "alternates": {"html": "https://wpnews.pro/news/show-hn-nerve-self-hosted-runtime-for-ai-agents", "markdown": "https://wpnews.pro/news/show-hn-nerve-self-hosted-runtime-for-ai-agents.md", "text": "https://wpnews.pro/news/show-hn-nerve-self-hosted-runtime-for-ai-agents.txt", "jsonld": "https://wpnews.pro/news/show-hn-nerve-self-hosted-runtime-for-ai-agents.jsonld"}}