OmniContext is a local-first desktop context engine.
It watches your folders, ingests text files, normalizes/chunks content, stores semantic + lexical indexes, and lets you search/preview context in a Slint UI. It also builds agent-safe context bundles that respect permissions.
OmniContext now ships local connectors for common daily workflows:
filesystem(custom folders)obsidiannotionlogseqvscodeslack_exportgmail_exportcalendar_exportslack_api(official Slack API sync)gmail_api(official Gmail API sync)
Network behavior is locked down:
- Local/export connectors never require network.
- API connectors are disabled by default.
- API connectors only use network during explicit authorized sync/auth flows.
- Query/search/context bundle paths stay local-only (LanceDB + Tantivy + local metadata).
- Ingest local files (
.md,.txt,.rs,.ts,.json,.toml,.yaml,.yml,.csv,.ics,.eml,.mbox) - Store searchable memory in:
- LanceDB (semantic vectors)
- Tantivy (lexical BM25)
- Automerge CRDT docs
- Run hybrid search (WRR fusion: semantic + lexical)
- Build token-budgeted context bundles with permission filtering
- Write append-only audit logs for connector fetches and context retrieval
omnict-app: desktop entrypointomnict-ui: Slint UI + core API adapteromnict-core: orchestrator, config, lifecycle, audit loggingomnict-memory: Tantivy + LanceDB hybrid searchomnict-ingest: ingestion state machine + embedder bridge + metadata storeomnict-crdt: Automerge-backed content/state updatesomnict-mcp: MCP host + connector runtimes + WASM runneromnict-connectors: built-in filesystem connector (+ wasm ABI exports)omnict-models: shared domain model typesomnict-config: config schema + migration + validationomnict-audit: typed append-only audit writer
- Build
cargo build --workspace --all-features- Run desktop app
cargo run -p omnict-app- In the UI
- Open Settings
- Add a folder path
- Enable the connectors you use daily
- For
gmail_api/slack_api, enable connector + network authorization toggles - Click Apply
- Use connector actions:
Auth StartAuth Complete(paste code/token)Sync NowClear Cache(removes local indexed items for that connector and resets cursor)
- Search from the command palette and preview a result.
Given a folder with:
roadmap.md: "Q2 roadmap includes agent permissions and audit logging"notes.md: "context bundle token budget discussion"
Searching audit logging roadmap returns roadmap.md near the top. Selecting the result loads full preview content.
For app connectors:
- Enable
obsidianandvscode - Keep
filesystemenabled for project folders - Search for
meeting notes api migration - You will get matches merged from your Obsidian vault notes + VSCode config/snippets + local files.
For cloud API connectors:
- Enable
gmail_apiorslack_api - Authorize once (tokens stored in OS keychain via
keyring) - Run sync
- Search works locally, including when offline after sync
By default, app connectors use common local directories under your home folder (for example ~/Documents/Notion or ~/Library/Application Support/Code/User).
You can override connector roots with env vars (comma-separated paths):
OMNICTX_OBSIDIAN_ROOTSOMNICTX_NOTION_ROOTSOMNICTX_LOGSEQ_ROOTSOMNICTX_VSCODE_ROOTSOMNICTX_SLACK_EXPORT_ROOTSOMNICTX_GMAIL_EXPORT_ROOTSOMNICTX_CALENDAR_EXPORT_ROOTSOMNICTX_FILESYSTEM_ROOTS
API connector env vars:
- Gmail:
OMNICTX_GMAIL_CLIENT_IDOMNICTX_GMAIL_SCOPE(optional)OMNICTX_GMAIL_DEVICE_URL(optional override)OMNICTX_GMAIL_TOKEN_URL(optional override)OMNICTX_GMAIL_API_BASE(optional override)
- Slack:
OMNICTX_SLACK_CLIENT_ID(optional for OAuth-code flow)OMNICTX_SLACK_CLIENT_SECRET(optional for OAuth-code flow)OMNICTX_SLACK_SCOPE(optional)OMNICTX_SLACK_AUTH_URL(optional override)OMNICTX_SLACK_TOKEN_URL(optional override)OMNICTX_SLACK_API_BASE(optional override)
~/.omnicontext/config.json now uses typed connector settings:
{
"chunk_size": 1000,
"overlap": 150,
"vector_weight": 0.65,
"lexical_weight": 0.35,
"max_token_budget": 12000,
"connectors": {
"filesystem": {
"enabled": true,
"mode": "local_export",
"roots": [],
"sync_interval_secs": null,
"network_authorized": false
},
"gmail_api": {
"enabled": false,
"mode": "cloud_api",
"roots": [],
"sync_interval_secs": 300,
"network_authorized": false
}
}
}Legacy bool maps are still deserialized for backward compatibility and auto-merged with new defaults.
~/.omnicontext/ now enforces:
lancedb/tantivy/crdt/meta.db(redb backend)config.jsonaudit.logsnapshots/
Default provider in config is deterministic for development/tests. To enable ONNX local embeddings, set embedding.provider to onnx_local and provide embedding.model_dir in ~/.omnicontext/config.json.
Required files in model_dir:
model.onnxtokenizer.jsonconfig.jsonspecial_tokens_map.jsontokenizer_config.json
cargo fmt --all -- --check
cargo clippy --workspace --all-targets --all-features -- -D warnings
cargo test --workspace --all-targets --all-features
cargo build --workspace --all-features
./scripts/check_layering.sh