Luca analyst v1: system prompt, read-only skills, verifier, evals#214
Merged
Conversation
…a, framing traps)
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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.
What this is
Luca v1 — the financial analyst of Zetta, built to the spec we agreed: he reads Zetta's published data and explains it. The ledger decides what is true; Luca decides how to explain it. He runs on Hermes (GPT-5.4) with his own verified wallet.
What's in this PR
The five trust mechanisms
get_agent_snapshot,get_revenue_quality,get_unresolved_items,get_anomalies,compare_periods,get_leaderboard. Public skills hit the PR Build backend financial intelligence engine #202 public API; internal skills are operator-gated behindZETTA_INTERNAL_SECRET. Luca never gets raw DB access and never computes his own deltas (server-computed only).src/verify-response.ts) — post-processing hook that extracts every $ figure and % from Luca's draft and confirms each one traces to a skill response (with rounding + percent↔fraction tolerance). Uncited figure → draft rejected. Plus forbidden-phrase guardrails ("wallets received revenue", "you should buy", hype).Backend work this PR surfaces (follow-up, not included)
The skills expect 5 small read-only endpoints that don't exist yet — all are simple queries over PR #202 tables:
GET /api/v1/financial-intelligence/{slug}/compare(public)GET /api/v1/financial-intelligence/leaderboard(public)GET /api/admin/financial-intelligence/revenue-quality(internal)GET /api/admin/financial-intelligence/unresolved(internal)GET /api/admin/financial-intelligence/anomalies(internal)Until those ship, Luca's public mode works against the existing
GET /api/v1/financial-intelligence/{slug}.Notes
luca/directory.