Review Data Questions and SQL Answers with Jev
这是 Sumanth 公开的项目资料。本站按原始来源展示项目信息,用中文说明适用场景和阅读边界;项目名、源帖与代码保持原样,便于逐项核对。
这条案例记录了什么
Agent 评估、安全与权限门禁
为已记录的输出或轨迹提供分类、分数或复核信号。
社区公开项目或作者演示
原始来源:Sumanth via X。作者自述,本站未独立复现。
Sumanth
记录日期:2026-10-07。日期与身份应以原始资料为准。
怎样核对这个项目
- 先打开原始来源,确认作者、日期与 Jev 在项目中的具体用途。
- 如果提供仓库,再检查代码、运行要求和许可证;仓库存在不代表本站已经运行成功。
- 对速度、成本、准确率和规模数字,查看原文的任务、环境和计算口径。
- 是否有可观察的正确答案。
- 评估输入是否完整。
- 分数与人工复核的一致性。
- 高风险动作是否单独授权。
原始文字与技术细节
以下内容保留原语言,供核对事实。中文页的场景说明是阅读提示,不是逐句翻译或实测结论。
展开英文项目摘要与原帖
项目摘要
Ask questions about a SQLite database in plain English. Qwen generates SQL and explanations; Jev reviews whether the question is clear, the SQL matches it, and the explanation is supported by returned rows. Deterministic code enforces read-only execution and row limits; Vercel Eve manages the agent loop and human approvals.
来源原文
I built a data analyst agent with Jev as the review layer! Qwen handles the main agent work, Jev acts as the review layer, and Vercel eve runs the agent loop, tool execution, and human approval flow. The agent takes a plain-English question about the data, inspects the database schema, writes the SQL, runs the query, and explains the result. The interesting part is what happens around that main loop. Qwen is responsible for generating the SQL and the final answer, while Jev reviews the parts where semantic judgment is actually useful. Anything that can be checked reliably with code stays deterministic. Jev reviews the agent at three points: - Before the agent starts, it checks whether the user's question is clear enough to answer from the available data. - After Qwen generates the SQL, it checks whether the query actually represents what the user asked. - After the query runs, it checks whether the final explanation is grounded in the returned rows. For example, we tested it with: “Who is our best customer?” The question sounds simple, but “best” could mean highest revenue, most purchases, highest average order value, or something else. Instead of letting Qwen silently choose a metric, Jev flagged the question as ambiguous and asked for clarification. The same separation applies to SQL execution. Qwen can propose a query, but it cannot decide whether that query is safe to run. The tool accepts only a single read-only `SELECT`, SQLite runs in read-only mode, results are capped at 200 rows, and queries without a `WHERE` clause can require human approval before execution. Those checks do not need another model call. But a query can be completely safe and still answer the wrong question. A deterministic rule can verify that the SQL is read-only. It cannot reliably judge whether a query for “revenue last month” accidentally calculates revenue across all time. That is where Jev comes in. It reviews the proposed SQL against the original question and schema before execution. After the rows come back and Qwen writes the explanation, Jev reviews that answer again to check whether the claims are actually supported by the returned data. The project uses a local SQLite sales database, Qwen through the Vercel AI Gateway, Gradio for the interface, and only two database tools: "inspect_schema" and "run_sql". No single model is responsible for everything. Qwen generates, Jev reviews, deterministic code controls execution, and Vercel eve manages the agent loop and approval flow. GitHub Repo: https://github.com/Sumanth077/Hands-On-AI-Engineering/tree/main/ai_agents/nl_data_analyst_agent 100% open source.
原记录的限制
- Source and code inspected; no independent end-to-end analysis or performance benchmark was run.
- The default Jev confidence threshold is 0.70. Low-confidence, inconsistent or unavailable reviews fail open with notes; deterministic SQL restrictions and approvals still apply.
- Designed for local SQLite use. Public or production deployment needs authentication, access controls and stronger query limits.
- Question, schema and answer evidence are sent through the configured model gateway; use appropriate data for the provider.