Skip to main content

Report Workflow

CI Python Tests License: MIT

繁體中文說明 → README.zh-TW.md

Give your AI the files you already have and one sentence about what you need. Get back a Word document you can hand in.

If the AI writes a number that is not in your files, that number does not reach the document. Same for a quote it reworded, or a paper it cited that does not exist. It gets stopped, and you are told which sentence and why.

You bring: a spreadsheet of measurements, a Word handout, a page of notes — whatever you already have. Plus one sentence, like "write a lab report on this".

You get: a .docx with a table of contents, page numbers, real Word tables, and charts drawn from your own numbers. It can follow your department's or your company's template. Chinese or English.

Two lines to install. No API key. Nothing to configure.

Look before you install

Here is a document it made, and the note that comes with it. Both are in this repository, so you can see the output before you run anything:

Three pages of a pipeline-rendered DOCX report: a title-and-abstract page, a table of contents, and a page with a line chart derived from the source data with a self-contained caption.

Use it

In Claude Code:

/plugin marketplace add 0Smallcat0/report-workflow

Then /plugin install report-workflow@report-workflow. Using something else that speaks MCP (Codex, Cursor, your own setup)? One command instead:

claude mcp add report-workflow -- uvx --from "report-workflow[mcp,render]" report-workflow-mcp

Then just ask, in your own words:

Use report-workflow to turn the files in ./data into a business report for the operations manager: what changed, what it costs, whether to adopt it.

Seven kinds of document: lab report, academic paper, business report, proposal, two admissions formats, and a general one. The maths a marker looks for — how close your measurements came to theory, an R², a budget total — is worked out by the tool from your own data, so the AI never has to make a number up. Formats, Chinese documents, and using your own Word template: docs/OUTPUT.md.

What it cannot do

It cannot read meaning. It checks whether the numbers, quotes and references in the text really appear in your files. It cannot tell whether the AI understood your data. If the AI writes a smooth sentence that gets your result backwards, that sentence goes through.

We measured that limit instead of talking around it: 69 hand-checked attempts to sneak something false past it, plus 10,000 test pairs from a public dataset nobody here wrote. The cases it still misses are kept in the test set on purposedocs/EVIDENCE.md.

It does not write. Your AI writes; this decides what stays. So you need an AI agent to use it.

Does it actually help?

That is the question worth asking about a writing tool, and for a while the honest answer here was no. Someone ran a real 16 KB Chinese market report through the whole pipeline and compared the delivered document against the one they had written by hand: 37 source links became 0, 24 rows of tables became 0, and every citation marker was deleted at render. The gates worked. The document was worse.

Worse still, the strictest gate had a 100% false-positive rate on Chinese. It bound each number to the characters following it, and Chinese has no spaces, so a claim passed only if it repeated the source's exact character sequence — one particle (的) was enough to block a true statement. The gate was rewarding transcription and punishing the synthesis a report exists to do.

Those findings are what the current version was built from. The fixes are in the history; the evidence they worked is checked in:

Before After
Correct Chinese claims blocked by the FE gate 3 of 3 0 of 3
Hallucination catch rate (69 adversarial cases) 86.4% 88.6%
Honest claims wrongly blocked 0% 0%
Source tables reaching the delivered document 0 of 4 4 of 4
Sources the document cites, reaching the bibliography 0 of 6 6 of 6
Chart recommendations dropped without a word 3 of 4 0

The comparison against writing without the tool is a benchmark you can rerun:

python scripts/run_report_quality_benchmark.py --check

Same source, same prompt, two arms, one scorer, both arms in the repository. The harness wins 6 of 8 dimensions. It loses 2, and those are reported rather than tuned away — one of them because the metric itself rewards vagueness, which is worth knowing about the metric. See the summary.

Other ways to run it

Just the checker, on any two pieces of text — no setup, same answer every time, fine to put in a test suite:

from report_workflow import verify

verify("The error rate fell to 0.2% [1].",
       {"1": "The error rate fell to 3.5% under the structured workflow."})
# publishable: False — 0.2% is nowhere in the source; the source says 3.5%

pip install "report-workflow[render]" gets you the command-line version and the Word renderer (it comes with the wheel; without it, tables and templates come out worse). pip install ships the package, not the examples — clone the repository for those and the test data. Or try it with nothing installed: Open In Colab

If the report-workflow command does nothing — usually an old report-workflow.exe left on your PATH on Windows — run python -m report_workflow instead.

Where to go next

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

report_workflow-4.39.0.tar.gz (696.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

report_workflow-4.39.0-py3-none-any.whl (495.9 kB view details)

Uploaded Python 3

File details

Details for the file report_workflow-4.39.0.tar.gz.

File metadata

  • Download URL: report_workflow-4.39.0.tar.gz
  • Upload date:
  • Size: 696.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for report_workflow-4.39.0.tar.gz
Algorithm Hash digest
SHA256 1d4ca535b780f8a0c1952ee6896d1637a9ec3d850a796531038fe73cfdc434a3
MD5 9907d202ef55bb8d1f4aa0a2848de344
BLAKE2b-256 ebe275f8c200bb36486fbb21d623d9425a1514403384ec90c464e45d2a5387b8

See more details on using hashes here.

Provenance

The following attestation bundles were made for report_workflow-4.39.0.tar.gz:

Publisher: release.yml on 0Smallcat0/report-workflow

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file report_workflow-4.39.0-py3-none-any.whl.

File metadata

File hashes

Hashes for report_workflow-4.39.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e2d17a1c69e72c1cb21206a4e462137c4b9e74becaf6f40e9beb453d7190dccc
MD5 279b65a9748f017fdeb27380842e45a7
BLAKE2b-256 b95d7158378db3445fe48c5841fae566948c1fb38937539e84fd3d303c3d01ab

See more details on using hashes here.

Provenance

The following attestation bundles were made for report_workflow-4.39.0-py3-none-any.whl:

Publisher: release.yml on 0Smallcat0/report-workflow

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

4.39.0 This release

2 files

4.38.0

2 files

4.37.0

2 files

4.36.1

2 files

4.36.0

2 files

4.35.0

2 files

4.34.0

2 files

4.33.0

2 files

4.31.0

2 files

4.29.1

2 files

4.29.0

2 files

4.28.2

2 files

4.28.1

2 files

4.28.0

2 files

4.27.1

2 files

4.27.0

2 files

4.23.1

2 files

4.23.0

2 files

4.22.1

2 files

4.22.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page