Skip to the content.

Agent Operating Model

CLike supports two complementary ways of working with coding agents. In both, CLike owns the Harper lifecycle and its governance; agents and models are executors.

Model 1 β€” Developer activates an agent through CLike

This is the local-agent (execution-agent) path. It covers the Harper phases /idea, /spec, /plan, /kit, /eval, /finalize, /extend and /idea --extend. All phases reuse the same execution-agent architecture; only the expected output files, allowed write paths, phase prompt and phase validation differ.

Developer
β†’ VS Code extension
β†’ Orchestrator builds an execution package (prompt, contract, write roots, expected outputs)
β†’ Extension runs the local agent (Claude Code, Codex CLI, …)
β†’ Orchestrator normalizes the result
β†’ RAG / Git / Eval / Gate continue through CLike

For the document phases the local agent writes docs/harper/IDEA.md (idea), docs/harper/SPEC.md (spec), and docs/harper/PLAN.md plus docs/harper/plan.json (plan); all other docs/harper/ paths stay protected (BMAD companions excepted). EXTEND also writes its dated report and, in the release cascade, TECH_CONSTRAINTS.yaml by addition; /finalize writes the integrated solution, never the REQs’ tests. Cloud and local execution remain semantically equivalent and CLike governance stays canonical.

Responsibilities

Orchestrator Extension
Harper phase semantics UI
Execution strategy and local-agent eligibility Workspace access
Executor hints Confined local filesystem writes
Prompt contracts, allowed write roots, expected outputs Local CLI execution (argv, no shell; prompt on stdin on Windows)
Fallback policy stdout/stderr/exit-code and generated-file collection
Result normalization Git integration

Local agents are executors only. They must not promote files, run Git operations, or write directly to canonical test/ or tests/ roots, nor to src/ outside /finalize. They authenticate through their own CLI session: cloud API keys are removed from their environment.

Free chat (Q&A) and Coding via local agent

The same execution-agent path serves the standalone chat modes. The Execution selector lets a request run via the local agent instead of the cloud:

Model availability is computed by the gateway from the configured provider keys. With at least one cloud key all execution options are available (agent only is the default); without cloud keys only agent only remains selectable. Provider/key mismatches surface as a clear message in the Text panel.

Model 2 β€” Agent interacts with CLike

This is the MCP-driven operating model.

External / local agent
β†’ CLike extension operational MCP server (opt-in, token-protected)
β†’ Extension dispatches the normal slash commands
β†’ Normal CLike flow: Orchestrator β†’ Gateway / local agent / RAG / Git / Eval / Gate

The agent does not call the orchestrator with invented Harper payloads: it asks the extension to run the same phases a developer would type (harper_run_phase, eval_run with optional fix, gate_check, harper_kit_next, harper_continue_loop, rag_reindex) and gets their outcome (files, warnings, the eval/gate verdict; long runs via harper_run_status, stopped with cancel_run; confirmations with confirm: true; /idea --extend with phase: idea, extend: true). Overrides, promotion choices and Git are not available from MCP. This keeps the workflow simple, auditable and aligned with the developer path. When there are no open or in-progress REQs, Model 2 tools report finalize_only.

See mcp.md for the tool list and authentication.

Methodology profiles

Methodology profiles (for example BMAD) can enrich how phases reason with role-aware guidance, but they never replace Harper governance:

See integrations/bmad/README.md.