reasonkit/verification/
mod.rs

1//! Verification Module - Protocol Delta Implementation
2//!
3//! This module implements Protocol Delta's verification capabilities,
4//! ensuring research claims remain anchored to immutable sources.
5//!
6//! ## Components
7//!
8//! - **ProofLedger**: Immutable citation ledger with cryptographic binding
9//! - **Anchor**: Snapshot of content at a specific point in time
10//!
11//! ## Philosophy
12//!
13//! > "We do not quote the wind. We quote the stone."
14//!
15//! Protocol Delta replaces weak URL citations with cryptographically-bound
16//! anchors that can detect content drift over time.
17//!
18//! ## Usage
19//!
20//! ```rust
21//! use reasonkit::verification::ProofLedger;
22//!
23//! # fn main() -> Result<(), Box<dyn std::error::Error>> {
24//! // Create a ledger
25//! let ledger = ProofLedger::in_memory()?;
26//!
27//! // Anchor a claim
28//! let content = "The global AI market was valued at $196.63B in 2023.";
29//! let hash = ledger.anchor(
30//!     content,
31//!     "https://example.com/ai-market",
32//!     None
33//! )?;
34//!
35//! // Later: verify the content hasn't drifted
36//! let result = ledger.verify(&hash, content)?;
37//! assert!(result.verified);
38//! # Ok(())
39//! # }
40//! ```
41//!
42//! ## Citation Format
43//!
44//! Instead of:
45//! ```text
46//! The market grew by 5% [1].
47//! [1] https://finance.yahoo.com/...
48//! ```
49//!
50//! Use:
51//! ```text
52//! The market grew by 5% [1].
53//! [1] sha256:8f4a... (Verified 2025-12-23) → https://finance.yahoo.com/...
54//! ```
55
56pub mod proof_ledger;
57
58// Re-exports
59pub use proof_ledger::{Anchor, ProofLedger, ProofLedgerError, VerificationResult};
60
61#[cfg(test)]
62mod tests {
63    use super::*;
64
65    #[test]
66    fn test_module_exports() {
67        // Verify main types are accessible
68        let _ledger = ProofLedger::in_memory();
69    }
70}