elips/docs
Chapter XIV · the query engine

EQL — lexer, parser, AST, executor

EQL is not a toy. It is a real, four-stage compiler embedded in the engine.

  • EQLLexer.cpp — char stream → tokens
  • EQLParser.cpp — tokens → AST (include/elips/query_engine/AST.hpp)
  • QueryExecutor.cpp — AST → QueryPlan → Vault calls
  • MetadataIndex collapses equality and IN-list terms into candidate sets

Bindings ($name) are typed at runtime — the executor checks that a $vector binding is the right dimension before the plan ever reaches a Vault.