{
  "markdown": "# Task Graph MCP Server\n\n**Agent task workflows that actually work.**\n\nWhen you have AI agents working on complex tasks, things go wrong fast. Agents lose context, skip steps, forget to coordinate. Task Graph solves this with structured workflows: phases to guide work, prompts for automatic guidance, gates to enforce quality, and coordination primitives for multi-agent scenarios—all through the Model Context Protocol.\n\n## Why Task Graph?\n\n**The problem**: You've got complex tasks that need structured execution. Maybe a single agent working through phases, or multiple agents coordinating in parallel. Without proper workflows, agents lose track, skip steps, and produce inconsistent results.\n\n**What you get**:\n\n- **Structured workflows** — Phases (explore, implement, review, test) guide agents through work. Transition prompts provide automatic guidance at each step.\n- **Quality gates** — Require tests to pass, code to be committed, or reviews to complete before transitions. Enforce your standards automatically.\n- **Ready-to-use topologies** — Pre-built workflows for solo work, parallel swarms, specialist relays, or hierarchical delegation. Start immediately, customize later.\n- **Configurable workflows** — Define your own states, phases, prompts, and gates. Match your process, not ours.\n- **Multi-agent coordination** — Advisory file locks, DAG dependencies, atomic claiming. No more conflicts or duplicate work.\n- **Token-efficient** — Designed for LLM context limits. Compact queries, minimal round-trips, structured outputs.\n- **Built-in accounting** — Track tokens, cost, and time per task. Know exactly what your agents are spending.\n- **Zero infrastructure** — SQLite with WAL mode. No database server to run. Just point at a file.\n\n## Features\n\n| Feature | Description |\n|---------|-------------|\n| **Task Hierarchy** | Unlimited nesting with parent/child relationships |\n| **DAG Dependencies** | Typed edges (blocks, follows, contains) with cycle detection |\n| **Phases** | Categorize work type (explore, implement, review, test, deploy) |\n| **Workflows** | Named workflow topologies (solo, swarm, relay, hierarchical) |\n| **Transition Prompts** | Automatic agent guidance on status/phase changes |\n| **Gates** | Exit requirements for status/phase transitions |\n| **Atomic Claiming** | Strict locking with limits and tag-based routing |\n| **File Coordination** | Advisory locks with reasons and change polling |\n| **Cost Tracking** | Token usage and USD cost per task |\n| **Time Tracking** | Automatic accumulation from state transitions |\n| **Live Status** | Real-time \"current thought\" visible to other agents |\n| **Full-text Search** | FTS5-powered search across tasks and attachments |\n| **Attachments** | Inline content, file references, or media storage |\n| **Agent Feedback** | Inter-agent communication with categorized feedback (conditional on config) |\n| **Dynamic Overlays** | Runtime workflow customization via add/remove overlay tools |\n\n## Quick Start\n\n```bash\n# Install\ncargo install task-graph-mcp\n\n# Add to your MCP client (Claude Code, etc.)\n```\n\n```json\n{\n  \"mcpServers\": {\n    \"task-graph\": {\n      \"command\": \"task-graph-mcp\"\n    }\n  }\n}\n```\n\n```\n# Agent workflow (worker_id auto-generated if omitted)\nconnect(workflow=\"swarm\", tags=[\"code\"])                 → \"bright-lunar-swift-fox\"\nlist_tasks(ready=true, agent=\"bright-lunar-swift-fox\")   → claimable work\nclaim(worker_id=\"bright-lunar-swift-fox\", task=\"add-auth\")  → you own it\nupdate(..., phase=\"implement\")                           → enter implementation phase\nthinking(agent=\"bright-lunar-swift-fox\", thought=\"Adding JWT...\")  → visible to others\nupdate(worker_id=\"bright-lunar-swift-fox\", task=\"add-auth\",\n       status=\"completed\",\n       attachments=[{type:\"commit\", content:\"abc123\"}])  → done\n```\n\n## Installation\n\n### From crates.io (Recommended)\n\n```bash\ncargo install task-graph-mcp\n```\n\n### Pre-built Binaries\n\nDownload the latest release for your platform from [GitHub Releases](https://github.com/Oortonaut/task-graph-mcp/releases):\n\n| Platform | Download |\n|----------|----------|\n| Linux (x64) | `task-graph-mcp-x86_64-unknown-linux-gnu.tar.gz` |\n| macOS (Intel) | `task-graph-mcp-x86_64-apple-darwin.tar.gz` |\n| macOS (Apple Silicon) | `task-graph-mcp-aarch64-apple-darwin.tar.gz` |\n| Windows (x64) | `task-graph-mcp-x86_64-pc-windows-msvc.zip` |\n\nExtract and place the binary in your PATH.\n\n### From Source\n\n```bash\ngit clone https://github.com/Oortonaut/task-graph-mcp.git\ncd task-graph-mcp\ncargo build --release\n```\n\nThe binary will be at `target/release/task-graph-mcp`.\n\n## Usage\n\n### As an MCP Server\n\nAdd to your MCP client configuration:\n\n```json\n{\n  \"mcpServers\": {\n    \"task-graph\": {\n      \"command\": \"task-graph-mcp\",\n      \"args\": []\n    }\n  }\n}\n```\n\n### CLI Options\n\n```\ntask-graph-mcp [OPTIONS]\n\nOptions:\n  -c, --config <FILE>     Path to configuration file\n  -d, --database <FILE>   Path to database file (overrides config)\n  -v, --verbose           Enable verbose logging\n  -h, --help              Print help\n  -V, --version           Print version\n```\n\n## Configuration\n\n> **Full reference**: See [docs/CONFIGURATION.md](docs/CONFIGURATION.md) for complete configuration documentation including workflows, prompts, gates, roles, and tags.\n\nCreate `.task-graph/config.yaml`:\n\n```yaml\nserver:\n  db_path: .task-graph/tasks.db\n  media_dir: .task-graph/media  # Directory for file attachments\n  skills_dir: .task-graph/skills  # Custom skill overrides\n  stale_timeout_seconds: 900\n  default_format: json  # or markdown\n\npaths:\n  style: relative  # or project_prefixed\n\nauto_advance:\n  enabled: false        # Auto-transition unblocked tasks\n  target_state: ready   # Target state (requires custom state in states config)\n```\n\n### States Configuration\n\nTask states are configurable. Default states: `pending`, `working`, `completed`, `failed`, `cancelled`.\n\nTo add a `ready` state for auto-advance:\n\n```yaml\nstates:\n  initial: pending\n  disconnect_state: pending  # State for tasks when owner disconnects (must be untimed)\n  blocking_states: [pending, working]\n  definitions:\n    pending:\n      exits: [ready, working, cancelled]\n    ready:\n      exits: [working, cancelled]\n    working:\n      exits: [completed, failed, pending]\n      timed: true    # Time in this state counts toward time_actual_ms\n    completed:\n      exits: []\n    failed:\n      exits: [pending]\n    cancelled:\n      exits: []\n\nauto_advance:\n  enabled: true\n  target_state: ready\n```\n\nSee [SCHEMA.md](SCHEMA.md#states-configuration) for full documentation on state definitions.\n\n### Dependencies Configuration\n\nDependency types define how tasks relate to each other. Default types: `blocks`, `follows`, `contains`, `duplicate`, `see-also`, `relates-to`.\n\n```yaml\ndependencies:\n  definitions:\n    blocks:\n      display: horizontal  # Same-level relationship\n      blocks: start        # Blocks claiming the dependent task\n    follows:\n      display: horizontal\n      blocks: start\n    contains:\n      display: vertical    # Parent-child relationship\n      blocks: completion   # Blocks completing the parent\n    duplicate:\n      display: horizontal\n      blocks: none         # Informational only\n    see-also:\n      display: horizontal\n      blocks: none\n    relates-to:\n      display: horizontal\n      blocks: none\n```\n\n| Property | Values | Description |\n|----------|--------|-------------|\n| `display` | `horizontal`, `vertical` | Visual relationship (same-level vs parent-child) |\n| `blocks` | `none`, `start`, `completion` | What the dependency blocks |\n\n### Attachments Configuration\n\nPreconfigured attachment keys provide default MIME types and modes, reducing boilerplate when attaching common content types.\n\n```yaml\nattachments:\n  unknown_key: warn  # allow | warn (default) | reject\n  definitions:\n    commit:\n      mime: text/git.hash\n      mode: append\n    checkin:\n      mime: text/p4.changelist\n      mode: append\n    meta:\n      mime: application/json\n      mode: replace\n    note:\n      mime: text/plain\n      mode: append\n```\n\n| Property | Values | Description |\n|----------|--------|-------------|\n| `unknown_key` | `allow`, `warn`, `reject` | Behavior for undefined attachment keys |\n| `definitions.<key>.mime` | MIME type string | Default MIME type for this key |\n| `definitions.<key>.mode` | `append`, `replace` | Default mode (append keeps existing, replace overwrites) |\n\n**Built-in defaults**:\n\n| Key | MIME Type | Mode | Use Case |\n|-----|-----------|------|----------|\n| `commit` | text/git.hash | append | Git commit hashes |\n| `checkin` | text/p4.changelist | append | Perforce changelists |\n| `changelist` | text/plain | append | Files changed |\n| `meta` | application/json | replace | Structured metadata |\n| `note` | text/plain | append | General notes |\n| `log` | text/plain | append | Log output |\n| `error` | text/plain | append | Error messages |\n| `output` | text/plain | append | Command/tool output |\n| `diff` | text/x-diff | append | Patches and diffs |\n| `plan` | text/markdown | replace | Plans and specs |\n| `result` | application/json | replace | Structured results |\n| `context` | text/plain | replace | Current context/state |\n\n**Usage**:\n```\n# MIME and mode auto-filled from config:\nattach(task=\"123\", name=\"commit\", content=\"abc1234\")\n# → mime=text/git.hash, mode=append\n\nattach(task=\"123\", name=\"meta\", content='{\"v\":1}')\n# → mime=application/json, mode=replace (overwrites existing meta)\n\n# Explicit values override defaults:\nattach(task=\"123\", name=\"commit\", mime=\"text/plain\", content=\"override\")\n```\n\nEnvironment variables:\n- `TASK_GRAPH_CONFIG_PATH`: Path to configuration file (takes precedence over `.task-graph/config.yaml`)\n- `TASK_GRAPH_DB_PATH`: Database file path (fallback if no config file)\n- `TASK_GRAPH_MEDIA_DIR`: Media directory for file attachments (fallback if no config file)\n- `TASK_GRAPH_LOG_DIR`: Log directory path (fallback if no config file)\n\n## MCP Tools\n\n### Worker Management\n\n| Tool | Description |\n|------|-------------|\n| `connect(worker_id?, tags?, workflow?, force?, db_path?, media_dir?, log_dir?, config_path?, overlays?: str[])` | Register a worker. Optional `workflow` selects named workflow (solo, swarm, relay, hierarchical). Returns `worker_id` and active `paths`. |\n| `disconnect(worker_id: worker_str, final_status?: status_str = \"pending\")` | Unregister worker and release all claims/locks. |\n| `list_agents(tags?: str[], file?: filename, task?: task_str, depth?: int, stale_timeout?: int)` | List connected workers with filters. |\n| `cleanup_stale(timeout?: int, final_status?: status_str)` | Evict stale workers and release their claims. |\n| `add_overlay(worker_id: str, overlay: str)` | Add a dynamic workflow overlay to a connected worker. |\n| `remove_overlay(worker_id: str, overlay: str)` | Remove a workflow overlay from a connected worker. |\n\n### Task CRUD\n\n| Tool | Description |\n|------|-------------|\n| `create(description: str, id?: task_str, parent?: task_str, priority?: int = 5, points?: int, time_estimate_ms?: int, tags?: str[])` | Create a task. Priority 0-10 (higher = more important). |\n| `create_tree(tree, parent?, child_type?, sibling_type?)` | Create nested task tree. `child_type` (default: \"contains\") for parent→child deps, `sibling_type` for sibling deps. |\n| `get(task: task_str)` | Get task by ID with attachment metadata and counts. |\n| `list_tasks(status?: status_str[], ready?: bool, blocked?: bool, claimed?: bool, owner?: worker_str, parent?: task_str, recursive?: bool, agent?: worker_str, tags_any?: str[], tags_all?: str[], sort_by?: str, sort_order?: str, limit?: int, offset?: int)` | Query tasks with filters. Use `ready=true` for claimable tasks. |\n| `update(worker_id: worker_str, task: task_str, status?: status_str, phase?: str, assignee?: worker_str, title?: str, description?: str, priority?: int, points?: int, tags?: str[], needed_tags?: str[], wanted_tags?: str[], time_estimate_ms?: int, reason?: str, force?: bool, attachments?: object[])` | Update task. Status/phase changes auto-manage ownership and trigger prompts. Include `attachments` to record commits/changelists. |\n| `delete(worker_id: worker_str, task: task_str, cascade?: bool, reason?: str, obliterate?: bool, force?: bool)` | Delete task. Soft delete by default; `obliterate=true` for permanent. |\n| `scan(task: task_str, before?: int, after?: int, above?: int, below?: int)` | Scan task graph in multiple directions. Depth: 0=none, N=levels, -1=all. |\n| `search(query: str, limit?: int = 20, include_attachments?: bool, status_filter?: status_str)` | FTS5 search. Supports phrases, prefix*, AND/OR/NOT, title:word. |\n| `rename(worker_id: worker_str, task: task_str, new_id: task_str)` | Atomically rename a task ID across all referencing tables. |\n\n### Task Claiming\n\n| Tool | Description |\n|------|-------------|\n| `claim(worker_id: worker_str, task: task_str, force?: bool)` | Claim a task. Fails if deps unsatisfied, at limit, or lacks tags. Use `force` to steal. |\n\n**Note**: Release via `update(status=\"pending\")`. Complete via `update(status=\"completed\")`. Status changes auto-manage ownership.\n\n### Dependencies\n\n| Tool | Description |\n|------|-------------|\n| `link(from: task_str\\|task_str[], to: task_str\\|task_str[], type?: dep_str = \"blocks\")` | Create dependencies. Types: blocks, follows, contains, duplicate, see-also, relates-to. |\n| `unlink(from: task_str\\|\"*\", to: task_str\\|\"*\", type?: dep_str)` | Remove dependencies. Use `*` as wildcard. |\n| `relink(prev_from: task_str[], prev_to: task_str[], from: task_str[], to: task_str[], type?: dep_str = \"contains\")` | Atomically move dependencies (unlink then link). |\n\n### Tracking\n\n| Tool | Description |\n|------|-------------|\n| `thinking(worker_id: worker_str, thought: str, tasks?: task_str[])` | Broadcast live status. Visible to other workers. Refreshes heartbeat. |\n| `task_history(task: task_str, states?: status_str[])` | Get status transition history with time tracking. |\n| `project_history(from?: datetime_str, to?: datetime_str, states?: status_str[], limit?: int = 100)` | Project-wide history with date range filters. |\n| `log_metrics(worker_id: worker_str, task: task_str, cost_usd?: float, values?: int[8])` | Log metrics (aggregated). |\n| `get_metrics(task: task_str\\|task_str[])` | Get metrics for task(s). |\n| `give_feedback(message: str, category?: str, sentiment?: str, agent_id?: str, tool_name?: str, task_id?: str)` | Record feedback about tools, workflows, or UX. Enabled by default; rejects writes past size limit (default: 1MB). |\n| `list_feedback()` | Read the feedback markdown file. |\n\n### File Coordination\n\n| Tool | Description |\n|------|-------------|\n| `mark_file(worker_id: worker_str, file: filename\\|filename[], task?: task_str, reason?: str)` | Mark file(s) to signal intent. Advisory, non-blocking. |\n| `unmark_file(worker_id: worker_str, file?: filename\\|filename[]\\|\"*\", task?: task_str, reason?: str)` | Remove marks. Use `*` for all. |\n| `list_marks(files?: filename[], worker_id?: worker_str, task?: task_str)` | Get current file marks. |\n| `mark_updates(worker_id: worker_str)` | Poll for mark changes since last call. |\n\n### Attachments\n\n| Tool | Description |\n|------|-------------|\n| `attach(task: task_str\\|task_str[], name: str, content?: str, mime?: mime_str, file?: filename, store_as_file?: bool, mode?: str)` | Add attachment. Use `file` for reference, `store_as_file` for media storage. |\n| `attachments(task: task_str, name?: str, mime?: mime_str)` | Get attachment metadata. Glob patterns supported for name. |\n| `detach(worker_id: worker_str, task: task_str, name: str, delete_file?: bool)` | Delete attachment by name. |\n\n### Advanced\n\n| Tool | Description |\n|------|-------------|\n| `check_gates(task: task_str)` | Check gate requirements before status/phase transition. Returns unsatisfied gates with pass/warn/fail status. |\n| `get_advisory(topic?: str, task?: task_str, worker_id?: worker_str)` | Get governance advisory guidance. Without topic: lists all topics. With topic: returns full advisory content with template expansion. |\n| `query(sql: str, params?: str[], limit?: int = 100, format?: str)` | Execute read-only SQL. SELECT only. Requires permission. |\n| `get_schema(table?: str, include_sql?: bool)` | Get database schema. Returns table names, columns, types, and foreign keys. |\n| `get_prompts(status?: str, phase?: str, task?: task_str, worker_id?: worker_str)` | Get workflow prompts. Without params: lists triggers. With status/phase: returns expanded prompts for that transition. |\n| `list_workflows()` | List available workflow configurations (solo, swarm, relay, hierarchical, etc.). |\n| `list_skills()` | List available bundled skills with descriptions. |\n| `get_skill(name: str)` | Get full content of a bundled skill. |\n\n## MCP Resources\n\n| URI | Description |\n|-----|-------------|\n| `query://tasks/all` | Full task graph with dependencies |\n| `query://tasks/ready` | Tasks ready to claim |\n| `query://tasks/blocked` | Tasks blocked by dependencies |\n| `query://tasks/claimed` | All claimed tasks |\n| `query://tasks/agent/{id}` | Tasks owned by an agent |\n| `query://tasks/tree/{id}` | Task with all descendants |\n| `query://files/marks` | All file marks |\n| `query://agents/all` | Registered agents |\n| `query://stats/summary` | Aggregate statistics |\n| `config://current` | All configuration in one response |\n| `config://states` | Task state definitions |\n| `config://phases` | Phase definitions |\n| `config://dependencies` | Dependency type definitions |\n| `config://tags` | Tag definitions |\n| `docs://index` | List all available documentation files |\n| `docs://search/{query}` | Full-text search across documentation |\n| `docs://skills/list` | List available skills |\n| `docs://skills/{name}` | Get specific skill content |\n| `docs://workflows/list` | List available workflows |\n| `docs://workflows/{name}` | Get workflow details |\n| `docs://overlays/list` | List available overlays |\n| `docs://overlays/{name}` | Get overlay details |\n| `docs://{path}` | Specific documentation file content |\n\n## Task Tree Structure\n\nCreate hierarchical tasks with `create_tree`:\n\n```json\n{\n  \"tree\": {\n    \"title\": \"Implement auth\",\n    \"children\": [\n      { \"title\": \"Design schema\" },\n      { \"title\": \"Write migrations\" },\n      { \"title\": \"Implement endpoints\", \"children\": [\n        { \"title\": \"Login endpoint\" },\n        { \"title\": \"Logout endpoint\" },\n        { \"title\": \"Refresh endpoint\" }\n      ]},\n      { \"title\": \"Write tests\" }\n    ]\n  },\n  \"sibling_type\": \"follows\"\n}\n```\n\n### Tree Node Fields\n\n| Field | Description |\n|-------|-------------|\n| `title` | Task title (required for new tasks) |\n| `description` | Task description |\n| `id` | Custom task ID (UUID7 generated if omitted) |\n| `ref` | Reference existing task by ID (other fields ignored when set) |\n| `priority` | Priority 0-10 (default 5) |\n| `points` | Story points / complexity estimate |\n| `time_estimate_ms` | Estimated duration in milliseconds |\n| `tags` | Categorization tags for the task |\n| `needed_tags` | Agent must have ALL of these tags to claim (AND) |\n| `wanted_tags` | Agent must have AT LEAST ONE of these tags to claim (OR) |\n| `children` | Nested child nodes |\n\n### Top-Level Parameters\n\n| Parameter | Default | Description |\n|-----------|---------|-------------|\n| `tree` | required | Root node of the task tree |\n| `parent` | null | Attach tree root to existing parent task |\n| `child_type` | \"contains\" | Dependency type from parent to children |\n| `sibling_type` | null | Dependency type between siblings (\"follows\" for sequential, null for parallel) |\n\n### Referencing Existing Tasks\n\nUse `ref` to integrate existing tasks into a tree structure:\n\n```json\n{\n  \"tree\": {\n    \"title\": \"Sprint 5\",\n    \"children\": [\n      { \"title\": \"New feature\" },\n      { \"ref\": \"existing-task-id\" },\n      { \"title\": \"Another task\" }\n    ]\n  },\n  \"sibling_type\": \"follows\"\n}\n```\n\n## Tag-Based Affinity\n\nWorkers declare capabilities via tags when connecting. Tasks can require specific tags to control which workers can claim them.\n\n**Example tag categories:**\n- **Model capabilities**: `image-in`, `audio-out`, `video-in`, `code`, `bulk`\n- **Access levels**: `prod-access`, `admin`, `external`\n- **Specializations**: `rust`, `python`, `frontend`, `database`\n\n*Note: Roles like coordinator/reviewer/deployer are better represented using phases.*\n\n**Task requirements:**\n- `needed_tags` (AND): Agent must have ALL of these\n- `wanted_tags` (OR): Agent must have AT LEAST ONE\n\n```json\n{\n  \"title\": \"Analyze screenshot and generate code\",\n  \"needed_tags\": [\"image-in\", \"code\"],\n  \"wanted_tags\": [\"bulk\"]\n}\n```\n\n```json\n{\n  \"title\": \"Deploy to production\",\n  \"phase\": \"deploy\",\n  \"needed_tags\": [\"prod-access\"],\n  \"wanted_tags\": [\"aws\", \"gcp\"]\n}\n```\n\n## Workflows and Phases\n\n### Phases\n\nTasks can have a `phase` to categorize the type of work being performed:\n\n```json\n{\n  \"title\": \"Add authentication\",\n  \"phase\": \"implement\"\n}\n```\n\nBuilt-in phases: `explore`, `implement`, `review`, `test`, `security`, `deploy`, `triage`, `diagnose`, `design`, `plan`, `doc`, `integrate`, `monitor`, `optimize`\n\nPhases enable:\n- **Transition prompts** — Automatic guidance when entering/exiting phases\n- **Gates** — Requirements that must be satisfied before phase transitions\n- **Role-based routing** — In relay workflows, specialists own specific phases\n\n### Named Workflows\n\nPre-built workflow topologies optimize for different coordination patterns:\n\n| Workflow | Description | Best For |\n|----------|-------------|----------|\n| `solo` | Single agent, full autonomy | Simple tasks, prototyping |\n| `swarm` | Parallel generalists, pull-based | High throughput, independent tasks |\n| `relay` | Sequential specialists, handoffs | Complex tasks, domain expertise |\n| `hierarchical` | Lead/worker delegation | Large projects, team coordination |\n| `push` | Push-based task distribution topology | Centralized assignment, load balancing |\n| `kanban` | Board-style task management with WIP limits | Continuous flow, visual tracking |\n| `sprint` | Time-boxed iteration planning | Scrum teams, fixed cadence |\n\nSelect a workflow on connect:\n\n```\nconnect(worker_id=\"agent-1\", workflow=\"swarm\")\n```\n\nEach workflow provides tailored prompts and coordination guidance. See [WORKFLOW_TOPOLOGIES.md](docs/WORKFLOW_TOPOLOGIES.md) for detailed patterns.\n\n### Transition Prompts\n\nAgents receive automatic guidance when status or phase changes:\n\n```yaml\n# workflows.yaml\nstates:\n  working:\n    prompts:\n      enter: |\n        You are now working on this task.\n        From {{current_status}} you can transition to: {{valid_exits}}\n      exit: |\n        Before leaving:\n        - [ ] Attach results\n        - [ ] Log costs\n```\n\nPrompts support template variables: `{{current_status}}`, `{{valid_exits}}`, `{{current_phase}}`, `{{valid_phases}}`\n\n### Gates\n\nGates are requirements that must be satisfied before status or phase transitions:\n\n```yaml\ngates:\n  status:working:\n    - type: gate/tests\n      enforcement: warn\n      description: \"Tests must pass\"\n```\n\nSatisfy a gate by attaching evidence:\n\n```\nattach(task=\"123\", type=\"gate/tests\", content=\"All tests passing\")\n```\n\nEnforcement levels: `allow` (advisory), `warn` (blocks unless `force=true`), `reject` (hard block)\n\n## File Coordination\n\nAgents can coordinate file edits using advisory marks with change tracking:\n\n```\nWorker A: connect() -> \"worker-a\"\nWorker A: mark_file(\"worker-a\", \"src/main.rs\", \"refactoring\")\nWorker B: connect() -> \"worker-b\"\nWorker B: mark_updates(\"worker-b\") -> sees worker-a's mark\nWorker A: unmark_file(\"worker-a\", \"src/main.rs\", \"ready for review\")\nWorker B: mark_updates(\"worker-b\") -> sees removal with reason\nWorker B: mark_file(\"worker-b\", \"src/main.rs\", \"adding tests\")\n```\n\n## Architecture\n\n```\n┌─────────────┐     ┌─────────────┐     ┌─────────────┐\n│  Agent A    │     │  Agent B    │     │  Agent C    │\n│  (Claude)   │     │  (GPT-4)    │     │  (Worker)   │\n└──────┬──────┘     └──────┬──────┘     └──────┬──────┘\n       │ stdio             │ stdio             │ stdio\n       ▼                   ▼                   ▼\n┌─────────────┐     ┌─────────────┐     ┌─────────────┐\n│ task-graph  │     │ task-graph  │     │ task-graph  │\n│    MCP      │     │    MCP      │     │    MCP      │\n└──────┬──────┘     └──────┬──────┘     └──────┬──────┘\n       │                   │                   │\n       └───────────────────┼───────────────────┘\n                           ▼\n                  ┌─────────────────┐\n                  │   SQLite + WAL  │\n                  │  .task-graph/   │\n                  │    tasks.db     │\n                  └─────────────────┘\n```\n\n- **Transport**: Stdio — each worker spawns its own server process\n- **Database**: SQLite with WAL mode for concurrent access across processes\n- **Deployment**: Single binary, no external dependencies, works offline\n\n## Compared to Alternatives\n\n| | Task Graph | Linear task lists | Custom databases |\n|---|---|---|---|\n| Workflow phases | ✓ Built-in with prompts | ✗ Manual tracking | DIY |\n| Quality gates | ✓ Configurable enforcement | ✗ | DIY |\n| Multi-agent safe | ✓ Atomic claims, file locks | ✗ Race conditions | Maybe, DIY |\n| Dependency tracking | ✓ DAG with cycle detection | ✗ Manual ordering | DIY |\n| MCP native | ✓ First-class | ✗ Wrapper needed | ✗ Wrapper needed |\n| Token accounting | ✓ Built-in | ✗ | DIY |\n| Setup required | None | None | Database server |\n\n## Documentation\n\n| Document | Description |\n|----------|-------------|\n| [CONFIGURATION.md](docs/CONFIGURATION.md) | Complete configuration reference (config.yaml, workflows, prompts, gates, tags) |\n| [SCHEMA.md](docs/SCHEMA.md) | Database schema and state machine documentation |\n| [DESIGN.md](docs/DESIGN.md) | Architecture and design decisions |\n| [WORKFLOW_TOPOLOGIES.md](docs/WORKFLOW_TOPOLOGIES.md) | Multi-agent workflow patterns (solo, swarm, relay, hierarchical) |\n| [EXPORT_IMPORT.md](docs/EXPORT_IMPORT.md) | Data export and import functionality |\n| [PROCESSES.md](docs/PROCESSES.md) | Release process, changelog maintenance |\n| [GATES.md](docs/GATES.md) | Workflow gate conditions and enforcement |\n| [METRICS.md](docs/METRICS.md) | Experiment metrics definitions and SQL examples |\n\n## License\n\nApache 2.0\n\n---\n\nBuilt for AI agents that need structured workflows and reliable coordination.\n",
  "bytes": 26346,
  "sha": "b092a82418e7e2eecfa75b6077e8c351161c8e7e8c810fe8d311a4c1453a4abe",
  "repo_slug": "oortonaut/task-graph-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_oortonaut_task_graph_mcp_4cf6e6a9/readme"
}