ahto

Commands

Every command of the ahto CLI on one page, in the groups ahto --help shows. ahto <command> --help shows the options of each.

Lake

CommandWhat it does
crawlfetch repositories and add them to the lake, then derive the read models and parse the new source files (getting started)
loginshow, check or keep the login for an https remote (private repositories)
repo list, repo show, repo rmthe repositories in the lake
storage status, storage compact, storage gc, storage derive, storage verifythe lake on disk and its read models (the lake)
parseparse the source files a crawl has not parsed yet; --rebuild parses them all again (parsing)

Query

CommandWhat it does
query sql, query file, query explain, query exportSQL over the lake, a file of SQL, a query plan, and export to JSON, CSV, Parquet or Arrow (querying)
query tables, query schemathe tables with their files, rows and bytes, and their columns with what each means
files, historythe files at a ref, and the commits that changed a path
inspectone commit, tree, blob or tag; --ast <ref>:<path> the syntax tree of a source file
security sync, security sourcesdownload the OSV, CISA KEV and EPSS feeds into the lake, and how the last sync went (security)
security search, security showsearch the advisories, and one advisory with the lake commits it names
security posture, security deps, security findingsa repository's grade, its pinned packages, and what puts it at risk at a commit
function list, function callthe built-in and WebAssembly functions over the lake, and running one (querying)
function new, function teststart a new function in a folder, and compile and call it once without adding it
task list, task tree, task get, task rollupthe node's task tree: the roots or a task's children, a subtree with roll-ups, one task with its path and links, and a roll-up
task add, task update, task move, task state, task linkadd a task, change the fields given as flags, move it under a parent or among its siblings, set its state (with --evidence, --pr, --reason or --force-reason), and add or --remove a link
task ready, task plan, task chain, task latethe tasks to start next, the open tasks fitted into days at --hours-per-day from --start, the longest chain of dependencies by hours, and what is late
task export, task importthe whole task log in the ahto.task.v1 format to a file or stdout, and adding the ops another node's export has that this one lacks

Serve

CommandWhat it does
serverun the gateway: MCP, REST, gRPC, JSON-RPC, GraphQL, WebSocket, MQTT and OpenAPI on one port, with the lake as the source service; serve --stdio serves the MCP tools over stdin and stdout instead, for a client that starts ahto itself. On a port it also answers the built-in web app at /, with the API also below /api; --no-ui leaves it out. It also takes OpenTelemetry on 127.0.0.1:4318 for the debugger; --otlp-listen off turns that off
mcp-toolsprint the MCP tools the gateway would offer
uiprint a one-time code that signs the web UI in as this node's owner, when the node is an authority member (identity)
migrateschema migrations of the configured databases (adapters)
p2p init, p2p id, p2p ca, p2p admit, p2p revoke, p2p network, p2p publish, p2p pskthe peer-to-peer node: its key and peer ID, the network's CA, and who is a member (networking)
p2p guardian list, set, rehearse, sign, cancelthe guardians that sign a network's recovery (identity)

Setup

CommandWhat it does
doctorcheck Git, the lake and DuckDB
versionthe versions of ahto, Go, Git, DuckDB and the lake schema
upgrade (update)replace this binary with the newest release, checked against its SHA256SUMS; --check only looks, --version v0.1.2 picks one
configprint the settings in effect (configuration)

Tools

CommandWhat it does
check run, check plan, check key, check mtimerun a repository's checks and skip the ones whose inputs did not change since they last passed (checks)
cas gocacheproga content-addressed store, served to go build as its GOCACHEPROG build cache (checks)

Global flags

FlagWhat it does
--lake <dir>the lake to use (AHTO_LAKE_DIR)
--config <file or dir>a YAML config, or a directory of them; repeat to layer (AHTO_CONFIG)
--env <name>development, test, staging or production (AHTO_ENV)
--profile <dir>write Go profiles (cpu, heap, mutex and more) to this directory; report prints a table of spans, trace adds an execution trace (large, and slow for cgo-heavy commands such as parse)
--log-level, --log-formathow much to log, and as console text or JSON
--pprof-listen <addr>serve Go's pprof on this loopback address while the command runs

From docs/commands.md · This page as Markdown