Search & browse

Semantic search and entity browsing from the CLI.

These commands query the local knowledge graph. Your AI agent uses MCP tools (search_code, search_document, etc.) for the same data during sessions. For code, MCP search_code returns graph-enriched source and optional inline annotations — see Knowledge layer.

Hybrid semantic + keyword search across indexed entities.

orkai search "how does authentication work"
orkai search "connection pool" --type=code --lang=go
orkai search "rate limiting" --brief --limit=5
orkai search "auth" --global --json

Flags

FlagDescription
--type typesFilter by entity type (comma-separated)
--lang langsFilter by language
--category idSearch within one project category
--globalSearch all categories
--limit nMax results (default 10)
--briefOne line per result
--jsonRaw JSON response
--graph-hops nGraph expansion depth (default 1)

orkai get

Fetch one entity by ID (full or partial ID).

orkai get a1b2c3d4

orkai get also verifies a create. See Create and update entities.

orkai list

Browse entities with filters, or list categories and orphans.

orkai list
orkai list --type=code --lang=go
orkai list --type=document --limit=5
orkai list --categories
orkai list --orphans --count
orkai list --global --count

Flags

FlagDescription
--categoriesList projects (categories) instead of entities
--orphansEntities with no category
--countCount only, no rows
--jsonRaw JSON