Skip to content

Watfile

Python CLI that sends each document's text extract to a Jev Choice question and files the file into a matching category folder, with a local laya backend available for offline runs.

Stars
2
Language
Python
Published by
Community
Author
jexp
Last verified
Oct 2026

About this project

Classify files with a decision-making AI model and sort them into category folders. watfile sends each document's text (title/abstract-grade extract) to a TypeSafe AI Jev (System One) Choice question, gets back a typed answer with a selected category, per-category probabilities and confidence, then moves the file into the matching folder. A Classifier abstraction keeps the backend pluggable — local MLX (laya) and other backends slot in later.

Quoted from the project's README. Read the full README.

Highlights

  • The Jev backend packs documents into one system_one call at roughly 256 tokens each, up to about 100 files per 30k-token window.
  • Categories come from a comma-separated list with optional name:description hints, or from the subfolders of a target directory.
  • Dry-run prints decisions without touching anything; the default placement is a symlink, with -m to move and --copy to copy.
  • The laya backend runs locally on MLX, Core ML or PyTorch and uses adaptive multi-chunk classification because its context window is small.

Watch out

Accuracy rests on four arXiv fixture PDFs whose ground truth comes from their arXiv subject tags: 4/4 for Jev and 3/4 for laya. That is four documents, not a benchmark, and tests/fixture is where they live if you want to look. PDFs go through liteparse with only the first two pages parsed and OCR disabled, so scanned or image-only PDFs are skipped, and text inputs are limited to .txt, .md, .markdown, .rst, .log, .csv and .json. Files that cannot be classified are skipped with a warning and name collisions get a _1, _2 suffix, so a run can leave things behind quietly. Placement is gated at a 0.5 confidence floor by default, which means raising it silently skips more files rather than flagging them. Requires Python 3.12 and uv, and the key resolves from TYPESAFE_API_KEY, then .env in the current directory, then ~/.config/watfile/config.toml. Copy reviewed against the repository README on 2026-10-04, not from running it.

Questions about this entry

Short answers drawn from the linked project or page.

More Jev resources like this

38GitHub stars
Local unofficial /v1/systemone adapter that serves Choice, Score, and Noul probabilities via first-token LLM judgments or a fine-tuned ModernBERT scorer, including Japanese docs.
Jev Practices & Patterns#community#awesomejev#catalog-import
24GitHub stars
Unofficial laptop study of parallel constrained decoding: prefill once, share the KV cache across fields, and decide all schema fields in one batched forward pass without writing JSON.
Jev Practices & Patterns#community#jevbest#catalog-import
22GitHub stars
Offline evaluator that checks whether classifier confidences match reality and converts mistake costs into a deployable threshold, emitting an HTML report plus machine-readable threshold files.
Jev Practices & Patterns#community#jevbest#catalog-import
16GitHub stars
Vendor-neutral harness that tests whether Jev reranking improves a small RAG stack, using frozen hybrid BM25 plus BGE-M3 candidates and isolating retrieval, rerank, and generation stages.
Jev Practices & Patterns#community#jevbest#catalog-import
37GitHub stars
Minimal Python recipe that turns any causal LLM into a Jev-style classifier by prefilling choice_index and constraining sampling to legal indexes in one forward pass.
Jev Practices & Patterns#community#jevbest#catalog-import
39GitHub stars
Open replica of the typed decision API on openly available base models, answering choice, score, and true-probability questions in one forward pass with no decoding.
Jev Practices & Patterns#community#jevbest#catalog-import

From the Jev guides

Original write-ups on what this entry is for.

Most Jev accuracy problems are state problems. What belongs in a state, what is a pre-made judgment to leave out, and why naming the slice you ask about matters more than the wording.
Jev Practices & Patterns#state#design#primitives
Read article
A Noul returns one number and no separate confidence. How to read the value, pin its boundary with criteria, split compound questions, and set a per-action threshold that matches the cost of being wrong.
Jev Practices & Patterns#noul#primitives#confidence
Read article
A Score is a weighted position, not a ruler. Why the number can land between levels, why levels are judged separately, and how to combine several atomic scores in code instead of one crowded rubric.
Jev Practices & Patterns#score#primitives#scoring
Read article
Back to all resources

From the Jev community

Posts from builders shipping with Jev right now.

Follow @typesafeai