Files
holocron/plugins/kyberforge/.apm/skills/forge/README.md
Defame1297 4aab9d327c refactor(kyberforge): retrofit forge to the ADR-0020 contract
Description 648 -> 387 chars, body 1093 -> 541 words. This was the last
body FAIL in the 39-skill corpus.

The body was not trimmed to fit. forge routes four artifact types that a
single invocation classifies between, so the contract requires a dispatch
table plus the gates common to every route, with each route self-contained
in references/. Adds references/author-routes.md (skill and agent),
references/apm-routes.md (plugin and marketplace entry) and
references/version-bump.md. Skill and agent share one file: they differ on
one axis only, which audit skill verifies the result.

Fixes three defects the first pass introduced or relocated:

- references/apm-routes.md claimed `apm audit` "already runs inside
  apm-workflow's own flow" and told the agent to confirm it ran clean.
  apm-workflow dispatches audit as its own row; the configure and
  marketplace rows never reach it. That was the only completion check
  these routes had, and it could never be satisfied. Replaced with a
  manual read-back the agent performs itself.
- "Read only the reference file" forbade the multi-artifact case the same
  body documents two lines later, and ADR-0011 records eight artifacts
  authored in one pass.
- The announce gate became a closing gate, reachable only after the
  invocation it was meant to precede. Moved to the end of Step 2.

Also restores the artifact enumeration to the plugin row, normalises to
bare unnamespaced skill names per AGENTS.md, adds a dispatch fallback for
artifacts matching no row, and corrects three provenance entries -- one
asserted a contribution that did not happen.

Refs #99

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MWb5RQgCL1ye7cGp2RPb2u
2026-08-30 16:31:23 +00:00

3.0 KiB

forge

Guided entry point for building or improving something in any plugin of this repo when the target artifact type isn't decided yet.

What it does

Grills the user's intent via bin:grill-with-docs (inline, interactive) against this repo's CONTEXT.md and docs/adr/, classifies the target artifact type (skill, agent/subagent definition, plugin, or marketplace entry), announces the classification, then routes to the matching author skill — chaining more than one, in dependency order, if the intent spans multiple artifact types.

Author-skill invocation defaults to a fork subagent (inherits the grilled-intent context) and falls back to inline when forking isn't possible or the routed flow needs live user interaction (clarifying questions, a HITL gate). After a skill-author or agent-author route finishes — each already closes out with its own inline audit — forge spins up a separate clean-context subagent to independently re-run the matching audit skill (skill-audit / agent-audit) as a distinct check on the finished artifact, not a duplicate of the inline one. If that clean audit turns up any unresolved finding, forge loops — re-invoke the author skill to resolve it, re-run the clean audit — until the clean audit comes back with nothing unresolved. apm-workflow routes (plugin, marketplace entry) get no recheck: they have no audit counterpart, and no automatic terminal check either — apm audit is a separate apm-workflow action, not a closing step of the configure or marketplace flow — so forge verifies those routes by reading the written manifest back against the grilled intent.

Before you start

Have a rough idea of what you want to build or change. forge doesn't require you to already know whether it's a skill, agent, plugin, or marketplace entry — that classification is its job.

Usage

/forge

Skip forge and call the target skill directly (/skill-author, /agent-author, /apm-workflow) when you already know the artifact type.

Files

File Loaded when
SKILL.md Always — Gotchas, the grill step, the classification dispatch table, and the gates common to every route
references/author-routes.md The intent classifies as a skill or an agent/subagent definition — fork-vs-inline judgment and the two-tier verification loop
references/apm-routes.md The intent classifies as a plugin or a marketplace entry — always-inline invocation, why these routes get no clean-context recheck, and the manual read-back that stands in for one
references/version-bump.md A finished route left the owning package's version unbumped — walk-up rule and the clean-context bump brief
references/sources.md Never loaded at runtime — provenance chain for the research sources that informed this skill

Routes to

Artifact type Skill
Skill skill-author
Agent / subagent definition agent-author
Plugin apm-workflow (configure)
Marketplace entry apm-workflow (marketplace)