sqlfu ships an agent skill atDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/iterate/sqlfu/llms.txt
Use this file to discover all available pages before exploring further.
skills/using-sqlfu/SKILL.md. It gives coding agents the project-specific facts they need before editing a sqlfu project: where to find the config, why SQL files are the authored source, how to draft migrations instead of inventing them, and which commands regenerate TypeScript outputs.
What the skill provides
The skill is a compactSKILL.md file in the skills format — an agent-agnostic plain-text operating guide. When an agent loads it, the skill supplies:
- Where to start — find
sqlfu.config.tsand read it before touching anything. The config says wheredefinitions.sql,migrations/, and the query directory live. - Which files are source — SQL files are authored source. Generated wrappers under
.generated/are output; do not hand-edit them. - How schema changes work — edit
definitions.sql, runsqlfu draft, review the migration, runsqlfu migrate, thensqlfu generateandsqlfu check. - How query changes work — add or edit a
.sqlfile, runsqlfu generate, import the new wrapper. - The command reference —
sqlfu init,draft,migrate,pending,applied,goto,baseline,sync,generate,check, andserve, with one-line descriptions.
Installing the skill
SKILL.md files) will pick it up automatically when working in the repo.
The skill is self-contained. It does not depend on the
sqlfu package itself. The SKILL.md format is agent-agnostic, so the same file works across different coding assistants.Using with URL-fetching agents
If your coding agent can fetch URLs but does not have the skill installed, point it at the agent documentation index before starting a sqlfu task. sqlfu publishes anllms.txt file at https://sqlfu.dev/llms.txt that lists the agent-oriented documentation in a format agents can consume directly.
Paste this prompt at the start of a sqlfu task:
When to use the skill
Editing application code
Any time an agent will edit code that imports from generated wrappers, the skill prevents it from hand-modifying the generated files instead of regenerating them.
Schema changes
The skill teaches agents the correct migration workflow: edit
definitions.sql, draft, review, migrate — not invent SQL by hand.Query changes
The skill ensures agents edit
.sql files and run sqlfu generate, rather than writing TypeScript wrappers directly.Repos with checked-in generated files
Especially useful when generated files are committed and reviewed through pull requests, where an agent editing output files would create misleading diffs.
Keeping the skill current
When sqlfu’s workflow changes, update the skill alongside the docs. The facts most likely to drift are:- where config is loaded from
- whether generated files are committed
- which commands update migrations, wrappers, and formatting
- which generated outputs are safe to edit by hand