| Crates.io | sochdb-query |
| lib.rs | sochdb-query |
| version | 0.4.3 |
| created_at | 2026-01-12 17:10:08.867819+00 |
| updated_at | 2026-01-23 20:34:38.437567+00 |
| description | SochDB query engine (sync-first execution and vector query planning) |
| homepage | https://sochdb.dev |
| repository | https://github.com/sochdb/sochdb |
| max_upload_size | |
| id | 2038226 |
| size | 1,168,312 |
Query planning and execution engine for SochDB.
sochdb-query provides the query layer for SochDB, featuring:
[dependencies]
sochdb-query = "0.2.5"
Most users should use the high-level sochdb crate:
use sochdb::{Database, Query};
let db = Database::open("./my_data")?;
// Query with builder pattern
let results = db.query("users")
.filter("age", ">", 21)
.select(&["name", "email"])
.order_by("name")
.limit(10)
.execute()?;
// Results in token-efficient TOON format
println!("{}", results.to_toon());
// users[3]{name,email}: Alice,alice@...|Bob,bob@...|Carol,carol@...
┌──────────────┐
│ Query │ User query (builder or path)
└──────┬───────┘
│
▼
┌──────────────┐
│ Parse │ Validate and normalize
└──────┬───────┘
│
▼
┌──────────────┐
│ Optimize │ Pushdown filters, projections
└──────┬───────┘
│
▼
┌──────────────┐
│ Execute │ Scan, filter, project, sort
└──────┬───────┘
│
▼
┌──────────────┐
│ Format │ TOON or JSON output
└──────────────┘
| Crate | Purpose |
|---|---|
sochdb |
High-level client API (start here) |
sochdb-core |
Core types and traits |
sochdb-storage |
Storage engine with WAL |
sochdb-index |
HNSW vector indexing |
sochdb-query |
Query execution (this crate) |
Apache-2.0 - see LICENSE for details.