About Taskflow
Taskflow is an MCP server published by heggria in the Agents category: dAG runtime for coding-agent workflows with verification, resume, replay, and effect checks. Conduid read 35 tools from its source: taskflow_analytics, taskflow_compile, taskflow_control_approval_decide, taskflow_control_approval_stage_edit, taskflow_control_approvals, taskflow_control_cancel and 29 more. No package is published for it, so it installs from a source checkout.
The repository has 81 stars and 12 forks, is licensed MIT, and its last commit was on 25 Nov 2026. The latest release is v1.0.0 (10 Oct 2026): Pi /tf web launches the public local console, opens the browser with a safe URL and provides manual fallback, reuses the owned service, and cleans it up on session exit. It follows v0.2.10 (12 Aug 2026), and the 5 most recent releases go back to v0.2.7 (6 Aug 2026). It passes 4 of the 5 static checks Conduid ran on the repository; it does not pass No dynamic code execution. Its topics include agent-orchestration, coding-agents, dag, deterministic-replay, grok-build and hermes-agent.
Install
git clone https://github.com/heggria/taskflowTools (35)
taskflow_analyticsSummarize the last N runs of a flow: status histogram, p50/p95 duration, per-phase fail and cache-hit rates. Zero tokens, no writes, no auto-tune.| Parameter | Type | Description |
|---|---|---|
| json | boolean | Return machine-readable JSON. |
| last | number | How many recent runs to include (default 20, max 100). |
| name * | string | Flow name (matches RunState.flowName). |
taskflow_compileRender a flow's DAG as a diagram (an inline SVG image) with issues overlaid (red=error, amber=warning, green=final), plus a compact status line. No execution. Provide `name`, `define`, or `defineFile`.| Parameter | Type | Description |
|---|---|---|
| define | object | |
| defineFile | string | Path to a JSON (or fenced-Markdown) flow file. See taskflow_run.defineFile. |
| name | string |
taskflow_control_approval_decideApprove, reject, or edit a pending approval with its expected run version. Edit requires a staged artifact and editKind.taskflow_control_approval_stage_editStage bounded output or plan text as a ledger-reachable approval edit artifact. Refresh status before deciding.taskflow_control_approvalsList durable approval requests in the authorized project.taskflow_control_cancelCancel a run through the Host's durable control path with its expected run version.taskflow_control_coordinatorRead user-global capacity and only this project's reservation identifiers and authorized command audit.taskflow_control_force_releaseExplicit operator only: release capacity without proving execution stopped; permanently marks operator-overridden. Requires acknowledgement and an audit reason.taskflow_control_projectsList projects authorized for this local session.taskflow_control_receiptRead the authorized evidence receipt for a terminal run.taskflow_control_resultRead the authorized run result, including final output only.taskflow_control_resumeResume a recoverable run through Host admission and authority checks.taskflow_control_runsList durable run status in the authorized project.taskflow_control_set_max_active_runsExplicit operator only: set the user-global admitted-run limit. Reuse commandId for exact retries.taskflow_control_statusRead durable status without phase transcripts.taskflow_control_submitSubmit a flow to the authenticated Host. Reuse commandId when retrying the same request.taskflow_control_whyExplain authorized durable run evidence and effect causes.taskflow_lintRun built-in and project-local pluggable verifiers (script-lint, custom checks) on a flow WITHOUT executing it. Discovers verifiers from .pi/taskflows/verifiers/. Provide `name`, `define`, or `defineFile`.| Parameter | Type | Description |
|---|---|---|
| define | object | |
| defineFile | string | Path to a JSON (or fenced-Markdown) flow file. |
| name | string |
taskflow_listList the saved taskflows discoverable from the current working directory (user + project scope).taskflow_peekInspect one phase's intermediate output from a stored run (post-hoc debugging). Use the runId reported by taskflow_run. Omit `phaseId` to list the run's phases. Output is hard-truncated (default 4000 chars) so a peek never floods the context window. Read-only.| Parameter | Type | Description |
|---|---|---|
| item | number | For map/parallel phases: the 1-based item section to extract. |
| json | boolean | Return the phase's parsed JSON instead of its text output. |
| limit | number | Truncation cap in chars (default 4000, max 32000). |
| phaseId | string | Phase to peek at. Omit to list all phases with status + output size. |
| runId * | string | The run to inspect (from a prior taskflow_run or the runs index). |
taskflow_planTerraform-plan for taskflows: bind typed args, verify structure, project phase order + dynamic/unresolved bindings, and compute a worst-case agent-call bound — WITHOUT spawning any agent. Provide `name`, `define`, or `defineFile` plus optional `args`.| Parameter | Type | Description |
|---|---|---|
| args | object | Invocation arguments to bind as {args.X}. |
| define | object | |
| defineFile | string | Path to a JSON (or fenced-Markdown) flow file. |
| json | boolean | Return the full PreflightResult as JSON. |
| name | string |
taskflow_recomputeReport what would re-run if a phase changed — the stale frontier from the seed phase. Dry-run only in MCP (zero tokens): reports the re-run / cutoff / reused sets with per-phase reasons. To actually re-execute (spending tokens), use the Pi adapter's /tf recompute --apply. Never calls a model in MCP.| Parameter | Type | Description |
|---|---|---|
| phaseId * | string | The assumed-changed seed phase. |
| runId * | string | The run whose frontier to compute. |
taskflow_reconcile_workspaceExplicitly accept the current external filesystem state after a resolve-only writer failed with an unknown outcome. This does not restore files or prove correctness: inspect or repair the workspace first. The host operator must also launch Taskflow with TASKFLOW_WORKSPACE_RECONCILE_MODE=explicit. Reconciliation takes an exclusive whole-root lease, durably clears dirty-unknown intents, and advances the workspace generation.| Parameter | Type | Description |
|---|---|---|
| acknowledgement * | string | Must exactly equal: ${WORKSPACE_RECONCILE_ACKNOWLEDGEMENT} |
| reason | string | Short audit reason describing what was inspected or repaired. |
taskflow_replayRe-evaluate a stored run's event trace offline against changed gate thresholds, budget caps, or model routes — without calling any model (zero tokens). Reports per-phase outcomes: reused, would-block, verdict-flipped, would-exceed-budget, needs-live-rerun, etc. Use after taskflow_trace when you want counterfactual analysis of a finished run.| Parameter | Type | Description |
|---|---|---|
| budgetMaxTokens | number | Alternate max token budget. |
| budgetMaxUSD | number | Alternate max USD budget for would-exceed-budget checks. |
| json | boolean | Return the full ReplayReport as JSON. |
| models | object | Map of phaseId → model id (currently marks needs-live-rerun; quality cannot be re-judged offline). |
| runId * | string | The run whose trace to replay (from a prior taskflow_run). |
| thresholds | object | Map of phaseId → new score threshold (re-judges recorded gate-score events). |
taskflow_resumeResume a stored run by forking a NEW run (the original run file is never modified). The child carries parentRunId pointing at the original. Reusable completed phases are copied (cache hits); the target phase + its transitive downstream re-run. With no overrides, ordinary resume re-runs the non-done phases. With overrides (requires phaseId + at least one of task/model/timeout/idleTimeout), exactly one phase is re-run with the patched values applied to the child's def only.| Parameter | Type | Description |
|---|---|---|
| idleTimeout | number | Override the target phase's idleTimeout in ms (>= 1000 or 0 to disable, requires phaseId). |
| model | string | Override the target phase's model (requires phaseId). |
| phaseId | string | Target phase to re-run with overrides (required when any override field is supplied). |
| runId * | string | The run to resume (from a prior taskflow_run). |
| task | string | Override the target phase's task (requires phaseId). Applied to the forked child only — the parent is never modified. |
| timeout | number | Override the target phase's timeout in ms (>= 1000, requires phaseId). |
taskflow_runRun a taskflow DAG and return its final output. Provide EITHER `name` (a saved flow) OR `define` (an inline flow definition: {name, phases:[…]} or a shorthand {task} / {tasks} / {chain}). Subagents execute as isolated host sessions. Intermediate phase outputs stay in the runtime; only the final phase output is returned — the reported runId can be passed to taskflow_peek to inspect intermediate phase outputs afterwards.| Parameter | Type | Description |
|---|---|---|
| args | object | Invocation arguments interpolated as {args.X}. |
| define | object | Inline flow definition (full DAG or shorthand). |
| defineFile | string | Path to a file holding the flow definition (raw JSON, or Markdown with a ```json fence). Lets you verify/compile/run share ONE persisted draft (e.g. in the OS tmp dir) — edit the file between calls instead of re-sending the whole definition. Precedence: define > defineFile > name. |
| incremental | boolean | Default every phase to cross-run cache reuse. |
| mode | string | Execution mode. foreground (default) waits for the full DAG; background returns a runId immediately and continues even if the MCP request ends. |
| name | string | Name of a saved flow to run. |
| reusedFromSearch | boolean | Set true when this run was chosen because of a prior taskflow_search → bumps the flow's reuseCount (the reuse flywheel). Default false; direct run-by-name does not bump. |
taskflow_runsList recent background runs, inspect one run, wait for completion without losing it when the MCP request ends, or request cancellation. Use after taskflow_run with mode:'background'.| Parameter | Type | Description |
|---|---|---|
| action * | string | Lifecycle action. |
| limit | integer | For list: maximum recent background runs (default 10, max 50). |
| reason | string | For cancel: optional audit reason. |
| runId | string | Required for status, wait, and cancel. |
| status | string | For list: show all runs (default), only active runs, or only terminal runs. |
| timeoutMs | integer | For wait: return after this many ms if still running (default 30000, max 300000). |
taskflow_saveSave a flow as a reusable library asset: persists the flow AND a sidecar .meta.json with purpose/tags/notes + auto-derived structural metadata (phase signature, generality score) so taskflow_search can retrieve it later. Pass purpose + 2-4 tags for any flow you expect to reuse — this is what makes search recall work.| Parameter | Type | Description |
|---|---|---|
| definition * | object | Full taskflow DSL object ({name, phases:[...]}) or shorthand ({task}|{tasks}|{chain}). |
| name * | string | Flow name (also the filename stem). |
| notes | string | Free-form reuse notes (when NOT to use, required args, gotchas). |
| purpose | string | One-line purpose — the single most important field for search recall. Write what the flow DOES and WHEN to use it. |
| scope | string | project (default) or user-global. |
| tags | array | 2-4 reuse tags (e.g. audit, fan-out, migration, security). |
taskflow_searchSearch saved flows by purpose BEFORE authoring a new one — the reuse flywheel. Returns ranked matches with a score, why it matched, and a reuse hint (direct-reuse / copy-and-generalize / write-fresh). Falls back to keyword+structural ranking when no embedding backend is configured (structural mode); uses cosine similarity when one is (semantic/mixed mode).| Parameter | Type | Description |
|---|---|---|
| limit | number | Max results (default 5, max 20). |
| minScore | number | Drop results below this score (0-1). |
| query * | string | Natural-language purpose string (what you want the flow to do). |
| scope | string | Which scopes to search (default from settings: both). |
| structureOnly | boolean | Skip embedding, use keyword+structural ranking only (zero latency). |
taskflow_showShow a saved flow's full definition as JSON.| Parameter | Type | Description |
|---|---|---|
| name * | string | Name of the saved flow. |
taskflow_traceRead the append-only event trace a run recorded (each subagent call's input/output + runtime decisions). Foundation for taskflow_replay. Responses are bounded; use limit to select up to 1000 newest events.| Parameter | Type | Description |
|---|---|---|
| json | boolean | Return a bounded machine-readable envelope instead of a human timeline. The envelope reports total/returned/truncated; oversized strings are truncated. |
| limit | number | Maximum newest trace events to return (default 200, max 1000). Large string fields and total response size are also bounded. |
| runId * | string | The run to inspect (from a prior taskflow_run or the runs index). |
taskflow_verifyStatically verify a flow (cycles, missing deps, undefined refs, …) WITHOUT executing it. Provide `name`, `define`, or `defineFile`.| Parameter | Type | Description |
|---|---|---|
| define | object | |
| defineFile | string | Path to a JSON (or fenced-Markdown) flow file. See taskflow_run.defineFile. |
| name | string |
taskflow_versionReport the engine package version, the git commit the dist was built from, the bound host identity (codex/claude/opencode/grok/hermes), and the run-state schema version. Zero tokens, no execution. Use to verify which taskflow build a host is running.taskflow_why_effectGiven a runId + effectId (+ optional phaseId): explain authorization and lifecycle from the durable resource intent ledger. Zero tokens and read-only. A declaration without matching principal/capability/intent evidence is unauthorized.| Parameter | Type | Description |
|---|---|---|
| effectId * | string | Effect id as declared on the phase (or phaseId/effectId composite). |
| json | boolean | Return the full WhyEffect record as JSON. |
| phaseId | string | Optional phase scope when the same effect id appears on multiple phases. |
| runId * | string | The run whose flow definition declares the effect. |
taskflow_why_staleGiven a runId (+ optional phaseId seed): with no seed, prints the observed dependency graph; with a seed, computes the transitive stale frontier — exactly which phases would need re-running and why (observed ∪ declared edges). Zero tokens. Read-only.| Parameter | Type | Description |
|---|---|---|
| phaseId | string | Optional assumed-changed seed phase. Omit to print the observed dependency graph. |
| runId * | string | The run to analyze. |
Security checks
- ✓README presentThe repository's README runs to about 1.5K words.
- ✓License declaredThe repository declares the MIT license.
- ✓Tests presentA test suite exists in the repository.
- ✓Dependencies pinnedA lockfile pins dependency versions.
- !No dynamic code executionScanned 212 source files and found 3 calls to eval or shell execution, in packages/taskflow-core/src/resources/persistence.ts and packages/taskflow-core/src/runtime/phases/script.ts among others. Review how tool inputs reach them before granting credentials.
1 check has not been run yet.
Releases
README
The repository's README runs to about 1.5K words, fetched a month ago. The original in the repository is authoritative.
Read full README