
andon
io.github.gulmezeren2-byte由 GitHub 帳號 gulmezeren2-byte 發布v0.6.0更新於 Nov 3, 2026
Deterministic verification for AI-generated analysis: run a spec, inspect or diff a workbook
概覽
以確定性算術複核成品報告與 Excel 活頁簿中的數字是否與來源相符,並向助理提供 run、inspect、diff 三個工具。
- 可以做什麼
- 依 YAML 規格執行算術檢查:對帳、內部一致性、schema 契約與 Excel 完整性
- 不需規格即可對活頁簿做完整性掃描,找出錯誤儲存格、被手動覆寫的公式、存成文字的數字與隱藏列
- 比較兩個活頁簿版本並分類每項變更,單獨標出新出現的錯誤儲存格與數值變動
- 回傳欄位名稱穩定的結構化結論與結束碼,並對未能讀取全部數值的檢查提供覆蓋計數
- 適用情境
- 適合助理起草分析、報告或試算表後,在結果被送出、提交或合併前設下一道機械化關卡。也適用於 CI 流程、pre-commit 鉤子,以及需要明確通過/不通過結論的代理工作流程。
- 執行需求
- 以 stdio 本機程序執行;安裝 andon-verify 的 PyPI 套件與 mcp 附加項目後啟動 andon-mcp 指令,或建置隨附的 Docker 映像。parquet 與 DuckDB 資料來源需要額外附加項目。未宣告任何帳號、API 金鑰或環境變數。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 andon,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
andon
Stop the line when the numbers don't add up.
[CI] [PyPI] [Python] [License: MIT]
andon re-checks the numbers in finished analysis — the report your AI agent just drafted, the workbook a colleague "quickly updated" — against the data they came from and against themselves. It does this with arithmetic, not with another LLM: reconciliation, internal consistency, schema contracts and Excel workbook integrity, written down as a small YAML spec and enforced with exit codes.
[andon stopping the line on a sabotaged quarterly report]
That screenshot is real output. The example it runs on is in
examples/quarterly-report/, staged by a script that
plants the defects I keep meeting in real reporting work: a count taken from a stale
snapshot, a revenue total typed over by hand, shares that sum to 101.2, a total row
nobody updated after a data refresh, a #REF!, and freight numbers stored as text.
Why this exists
I'm an industrial engineer. I build and run operations reporting — delivery KPIs, forecast accuracy, inventory analytics — and over the last two years an increasing share of the first drafts around me has been written by AI agents. They are fast, tireless, and confidently wrong in ways a tired human is not: the filter that silently dropped cancelled orders, the percentage column that almost sums to 100, the total row that survived three edits of its parts.
The common answer is to ask a second model to review the first one. I think that is the wrong tool. Whether 539 rows really sum to 257,060.48 is not a matter of opinion, and no amount of model capability makes an opinion the right instrument for it.
Manufacturing solved this problem decades ago. On a Toyota line, any worker who spots a defect pulls a cord — the andon — and the line stops until the problem is understood. The machine equivalent, jidoka, is a machine that stops itself when it detects an abnormal condition. This tool is that cord for spreadsheets and reports: a small, deterministic gate between "the analysis is written" and "the analysis is sent."
The iron rules
andon's behavior is easier to trust because it is constrained. These rules are enforced in code, not just promised here:
- Only arithmetic can fail the build. Heuristic checks (distribution shifts, plausibility bounds) can raise a REVIEW flag; the engine will not let them FAIL, even if a buggy check tries.
- No silent blessings. Every report ends with what was read, what was skipped, and which worksheets were never touched (the report calls this the honesty block). A PASS covers the listed assertions and nothing else.
- A check that can't run is a finding, not a pass. Missing file, unreadable range, text in a numeric column — the run continues, the check is recorded as ERROR, and the exit code is non-zero. "Not verified" must never be readable as "fine."
- Read-only by construction. There is no code path that writes to your data.
Install
The PyPI distribution is named andon-verify (the bare andon name was already
taken); the command and the import stay andon — andon run ..., import andon.
From source: pip install git+https://github.com/gulmezeren2-byte/andon.
Quick start
Point andon at data and claims:
Or try the sabotaged example in this repo:
What it checks
Full parameter reference with examples: docs/checks.md.
Exit codes and CI
Exit codes are a contract:
As a GitHub Action — one line, and the verdict lands in your job summary:
Or plainly, in any runner:
As a pre-commit hook
Stop a commit before a broken report leaves your machine:
Using andon with AI agents
andon is built to be driven by agents, not to contain one:
--jsonemits the full report with stable field names; the exit code alone is enough for a go/no-go decision.- Error messages name the sources, columns and sheets involved, so an agent can repair its own spec instead of guessing ("Column 'Revenue' not found. Columns are: region, share_pct, revenue").
skills/verify-with-andon/ships a skill for Claude Code and compatible harnesses that teaches an agent the discipline: after drafting any analysis, write the spec, run andon, and report the verdict — including the rule that loosening a tolerance to make a check pass must be declared, never silent.- MCP server.
pip install 'andon-verify[mcp]'and runandon-mcpto expose three tools to any MCP-speaking runtime:run(execute a spec),inspect(integrity-scan a workbook with no spec), anddiff(classify what changed between two versions). The agent gets the same structured verdict a human gets — not prose it has to parse back.
No local Python? The Dockerfile builds the same server:
docker build -t andon . && docker run --rm -i -v "$PWD:/work:ro" -w /work andon.
My working rule: the agent that wrote the analysis also writes the spec, and neither is
finished until andon run exits 0 — or a human has signed off on every flag it raised.
What andon is not
- Not a data-quality platform. Great Expectations and pandera validate data inside pipelines, in code, usually against a warehouse. andon verifies claims in finished artifacts — the report against its source — and treats Excel as a first-class citizen, because that is where analysis actually lives in most companies.
- Not an LLM evaluator. It doesn't score model outputs; it re-derives numbers.
- Not a replacement for reading the report. It removes a class of mechanical error so human review can spend itself on judgment.
Limitations, honestly
- Formula cells need cached values. andon reads the value Excel last calculated. A workbook produced by a library and never opened in Excel/LibreOffice carries no cached values for its formulas; andon refuses to guess and reports exactly that.
wherefilters are pandasquery()expressions. They are expressive, which means a spec can encode the same mistakes as any query. Specs are code — review them like code.- Heuristic checks have false positives by design. That is why they cannot fail a build.
- Scale is untested beyond mid-size files. Everyday operational workbooks and CSVs (hundreds of thousands of rows) are fine; nobody has benchmarked it against 10 GB of parquet. If you do, tell me what broke.
- Parquet sources need
pip install 'andon-verify[parquet]'.
CSV encoding, delimiter, and how numbers are punctuated
A CSV source is read as utf-8 by default, and Excel's BOM is stripped so it can't poison
the first column name. When a file isn't utf-8 — Turkish exports out of Excel are often
;-separated, encoded cp1254, and write amounts as 1.234,56 — give the source as a
mapping instead of a bare path:
Get the encoding wrong and andon says so, naming the likely culprit — it does not silently mojibake your column names and then "verify" them.
The last two matter more than they look. Without them 1.234,56 is read as text, and
a column of text is a column a numeric check cannot examine. andon will tell you that
rather than pass — see below — but declaring the punctuation is what makes the column
checkable in the first place.
What a check does when it can't read the data
Every report ends with the same line: a PASS is not an opinion about the analysis; it is arithmetic about these claims. That obliges the checks to distinguish two things a careless implementation runs together:
- "I compared them and they were fine" — a PASS.
- "I had nothing to compare" — never a PASS.
So a plausibility check that finds no numeric values says so, instead of reporting that zero values fell outside the bounds:
And when only part of a column is readable, the verdict carries the denominator, because a statement about the half that parsed is not a statement about the data you handed over:
Every such check reports values_checked, values_total and values_skipped in its
evidence, so the coverage is machine-readable too. Values that pandas turns into NaN at
read time — n/a, -, #N/A — are counted as skipped like anything else; they are
invisible to a naive coercion count, which is exactly how they used to go unnoticed.
Verify against a warehouse query (DuckDB)
A source can be a SQL query instead of a file — so you can reconcile a report against
the same data your BI tool reads, not just against a CSV. With
pip install 'andon-verify[duckdb]', prefix a source with duckdb: and DuckDB runs it
(it reads CSV, parquet, JSON and .duckdb files inside the query; relative paths resolve
against the spec):
Diff two workbook versions
"Someone edited the workbook — what actually changed?" git diff on an .xlsx is noise,
and the tools that compare spreadsheets show every changed cell flat. andon diff
classifies each change instead, so a new #REF! doesn't hide behind reformatted dates:
A new error cell is called out on its own; numeric moves come with a delta and a percent.
Exit codes: 0 = nothing meaningful changed, 1 = a new error appeared (or, with --strict,
any change), 2 = changes but no new error.
Roadmap
Shipped since 0.1: a GitHub Action and pre-commit hook, DuckDB
sources, andon diff, an MCP server, CSV encoding/delimiter
controls, and JSON/JSONL sources.
Near-term, in order:
- Row-level diff for data sheets, not just cell-by-cell
- A
--watchmode: re-run a spec when its sources change on disk
Not planned: dashboards, scheduled runners, LLM-powered anything inside the verifier. The verifier stays deterministic; that is the point.
How this project is built
I design the checks, decide the semantics and review every line; I use AI agents
(Claude Code) heavily for implementation speed, and the commit trailers say so. If that
bothers you, read tests/ first: the suite builds real CSV and XLSX fixtures, no
mocks, and it is the contract. Tests don't care who typed them.
Related
- opsaudit — the same instinct, one level up: operations analytics that audits its own numbers instead of trusting them.
andonchecks a finished report against its sources;opsauditcomputes the metrics with the honesty block built in.
More tools by Eren Gülmez.
License
MIT — Mehmet Eren Gülmez
來源:README.md,提交 1fbc56a
工具
0版本歷史
1- v0.6.0最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分