Skip to content

docs(readme): expand hero to define the whole block, then get#5

Merged
saba-ch merged 1 commit into
mainfrom
readme-full-block-example
Jun 8, 2026
Merged

docs(readme): expand hero to define the whole block, then get#5
saba-ch merged 1 commit into
mainfrom
readme-full-block-example

Conversation

@saba-ch

@saba-ch saba-ch commented Jun 8, 2026

Copy link
Copy Markdown
Member

The root README hero only showed .get(). This expands it to define the
whole nutrition Thinking Block — schema (the spec), agent, identity
(the serial), prepareCall, and both QC gates (check code-caliper +
judge model-inspector) — and then call .get({ food: "dragon fruit" }).

  • Mirrors examples/nutrition/src/block.ts (Atwater reconcile tolerance,
    judge wiring) so it stays faithful to the real, tested API.
  • Uses the AI SDK gateway model string "openai/gpt-5" like the flagship
    README, so imports match npm install thinking-blocks ai zod exactly.
  • Verified: dropped the snippet into the nutrition example's package
    and ran tsc --noEmit. First pass without validator generics failed
    ('output' is of type 'unknown'); added check<…> / judge<…> params
    to match block.ts and it's green.

🤖 Generated with Claude Code


View with Codesmith Autofix with Codesmith
Need help on this PR? Tag /codesmith with what you need. Autofix is disabled.

The root README hero only showed `.get()`; expand it to define the full
ThinkingBlock — schema, agent, identity, prepareCall, and both QC gates
(check + judge) — and then call `.get()`. Mirrors examples/nutrition's
block.ts (Atwater reconcile tolerance, judge wiring) and uses the AI SDK
gateway model string so imports match `npm install thinking-blocks ai zod`.
Verified with `tsc --noEmit` in the nutrition example's package context.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@saba-ch saba-ch merged commit d4156ae into main Jun 8, 2026
1 check passed
@saba-ch saba-ch deleted the readme-full-block-example branch June 8, 2026 17:29
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