Docs / Introduction Learn
How EKOS Works
An end-to-end walk from raw files to a cited answer.
One pass through the pipeline
ekos buildwalks the project's[[sources]](or the paths in[observe]), redacts secrets and PII, and stores content-addressable observation artifacts. It also writes aFileobject per observed file, and reads the catalog of each live database in[[databases]](Oracle, PostgreSQL, ClickHouse) in a read-only session.ekos recoverruns one analyzer per source kind — SQL DDL, views, PL/pgSQL and PL/SQL routines and triggers, migration scripts as schema history, Rust/Python/JavaScript/Elixir/Perl/Java sources, Git history and ticket ids, GitHub issues, Confluence pages, documents, dbt projects, Pentaho jobs, crate topology, live database catalogs — and emits typed KIR (Knowledge Intermediate Representation) objects, relationships and evidence.ekos resolvemerges duplicates. Exact-name duplicates from the same source kind merge; fuzzy matches whose names agree word for word become reviewableunconfirmedSameAsrelationships instead of silent merges. Objects read from a live database are never merged.ekos compileturns resolved KIR into the Canonical Knowledge Model (CKM), including derived objects such as concentration risks andConflictingEvidenceitems where two sources disagree.ekos commitappends the CKM to the ledger, then builds search indexes and subsystem rollups, links data lineage, routines, schema changes and tickets to tables, compares code with the live database, derives each table's write behaviour and writes the cross-reference integrity index (ekos check refs). LLM descriptions and embeddings follow if enabled.- Query.
ekos mcp serveexposes the ledger read-only to agents;ekos ask,ekos queryandekos ekldo the same from a terminal, and the web console serves the same projects to people and, through its MCP gateway, to agents with an API token.
Each pipeline command writes a JSON-lines run log, one line per step with its counts, ending with the number of model calls it made.
Details for each stage: Compilation Pipeline.