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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
//! # vaultdb-core
//!
//! A markdown-as-database engine. Treats folders of `.md` files with YAML
//! frontmatter as queryable structured data, with `[[wikilinks]]` forming a
//! first-class link graph. Both the tabular (frontmatter) and graph (link)
//! shapes are equally first-class — you can filter records by frontmatter,
//! by graph predicates ("links to anything tagged X"), or by any combination.
//!
//! ## Quick start
//!
//! ```no_run
//! use vaultdb_core::{Expr, Predicate, Query, Value, Vault};
//!
//! let vault = Vault::discover(std::path::Path::new(".")).unwrap();
//! let q = Query {
//! folder: "notes".into(),
//! filter: Some(Expr::Predicate(Predicate::Equals {
//! field: "status".into(),
//! value: Value::String("active".into()),
//! })),
//! select: None,
//! sort: None,
//! limit: Some(10),
//! recursive: false,
//! };
//! let records = vault.query(&q).unwrap();
//! ```
//!
//! ## Public API surface
//!
//! - [`Vault`]: entry point. Discover, load, query, build the link graph.
//! - [`Record`] and [`Value`]: the row + cell types.
//! - [`Expr`], [`Predicate`], [`LinkPredicate`], [`Query`]: the query AST.
//! - [`LinkGraph`], [`GraphScope`], [`Direction`], [`UnresolvedLink`]: the link
//! graph and its traversal/scoping types.
//! - [`UpdateBuilder`], [`DeleteBuilder`], [`MoveBuilder`], [`RenameBuilder`]:
//! typed mutation API. Each has [`UpdateBuilder::plan`]-style preview and
//! `execute` commit methods.
//! - [`render`]: serialize query results to CSV / JSON / YAML / XLSX and
//! write them to a vault-scoped path. The CLI's `--output` flag and the
//! MCP read tools' `export` parameter both use this. XLSX is behind
//! the `xlsx` Cargo feature.
//! - [`LoadResult`], [`ParseError`]: parse-diagnostic surfacing for
//! [`Vault::load_records`].
//! - [`VaultdbError`], [`Result`]: error types.
//!
//! ## Design philosophy
//!
//! No daemon, no cache, no state files. Every read traverses the filesystem
//! fresh. Stateful concerns (file watchers, full-text indexes, typed schemas)
//! belong in consumers, not in vaultdb-core.
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use WriteOptions;