Skip to content

feat(scaffold): reroute materializer to @stackbilt/scaffold-core#53

Merged
stackbilt-admin merged 4 commits into
mainfrom
feat/scaffold-core-reroute
Jun 12, 2026
Merged

feat(scaffold): reroute materializer to @stackbilt/scaffold-core#53
stackbilt-admin merged 4 commits into
mainfrom
feat/scaffold-core-reroute

Conversation

@stackbilt-admin

Copy link
Copy Markdown
Member

Summary

  • Replaces materializeScaffold calls in gateway.ts and rest-scaffold.ts with buildScaffold from @stackbilt/scaffold-core
  • Adds @stackbilt/scaffold-core: ^1.0.0 to package.json
  • Introduces scaffold-core-shim.ts as a temporary bridge (wraps the existing local materializer behind the LocalScaffoldResult API contract) until charter#220 publishes the package
  • buildScaffold returns ScaffoldFile[] with { path, content, role } — both call sites strip role when forwarding files to consumers
  • scaffold-materializer.ts is retained for now (shim depends on it); delete it along with the shim once the package is live

Activation path once charter#220 merges

  1. npm install picks up @stackbilt/scaffold-core
  2. Uncomment the direct import { buildScaffold } from '@stackbilt/scaffold-core' lines in gateway.ts and rest-scaffold.ts
  3. Delete src/scaffold-core-shim.ts and src/scaffold-materializer.ts

Test plan

  • npm run typecheck — clean
  • npm test — 183/183 passing
  • npm install --dry-run confirms 404 on unpublished package (expected; shim path handles it)
  • After charter#220 publishes: swap to direct import, delete shim + materializer, re-run tests

Closes #50

🤖 Generated with Claude Code

Kurt Overmier and others added 3 commits June 12, 2026 06:03
Replaces direct `materializeScaffold` calls in gateway.ts and
rest-scaffold.ts with `buildScaffold` from @stackbilt/scaffold-core.

Because charter#220 (publish) is still open, a shim at
scaffold-core-shim.ts bridges the gap: it wraps the existing
scaffold-materializer.ts behind the LocalScaffoldResult API contract
(files with { path, content, role }, plus nextSteps). Both call sites
strip the `role` field when forwarding files to downstream consumers.

When charter#220 merges:
  1. `npm install` picks up @stackbilt/scaffold-core
  2. Uncomment the direct import in gateway.ts and rest-scaffold.ts
  3. Delete scaffold-core-shim.ts and scaffold-materializer.ts

TODO comments reference charter#220 in both changed files.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…caffold-core@1.0.0

Removes the local scaffold-core-shim.ts and scaffold-materializer.ts; gateway.ts
and rest-scaffold.ts now import directly from the published npm package. Removed
the non-existent `nextSteps` field references (LocalScaffoldResult has no such
field — fallback generation handles next steps downstream). Typecheck clean,
183/183 tests green.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…minates TarotScript 401

scaffold_classify was calling TarotScript /run (classify-cast spread) without auth,
causing HTTP 401. Now calls classify() from @stackbilt/scaffold-core directly: zero
network, zero inference, <1ms. Returns pattern/confidence/traits/qualityProfile.
Updated gateway test to verify output shape instead of header pass-through.

Closes #51

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@stackbilt-admin stackbilt-admin merged commit 67fe1f8 into main Jun 12, 2026
1 check passed
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.

feat: scaffold_create routes to @stackbilt/scaffold-core (canonical engine, replaces TarotScript scaffold-cast)

1 participant