Phase 3: playground — grounded extraction demo (Hono API + Vite/React) - #3
Merged
Conversation
apps/playground: drag-drop a PDF/image, watch fields stream in, hover a field to highlight its source region on the page. - Hono API (@hono/node-server): GET /api/config, POST /api/extract streamed as SSE via core's streamExtract; model registry injectable so routes test against a mock model with no API key. - Vite/React client: pdfjs for PDFs (lazy-loaded) + images, bbox overlays from core's normalized coords, live field reveal, per-field confidence, token usage and cost. - Preset invoice/receipt schemas defined server-side; models resolved from whichever provider keys are present. - 50 tests (SSE parser, geometry, field tree, upload, model/schema registries, full /api/extract SSE flow); dual client/server tsconfigs. Docs (README, ROADMAP, CLAUDE.md, apps/playground/README) updated. The demo GIF + first live extraction remain gated on a provider key. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
Ships Phase 3 of the roadmap:
apps/playground, the hosted demo. Drag-drop a PDF/image, watch fields stream in, and hover a JSON field to highlight the exact region it came from on the page.What's here
src/server) — Hono on@hono/node-server:GET /api/config— preset schemas + models resolved from whichever provider keys are setPOST /api/extract— multipart upload streamed back as SSE, driving core'sstreamExtract, then a terminalresultor typederrorsrc/client) — Vite + React 19: drag-drop with validation,pdfjsfor PDFs (lazy-loaded) + images, bbox overlays from core's normalized 0–1 coords, live field reveal, per-field confidence bars, token usage + cost.Verification
Still gated on a provider key
The demo GIF and first end-to-end live extraction need a real provider key — the same gate as the Phase 2 first live run — so that ROADMAP item stays unchecked rather than fabricated.
🤖 Generated with Claude Code