Skip to main content

Golden Chain v1.1: Truth & Provenance Layer

Date: 2026-02-13 Version: 1.1.0 Status: Implemented & Tested


Summary

Golden Chain v1.1 adds a Truth & Provenance Layer to the existing 8-node agent pipeline. Every pipeline step now produces an immutable SHA256 hash-chained provenance record with truth verification, providing blockchain-style traceability for AI responses.


Key Metrics

MetricValueStatus
SHA256 hash chain8 records per queryActive
TruthVerdict types3 (Verified/Unverified/LowConfidence)Active
Confidence threshold0.7 (70%)Configured
TVC similarity threshold0.3 (30%)Configured
Max provenance records16 per sessionConfigured
New tests added8All passing
Total tests15 (7 old + 8 new)All passing
New ChatMsgTypes2 (provenance_step, truth_verification)Active
Chat lines per query~18 (was ~10)Expected

What This Means

For Users

  • Every AI response now shows a visible provenance trail in the chat
  • Each pipeline step displays: [hash_prefix] NODE | VERDICT | confidence% | tvc:similarity
  • Chain integrity is verified at the DELIVER step with a final TRUTH verdict
  • Users can see exactly which steps were verified vs unverified

For Operators

  • Immutable hash chain prevents response tampering
  • SHA256 cryptographic hashing ensures integrity
  • TVC corpus cross-checking provides independent truth verification
  • Full provenance audit trail for compliance

For Developers

  • ProvenanceRecord struct with SHA256 hash computation
  • TruthVerdict enum with ternary assessment logic
  • assessTruth() function for confidence + TVC evaluation
  • verifyProvenanceChain() for end-to-end chain integrity verification

Technical Details

Architecture

Query Input
|
v
[GOAL_PARSE] --> ProvenanceRecord #0 (genesis, prev_hash = 0x00..00)
| SHA256(0x00 + "GOAL_PARSE" + content + conf + timestamp)
v
[DECOMPOSE] --> ProvenanceRecord #1 (prev_hash = hash[0])
| SHA256(hash[0] + "DECOMPOSE" + content + conf + timestamp)
v
[SCHEDULE] --> ProvenanceRecord #2
v
[EXECUTE] --> ProvenanceRecord #3 (includes tvc_similarity from corpus)
v
[MONITOR] --> ProvenanceRecord #4
v
[ADAPT] --> ProvenanceRecord #5
v
[SYNTHESIZE] --> ProvenanceRecord #6
v
[DELIVER] --> ProvenanceRecord #7
| + verifyProvenanceChain() -> TRUTH verdict
v
Response Output

Hash Chain Construction

Each ProvenanceRecord contains:

  • prev_hash[32] -- previous record's SHA256 (genesis = all zeros)
  • current_hash[32] -- SHA256(prev_hash + node_label + content_digest + confidence_bytes + timestamp_bytes)
  • truth_verdict -- assessed from confidence and TVC similarity

TruthVerdict Logic

if confidence < 0.7  -> LowConfidence
if tvc_similarity < 0.3 -> Unverified (no corpus confirmation)
else -> Verified (both thresholds met)

Chat Visualization

[● GOAL_PARSE] Goal: "Build a web server" -> type: CodeGen
[■ HASH] [a3f2b1c9] GOAL_PARSE | VERIFIED | 95% | tvc:0.00

[● EXECUTE] pub fn main() !void { ... }
[■ HASH] [d9a2c4f1] EXECUTE | VERIFIED | 92% | tvc:0.78

[● DELIVER] Chain complete | Total: 92% | 1350us
[■ HASH] [f4e2a7b9] DELIVER | VERIFIED | 92% | tvc:0.00
[✓ TRUTH] Chain integrity: VERIFIED (8/8 hashes valid)

Files Modified

FileChanges
specs/tri/hdc_golden_chain_truth_v1_1.vibeeCreated -- specification (source of truth)
src/vibeec/golden_chain.zig+TruthVerdict, +ProvenanceRecord, +SHA256 hash chain, +recordProvenance(), +verifyProvenanceChain(), +8 tests
src/vsa/photon_trinity_canvas.zig+2 ChatMsgType (provenance_step, truth_verification), +colors, +labels
src/wasm_stubs/golden_chain_stub.zig+2 enum values, +TruthVerdict stub, +ProvenanceRecord stub

Technology Tree

v1.0 Golden Chain (8-node pipeline)
|
v
v1.1 Truth & Provenance Layer <-- YOU ARE HERE
|
v
v1.2 On-Chain Attestation (external blockchain anchoring)
|
v
v2.0 Phi-Engine Integration (quantum-inspired truth computation)

Conclusion

Golden Chain v1.1 establishes cryptographic provenance for every AI pipeline step. The SHA256 hash chain creates an immutable audit trail, while the TruthVerdict system provides real-time fake/hallucination detection through confidence scoring and TVC corpus cross-checking. All 15 tests pass, compilation succeeds for both native and WASM targets.