cpm-planner 0.0.1

Critical Path Method (CPM) planner exposed as an MCP server: schedules a task graph (earliest/latest start, slack, critical path, bottlenecks) and coordinates lock-aware parallel execution over MCP.
Documentation

cpm-planner

CI crates.io docs.rs License: Apache-2.0

cpm-planner is a Critical Path Method (CPM) planner exposed as an MCP server. You submit a task graph; it computes the schedule — earliest/latest start and finish, slack, the critical path, and the bottleneck tasks that actually gate completion — and it coordinates lock-aware cohort scheduling so multiple workers can run disjoint deliverables in parallel without colliding. Any MCP client (Claude Code, Cursor, a custom orchestrator, or an mcp-flowgate workflow) drives it over the standard protocol.

It is a standalone tool: it has no dependency on mcp-flowgate and is consumed purely over MCP.

Install

From crates.io:

cargo install cpm-planner

Or download a pre-built binary for your platform from the latest release (verify against the release's checksums.sha256):

Platform Download
Linux x86_64 .tar.gz
Linux ARM64 .tar.gz
macOS x86_64 .tar.gz
macOS Apple Silicon .tar.gz
Windows x86_64 .zip

It speaks MCP over stdio (the standard transport). Wire it into your editor like any other MCP server:

{ "command": "cpm-planner", "args": [] }

MCP tools

Tool Does
plan.submit Submit a task graph; returns a plan id (idempotent on the graph + caller).
plan.acquire_cohort Atomically acquire up to N ready deliverables with mutually disjoint file sets.
plan.heartbeat Refresh the TTL on a held lock.
plan.mark_status Mark a deliverable complete/failed; releases its lock.
plan.status Read-only snapshot of the plan and its locks.
plan.force_release Operator escape hatch: release a lock regardless of holder/TTL.

Use as a library

The CPM kernel is also a plain Rust library, independent of MCP:

use cpm_planner::{CpmAlgorithm, Task, TaskKind};

let mut tasks = vec![
    Task::new("design", "Design", TaskKind::Custom { description: "design".into() }, 4.0),
    Task::new("build", "Build", TaskKind::Custom { description: "build".into() }, 8.0)
        .depends_on("design"),
    Task::new("test", "Test", TaskKind::Custom { description: "test".into() }, 2.0)
        .depends_on("build"),
];

let result = CpmAlgorithm::calculate(&mut tasks);
println!("critical path: {:?}", result.critical_path); // ["design", "build", "test"]
// also: result.bottlenecks, result.optimal_duration_parallel,
// and per-task .float (slack) / .is_critical on each Task.

See the API docs.

With mcp-flowgate

Wire it into a flowgate workflow as an MCP connection — no code dependency, just the protocol:

connections:
  planner:
    kind: mcp
    command: cpm-planner

License

Apache-2.0.