feat(evals): eval system with LLM judge, JSONL push, and React UI#8
Merged
Conversation
- Migrate 8 test cases from inline array to evals/cases/*.json - Add LLM judge (Groq json_object mode) with score + reasoning - Write JSONL per run, push to openwalletvn/evals via GitHub API - Add evals/server.ts (port 3006, trigger endpoint) - Add evals/ui/ — Vite+React UI with RunList, RunDetail, PromptCompare - Add evals/wrangler.toml for Cloudflare Pages deploy - Add .github/workflows/eval-run.yml and evals-site.yml - pnpm evals → single port 3005, /server proxy to backend Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
- Fix CWD bug in server.ts (parent of web/ → web/) - Add SSE streaming: POST trigger returns runId, GET stream/:runId pipes stdout in real-time via EventEmitter fan-out - Add triggered_by (ui/cli/ci) and system_prompt fields to EvalResult - UI: two-column layout, dark terminal progress panel, card-based run list with tag summary and trigger badge, run detail with full system prompt + expandable AI responses + judge/rule disagreement flag - Rewrite 13 eval cases with realistic Vietnamese queries: shopee+supermarket cashback, no annual fee, travel abroad, installment 0%, hallucination guards for fabricated rates, out-of-scope: gold/stocks/real estate - Add .claude/docs/evals.md maintenance documentation Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Single case selector: dropdown grouped by tag, runs just one case - Push to GitHub checkbox: skip polluting results with WIP runs - Delete run: button per card proxies GitHub Contents API delete - Re-run failures: button appears when selected run has failing cases - Live progress: SSE streaming with current case name + N/M counter - System prompt per run: expandable with GitHub blob link at that SHA - Trigger source tracking: ui/cli/ci badge on each run card - Score trend arrow vs previous run, disagreement flag (rule vs judge) - Copy button on AI response, inline re-run per test case card - Relative timestamps with absolute on hover, descriptive button labels Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…X features Co-Authored-By: Claude Sonnet 4.6 <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.
Summary
evals/cases/*.jsonresponse_format: json_object) scoring 1-100 per runopenwalletvn/evalsrepo via GitHub APIevals/top-level directory — completely separate fromadmin/(blog)evals/server.ts— Express on port 3006 (trigger endpoint only)evals/ui/— Vite+React UI: RunList, RunDetail, PromptCompare, TriggerButtonevals/wrangler.toml— Cloudflare Pages config forevals.openwallet.vn.github/workflows/eval-run.yml— runs evals on PR +workflow_dispatch.github/workflows/evals-site.yml— deploys UI to Cloudflare Pages on push to mainUsage
Pending secrets (GitHub repo settings)
EVALS_GITHUB_TOKEN— PAT withcontents:writeonopenwalletvn/evalsCLOUDFLARE_API_TOKEN+CLOUDFLARE_ACCOUNT_ID— for evals-site.yml deployTest plan
npx tsx scripts/eval-chat.ts→ 8/8 pass, avg score 81, JSONL pushed to evals repopnpm build→ Next.js build cleanpnpm evals:build→ Vite UI build cleangit diff origin/preview -- admin/server.ts→ empty (blog admin untouched)🤖 Generated with Claude Code