Skip to content

build-set: one compact conformance suite per set, and no template leftovers - #23

Open
afflom wants to merge 7 commits into
mainfrom
claude/set-compact-suite
Open

afflom wants to merge 7 commits into
mainfrom
claude/set-compact-suite

Conversation

@afflom

@afflom afflom commented Nov 15, 2026

Copy link
Copy Markdown
Owner

Requested by Alex · project thread

Why

Building afflom/prism-kat (seven apps, one set) straight from build-set hit four things I had to patch by hand. The goal is that a Prism is only its content (the prompts and the set) and the builder imports everything else.

  1. The only-Prism ratchet (Only Prism is implemented (audit-prism), and the frame lock binds frame/ and identity/ UOR-Foundation/template#91, audit-prism) refuses net growth in non-Prism code. build-set wrote one Rust suite per app, each repeating the same four helpers, so the fresh seven-app instance added 8 files and 510 lines and failed against main.
  2. The template example's src/Contract.lex.tex stayed in app/lexlean.toml's entrypoints (LLC0101), because it was still on disk when the entrypoints were read.
  3. The prism.qual and prism.sec lexicons were never declared when lexlean.toml already listed sources (LLR3001).
  4. The template's TC-01 register row survived its removed scenario and test, which failed the honesty gate (CM-02). Also, site/app.json kept the template's promise text.

What changes (builder/set.mjs)

  • A set writes one crates/conformance/tests/<set>.rs: one pins helper, then one #[test] line and one fn line per claim in a #[rustfmt::skip] module. Each test makes the same two assertions as before (a property's condition plus "no request meets it", or a facet theorem's statement plus decide). For prism-kat that is 75 counted lines, against the 82 of the template example it replaces. Per-app suites the set no longer writes are added to remove.
  • Entrypoints never keep TEMPLATE_EXAMPLE paths, and a missing prism.arch, prism.qual or prism.sec source is appended.
  • The contract suite's rows go when the template example is replaced (not when a set is hosted by a repository's own root).
  • site/app.json's promise comes from the set's optional promise member, or else from its title and purpose.

Single-prompt build is unchanged.

Checked

  • node builder/test.mjs passes DR-07, 08, 09, 10, 12, 13, 14, 17, 18, 19, 20, 21 and 22. I did not run DR-11 here: it builds every example in the template.
  • build-set into a fresh template copy writes no Contract entrypoint, declares all three prism lexicons and keeps no TC-01 row. Its suite passes rustfmt --check, and the template's workspace_test_names sees every claim's test.
  • prism-kat pins this branch's head; its gate is running in the pinned SDK image.

Generated by Claude Code

…tovers

The template's audit-prism ratchet refuses net growth in non-Prism code,
and build-set wrote one Rust suite per app, each repeating the same four
helpers: a fresh seven-app instance added 8 files and 510 lines and failed
it. A set now writes one crates/conformance/tests/<set>.rs: one helper
that pins a declaration's text, and one table line per claim, expanded by
a macro into a test named for its ID. Each test asserts what the old ones
did. Per-app suites a set no longer writes are removed.

Three leftovers of the template's example app also go: its Contract
entrypoint stays out of app/lexlean.toml, its TC-01 register row is
dropped with its scenario and test, and the prism.qual and prism.sec
lexicons the facet modules use are declared even when lexlean.toml
already lists other sources. site/app.json's promise comes from the set's
optional 'promise' member, or its title and purpose, instead of the
template's.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Asa3Ns5C7CRWRVtEQBxEq
The template's honesty gate reads test names from a '#[test]' line and the
'fn' line after it, so tests a macro expands are invisible to it. Each
claim is now one '#[test]' and one 'fn' line in a #[rustfmt::skip] module,
still 75 counted lines for a seven-app set against the 82 of the template
example it replaces.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Asa3Ns5C7CRWRVtEQBxEq
@afflom afflom self-assigned this Nov 15, 2026
The single-app and set builders now share the compact suite writer, so the
old per-app generator goes and the builder shrinks (81 lines out, 54 in),
as the only-Prism ratchet asks.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Asa3Ns5C7CRWRVtEQBxEq
…ct.rs

The template's only-Prism ratchet refuses any new non-Prism file, so the set's
compact suite replaces the template example's test file instead of adding one,
and any earlier per-app or per-set test file is removed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Asa3Ns5C7CRWRVtEQBxEq
Four fewer generated lines per suite, so a model with more claims still
shrinks the instance's non-Prism code.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Asa3Ns5C7CRWRVtEQBxEq
…t runs in

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Asa3Ns5C7CRWRVtEQBxEq
…tes its design/ files

With the merged OPM and UML views, prismpm verify's second regeneration does
not reproduce the design/ files build emits, so verify refuses with PP5004.
Removing Design (and its Compliance import and obligation) makes the set's
app verify. The single-app build keeps its Design module.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Asa3Ns5C7CRWRVtEQBxEq

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants