- png.zig: Remove crypto dependency, simple XOR key derivation - png.zig: Fix type casts for u16/u32 calculations - transport_skins.zig: Replace inline else in deinit - duckdb.zig: Simplify enum definition - build.zig: Remove crypto import for png module Refs: RFC-0015 |
||
|---|---|---|
| capsule-core | ||
| docs | ||
| examples | ||
| features/transport | ||
| l0-transport | ||
| l1-identity | ||
| l2-federation | ||
| l2-membrane | ||
| l4-feed | ||
| membrane-agent | ||
| scripts | ||
| src/crypto | ||
| vendor | ||
| .gitignore | ||
| .gitmodules | ||
| Containerfile.fast | ||
| Containerfile.wolfi | ||
| LICENSE | ||
| README.md | ||
| build.zig | ||
| build.zig.zon | ||
| build_err.txt | ||
| build_error_j1.txt | ||
| l0_transport.zig | ||
| l1_identity.zig | ||
| root | ||
README.md
Libertaria SDK
Sovereign Infrastructure for Autonomous Agents
Sovereign; Kinetic; Anti-Fragile.
What is Libertaria?
Libertaria is a stack for building sovereign agent networks — systems where:
- Exit is Voice: Cryptographic guarantees, not platform promises
- Profit is Honesty: Economic incentives align with truth
- Code is Law: Protocols, not platforms, govern behavior
This SDK implements the L1 Identity Layer with:
- Ed25519 sovereign identities with rotation/burn
- Trust Graph (QVL) with betrayal detection
- GQL (ISO/IEC 39075:2024 compliant) query interface
- Persistent storage with Kenya Rule compliance
Quick Start
# Clone
git clone https://github.com/MarkusMaiwald/libertaria-sdk.git
cd libertaria-sdk
# Build
zig build
# Test (166/166 passing)
zig build test
Architecture
┌─────────────────────────────────────────────────────────────┐
│ Application Layer │
├─────────────────────────────────────────────────────────────┤
│ Libertaria SDK │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐ │
│ │ Identity │ │ Trust Graph │ │ GQL │ │
│ │ (identity) │ │ (qvl) │ │ (gql/*.zig) │ │
│ └──────────────┘ └──────────────┘ └──────────────┘ │
├─────────────────────────────────────────────────────────────┤
│ Janus Standard Library │
├─────────────────────────────────────────────────────────────┤
│ Janus Compiler (:service) │
└─────────────────────────────────────────────────────────────┘
Modules
Identity (l1-identity/)
crypto.zig— Ed25519 signatures, key rotationdid.zig— Decentralized identifierssoulkey.zig— Deterministic key derivationentropy.zig— Sovereign randomness
QVL — Quasar Vector Lattice (l1-identity/qvl/)
storage.zig— PersistentGraph with libmdbxbetrayal.zig— Bellman-Ford negative cycle detectionpathfinding.zig— A* trust path discoveryfeed.zig— L4 temporal event store (DuckDB + LanceDB)gql/— ISO/IEC 39075:2024 Graph Query Languagelexer.zig— Tokenizerparser.zig— Recursive descent parserast.zig— Abstract syntax treecodegen.zig— GQL → Zig transpiler
GQL Example
const gql = @import("qvl").gql;
// Parse GQL query
const query_str = "MATCH (n:Identity)-[t:TRUST]->(m) WHERE n.did = 'alice' RETURN m";
var query = try gql.parse(allocator, query_str);
defer query.deinit();
// Transpile to Zig code
const zig_code = try gql.generateZig(allocator, query);
defer allocator.free(zig_code);
Kenya Compliance
| Metric | Target | Status |
|---|---|---|
| Binary Size (L1) | < 200KB | ✅ 85KB |
| Memory Usage | < 10MB | ✅ ~5MB |
| Storage | Single-file | ✅ libmdbx |
| Cloud Calls | None | ✅ Offline-capable |
Testing
# All tests
zig build test
# Specific module
zig test l1-identity/qvl/gql/lexer.zig
zig test l1-identity/qvl/storage.zig
Current Status: 166/166 tests passing ✅
Related Projects
- Janus Language — The foundation
- libertaria.blog — This project's blog
- libertaria.bot — Agent marketplace (coming soon)
Philosophy
Collectivist Individualism
Radical market innovation fused with extreme communal loyalty.
The Kenya Rule
If it doesn't run on a $5 Raspberry Pi, it doesn't run at all.
Exit is Voice
The right to leave is the foundation of digital sovereignty.
License
MIT License + Libertaria Commons Clause
See LICENSE for details.
Forge burns bright. The Exit is being built.
⚡️