about

The model should work out what you want. Not do the work.

That one sentence is the whole design. A small local model reads your request and emits a JSON plan. From there, ordinary code validates the plan, expands it into concrete steps, asks before it writes, and runs it. The model never runs a command, never writes a shell string, and never owns a safety decision.

the name

knaif is a portmanteau of knife and AI — which is why the wordmark brackets the AI. Think of a Swiss Army knife: a compact tool where every blade does one thing well and folds cleanly away. Each skill is a blade. You carry the ones you need; the handle stays the same.

The brackets do double duty. In the plan pipeline, the model is the only non-deterministic step — genuinely fenced in, with tested code on either side:

your words[ model ]validateexpandconfirmrun

why not just use an agent

Most agents use the model as a general-purpose brain. Every request goes through it, trivial or not — "trim this video to 10 seconds" gets the same multi-thousand-token treatment as "refactor my auth layer". That buys three problems:

Waste

You spend tokens, electricity and time regenerating logic that is fundamentally deterministic. The 200th "compress this video" reasons from scratch like the first.

Non-determinism

The same request can produce a different command tomorrow. For a wrapper around a CLI, that is a bug, not a feature.

Dependency

The capability lives in someone else's data centre, behind a meter, and can be repriced or withdrawn.

knaif inverts it. The model is a thin intent layer; the capability lives in hand-written, tested code. The model picks compress_video and extractstarget_size_mb: 25. Code turns that into a probe → recipe → preview → confirm → run workflow and renders the exact command. Same input, same output, every time.

what that costs to run

Every cloud agent pays for inference per use, forever — real electricity, at data-centre scale, for work that is mostly deterministic. knaif pays the AI cost once, during development: you spend it building and tuning a skill, and ship something whose runtime cost is one short call to a 4B model on the user's own machine.

Our measured comparison puts a number on it: roughly $0.058–0.14 every single time someone asks, against $0 and a tenth of the latency, for work all four systems completed equally well. One request is pocket change. A habit is not, and neither is a million people with the same habit.

Write once. Run free, run local, run the same way every time.

what it is not

The narrow scope is the point. knaif wins by being a sharp tool for a few deterministic jobs, not a dull one for everything.

Download knaifRead the sourceBuild a skill

Apache 2.0. Found a case where it plans the wrong thing? That isthe most useful issue you can file.