Skip to content

forge-cli: author templates/archetypes/service/ from the relay pilot + strip mint status from archetype bundles (ADR-0002) - #50

Merged
ALLiDoizCode merged 5 commits into
mainfrom
sandcastle/issue-49
Aug 10, 2026
Merged

forge-cli: author templates/archetypes/service/ from the relay pilot + strip mint status from archetype bundles (ADR-0002)#50
ALLiDoizCode merged 5 commits into
mainfrom
sandcastle/issue-49

Conversation

@toon-backlog-bot

Copy link
Copy Markdown
Contributor

Produced by the sandcastle agent:implement runner; awaiting human review.

Closes #49

🤖 Generated with Claude Code

RALPH and others added 2 commits July 25, 2026 01:50
…trip mint status (Forge#49)

Implements Forge#49 (toon-meta#198 epic, part 2 of toon-meta#207): the one
minted-eligible archetype (`service`, pilot relay) had no bundle, and
`game`'s bundle contradicted ADR-0002 (toon-meta/docs/adr/
0002-registry-is-sole-mint-authority.md — FACTORY.md is the sole mint
authority, bundles describe the opinion, never the existence).

Part 1 — templates/archetypes/service/ (archetype.toml, DOCTRINE.md,
factory.toml.example, README.md), mirroring game's shape. Pinned from
relay's real tree (`gh api repos/toon-protocol/relay/...`), not from
toon-meta#207's aspiration:
- `[environment] kind = "node-pnpm"`, `node = "22"`, `devbox = true`
  (relay's devbox.json/devbox.lock, asserted live by a CI devbox-validate
  job).
- Oracle ladder: t0-lint/t1-typecheck/t2-test/t3-build (relay ci.yml's
  build job, same shape as --blank node-pnpm) plus t4-devbox-validate
  (relay's devbox smoke-build job) — no protected/golden tier, since relay
  proves no such oracle.
- DOCTRINE.md/README.md call out what #207 claimed but relay does NOT
  have: no e2e.yml, no journey.yml, no deploy-*.yml. What relay DOES have
  beyond the base ladder — release.yml (changesets), publish-relay-image/
  publish-relay-connector-image.yml (GHCR), a deploy/ bundle — is pinned as
  doctrine but not stamped as workflow files yet (stamp.ts only stamps the
  base five + factory.toml.example + DOCTRINE.md from an archetype bundle
  today; archetype-specific workflow stamping is a future capability, not
  this diff's scope).
- connector stays --blank (npm-workspaces, not node-pnpm) per FACTORY_SPEC
  §2.1 "alternate opinions are new archetypes, not flags".

Part 2 — strip mint status (ADR-0002): removed status/minted/proving_repo
from game/archetype.toml (kept name/environment/doctrine/manifest_example/
oracle_tiers), replaced with a comment that FACTORY.md alone decides
existence. Did not add those fields to service/archetype.toml. Fixed
game/archetype.toml's header comment (it promised a "status flip in
FACTORY.md" while its own `minted = false` field said otherwise) and every
stale README.md/DOCTRINE.md reference to the now-removed fields, in both
bundles and templates/README.md. Grepped packages/ first: nothing reads
archetype.toml's own status/minted/proving_repo — new.ts's/validate.ts's
"minted" checks parse FACTORY.md's catalog table, not this file — so no
production code needed to change.

Tests: packages/forge-core/src/templates.test.ts gained a service-bundle
describe block (inventory, no mint fields, schema-valid manifest, no
protected tier) mirroring game's, plus a cross-bundle ADR-0002 test
asserting both archetype.toml files expose only the five opinion keys.
packages/forge-cli/src/stamp.test.ts gained a service archetype-branch
describe block asserting a stamped service tree round-trips through
forge-core's real validateManifest, with no verify/ stub needed (no
protected tiers to rewire) and DOCTRINE.md copied through.

Files changed: templates/archetypes/service/{archetype.toml,DOCTRINE.md,
factory.toml.example,README.md} (new), templates/archetypes/game/
{archetype.toml,DOCTRINE.md,README.md}, templates/README.md,
packages/forge-core/src/templates.test.ts, packages/forge-cli/src/
stamp.test.ts.

Gate green locally: lint, typecheck, 181 tests (+11), build, format:check.
`forge doctor` green on HEAD.

Notes for next iteration: no blockers. Minting `service` (registry edit in
toon-meta/FACTORY.md, toon-meta#207's toon-meta-side scope) and
archetype-specific workflow stamping (release.yml/publish-*-image.yml/
deploy/) are explicitly out of this diff's scope.

Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
The service archetype tests (Forge#49) copied the game archetype's
inline parseToml-result type verbatim. Extract a shared
readArchetypeToml() helper so the shape lives in one place.
@ALLiDoizCode ALLiDoizCode added the agent:review One labeled review action over a PR. Fires the sandcastle review runner. label Aug 9, 2026
sandcastle-reviewer and others added 2 commits August 9, 2026 20:51
relay's actual pinned CONNECTOR_TAG (deploy/Dockerfile, deploy/.env.example)
is rust-sha-440eab7; 3.28.0 is the retired TypeScript connector's version,
mentioned only in a historical comment in relay's connector.toml, not the
current pin.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent:review One labeled review action over a PR. Fires the sandcastle review runner.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

forge-cli: author templates/archetypes/service/ from the relay pilot + strip mint status from archetype bundles (ADR-0002)

1 participant