mate
Capabilities

Overview

Optional alpha integrations that Mate can wire into companion and working repositories.

Capabilities are optional tools that Mate can configure during mate companion setup and sync into linked working repositories when you run mate opencode or mate claude.

Capabilities are selected per companion. They affect the dependency plan used by mate install; selecting a capability never silently enables another optional capability.

Projects

Mate can also wire in these optional projects:

  • RTK for compact command output (Apache-2.0)
  • Context7 for library documentation through MCP (MIT)
  • Context Mode for session context management (Elastic License 2.0)

Mate installs each project from its own source; it does not bundle them.

Skill Acknowledgements

Mate’s bundled process skills are adapted from open-source work by:

These adaptations add Mate-specific workflow, policy, and companion integration while preserving credit to the original authors.

How They Fit

The default workflow starts with mate install in the working repository, then mate companion link. Linking reads the selected companion capabilities and installs their resulting dependency plan automatically.

Use mate companion setup in the companion repository when you need to change those selections. Run mate install afterward to refresh the dependency plan. Then mate opencode and mate claude launch from the working repository with the selected companion-managed capabilities available.

Skill Locations

Capability skills live in two companion skill roots:

  • .claude/skills/ for Claude.
  • .agents/skills/ for every other agent runtime, currently OpenCode.

OpenCode keeps its /opsx-* OpenSpec commands in .opencode/commands/. Claude keeps its /opsx:* commands in .claude/commands/opsx/. A wrapped working repository gets a link to each companion skill folder and command folder under its own .claude/, because Claude does not load commands from the companion directly. Mate only manages the skills it installs, so your own skills and third-party skills in .agents/skills/ stay untouched. Companions created by earlier Mate versions kept OpenCode skills in .opencode/skills/. Run mate companion update once to move them, then commit the result.

Capability Details

OpenSpec

OpenSpec commands are routed through the companion context:

mate cap openspec <subcommand> [args...]

Mate ships two schema profiles and installs both into the companion. Schema choice selects the artifact set; both profiles still explore before proposing:

  • mate-v1: the complete proposal → specs → design → tasks artifact set
  • mate-minimal: the short specs → tasks artifact set, with parser-compatible requirements written as user stories and Given/When/Then acceptance criteria

Choose mate-minimal only when every gate is true:

  • one repository and one Area
  • no new dependency or data migration
  • no public API change or breaking behavior
  • no cross-cutting architecture or unresolved technical decision

If any gate is false or unclear, use mate-v1. Its proposal, specs, design, and tasks artifacts are required, but they can stay concise for simple changes. Installing a schema does not activate it. Setup keeps OpenSpec’s own default unless mate-v1 is explicitly selected as the companion default during mate companion setup, which is the only flow that writes openspec/config.yaml. mate-minimal is never the companion default.

Both profiles can be selected for one change without changing the companion default:

mate cap openspec new change <name> --schema mate-v1
mate cap openspec new change <name> --schema mate-minimal

OpenSpec records the selected profile in the change’s .openspec.yaml.

OpenSpec Version And Generated Files

The openspec-* skills and /opsx commands are generated by the openspec CLI and committed in the companion. Only mate companion setup and mate companion update regenerate them. Both upgrade an outdated CLI to @fission-ai/openspec@latest, then run openspec init and openspec update. Commit the result so every teammate shares the same OpenSpec output.

Launches never rewrite these files. Instead, a launch reads the metadata.generatedBy version from the committed OpenSpec skills. When the installed CLI is older, Mate installs exactly that version globally. A newer installed CLI is left alone, and pinned deployments skip the install. A new OpenSpec release reaches the companion only after someone runs mate companion update.

Every OpenSpec process Mate starts, including the openspec wrapper agents call, runs with OPENSPEC_TELEMETRY=0 and OPENSPEC_NO_UPDATE_CHECK=1.

Delta And Canonical Specs

A change writes proposed requirements as delta specs under openspec/changes/<name>/specs/<capability>/spec.md. The durable current contract lives under openspec/specs/<capability>/spec.md as the canonical spec. Do not edit canonical specs while planning a change.

openspec archive is the bridge: it merges the delta requirement blocks into the canonical spec and moves the change into openspec/changes/archive/<date>-<name>/. mate artifact publish is the sanctioned terminal flow for that archive and its follow-up Git work.

Graphify

Graphify manages a repository knowledge graph and companion-managed agent wrappers. Refresh its index directly or through the combined index command:

mate cap graphify <subcommand> [args...]
mate cap index --graphify

TokenSave

TokenSave provides code-graph exploration through MCP and keeps its native .tokensave store in the working repository. Refresh it with:

mate cap index --tokensave

React Doctor

React Doctor installs the mate-react-doctor skill for Claude and OpenCode. It adds no hooks and never scans in the background: it runs only when the skill is invoked.

With OpenSpec, the shared Mate conventions add a [skill:mate-react-doctor] verification task to the end of every Area whose tasks change React code. The apply phase works through that task, and before it reports a change complete, it runs the skill for any React Area that has no checked verification task. The skill scans the change’s diff with Mate’s pinned React Doctor binary, fixes regressions the change introduced, and reports what it could not fix. Outside an OpenSpec change, invoke the skill directly.

React Doctor is configured during setup and does not have a separate mate cap command.

Index Synchronization

Launches automatically refresh enabled code-exploration capabilities. You can also refresh them explicitly from a linked working repository:

mate cap index

If both Graphify and TokenSave are enabled, Mate refreshes TokenSave and then Graphify so Graphify sees the resulting repository state.