1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
//! Reflex: Local-first, structure-aware code search engine
//!
//! Reflex is a fast, deterministic code search tool designed specifically
//! for AI coding agents. It provides structured results (symbols, spans,
//! scopes) with sub-100ms latency by maintaining a lightweight, incremental
//! cache in `.reflex/`.
//!
//! # Architecture
//!
//! - **Indexer**: Scans code and builds trigram index; writes to cache
//! - **Query Engine**: Loads cache on demand; executes deterministic searches; parses symbols at runtime
//! - **Cache**: Memory-mapped storage for trigrams, content, and metadata
//!
//! # Example Usage
//!
//! ```no_run
//! use reflex::{cache::CacheManager, indexer::Indexer, models::IndexConfig};
//!
//! // Create and initialize index
//! let cache = CacheManager::new(".");
//! let config = IndexConfig::default();
//! let indexer = Indexer::new(cache, config);
//! let stats = indexer.index(".", false).unwrap();
//!
//! println!("Indexed {} files", stats.total_files);
//! ```
// Re-export commonly used types
pub use CacheManager;
pub use Indexer;
pub use ;
pub use ;
pub use ;