HAI-MCP

v0.1.0
io.github.smlfg/hai-mcp Checked 4 days ago Published 1 month ago

Model-agnostic MCP control plane for HAI: bounded missions, owner-gated actions, drift checks.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

hai_health

Check HAI-MCP server health and optional project path usability. No model calls.

ParameterTypeDescription
project_path

hai_status

Return ACTIVE lanes, focus, inbox count, and optional project next-step flags.

ParameterTypeDescription
project_path

hai_get_next_step

Read the canonical NEXT_STEP.md for a project (or report none).

ParameterTypeDescription
project_path *string

hai_read_artifacts

Read-only summary of HAI Projek-Managment run-contract artifacts.

ParameterTypeDescription
project_path *string
max_charsinteger

hai_park

Park a thought/meta item in HAI inbox without changing ACTIVE lanes.

ParameterTypeDescription
text *string
tags

hai_set_focus

Set focus and register an ACTIVE lane (max 2). Fails if a third ACTIVE is requested.

ParameterTypeDescription
focus_id *string
label
project_path

hai_propose_next_step

Write NEXT_STEP.proposed.md (not canonical). Promote via hai_accept_next_step.

ParameterTypeDescription
content *string
project_path *string

hai_accept_next_step

Promote proposed (or provided) content to canonical NEXT_STEP.md — owner-gated. Default gate (nonce): call once WITHOUT owner_code; a one-time code is delivered to the owner (never to this client). Ask the owner for it and call again with owner_code=<code>. The code is bound to the exact content and is single-use. Legacy gate (ack_legacy): owner_ack=true + reason.

ParameterTypeDescription
project_path *string
content
owner_ackboolean
owner_code
reason

hai_checkpoint

Snapshot ACTIVE_CONTEXT and optional project artifacts under HAI_HOME/history/checkpoints.

ParameterTypeDescription
note
project_path

hai_recover

Return the smallest recovery next action from latest or named checkpoint (read-only advice).

ParameterTypeDescription
checkpoint_id

hai_open_mission

Open a bounded mission with a versioned canonical contract. One active mission globally.

ParameterTypeDescription
artifact *string
done_criteria *array
objective *string
owner *string
constraints
non_goals

hai_authorize_session

Grant a time-bounded session lease tied to mission ID and exact contract version.

ParameterTypeDescription
agent_identity *string
contract_version *integer
contribution *string
criterion_ids *array
duration_minutes *integer
expected_result *string
mission_id *string
role *string
capabilities
device_id
harness_id

hai_bind_project

Bind a device-local directory to a logical project_id mount table entry. Requires owner_ack=true + reason.

ParameterTypeDescription
device_id *string
local_path *string
owner_ack *boolean
project_id *string
reason *string

hai_get_contract

Return the exact canonical mission contract for a valid session lease (not a summary).

ParameterTypeDescription
session_id *string

hai_check_activity

Deterministically classify planned or observed activity against the mission contract.

ParameterTypeDescription
activity_step *string
session_id *string
activity_kind
affected_paths
criterion_id
declares_blockerboolean
evidence
trace_events

hai_park_item

Park a mission-linked idea with full context. Grants no execution right; contract unchanged.

ParameterTypeDescription
idea *string
mission_id *string
origin_session_id *string
rationale *string
trigger_event *string

hai_recontract

Apply a visible field-level contract diff; revokes all leases. Owner-gated. First call (no owner_code) returns the diff and delivers a one-time code to the owner; call again with owner_code=<code from the owner>. Legacy gate: owner_ack=true.

ParameterTypeDescription
changes *object
contract_version *integer
mission_id *string
reason *string
break_glass_markerboolean
modestring
owner_ackboolean
owner_code

hai_close_mission

Complete with verified per-criterion evidence, or abandon (owner-gated). Abandon: first call delivers a one-time code to the owner; call again with owner_code. Legacy gate: owner_ack=true.

ParameterTypeDescription
closure *string
contract_version *integer
mission_id *string
outcome_summary *string
device_id
evidence
owner_ackboolean
owner_code

hai_intake

Capture a raw thought immutably. Returns an intake id only — never actionable, never starts an agent.

ParameterTypeDescription
raw *string

hai_distill

Reduce an intake to EXACTLY one decision + one next step; the server parks everything else.

ParameterTypeDescription
decision *string
intake_id *string
next_step *string
parklist

hai_mission_start

Fast start: declare problem + artifact + time limit. Thin wrapper over hai_open_mission (one canonical contract).

ParameterTypeDescription
artifact *string
done_criteria *array
owner *string
problem *string
constraints
non_goals
time_limit_hoursnumber

hai_drift_check

Lightweight mismatch check against the mission contract. Thin wrapper over hai_check_activity.

ParameterTypeDescription
activity_step *string
session_id *string
activity_kind
affected_paths
criterion_id
declares_blockerboolean
evidence
trace_events

hai_proof

Close a mission only against verified per-criterion evidence. Thin wrapper over hai_close_mission (completed).

ParameterTypeDescription
contract_version *integer
evidence *object
mission_id *string
outcome_summary *string
device_id

hai_stop

Hard day terminal: record the three answers, invalidate active leases; no next-day plan. Missions are not closed. manual_practice: what the owner did BY HAND today (e.g. "read the auth diff", "ran pytest", "wrote the date regex") — the currency logbook for verification skills.

ParameterTypeDescription
agency_gained *string
clearer *string
day *string
loop_closed *boolean
manual_practice