SuperAPI AI Directory

sqlite-axi

Data & analytics

View repository

Updated 10-16 03:03

About this skill

sqlite-axi

sqlite-axi is an AXI for SQLite. It opens databases read-only and returns token-efficient TOON. The database is auto-discovered in the current directory or one level down, or passed as a file path / --db.

Run without a global install:

npx -y sqlite-axi <command>

Commands

  • sqlite-axi tables [db] — base tables with row and column counts.
  • sqlite-axi schema [db] <table-or-view> — columns (type, pk, notnull, default), indexes, foreign keys.
  • sqlite-axi sample [db] <table-or-view> [--limit 10] [--full] — preview rows; cells truncate unless --full.
  • sqlite-axi query [db] "<sql>" [--limit 50] [--full] — a single read-only query (SELECT / WITH ... SELECT / EXPLAIN SELECT / EXPLAIN QUERY PLAN SELECT only).

Notes

  • Read-only is enforced two ways: the file is opened with SQLite's read-only flag, and a validator rejects anything but the allowed read statements.
  • --limit flags accept decimal integers and cap at 1000 rows.
  • Errors are structured TOON on stdout with a help line. Exit codes: 0 ok, 1 error, 2 usage/read-only violation.
  • Unknown table/view → NOT_FOUND suggesting sqlite-axi tables.