Skip to content

[renderer] Core + signpost slice#348

Closed
leeovery wants to merge 1 commit into
mainfrom
feat/render-core-signpost
Closed

[renderer] Core + signpost slice#348
leeovery wants to merge 1 commit into
mainfrom
feat/render-core-signpost

Conversation

@leeovery

@leeovery leeovery commented Jun 4, 2026

Copy link
Copy Markdown
Owner

Summary

First code slice of the deterministic renderer (idea #32; design log in #346). Adds skills/workflow-render — a library and CLI sharing one wrap/width core, so the gutter-budget bug can exist in exactly one place.

  • Core: fillTo, wrap (greedy + hard-split), wrapWithPrefix (budget = width − prefix.length; throws on an impossible prefix rather than overflowing).
  • Shapes: signpost (step / sub-step markers), box (phase-title).
  • CLI for Claude (via Bash) and module.exports for data-owning scripts to require() in-process (guarded by require.main). SKILL.md API reference.
  • Scoped to signposts; menus/lists/trees stack on this core next.

Test plan

  • node --test tests/scripts/test-render.cjs — 17 tests (core invariants, prefix-budget guard, shape widths).
  • Validated byte-for-byte against live hand-drawn shapes in the skills: 8/8 ── … ── step markers and the ●──● border match exactly.
  • Surfaced (did not change) existing drift: ·· Document Review ·· is 50 chars in two files, 49 in a third — the renderer normalises to the canonical 49.

🤖 Generated with Claude Code

First slice of the deterministic renderer (idea #32). Adds
skills/workflow-render — a library+CLI sharing one wrap/width core:

- core: fillTo, wrap (greedy + hard-split), wrapWithPrefix (budget =
  width - prefix.length, the single home of the gutter-budget bug)
- shapes: signpost (step/sub-step markers), box (phase-title)
- CLI (Claude, via Bash) + library (scripts require() in-process)
- SKILL.md API reference; 17 tests

Proven byte-exact against live hand-drawn markers/borders pulled from
skills; surfaced existing 50-char sub-step drift the renderer normalises.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@leeovery

Copy link
Copy Markdown
Owner Author

Consolidated into #380 (single branch off current main, same content, additive-only). Closing to keep one clean hand-off PR.

@leeovery leeovery closed this Jun 10, 2026
@leeovery leeovery deleted the feat/render-core-signpost branch June 10, 2026 18:42
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