### Quick Start Installation Source: https://github.com/clickhouse/nerve/blob/main/docs/setup.md This bash script provides the fastest way to get Nerve running by cloning the repository, installing dependencies, building the web UI, and initializing the setup wizard. ```bash git clone https://github.com/ClickHouse/nerve.git nerve cd nerve pip install -e . # or: uv pip install -e . cd web && npm install && npm run build && cd .. nerve init # Interactive wizard — handles everything nerve start ``` -------------------------------- ### Install Dependencies and Run Dev Server Source: https://github.com/clickhouse/nerve/blob/main/docs/web-ui.md Navigate to the web directory, install project dependencies using npm, and start the development server. The dev server proxies API and WebSocket requests to localhost:8900. ```bash cd web # Install dependencies npm install # Dev server (proxies to backend on :8900) npm run dev ``` -------------------------------- ### Initialize Nerve Setup Wizard Source: https://context7.com/clickhouse/nerve/llms.txt Run the first-time setup wizard for Nerve. ```bash nerve init ``` -------------------------------- ### Install Nerve with Curl Source: https://github.com/clickhouse/nerve/blob/main/README.md Use this command to download and execute the installation script for Nerve. The script handles dependency installation and launches an interactive setup wizard. ```bash curl -fsSL https://raw.githubusercontent.com/ClickHouse/nerve/main/install.sh | bash ``` -------------------------------- ### Server Installation (Bare Metal) Source: https://github.com/clickhouse/nerve/blob/main/docs/setup.md Steps for installing Nerve on a bare metal server, including creating a virtual environment and installing the project and its web UI. ```bash git clone https://github.com/ClickHouse/nerve.git nerve cd nerve # Create virtual environment uv venv source .venv/bin/activate # Install Nerve uv pip install -e . # Build web UI cd web && npm install && npm run build && cd .. # Run the setup wizard nerve init ``` -------------------------------- ### Manual Nerve Installation Steps Source: https://github.com/clickhouse/nerve/blob/main/README.md Follow these steps for a manual installation, which requires Git, Python 3.13+, uv, and Node.js 18+. This includes cloning the repository, setting up a virtual environment, installing dependencies, building the web UI, and initializing Nerve. ```bash git clone https://github.com/ClickHouse/nerve.git && cd nerve uv venv --python 3.13 && source .venv/bin/activate uv pip install -e . cd web && npm ci && npm run build && cd .. nerve init nerve start -f ``` -------------------------------- ### Structured TASK.md Example After Onboarding Source: https://github.com/clickhouse/nerve/blob/main/docs/worker-guide.md An example of the structured task description in TASK.md after the onboarding process. This format includes Mission, Scope, Triggers, Actions, Approval, and References. ```markdown # Task ## Mission Monitor CI pipelines for flaky test failures and propose targeted fixes. ## Scope - Repository: github.com/org/repo - CI system: GitHub Actions - Test framework: pytest ## Triggers - CI run fails with a test that passed on the previous commit - Same test fails >2 times in the last 7 days with different commits ## Actions 1. Identify the flaky test from CI logs 2. Check git blame and recent changes to the test and tested code 3. Reproduce locally if possible 4. Propose a fix via plan-approve workflow ## Approval - Bug fixes: propose plan, wait for approval - Test-only changes: propose plan, wait for approval - Infra changes: always escalate via notification ## References - CI dashboard: https://github.com/org/repo/actions - Test conventions: docs/testing.md ``` -------------------------------- ### Raw TASK.md Example Source: https://github.com/clickhouse/nerve/blob/main/docs/worker-guide.md An example of the raw task description in TASK.md before onboarding. This format is a plain English description of the worker's objective. ```markdown # Task Monitor the CI pipeline for flaky tests. When a test fails intermittently, investigate the root cause and propose a fix. ``` -------------------------------- ### Clone and Install Nerve Source: https://github.com/clickhouse/nerve/blob/main/docs/worker-guide.md Clone the Nerve repository, set up a virtual environment, and install the project dependencies. ```bash git clone https://github.com/ClickHouse/nerve.git nerve cd nerve uv venv && source .venv/bin/activate uv pip install -e . ``` -------------------------------- ### Docker Deployment Source: https://github.com/clickhouse/nerve/blob/main/docs/setup.md Instructions for deploying Nerve using Docker, which involves cloning the repository, installing a host dependency for the wizard, and initializing the setup. ```bash git clone https://github.com/ClickHouse/nerve.git nerve cd nerve pip install -e . # Needed to run the wizard on the host nerve init # Choose "docker" at the deployment step ``` -------------------------------- ### Installing Frontend Dependencies Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/skills/nerve-dev/SKILL.md Command to install frontend Node.js dependencies, typically run after changes to package.json. ```bash cd ~/nerve/web # Install dependencies (only if package.json changed) npm install ``` -------------------------------- ### Worker Mode Initialization and Start Source: https://context7.com/clickhouse/nerve/llms.txt Commands to initialize Nerve in worker mode, providing a task description during setup, and then starting the agent. The first boot triggers an onboarding process. ```bash # Initialize worker mode nerve init --mode worker # → Wizard asks for task description # → Agent onboards itself on first boot # Example task description during init: # "Monitor the CI pipeline for flaky tests. When a test fails intermittently, # investigate the root cause and propose a fix." # Start (first boot triggers onboarding) nerve start -f ``` -------------------------------- ### Task File Structure Example Source: https://github.com/clickhouse/nerve/blob/main/docs/tasks.md Illustrates the directory structure for active and completed tasks. ```text workspace/memory/tasks/ ├── active/ │ ├── 2026-02-25-fix-auth.md │ └── 2026-02-26-review-pr.md └── done/ └── 2026-02-20-setup-cron.md ``` -------------------------------- ### Non-interactive Docker Setup Source: https://github.com/clickhouse/nerve/blob/main/docs/setup.md This command initiates a non-interactive Docker setup for Nerve, suitable for CI/CD pipelines or automated deployments, by configuring environment variables and starting the service. ```bash cp .env.example .env # Edit .env with your ANTHROPIC_API_KEY (or set NERVE_USE_PROXY=1) docker compose up ``` -------------------------------- ### Install and Configure mkcert for HTTPS Source: https://github.com/clickhouse/nerve/blob/main/docs/setup.md This section covers installing mkcert and generating self-signed SSL certificates for local development. The generated certificates should be referenced in your `config.yaml`. ```bash sudo apt install libnss3-tools curl -L https://github.com/FiloSottile/mkcert/releases/download/v1.4.4/mkcert-v1.4.4-linux-arm64 -o mkcert chmod +x mkcert && sudo mv mkcert /usr/local/bin/ ``` ```bash mkdir -p ~/.nerve/certs mkcert -install mkcert -cert-file ~/.nerve/certs/cert.pem -key-file ~/.nerve/certs/key.pem \ localhost 127.0.0.1 "$(hostname)" "$(hostname).local" ``` -------------------------------- ### Manual Configuration Placeholder Source: https://github.com/clickhouse/nerve/blob/main/docs/setup.md This section indicates where manual configuration steps would be detailed, though the wizard handles most setup automatically. ```bash ``` -------------------------------- ### Cron Job Configuration Example Source: https://context7.com/clickhouse/nerve/llms.txt Example of defining scheduled AI sessions using YAML format for cron job configuration. ```yaml schedule: "*/5 * * * *" action: tool: "list_sources" args: consumer: "inbox" ``` -------------------------------- ### List Available Sources Source: https://github.com/clickhouse/nerve/blob/main/docs/sources.md Example of the `list_sources` agent tool, showing message counts and consumer cursor status for different sources. ```shell list_sources(consumer="inbox") → - github: 45 messages | consumer "inbox": 3 unread - gmail:user@example.com: 120 messages | consumer "inbox": 0 unread - telegram: 200 messages | consumer "inbox": 5 unread ``` -------------------------------- ### Docker Subsequent Starts and Logs Source: https://github.com/clickhouse/nerve/blob/main/docs/setup.md Common Docker Compose commands for managing the Nerve container, including starting, stopping, and viewing logs. ```bash docker compose up # Start docker compose up -d # Start in background docker compose down # Stop docker compose logs -f # Follow logs ``` -------------------------------- ### Get Plan Details Source: https://context7.com/clickhouse/nerve/llms.txt Retrieves the detailed content and metadata for a specific implementation plan. Requires the plan ID and an authorization token. ```bash curl http://localhost:8900/api/plans/plan-abc123 \ -H "Authorization: Bearer $TOKEN" ``` -------------------------------- ### Start Nerve Server in Daemon or Foreground Mode Source: https://context7.com/clickhouse/nerve/llms.txt Start the Nerve server. Use '-f' for foreground mode, which is useful for debugging. ```bash nerve start # Daemon mode (background) nerve start -f # Foreground mode (for debugging) ``` -------------------------------- ### Get Source Overview with Stats Source: https://context7.com/clickhouse/nerve/llms.txt Fetches an overview of all configured sources along with their message counts and last run times. ```bash curl http://localhost:8900/api/sources/overview \ -H "Authorization: Bearer $TOKEN" ``` -------------------------------- ### Interactive Tool Handler Example Source: https://github.com/clickhouse/nerve/blob/main/docs/architecture.md This example demonstrates the interactive tool handler which pauses the agent for tools needing user input. Answers are routed via WebSocket. ```python def can_use_tool(self, tool_name: str, tool_args: dict) -> bool: if tool_name in ("AskUserQuestion", "ExitPlanMode", "EnterPlanMode"): # Pause agent for user input return True # Auto-approve all other tools return False ``` -------------------------------- ### Start Nerve in Foreground Source: https://github.com/clickhouse/nerve/blob/main/docs/worker-guide.md Start the Nerve worker in the foreground. The first boot will trigger the onboarding process if not already completed. ```bash nerve start -f ``` -------------------------------- ### Ask User Tool Example Source: https://github.com/clickhouse/nerve/blob/main/docs/architecture.md This tool facilitates questions with predefined options or free-text input, supporting both blocking and asynchronous modes. ```python async def ask_user(session_id: str, question: str, options: list[str] | None = None, wait: bool = False): # Logic to ask the user a question and handle the response pass ``` -------------------------------- ### Initialize and Start Multiple Nerve Workers Source: https://github.com/clickhouse/nerve/blob/main/docs/worker-guide.md Deploy multiple workers by cloning the Nerve repository into separate directories and initializing each with the worker mode. Start each worker independently. ```bash cd ~/nerve-ci-monitor nerve init --mode worker nerve start ``` ```bash cd ~/nerve-pr-reviewer nerve init --mode worker nerve start ``` -------------------------------- ### Installing/Updating Backend Dependencies Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/skills/nerve-dev/SKILL.md Command to install or update backend Python dependencies after changes to pyproject.toml, using uv. ```bash cd ~/nerve # Install/update dependencies after pyproject.toml changes .venv/bin/uv pip install -e . ``` -------------------------------- ### Nerve Agent Configuration Example Source: https://github.com/clickhouse/nerve/blob/main/docs/sources.md Example configuration for Nerve agent sources in YAML format. Includes settings for message TTL, consumer cursor TTL, and specific configurations for Telegram, Gmail, GitHub, and GitHub Events. ```yaml sync: message_ttl_days: 7 # How long to keep inbox messages consumer_cursor_ttl_days: 2 # Consumer cursors expire after N days of inactivity telegram: enabled: true api_id: 12345678 # From my.telegram.org api_hash: "abc123..." # From my.telegram.org schedule: "*/5 * * * *" # Every 5 minutes batch_size: 50 # Max records per fetch condense: false exclude_chats: [] # Chat IDs to skip monitored_folders: [] # Telegram folder names to filter gmail: enabled: true accounts: # One source per account, each with own cursor - personal@gmail.com - work@company.com keyring_password: "..." # gog keyring password (in config.local.yaml) schedule: "*/15 * * * *" batch_size: 20 condense: true # Strip boilerplate + Haiku extraction for long emails github: enabled: true schedule: "*/15 * * * *" batch_size: 30 condense: true # Haiku extraction for long notifications github_events: enabled: true schedule: "*/15 * * * *" repos: [] # Empty = all repos. Example: ["owner/repo"] username: "" # Auto-detect from gh auth batch_size: 50 condense: false # Events are naturally short ``` -------------------------------- ### Task ID Generation Example Source: https://github.com/clickhouse/nerve/blob/main/docs/tasks.md Shows how a task ID is generated from the date and a slugified title. ```text 2026-02-25-fix-auth-token-expiry ``` -------------------------------- ### Get Skill Instructions Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/personal/AGENTS.md Use `skill_get` to load detailed instructions for a specific skill. This provides information on how to use the skill and its parameters. ```python skill_get(skill_name="web_search") ``` -------------------------------- ### Nerve Template Configuration File Source: https://context7.com/clickhouse/nerve/llms.txt Example of the main `config.yaml` file for template settings, including workspace, timezone, agent models, gateway, and sync schedules. ```yaml # config.yaml — Template settings (committed to repo) workspace: ~/nerve-workspace timezone: America/New_York agent: model: claude-opus-4-7 # Primary model for conversations cron_model: claude-sonnet-4-6 # Cheaper model for cron jobs max_turns: 50 max_concurrent: 4 gateway: host: 0.0.0.0 port: 8900 ssl: cert: ~/.nerve/certs/cert.pem key: ~/.nerve/certs/key.pem telegram: enabled: true dm_policy: pairing # "open" or "pairing" sync: telegram: enabled: true schedule: "*/5 * * * *" gmail: enabled: true schedule: "*/15 * * * *" github: enabled: true schedule: "*/15 * * * *" memory: chat_model: claude-sonnet-4-6 categories: - name: work description: "Work projects, PRs, reviews" - name: personal description: "Personal tasks, finances" ``` -------------------------------- ### Markdown Task File Format Example Source: https://github.com/clickhouse/nerve/blob/main/docs/tasks.md Defines the structure and metadata for a task markdown file. ```markdown # Fix Auth Token Expiry **Source:** https://github.com/... **Deadline:** 2026-02-28 Context and details here... ## Updates - 2026-02-25: Created - 2026-02-26: Started investigation - 2026-02-27: DONE — Fixed in PR #123 ``` -------------------------------- ### CLI Command Example Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/worker/TOOLS.md The 'gh pr list' command defaults to returning a maximum of 30 items. Use the --limit flag to retrieve more. ```bash gh pr list --limit 100 ``` -------------------------------- ### Diff Computation Example Source: https://github.com/clickhouse/nerve/blob/main/docs/architecture.md Computes structured unified diffs using difflib from stored snapshots versus the current file content. ```python import difflib def compute_diff(original_content: str, current_content: str, fromfile='a', tofile='b'): return list(difflib.unified_diff( original_content.splitlines(keepends=True), current_content.splitlines(keepends=True), fromfile=fromfile, tofile=tofile, )) ``` -------------------------------- ### Nerve Local Configuration File for Secrets Source: https://context7.com/clickhouse/nerve/llms.txt Example of the `config.local.yaml` file for secrets and overrides, which should be gitignored. Includes API keys and authentication details. ```yaml # config.local.yaml — Secrets and overrides (gitignored) anthropic_api_key: sk-ant-... openai_api_key: sk-... # Optional: enables vector embeddings telegram: bot_token: "123456:ABC..." auth: password_hash: "$2b$12$.." jwt_secret: "your-secret-here" ``` -------------------------------- ### Upgrade Nerve Installation Source: https://context7.com/clickhouse/nerve/llms.txt Perform an upgrade of the Nerve installation, including fetching the latest code, installing dependencies, and rebuilding the frontend. ```bash nerve upgrade # Git pull, install deps, rebuild frontend ``` -------------------------------- ### Building Frontend for Production Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/skills/nerve-dev/SKILL.md Command to build the frontend for production, including TypeScript checks and Vite bundling. ```bash cd ~/nerve/web # Build for production (TypeScript check + Vite bundle → dist/) npm run build ``` -------------------------------- ### Create a New Task Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/personal/AGENTS.md Use `task_create` to initiate a new task. Provide a title and description for the task. ```python task_create(title="Refactor authentication module", description="Improve security and performance.") ``` -------------------------------- ### Clone and Set Up Nerve Repository Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/skills/nerve-dev/SKILL.md Steps to clone the Nerve repository, add the upstream remote, and set up Python and frontend environments. Ensure you have Python 3 and npm installed. ```bash # 1. Fork on GitHub, then clone your fork git clone git@github.com:/nerve.git cd nerve # 2. Add upstream remote git remote add upstream git@github.com:ClickHouse/nerve.git # 3. Set up Python environment python3 -m venv .venv source .venv/bin/activate pip install -e . # 4. Set up frontend cd web && npm install && cd .. # 5. Verify .venv/bin/pytest tests/ -v cd web && npm run build ``` -------------------------------- ### Build Production Bundle Source: https://github.com/clickhouse/nerve/blob/main/docs/web-ui.md Build the production-ready bundle for the web application. The output is placed in the web/dist/ directory, which is automatically served by the FastAPI backend. ```bash cd web && npx vite build ``` -------------------------------- ### Worker Task Description Example Source: https://context7.com/clickhouse/nerve/llms.txt An example Markdown file defining the mission, scope, triggers, and actions for a Nerve agent operating in worker mode. This file is generated after the agent's onboarding. ```markdown # Task ## Mission Monitor CI pipelines for flaky test failures and propose targeted fixes. ## Scope - Repository: github.com/org/repo - CI system: GitHub Actions - Test framework: pytest ## Triggers - CI run fails with a test that passed on the previous commit - Same test fails >2 times in the last 7 days ## Actions 1. Identify the flaky test from CI logs 2. Check git blame and recent changes 3. Reproduce locally if possible 4. Propose a fix via plan-approve workflow ## Approval - Bug fixes: propose plan, wait for approval - Infra changes: always escalate via notification ``` -------------------------------- ### Create a New Task Source: https://context7.com/clickhouse/nerve/llms.txt Creates a new task with a title, content, deadline, and optional source URL. Requires an authorization token. ```bash curl -X POST http://localhost:8900/api/tasks \ -H "Authorization: Bearer $TOKEN" \ -H "Content-Type: application/json" \ -d '{ "title": "Review PR #123", "content": "Review the authentication changes in PR #123", "deadline": "2026-03-15", "source_url": "https://github.com/org/repo/pull/123" }' ``` -------------------------------- ### Get Plans for Task Source: https://github.com/clickhouse/nerve/blob/main/docs/plans.md Retrieves all plans associated with a specific task. ```APIDOC ## GET /api/tasks/:id/plans ### Description Retrieves a list of all plans associated with a specific task. ### Method GET ### Endpoint /api/tasks/:id/plans ### Path Parameters - **id** (string) - Required - The unique identifier of the task. ``` -------------------------------- ### Initialize Theme from Local Storage Source: https://github.com/clickhouse/nerve/blob/main/web/index.html This script initializes the theme of the application by checking local storage for a saved theme preference ('light' or 'dark') and applying it to the document's root element. It runs immediately upon loading. ```javascript Nerve (function() { var p = localStorage.getItem('nerve-theme'); if (p === 'light' || p === 'dark') { document.documentElement.setAttribute('data-theme', p); } })(); ``` -------------------------------- ### Get Plan Detail Source: https://github.com/clickhouse/nerve/blob/main/docs/plans.md Retrieves the details of a specific plan by its ID. ```APIDOC ## GET /api/plans/:id ### Description Retrieves the detailed information for a specific plan. ### Method GET ### Endpoint /api/plans/:id ### Path Parameters - **id** (string) - Required - The unique identifier of the plan. ``` -------------------------------- ### Create a New Source Adapter Source: https://github.com/clickhouse/nerve/blob/main/docs/sources.md Implement a new data source by creating an adapter class inheriting from `nerve.sources.base.Source`. The `fetch` method is crucial for retrieving data, and `preprocess` can be used for data cleanup. ```python from nerve.sources.base import Source from nerve.sources.models import FetchResult, SourceRecord class MySource(Source): source_name = "mysource" def __init__(self, config: dict): self._config = config async def fetch(self, cursor: str | None, limit: int = 100) -> FetchResult: # Fetch records from your service # cursor is opaque — you define the semantics (timestamp, ID, page token, etc.) records = [] next_cursor = cursor # ... fetch logic here ... # Build SourceRecord objects: # SourceRecord(id, source, record_type, summary, content, timestamp, metadata) return FetchResult( records=records, next_cursor=next_cursor, has_more=False, ) async def preprocess(self, records: list[SourceRecord]) -> list[SourceRecord]: # Optional: source-specific content cleanup before storage. # Default (inherited from Source): returns records unchanged. return records async def close(self) -> None: # Optional cleanup (disconnect clients, etc.) pass ``` -------------------------------- ### Notify Tool Example Source: https://github.com/clickhouse/nerve/blob/main/docs/architecture.md This tool is used for fire-and-forget notifications, such as status updates, alerts, and reminders. ```python async def notify(session_id: str, message: str): # Logic to send a notification pass ``` -------------------------------- ### Task Search FTS5 Query Example Source: https://github.com/clickhouse/nerve/blob/main/docs/tasks.md Demonstrates the AND semantics used in `task_search` for precise matching. ```text Note: `task_search` (user-facing) uses strict AND matching for precision. Duplicate detection (internal) uses fuzzy OR matching for recall — these are intentionally different trade-offs. ``` -------------------------------- ### Approve Plan and Spawn Implementation Session Source: https://context7.com/clickhouse/nerve/llms.txt Approves a specific implementation plan and initiates a new session for its implementation. Requires the plan ID and an authorization token. ```bash curl -X POST http://localhost:8900/api/plans/plan-abc123/approve \ -H "Authorization: Bearer $TOKEN" ``` -------------------------------- ### Task Planner Workflow Source: https://github.com/clickhouse/nerve/blob/main/docs/plans.md Illustrates the workflow of the proactive task planner, from cron job triggering to user review and plan execution. ```text Cron (every 4h) → persistent "task-planner" job → agent browses tasks, checks memory, picks one worth planning → explores codebase with Read, Glob, Grep, Bash, etc. → calls plan_propose(task_id, content) to store the proposal → plan appears in /plans UI for review User reviews (via /plans UI or chat tools) → approve → spawns implementation session (visible in Chat) → decline → marks plan declined → request revision → sends feedback to same persistent planner session ``` -------------------------------- ### Manage Skills with Skill Tools Source: https://context7.com/clickhouse/nerve/llms.txt Use these tools to load, read, run, create, and update skills. Ensure the skill name and path are correct for operations. ```python skill_get(name="deploy-app") ``` ```python skill_read_reference(name="deploy-app", path="deployment-checklist.md") ``` ```python skill_run_script(name="deploy-app", path="pre-deploy-check.sh", args="--env staging") ``` ```python skill_create( name="database-migration", description="This skill should be used when running database migrations...", content="## Steps\n1. Create backup\n2. Run migration script\n3. Verify data..." ) ``` ```python skill_update( name="database-migration", content="---\nname: database-migration\ndescription: ...\n---\n\n# Updated Instructions..." ) ``` -------------------------------- ### OpenClaw Cron Job JSON Format Source: https://github.com/clickhouse/nerve/blob/main/docs/migration.md Example of a cron job configuration in the legacy OpenClaw JSON format. ```json { "id": "morning-telegram", "cron": "30 11 * * *", "payload": "...", "model": "claude-sonnet-4-6" } ``` -------------------------------- ### List Configured Sync Sources Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/personal/AGENTS.md Use `list_sources` to check the status and configuration of integrated external services. This helps in understanding which sources are active and healthy. ```python list_sources() ``` -------------------------------- ### Nerve API Health Check Endpoint Source: https://context7.com/clickhouse/nerve/llms.txt Example of a health check request to the Nerve API. This endpoint does not require authentication. ```bash # Health check (no auth required) curl http://localhost:8900/health # Response: {"status": "ok", "version": "0.1.0"} ``` -------------------------------- ### Get System Diagnostics Source: https://context7.com/clickhouse/nerve/llms.txt Retrieves system-level diagnostic information, including memory usage, disk space, and task statuses. ```bash curl http://localhost:8900/api/diagnostics \ -H "Authorization: Bearer $TOKEN" ``` -------------------------------- ### List Pending Plans Source: https://context7.com/clickhouse/nerve/llms.txt Retrieves a list of implementation plans that are currently in a pending state. Requires an authorization token. ```bash curl "http://localhost:8900/api/plans?status=pending" \ -H "Authorization: Bearer $TOKEN" ``` -------------------------------- ### Get memU Semantic Memory API Response Source: https://github.com/clickhouse/nerve/blob/main/docs/api.md Response structure for retrieving memU categories, items, and indexed resources. ```json Response: { "available": true, "categories": [{ "id": "...", "name": "preferences", "description": "...", "summary": "..." }], "items": [{ "id": "...", "memory_type": "profile", "summary": "User works at Acme Corp", "resource_id": "...", "created_at": "...", "happened_at": "..." }], "resources": [{ "id": "...", "url": "/path/to/file.md", "modality": "document", "caption": "...", "created_at": "..." }], "category_items": { "category_id": ["item_id_1", "item_id_2"] } } ``` -------------------------------- ### Get Task Details API Response Source: https://github.com/clickhouse/nerve/blob/main/docs/api.md Response structure for retrieving task details, including its full markdown content. ```json Response: { "id": "2026-03-01-fix-bug", "title": "Fix bug", "status": "pending", "content": "# Fix bug\n\n...", ... } ``` -------------------------------- ### Update Task API Request Source: https://github.com/clickhouse/nerve/blob/main/docs/api.md Examples of request payloads for updating a task. Fields like status, note, and content are optional. ```json Request: { "status": "done", "note": "Fixed in PR #123" } ``` ```json Request: { "content": "# Updated Title\n\n**Deadline:** 2026-03-15\n\nNew details..." } ``` -------------------------------- ### Propose an Implementation Plan Source: https://github.com/clickhouse/nerve/blob/main/nerve/templates/personal/AGENTS.md Use `plan_propose` to submit an implementation plan for asynchronous approval. This is used for outlining steps for autonomous work or background tasks. ```python plan_propose(plan_description="Automate daily report generation.", steps=["Fetch data", "Generate report", "Send notification"]) ``` -------------------------------- ### Agent Task Tools Overview Source: https://github.com/clickhouse/nerve/blob/main/docs/tasks.md Lists the available agent tools for managing tasks, including their purpose. ```text | Tool | |------|-------------| | `task_create` | Create task with duplicate detection (writes .md + inserts SQLite row) | | `task_search` | Full-text search on title + content (FTS5) | | `task_list` | List tasks with status filter (queries SQLite) | | `task_update` | Update status/deadline/notes (updates both) | | `task_read` | Read full task content | | `task_done` | Mark complete, move to `done/` | ``` -------------------------------- ### Get Source Run History Source: https://context7.com/clickhouse/nerve/llms.txt Retrieves the history of synchronization runs for all sources, including timestamps, records fetched, and any errors encountered. ```bash curl http://localhost:8900/api/sources/runs \ -H "Authorization: Bearer $TOKEN" ```