W04 Paperwork Workflow Agentic file workflow

Messy Intake Folder

A chaotic intake folder where the model must identify active sources, ignore stale files, write manifests, and preserve incoming sources.

Transparency boundary

This page shows the files the model can inspect. It does not show the hidden oracle solution.

Excluded: ground_truth.json, expected_artifacts.json, manual readings, and calibration notes.

What This Tests

old bank exportduplicate vendor filedraft PO listnon-invoice scanprotected source folder

Files Shown

4 generated image files and 9 text/CSV/task files.

All files are synthetic benchmark material.

Generated Images

Scans and visual attachments visible to the model
W04 input incoming/quote_or_credit_note.png
incoming/quote_or_credit_note.png
W04 input incoming/scan_001.png
incoming/scan_001.png
W04 input incoming/scan_002.png
incoming/scan_002.png
W04 input incoming/scan_003.png
incoming/scan_003.png

Task And Source Files

No oracle solution files
incoming/README_TASK.md
# Paperwork Workflow Case 04: Messy Intake Folder

Case ID: P3-WORK-04

You are auditing a messy synthetic intake folder. Some files are active sources, some are stale drafts, and one scan is not an invoice.

Create:
- `work/normalized_manifest.json`
- `work/document_index.json`
- `work/normalized/INV-9107.txt`
- `work/normalized/INV-9108.txt`
- `work/normalized/INV-9109.txt`
- `audit_result.json`
- `proof.txt`

`work/normalized_manifest.json` schema:

```json
{
  "case_id": "P3-WORK-04",
  "active_files": [],
  "ignored_files": [],
  "normalized_files": []
}
```

`active_files` should list the active final sources used for the audit. `ignored_files` should list stale drafts, old exports, duplicate vendor files, and non-invoice scans. `normalized_files` should list the normalized invoice text files you create.

`work/document_index.json` schema:

```json
{
  "case_id": "P3-WORK-04",
  "documents": [
    {
      "document_id": "",
      "document_type": "",
      "source_path": "",
      "normalized_path": ""
    }
  ]
}
```

Use `document_type` values `invoice` or `credit_note`. For ignored non-invoice documents, set `normalized_path` to an empty string.

Each normalized invoice file must use exactly these five lines:

```text
invoice_id=...
vendor_id=...
vendor_name=...
po_id=...
gross_total_cents=...
```

Use the final bank export, the active vendor master, and the final purchase order list:
- final bank export: `incoming/bank-may-final.csv`
- active vendor master: `incoming/vendor_master.csv`
- final purchase orders: `incoming/purchase_orders.csv`

Ignore:
- `incoming/bank_export_old.csv`
- `incoming/vendors copy.csv`
- `incoming/po-list-draft.csv`
- the non-invoice document scan

The scan files contain the source document text. If your tool returns OCR text for an image, use it as the scan reading and cross-check it against the CSV files.

`audit_result.json` must contain exactly these keys:
- case_id
- approved_invoice_ids
- review_invoice_ids
- reject_invoice_ids
- ignored_document_ids
- total_approved_gross_cents
- warnings_by_invoice
- evidence
- proof_code

`warnings_by_invoice` must include every real invoice ID. Use an empty array when an invoice has no warnings.

Allowed warning codes:
- payment_short
- missing_payment
- missing_po
- inactive_vendor

Rules:
- Approve only active-vendor invoices with matching PO and exact final-bank payment.
- Put invoices with short payment, missing payment, missing PO, or inactive vendor into review.
- Reject only when a document is clearly invalid as an invoice. Non-invoice documents belong in `ignored_document_ids`.
- `total_approved_gross_cents` is the sum of approved invoice gross totals only.
- `evidence` must list the active source files used for the audit, with paths relative to the workspace.

Proof code formula:

`proof_code = total_approved_gross_cents + sum(numeric parts of all real invoice IDs) + 97 * total_warning_count`

`proof.txt` must contain only the proof code number and nothing else.
incoming/bank-may-final.csv
date,description,amount_cents,reference
2026-05-03,ALPHA DESK SYSTEMS INV-9107,-11900,INV-9107
2026-05-04,BETA OFFICE SUPPLY INV-9108,-23055,INV-9108
2026-05-06,ORION LEGACY PARTS PAYMENT,-6400,INV-9099

incoming/bank_export_old.csv
date,description,amount_cents,reference
2026-04-28,OLD TEST EXPORT DO NOT USE,-24855,INV-9108
2026-04-29,OLD ORION TEST EXPORT,-8740,INV-9109

incoming/notes_from_ap.txt
Use bank-may-final.csv, not the old export.
Use vendor_master.csv, not the copy.
Use purchase_orders.csv, not the draft list.
The credit note scan is not an invoice for this audit.
INV-9109 should not be approved while the vendor is inactive and the listed PO is cancelled.

incoming/po-list-draft.csv
po_id,vendor_id,gross_limit_cents,status
PO-7001,V-321,12500,open
PO-7002,V-654,25000,cancelled
PO-7003,V-777,9000,open

incoming/purchase_orders.csv
po_id,vendor_id,gross_limit_cents,status
PO-7001,V-321,12500,open
PO-7002,V-654,25000,open
PO-7003,V-777,9000,cancelled

incoming/vendor_master.csv
vendor_id,vendor_name,tax_id,status
V-321,Alpha Desk Systems,TX-321,active
V-654,Beta Office Supply,TX-654,active
V-777,Orion Legacy Parts,TX-777,inactive

incoming/vendors copy.csv
vendor_id,vendor_name,tax_id,status
V-321,Alpha Desk Systems,TX-321,active
V-654,Beta Office Supply,TX-654,inactive
V-777,Orion Legacy Parts,TX-777,active

model_prompt.md
You are in a synthetic paperwork benchmark workspace.

Audit the messy intake folder in `incoming/`.

Create these final artifacts:
- `work/normalized_manifest.json`
- `work/document_index.json`
- `work/normalized/INV-9107.txt`
- `work/normalized/INV-9108.txt`
- `work/normalized/INV-9109.txt`
- `audit_result.json`
- `proof.txt`

Rules:
- Identify the active source files.
- Ignore drafts, old exports, duplicate vendor files, and non-invoice docs.
- Do not modify anything in `incoming/`.
- Return no advice. This is benchmark bookkeeping, not financial, tax, or legal advice.
- `proof.txt` must contain only the final numeric `proof_code`.

Artifact schemas:
- `work/normalized_manifest.json` must be one JSON object with keys `case_id`, `active_files`, `ignored_files`, `normalized_files`.
- `work/document_index.json` must be one JSON object with keys `case_id`, `documents`.
- Each `documents` entry must use keys `document_id`, `document_type`, `source_path`, `normalized_path`.
- Normalized invoice text files must use exactly this line format:
  - `invoice_id=...`
  - `vendor_id=...`
  - `vendor_name=...`
  - `po_id=...`
  - `gross_total_cents=...`
- `warnings_by_invoice` must include every real invoice ID. Use an empty array when an invoice has no warnings.