Skip to content

Classify bounded article image-well geometry evidence - #483

Draft
chubes4 wants to merge 1 commit into
mainfrom
fix/480-image-well-proof
Draft

chubes4 wants to merge 1 commit into
mainfrom
fix/480-image-well-proof

Conversation

@chubes4

@chubes4 chubes4 commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

Summary

Extend the existing layout geometry proof export with a source-derived discriminator for article image wells, making eligible geometry easier for downstream imports to identify and edit while retaining the existing bounds and overlap protections.

What changed

  • Classify accepted reductions as `article_image_well` when the target is an `img` or `picture` within an `article`; retain `generic` for all other reductions.
  • Preserve existing source-path and source-hash identification, viewport and candidate bounds, and non-overlapping reduction selection.
  • Add regression coverage for the article image-well classification and document the exported discriminator.

How to test

  1. Run npm test -- src/lib/screenshot/layout-geometry-proof.test.ts; expect passes as recorded by Cook's deterministic gate.

Compatibility

Additive proof-schema content: consumers can use the new `kind` discriminator, while existing node evidence and generic classifications remain available. Runtime change is limited to classification based on the final exported DOM; it does not change capture selection or geometry acceptance. Source relationship: existing layout-geometry proof pipeline. Change kind: additive export metadata. Verification capability: focused test and diff checks. Evidence boundary: only accepted reductions targeting `img` or `picture` inside an `article` receive the image-well label.

Evidence

  • Verified command npm test -- src/lib/screenshot/layout-geometry-proof.test.ts: status=succeeded; candidate commit 5d13ad731b293dd926600a6acb38a8f830673841, tree 9c2b5ae6e57bc829b4a8414c30efb2ed95f83fc3, fingerprint 73b99c294dca7c750588871dc8be7f1c1603708cf33d46587838aa7583b0a78c; durable gate gate-1
  • Base unchanged since verification: main remains at 8bf92c3.
  • CI expected: Homeboy CI after push
  • Candidate adoption provenance: the candidate was promoted from the recorded Cook task execution.
  • Cook deterministic verification: 1 gate(s) completed green.
  • Durable run execution: Succeeded
  • Reviewer-resolvable evidence from source_refs[0]: Export source-identified image-well geometry for editable imports, beyond redundant wrapper reductions #480
  • Task objective: Export bounded source-identified nonredundant article image-well geometry for editable downstream imports
  • Verified candidate scope: 3 changed file(s): docs/layout-geometry-proof.md, src/lib/screenshot/layout-geometry-proof.test.ts, src/lib/screenshot/layout-geometry-proof.ts.
  • Verified finalization base: main at 8bf92c3
  • deterministic gate passed: sh -lc npm test -- src/lib/screenshot/layout-geometry-proof.test.ts (Passed)

AI assistance

  • AI assistance: Yes
  • Tool(s): Homeboy (opencode)
  • Model: openai/gpt-6-luna
  • Used for: Inspected the existing capture, proof-export contract, documentation, and tests first; added bounded source-derived classification and regression coverage. `git diff --check` passed. The focused test command was attempted but could not run because Vitest is unavailable in this workspace; this is an observation, not a final gate result. Homeboy runs the declared deterministic gate after harvest.

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.

1 participant