Architecture Overview
High-level overview of the Intentra CLI architecture.
Design Principles
- Local-first - All data stored locally, works offline
- Multi-tool - Unified interface for Cursor, Claude Code, Gemini CLI
- Normalized - Consistent event schema across different tools
- Privacy-focused - No code or prompts stored
Components
CLI
The intentra CLI is the core component:
- Installs and manages hooks for AI tools
- Captures and normalizes events from different sources
- Stores data locally in SQLite
- Aggregates events into meaningful scans
- Optionally syncs data to remote servers
Hook Normalizers
Each AI tool has a dedicated normalizer:
- Cursor - Parses Cursor’s hook events
- Claude Code - Processes Claude Code output
- Gemini CLI - Normalizes Gemini CLI logs
All normalizers produce the same unified event schema.
Local Storage
SQLite database stores:
- Raw events from hooks
- Aggregated scans
- Configuration settings
- Sync queue (when enabled)
Sync Layer (Optional)
Multiple authentication methods supported:
- HMAC - Signed requests with shared secret
- API Key - Simple bearer token auth
- mTLS - Certificate-based mutual TLS
Data Flow
- User performs AI action in IDE/CLI
- Tool’s hook fires, invokes Intentra CLI
- CLI normalizes event to unified schema
- Event stored in local SQLite buffer
- Events aggregated into scans
- (Optional) Scans synced to remote server
Security
- All data stored locally by default
- No code or prompts captured
- Token counts and metadata only
- Optional encrypted sync over HTTPS