๐ŸชŸ Windows ยท Codex CLI + Claude Code CLI ยท No API keys

Drop a paper in a folder.
Wake up to a reviewed, revised draft.

Every morning at 09:00, this pipeline walks every employee's client folders, sends each eligible paper through a Q1-standard review and a scientific revision โ€” driven entirely by the Codex and Claude Code CLIs on your own subscriptions, never an API key. Nobody opens a chat window. It reads and writes files on disk.

Python Flask control panel SQLite audit trail Windows Task Scheduler PyInstaller + Inno Setup

What it does

A scheduled, file-driven pipeline built around one hard rule: it never deletes, moves, or renames a client's files.

๐Ÿ•˜

Fully scheduled

Fires daily via Windows Task Scheduler. Walks every employee and client folder, decides what's eligible, and processes it โ€” no manual trigger needed.

๐Ÿ”’

Zero delete/rename/move

Enforced by an AST-checked test, not just a convention โ€” tests/test_safety.py fails the build if that invariant is ever broken.

๐Ÿงช

Scientific integrity checks

Every revision is diffed against the original and flagged for changed metrics, invented numbers, leftover placeholders, or suspicious truncation.

๐Ÿ‘ฅ

Role-based LAN dashboard

Admins see every employee's papers and settings; Users see only their own โ€” enforced server-side, not just hidden in the UI.

๐Ÿ“œ

Full audit trail

Every paper's timestamp, phase, model, outcome, and any error is recorded in SQLite and queryable directly.

โ™ป๏ธ

Idempotent & crash-safe

Eligibility is recomputed from disk every run. A crash halfway through just picks back up โ€” it can't double-process a paper.

๐Ÿ–ฅ๏ธ

Tray app + desktop icon

A system tray icon and one-click desktop shortcut keep the dashboard always reachable, without a console window.

๐Ÿ“ฆ

Portable installer

A PyInstaller + Inno Setup build packages five executables under one per-user installer โ€” no Python environment required on the target machine.

How it works

Two phases, both driven by CLI subprocesses reaching your Codex and Claude Code subscriptions โ€” never a direct API call.

09:00 daily

Scan

Walk every employee โ†’ client folder for the current month, apply the file-count rules to decide what's eligible.

โ†’
Review ยท Codex

paper.docx โ†’ review

Converted to markdown, reviewed to a Q1 standard by the Codex CLI, written back as <Client>_review.docx.

โ†’
Revise ยท Claude

paper + review โ†’ revision

Re-scanned from disk, then paper and review are sent to Claude Code, producing Correct_<Client>_paper.docx.

โ†’
Validate

Check & log

The revision is validated against the original; anything suspicious is flagged REQUIRES_HUMAN_REVIEW, never silently accepted.

Screenshots

The LAN-only control panel โ€” reachable only from your office network, never the public internet.

Sign-in screen
Sign inAccount requests need admin approval before first login.
Dashboard overview
DashboardThis month's papers by status, with a one-click Start.
Which AI is used and schedule
Which AI is usedCodex finds the problems, Claude writes the corrections โ€” plus the daily schedule.
System status and jobs
System statusStorage, automation, schedule, workers, and network state at a glance.
Instructions editor
InstructionsThe exact prompts sent to Codex and Claude โ€” editable, with integrity rules always appended.
Settings screen
SettingsReview mode, model access, and per-stage model selection.
Users administration screen
UsersEvery account and role, with disable/reset/rename/delete controls.

Built around not trusting the model blindly

Both prompts forbid inventing results, datasets, citations, or statistics โ€” and the pipeline checks that, rather than taking the model's word for it.

๐Ÿšซ A revision fails validation when it:

  • Reports a metric whose value changed from the original โ€” the signature failure this guards against (an inflated accuracy, say)
  • Introduces a metric that wasn't in the original at all
  • Leaves placeholder text behind โ€” [TODO], [INSERT RESULT], [ADD CITATION]
  • Comes back less than half the length of the original โ€” likely truncated

โš ๏ธ Warned, not failed

A disappearing dataset or model name, or a missing expected section, is flagged but doesn't block the file โ€” every flagged paper is recorded REQUIRES_HUMAN_REVIEW, and the file is still written so a human can inspect it directly.

Roles

Every restriction is enforced on the server โ€” hiding a button is cosmetic, calling the API directly as a User is refused with a 403.

AdminUser
See papersEvery employeeOwn employee only
Start a run, change settings/schedule/promptsYesNo
Approve/reject sign-up requestsYesNo
Open a file on the serverAny paperOwn only

Setup

Both models are reached through the Codex and Claude Code CLI binaries, authenticated with your existing subscriptions โ€” no API keys anywhere.

Install & configure

py -m pip install -r requirements.txt
copy config.example.toml config.toml
# set research_papers_root in config.toml

codex login
claude

Try it safely

py run.py --dry-run      # reports decisions, changes nothing
py run.py --test-mode    # mock model, checks file naming
py run.py --provider real   # one real paper

powershell -File scripts\register_task.ps1  # schedule it