Skip to main content

NeuroDock task fractionator MCP server — goal decomposition and next-action selection.

Project description

neurodock-mcp-task-fractionator

Local-first goal decomposition and single next-action selection, exposed as an MCP server.

Tools

decompose(goal, time_budget?)

Local-heuristic decomposition into atomic 5–90 minute tasks. Every task carries at least one acceptance criterion, a dependency-sorted sequence number, and a small bag of tags. Stateless: the server returns the list and does not persist it. Persistence is the caller's job via mcp-cognitive-graph.

  • goal — 5..500 character plain-language goal. Never logged.
  • time_budget — optional ISO 8601 duration (PT4H, P3D, PT2H30M). Unparseable input returns TIME_BUDGET_UNPARSEABLE. P3D is treated as 3 working blocks of 4 hours, not 72 hours, per ADR 0003 §3.

Errors: GOAL_REQUIRED, GOAL_TOO_LONG, TIME_BUDGET_UNPARSEABLE, BUDGET_INFEASIBLE, DEPENDENCY_CYCLE, ACCEPTANCE_CRITERIA_REQUIRED, DECOMPOSITION_UNAVAILABLE.

next_one(project)

Returns exactly one task — the single thing the user should do next — with a short reasoning paragraph and a confidence score in [0, 1].

  • project — 1..120 char project name (case-sensitive, no fuzzy match).
  • Pending tasks are read from a pluggable PendingTaskSource.
  • Selection: lowest sequence whose dependencies are all already complete in the pending set.

Errors: PROJECT_REQUIRED, NO_TASKS_AVAILABLE, ALL_TASKS_BLOCKED, COGNITIVE_GRAPH_UNAVAILABLE.

Quick start

# From the repo root
uv sync
uv run pytest packages/mcp-task-fractionator/tests/ -v

# Run the server over stdio (the MCP transport):
uv run neurodock-mcp-task-fractionator

In-memory-only next_one (v0.0.3 caveat)

next_one reads pending tasks from a PendingTaskSource. v0.0.3 ships two implementations:

  • InMemoryPendingTaskSource — default, used by tests. Holds tasks in process memory. Build the server explicitly with this source and seed it before calling next_one:

    from neurodock_mcp_task_fractionator import (
        InMemoryPendingTaskSource, build_server,
    )
    
    source = InMemoryPendingTaskSource()
    source.add("founding-scope-rfc", [task_1, task_2, task_3])
    server = build_server(source=source)
    
  • CognitiveGraphPendingTaskSource — Phase 2 stub. Always raises COGNITIVE_GRAPH_UNAVAILABLE. Real wiring lands once the mcp-cognitive-graph Python client ships.

Selection via env var: NEURODOCK_TASK_SOURCE=memory|graph (default memory). Unknown values fall back to memory rather than crashing.

Privacy

Per ADR 0003 §7 the goal text and project name are treated as sensitive user data:

  • No remote calls. No LLM call inside the server.
  • Goal text is never logged at any level.
  • Validation errors reference field names, not user content.
  • The rationale paragraph is built from recognised vocabulary tokens only; it never embeds the user's original goal text verbatim.

A test (test_decompose.py::test_rationale_does_not_contain_goal_text) encodes the privacy invariant.

Development gates

# Lint + format check
uv run ruff check packages/mcp-task-fractionator/
uv run ruff format --check packages/mcp-task-fractionator/

# Strict type check
uv run mypy --strict packages/mcp-task-fractionator/src/

# Tests
uv run pytest packages/mcp-task-fractionator/tests/ -v

All four must pass before a PR is mergeable.

Pointers

  • Architecture rationale: ADR 0003 — task-fractionator tool design.
  • The five-principles manifesto this server has to honour: MANIFESTO.md.
  • Sibling servers: mcp-chronometric (time, idle, breaks) and mcp-cognitive-graph (persistent state — where pending tasks will live).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

neurodock_mcp_task_fractionator-0.0.5.tar.gz (38.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

neurodock_mcp_task_fractionator-0.0.5-py3-none-any.whl (27.8 kB view details)

Uploaded Python 3

File details

Details for the file neurodock_mcp_task_fractionator-0.0.5.tar.gz.

File metadata

  • Download URL: neurodock_mcp_task_fractionator-0.0.5.tar.gz
  • Upload date:
  • Size: 38.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for neurodock_mcp_task_fractionator-0.0.5.tar.gz
Algorithm Hash digest
SHA256 260963683f6c118c418942362f1e5115491d06a95b914726206ae3fdc278b7f4
MD5 606b4a36991a0838d6d1bd278672a2ba
BLAKE2b-256 78efd9117b9a198f3ce3435b63ae83044ce0acaa9f5fd4e074fb4e223f208922

See more details on using hashes here.

File details

Details for the file neurodock_mcp_task_fractionator-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: neurodock_mcp_task_fractionator-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 27.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for neurodock_mcp_task_fractionator-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 a88502cb99b6cc39f301dfa4d1369e2bdc2523e3315ef2251a3f07f24dfd29a2
MD5 b39379b638abb16e22b525832cd5d4ef
BLAKE2b-256 ee1d644f1e1f6ec9816257b7847ae29b050935a1abaed64af142310d8c76f92a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page