deft / guides

File jobs for AI coding agents

Ask a coding agent to merge two PDFs or shrink a folder of photos, and it often writes a small Python script, installs a library, runs it, and fixes what broke. Deft turns each of those jobs into one command.

What goes wrong with a throwaway script

A script for a file job looks short, but the agent pays for every step around it:

The same jobs with deft

Deft is one binary with commands for PDF, images, Word and ODT documents, slides, spreadsheets, Markdown, HTML, e-books, JSON, YAML, TOML and QR codes. Every command has the same shape:

deft <group> <command> [inputs] -o <output> [--options]
JobCommand
Merge PDFsdeft pdf merge report.pdf appendix.pdf -o all.pdf
Shrink a PDFdeft pdf compress report.pdf --level strong -o small.pdf
Reorder pagesdeft pdf select three-pages.pdf --pages 3,1-2 -o reordered.pdf
Resize a photodeft image resize photo.jpg --size 800x -o small.jpg
Photos into one PDFdeft image to-pdf photo-1.jpg photo-2.jpg -o album.pdf
Markdown to PDFdeft md to-pdf notes.md -o notes.pdf
Word to Markdowndeft doc to-md letter.docx -o letter.md
CSV to Exceldeft sheet convert people.csv --to xlsx -o table.xlsx

Each command prints one line: what it read, what it wrote and the result, or an error with a stable code and a hint. That is all the agent has to read.

Finding the right command

The agent does not need to know the command names. It can search by intent:

$ deft find "shrink pdf"
pdf compress  pdf -> pdf  Make smaller: --level, --target-size 2MB

When no command fits, deft find says no command does this, and the agent knows to use another tool instead of guessing.

Safe by default

When a script is still the right call

Deft covers common jobs, not every job. If the task needs custom logic, such as pulling particular fields out of hundreds of invoices or a chart built from your own rules, a script is the better tool. The point is to stop writing one for the jobs that are already solved.

Next