Repository navigation
Cross-generation similarity: the fingerprint the log never read - #97
Open
muditagrawal2007 wants to merge 2 commits into
Open
muditagrawal2007 wants to merge 2 commits into
muditagrawal2007 wants to merge 2 commits into
Conversation
Gate 32 and macrostructures.md both say a build may share no more than three of the six fingerprint axes with any of the last three logged entries, and theme.mjs log has required a fingerprint field since v2. But nothing ever read it: the field was written and never compared, so the one defence against a second page that looks like the first was a sentence in a reference file, checked by memory. Issue Nutlope#28 asks for a cross-generation similarity check. This is it. - theme.mjs reads the six axes and their vocabulary, and every shape file now states its own fingerprint, so a shape is a fingerprint with a name. - theme.mjs check --fingerprint measures a plan against the last three logged builds, names the axes they share and exits 1 when more than three are shared. - theme.mjs log refuses a build whose fingerprint is already logged, and warns when more than three axes are shared; a redesign keeps the fingerprint it has. - theme.mjs draw keeps clear of a shape that repeats a logged fingerprint, and states the fingerprint of the shape it deals. - theme.mjs fingerprint prints the axes and the twenty-one shapes. - refcheck holds the vocabulary in the code, the vocabulary in the docs and the twenty-one shape files in step. - The first test suite in the repo: seventeen tests over the fingerprint, the log and the draw, on the built-in runner, in CI.
|
@muditagrawal2007 is attempting to deploy a commit to the Together AI Team on Vercel. A member of the Team first needs to authorize it. |
… the last three builds
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #28.
The issue
references/gates.mdgate 32 andreferences/macrostructures.md§ The fingerprint say the same thing:and
scripts/theme.mjs loghas required afingerprintfield since v2. But nothing ever read it. The field was written to.hallmark/log.jsonand never compared with anything. So the one defence against a second page that reads like the first was a sentence in a reference file, checked from memory, by a model that will not remember.theme.mjshad the pieces and none of the join. It compared a theme's threeaxes(paper, display, accent) against the log, and it compared the shape, hero, nav and footer by substring. The field that carries the page's actual structure was inert.#28 asks for a cross-generation similarity check. This is that check, wired into the three places a build touches the log.
The solution
The fingerprint, made readable.
theme.mjsnow knows the six axes and the vocabulary each one answers in, taken frommacrostructures.md§ The fingerprint. Every one of the twenty-one shape files states its own fingerprint as one line, so a shape is a fingerprint with a name:check --fingerprintmeasures a plan against the last three logged builds, names the axes they share and exits 1 when more than three are shared.logrefuses a build whose fingerprint is already logged, and warns when more than three axes are shared. A redesign keeps the fingerprint it has.drawkeeps clear of a shape that repeats a logged fingerprint, and states the fingerprint of the shape it deals, so the value reaches the stamp and the log entry.theme.mjs fingerprintprints the six axes and the twenty-one shapes, so a build can read the ruler it is measured against.The rule the docs already state is now the rule the tool runs: a None on Image or Reveal is the absence of a choice, not a choice, so it never counts as a shared axis.
The tests
theme.mjshad no automated coverage at all. This adds the first suite in the repo, on Node's built-in runner, no dependency:skills/hallmark/scripts/tests/theme.test.mjs, seventeen tests.macrostructures.mdMarginaliais not a headingrefcheckholds three things in step now: the vocabulary in the code, the vocabulary inmacrostructures.md, and the twenty-one shape files. Change one and it says which.CI runs both:
npm testandnpm run verifyare new.Notes for the reviewer
refcheckwill keep the file honest either way.theme.mjs checkkeeps its--axes,--faceand--huebehaviour.--fingerprintis a new branch, and it exits 1 when it is over the limit so a build script can act on it.site/changed, and the skill's own sweep over the showcase is unchanged at 2 FAIL / 10 REFLEX (those are pre-existing, insite/style.css).Note for the reviewer: GitHub holds the workflow on a first-time contributor's fork until a maintainer approves it. The three CI steps pass locally:
refcheckclean across 101 reference files, 17 of 17 tests, every theme validates, the theme index unchanged.🤖 Generated with Claude Code