duckdb
Skill1 starsChanged 15 days agoMITView on GitHub
Gate the DuckDB 2.0 CLI binary, select agent output modes, evaluate result trust, and route to specialized skills. Use when the user mentions DuckDB, a .duckdb file, or the duckdb CLI.
- Pipes a download into a shell
13 other projects use a version of this.
Adopted by
Most recently taken up by
- gspencergoog/skillstheir own version, first seen Nov 8, 2026
- fmind/dottheir own version, first seen Nov 8, 2026
- fmind/dotfilestheir own version, first seen Nov 8, 2026
- bmsuisse/skillstheir own version, first seen Nov 6, 2026
- kevmoo/kevmoo_skillstheir own version, first seen Nov 5, 2026
- mjun0812/skillstheir own version, first seen Nov 1, 2026
Other versions13 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 13
- erikdarlingdata/PerformanceMonitor★ 526same name
- kevmoo/kevmoo_skills★ 22same name
- tondevrel/scientific-agent-skills★ 22same name
- G1Joshi/Agent-Skills★ 15same name
- fmind/dot★ 13same name
- fmind/dotfiles★ 13same name
- benjaminwestern/google-engineer-skills★ 5same name
- bmsuisse/skills★ 2same name
- gspencergoog/skills★ 2same name
- Jiplet/transformation-os★ 2same name
3 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository14 other files it gives its agents.
- duckdb-dbtSkill
- duckdb-docsSkill
- duckdb-extensionsSkill
- duckdb-filesSkill
- duckdb-lakehouseSkill
- duckdb-migrateSkill
- duckdb-profileSkill
- duckdb-pythonSkill
- duckdb-quackSkill
- duckdb-searchSkill
- duckdb-sessionSkill
- duckdb-spatialSkill
- duckdb-sqlSkill
- duckdb-variantSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
17 rules. 0 are common, 6 are distinctive, and 11 are very specific to this project.
0
Common
Most of the 10 edited versions we read keep these.
6
Distinctive
This author's own choices. Worth a look.
11
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
Before running DuckDB commands, verify the binary version:
- Very specific: line 21
If stdout does not contain v2.0, stop.
- Distinctive: line 23
If DuckDB 2.0 is missing or outdated, install it:
- Very specific: line 40
When passing any output flag (-json, -csv, -box), DuckDB disables automatic agent mode.
- Very specific: line 42
When combining -agent with -json or -csv, DuckDB preserves JSON errors and banners on stderr, but omits the 1,000-row, 10,000-byte, and …
- Very specific: line 44
Always read stderr. Agent mode directs its startup banner, JSON errors, cost estimates, and execution progress there.
- Distinctive: line 48
Before trusting output, check the exit code first, stderr second, and the result footer third.
- Very specific: line 59
When verifying result determinism, rerun with a different ORDER BY.
- Very specific: line 63
When launching duckdb -ui, DuckDB auto-installs the ui extension on initial run.
- Very specific: line 67
Every duckdb process starts with an isolated in-memory database and executes ~/.duckdbrc unless -no-init is passed.
- Very specific: line 79
When passing -init FILE, DuckDB replaces ~/.duckdbrc.
- Very specific: line 81
When combining a dot command with SQL statements, use -cmd or a heredoc.
- Very specific: line 91
If stderr prints an estimate: line scanning 1,000,000 or more rows, request user confirmation before running an unbounded query.
- Distinctive: line 95
When DuckDB 2.0 creates a new database file under default settings, it writes storage version 69.
- Very specific: line 116
When configuring a Model Context Protocol client or server, consult references/mcp.md.
- Distinctive: line 118
When an error names a specific feature or symptom, route to the owning skill:
- Distinctive: line 131
Run verification commands to confirm CLI version and agent framing:
“Common” is measured: kept by at least 6 in 10 of the 10 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
DuckDB 2.0
Target DuckDB 2.0.0 LTS and newer 2.0 patch releases.
Gate the binary
Before running DuckDB commands, verify the binary version:
duckdb -no-agent --versionIf stdout does not contain v2.0, stop. DuckDB 1.x is unsupported. When piping version output, pass -no-agent because stderr banner pollution invalidates 2>&1 | head -1.
If DuckDB 2.0 is missing or outdated, install it:
curl -fsSL https://install.duckdb.org | shThe installer places the binary in ~/.duckdb/cli/<version>/, points ~/.duckdb/cli/latest at it, and links ~/.local/bin/duckdb when that directory exists without an existing duckdb binary. If using Homebrew, check the version immediately because Homebrew packages can lag releases. If a 2.0 binary resides outside PATH, invoke it by its absolute path.
Choose the output mode
| Consumer | Command | Output characteristics |
| Model reads table | duckdb -agent -c "..." | Compact Markdown, JSON errors on stderr, row/byte/cell caps, result hash |
| Script parses rows | duckdb -json -c "..." | One JSON array on stdout, text errors on stderr |
| Human reads terminal | duckdb -box -c "..." | Unicode box table |
| Human explores visually | duckdb -ui | Browser UI served at localhost:4213 |
When passing any output flag (-json, -csv, -box), DuckDB disables automatic agent mode. To preserve agent framing (stderr JSON errors and banner) with another renderer, pass -agent explicitly (for example, duckdb -agent -json).
When combining -agent with -json or -csv, DuckDB preserves JSON errors and banners on stderr, but omits the 1,000-row, 10,000-byte, and 500-character cell caps. When results can be large, add LIMIT for an intentional sample or use an aggregate for a complete count.
Always read stderr. Agent mode directs its startup banner, JSON errors, cost estimates, and execution progress there. When the footer reads first X and last Y of N rows, the terminal display is truncated; the underlying query returned N rows and the result hash covers all N rows.
Result trust
Before trusting output, check the exit code first, stderr second, and the result footer third.
| Signal | Meaning | Action |
Exit 0, empty stderr, N rows, hash ... | Complete query result | Accept output. If the query specifies LIMIT, do not treat as dataset total. |
| Exit 0, empty stderr, no footer, 1 to 9 rows | Complete query result (hash omitted) | Accept output. |
first X and last Y of N rows | Display truncated; query returned N rows | Pass .maxrows -1 to inspect all rows, or use an aggregate for dataset total. |
first X of at least N rows or query stopped early | Incomplete lower bound | Stop and bound the query with selective filters. |
| Exit 1 with stderr JSON error | Query execution failed | Read the stderr JSON error. Do not parse stdout. |
| Exit 1 with header-only stdout, no JSON error | Process interrupted (SIGINT or timeout) | Rerun with bounded work or a higher timeout. |
When verifying result determinism, rerun with a different ORDER BY; the result hash is order-independent. Never treat a LIMIT query result as complete for the underlying dataset.
Before parsing -json output, check the exit code and stderr; on failure, -json can emit an unclosed [ on stdout. When executing multiple statements under -json, DuckDB emits one JSON array per statement rather than a single document. Note that NaN and Infinity emit as bare tokens, violating strict JSON. When running EXPLAIN ANALYZE, DuckDB prints a formatted profile text block, ignoring -json.
When launching duckdb -ui, DuckDB auto-installs the ui extension on initial run. If installation fails, note that extension builds can lag releases and lack 2.0.0 binaries for osx_amd64 or windows_arm64 (see references/cli.md).
Run SQL
Every duckdb process starts with an isolated in-memory database and executes ~/.duckdbrc unless -no-init is passed. When session state must persist across invocations, use duckdb-session.
duckdb -agent -c "SELECT 42 AS answer;"
duckdb -agent <<'SQL'
.maxrows 50
SELECT 42 AS answer;
SQL
duckdb -f query.sql
duckdb -init .duckdb/state.sql -agent -c "SHOW TABLES;"When passing -init FILE, DuckDB replaces ~/.duckdbrc. When passing -no-init, DuckDB skips all initialization files.
When combining a dot command with SQL statements, use -cmd or a heredoc; a single -c string cannot mix both. When passing -cmd COMMAND, DuckDB executes it at its positional argument index, even following the last -c or a completed -f.
When running -f FILE, execution halts at the first error by default; stdin input continues past errors. When passing -readonly, DuckDB denies write access to the opened database, unless overridden by an explicit ATTACH ... (READ_WRITE). When passing -safe, DuckDB disables external file access and locks configuration before -init runs, while still opening any database file specified on the command line.
To bound query duration, configure max_execution_time in milliseconds (0 disables timeout):
SET max_execution_time = 30000;If stderr prints an estimate: line scanning 1,000,000 or more rows, request user confirmation before running an unbounded query.
Storage compatibility
When DuckDB 2.0 creates a new database file under default settings, it writes storage version 69. DuckDB 1.x cannot open version 69 files. DuckDB 2.0 reads legacy 1.x files and preserves their existing storage version across writes. Before creating a file destined for older clients, consult duckdb-migrate.
Route
| Task | Skill |
| Write or run SQL, lambdas, triggers, nested schemas | duckdb-sql |
| Diagnose a slow query, plan, spill, or Parquet layout | duckdb-profile |
| Attach a database and keep it across calls | duckdb-session |
| Read, convert, or batch-ingest a file, or query object storage | duckdb-files |
VARIANT or semi-structured columns | duckdb-variant |
| Full-text search, BM25, HNSW, or vector search | duckdb-search |
| dbt v2 project, profile, or dbt-duckdb migration | duckdb-dbt |
Serve a database, CONNECT, Postgres or MySQL pushdown | duckdb-quack |
| DuckLake, Iceberg, Delta | duckdb-lakehouse |
| Install or update extensions | duckdb-extensions |
| Search the 2.0 manual | duckdb-docs |
| Move a 1.x deployment to 2.0 | duckdb-migrate |
| Python client code | duckdb-python |
| Geodata, distances, Overture | duckdb-spatial |
When configuring a Model Context Protocol client or server, consult references/mcp.md. The duckdb_mcp community extension targets 2.0; the MotherDuck local server pins 1.5.6.
When an error names a specific feature or symptom, route to the owning skill:
| Symptom | Skill or action |
Deprecated lambda arrow, Division by zero, nested schema, BEFORE ... FOR EACH ROW | duckdb-sql |
sqlite_master does not exist, read_csv on a Parquet file, a secret validation failure | duckdb-files |
Trying to read a database file with version number 69 | duckdb-migrate |
Extension ... not found, no update available | duckdb-extensions |
Out of Memory Error, actual rows dwarfing estimate, Row Groups Scanned near the total | duckdb-profile |
| Output is box drawing under an agent | Check ~/.duckdbrc; rerun with -no-init |
Verify
Run verification commands to confirm CLI version and agent framing:
duckdb -no-agent --version
duckdb -agent -c "SELECT 42 AS answer;"
duckdb -json -c "SELECT 42 AS answer;"The version check must print v2.0 on stdout. The agent query must render a compact Markdown table. The JSON query must emit [{"answer":42}].
References
- Command line client owns the CLI surface.
- Agent mode owns output limits and stderr splitting.
- Command line arguments owns the flag list.
- Output formats owns the renderer list.
- Migration guide owns the storage break.
- Install owns platform install commands.
- The complete flag, dot command, and setting tables are in references/cli.md.
- MCP configuration and security controls are in references/mcp.md.
- Release verified against DuckDB 2.0.0
d54cbbe3df. Agent limits and JSON error splitting validated locally.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

