Spaces:
Sleeping
Sleeping
Commit History
-
perf: deterministic-first model routing; trim model ctx/tokens
Stephen Lee +1: Claude Opus 4.8 (1M context)On the live CPU Space the model sat on the hot path for every question. Reorder interpret_question to try the deterministic source lookup first and call MiniCPM only when a question doesn't cleanly resolve (messy/underspecified input) — clean questions and the example chips now answer instantly, while the model still runs and normalizes the hard cases. Trim n_ctx 2048->1536 and max_tokens 400->200 so the calls that do happen are lighter. Tests: route the two model-path tests through genuinely underspecified questions (no explicit species token) so they still exercise the model + its fact-type guard. 171 pass. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>6d498ea -
feat: source-derived Q&A with statewide CA ocean species coverage (#1)
Stephen S. LeeUnverified signatureSource-backed Q&A over the full California ocean sport-fishing species set. - 78 distinct species with source-verified facts (size/bag/season/closure), every value traced to a CDFW page or CCR Title 14: groundfish (RCG complex), halibut, surfperch, seabass, sharks, sturgeon, crab, salmon, SoCal gamefish (kelp/sand bass, sheephead, barracuda, bonito, yellowtail), nearshore species, invertebrates (spiny lobster, scallops, squid, clams), and no-take species. - Species resolution: model (MiniCPM) + deterministic name search with a guard that prefers specific user-typed aliases (length-aware scoring), plus a rule-card posture fallback for species without an extracted fact. - "Refresh official sources" applies live snapshot freshness to the session; structured facts stay curated and are never auto-derived from fetched HTML. - Answers state regulations directly (source shown in the evidence section). 171 tests pass; verified end-to-end on the local MiniCPM model server.c1b067e -
feat: redesign CoastWise UI (Ocean & Trust) and harden source freshness
Stephen Lee +1: Claude Opus 4.8 (1M context)UI/UX (ui-ux-pro-max "Ocean & Trust"): - Custom teal/navy theme with Lexend + Source Sans 3, branded header with offline-ready badge, status-badge answer cards, an honest "How CoastWise reached this answer" disclosure, example-question chips, light/dark pairing, responsive layout, and WCAG-minded contrast/focus. - Search-bar layout: the Ask button is embedded inside the question field. - Top source bar shows "Sources updated <time> - <freshness>" with a compact refresh icon button. Gradio 6 fixes: - Apply theme/css via launch() (silently ignored on gr.Blocks in Gradio 6). - Set answer text via the mode-adaptive --body-text-color so colors stay legible in light and dark (Gradio mangles .dark custom selectors and its ".prose *" rule outranks single-class colors). - Bounded, concurrent, offline-first Refresh that never hangs the UI, with a "Checking..." state and graceful "using last-good cache" messaging. Content/data: - Re-stamp the bundled seed cache to 2026-06-15 so an…4a604dd
-
fix: cover real query source retrieval gaps
Stephen Lee5aad229 -
feat: ship source-backed Gradio Q&A
Stephen Leea975979 -
feat: add official source cache foundation
Stephen Leea3c85ad -
feat: answer crab season from cached evidence
Stephen Lee8857545 -
feat: guard cached evidence synthesis
Stephen Leedce1360 -
feat: build cached evidence packets
Stephen Lee38d8c96 -
feat: add real query cache coverage
Stephen Lee95941cd -
feat: normalize real query aliases
Stephen Lee7cdae4e -
Block bare Dungeness topic fallbacks
Stephen Leed7e6d20 -
Tighten Dungeness fallback guard
Stephen Lee12498dd -
Tighten Dungeness generic fallback tests
Stephen Lee42968f0 -
Allow concrete Dungeness harvest answers
Stephen Lee12b7082 -
Tighten Dungeness fallback matcher
Stephen Lee222f0a1 -
test: catch more dungeness unknown status fallbacks
Stephen Lee5d0e344 -
test: catch unavailable dungeness harvest status
Stephen Lee21993da -
test: catch dungeness harvest status without authority
Stephen Lee787bc14 -
test: catch dungeness harvest status fallback
Stephen Lee9b8306e -
test: allow sourced dungeness open season answers
Stephen Leebd3c0a8 -
test: catch dungeness harvest intent fallback
Stephen Leedd077ea -
test: catch dungeness harvest status fallback
Stephen Lee7a9c247 -
test: flag dungeness open closed alternatives
Stephen Lee8e567a4 -
test: narrow dungeness concrete result guard
Stephen Leea2a9026 -
test: allow concrete dungeness direct answers
Stephen Lee7c45bab -
test: broaden dungeness fallback guard
Stephen Leea4b0d07 -
test: use semantic dungeness fallback guard
Stephen Lee9a762a9 -
test: bound forbidden claim matching
Stephen Leec5ee242 -
test: tighten forbidden claim negation scope
Stephen Lee6af4519 -
test: scope dungeness fallback to direct answer
Stephen Leed97637b -
test: allow negated forbidden answer claims
Stephen Lee38de4b2 -
test: narrow certification forbidden terms
Stephen Leeaf29444 -
test: narrow safety forbidden phrases
Stephen Leec209e4b -
test: reduce real query fixture brittleness
Stephen Leeb05c101 -
test: scope required answer terms to answer copy
Stephen Leebc261f9 -
test: separate real query assertion buckets
Stephen Lee09d198a -
test: accept species display casing
Stephen Lee65d2220 -
test: add real CoastWise query fixture
Stephen Lee8630a18
-
Clarify CoastWise safety limits
Stephen Lee63bec9a -
Implement reference image photo candidates
Stephen Lee1ccc8be -
Implement hackathon readiness helpers
Stephen Leebfa2cf4 -
Implement advisory and context overlays
Stephen Leede1d671 -
Implement CoastWise search and rule cards
Stephen Leed3470b3 -
Implement CoastWise foundation
Stephen Leec41387e