Audit sampling

Journal Sampling

Turn variable accounting journals into reproducible audit samples.

Codex handles format ambiguity, column mapping and review questions. Deterministic Python scripts extract, normalize, sample and preserve the audit trail.

What it does

From mixed journals to a sample with diagnostics

Use it when a journal is readable but not standardized: good Excel, CSV, print-style Excel exported from PDF, or text PDF. Codex guides only the uncertain parts.

input/
  journal.xlsx
  print_export_from_pdf.xlsx
  general_journal.pdf
out/
  inspection.json
  suggested_recipe.json
  normalized_journal.csv
  normalization_diagnostics.json
  sample/
    journal_sample.csv
    journal_sample.xlsx
    sampling_audit.json

Inputs

What it reads

The plugin works with local files already available to the firm. OCR-only scanned PDFs are flagged for manual handling rather than treated as readable input.

Outputs

What it produces

The result is a reviewable work folder: mapped recipe, normalized population, sample files, diagnostics and audit trail.

Reviewable sampling, guided in Codex

Codex inspects the customer format, proposes a mapping and asks only the smallest unresolved question: header row, account column, debit/credit convention or sample assumptions.

The scripts remain responsible for extraction, normalization, filtering, sampling and exports. If a parser misses a pattern, the improvement is a new deterministic rule or script, not a silent model correction.

After sampling, Codex can summarize parser gaps and recommended improvements.

Use

How it runs in Codex

Open the work folder in Codex, call the plugin, and let Codex inspect the journal before running the deterministic scripts.

Prompts

Starter prompts

Start from one of these prompts and replace the folder path, language, method and sample size. Codex will ask before resolving essential ambiguities.

Download

Download the plugin

Requires Codex desktop. One ZIP installs the standard Accounting Plugin Pack.

Installation

Official download: Codex desktop.

    /Users/name/Documents/CodexPlugins/mp-codex-plugins

    First use

    In a Codex chat, provide the journal folder, language, sampling method and target size.

    Use Journal Sampling on /path/input.
    Language: en. Document language: auto.
    Inspect the files, ask only for essential mapping ambiguities, then generate sample, diagnostics and audit trail.
    Method: random. Size: 25.