Revolutionary spam filtering using MATL reputation scores at the protocol level.
Mycelix Mail is a decentralized email system built on Holochain that replaces content-based spam filtering with sender reputation filtering. Instead of scanning your emails (surveillance), we score the sender's trust and reject low-trust senders before the message even downloads.
- MATL Integration: Uses your existing Mycelix Adaptive Trust Layer (45% Byzantine tolerance) for spam detection
- E2E Encryption: All message bodies encrypted with recipient's public key
- Agent-Centric: Your inbox lives on YOUR device, not a corporate server
- Legacy Compatible: SMTP bridge for Gmail/Outlook interoperability (planned Phase 3)
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Integrity Zome (mycelix_mail_integrity) β
β β’ MailMessage (core message type) β
β β’ TrustScore (MATL scores cached on DHT) β
β β’ EpistemicTier (from Epistemic Charter v2.0) β
β β’ Validation rules β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Coordinator Zomes β
β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β mail_messages β β
β β β’ send_message() β β
β β β’ get_inbox() β β
β β β’ get_outbox() β β
β β β’ get_thread() β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β trust_filter (THE SPAM KILLER) β β
β β β’ check_sender_trust() β β
β β β’ filter_inbox(min_trust) β β
β β β’ update_trust_score() β β
β β β’ report_spam() β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Holochain DHT β
β β’ Source chains (your personal mailbox) β
β β’ DHT storage (message metadata + trust scores) β
β β’ IPFS (encrypted message bodies) β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
mycelix-mail/
βββ dna/ # Holochain DNA
β βββ integrity/ # Core data types
β β βββ src/
β β βββ lib.rs # MailMessage, TrustScore, validation
β βββ zomes/
β β βββ mail_messages/ # Send/receive logic
β β β βββ src/lib.rs
β β βββ trust_filter/ # MATL integration & spam filter
β β βββ src/lib.rs
β βββ Cargo.toml # Rust workspace
β βββ dna.yaml # DNA configuration
βββ ui/ # User interfaces (Phase 4)
β βββ tauri-app/ # Desktop client (Rust + React)
β βββ web/ # Web client (Holochain + Vue)
βββ smtp-bridge/ # Legacy email bridge (Phase 3)
β βββ validator.py # SMTP β Holochain translator
βββ scripts/ # Build and deployment scripts
βββ docs/ # Documentation
# Install Holochain (via Nix)
nix-shell -p holochain
# Verify installation
hc --version # Should be 0.3.0-beta or latercd mycelix-mail/dna
# Build all zomes
cargo build --release --target wasm32-unknown-unknown
# Copy WASM files
cp target/wasm32-unknown-unknown/release/mycelix_mail_integrity.wasm .
cp target/wasm32-unknown-unknown/release/mail_messages.wasm .
cp target/wasm32-unknown-unknown/release/trust_filter.wasm .
# Pack the DNA
hc dna pack .# Start a Holochain sandbox
hc sandbox create -d mycelix-mail.dna
# Call functions
hc sandbox call -- send_message '{"from_did": "did:mycelix:alice", "to_did": "did:mycelix:bob", "subject_encrypted": [72,101,108,108,111], "body_cid": "QmTest123", "timestamp": 1234567890, "thread_id": null, "epistemic_tier": "Tier1Testimonial"}'
# Get inbox
hc sandbox call -- get_inbox
# Filter by trust
hc sandbox call -- filter_inbox 0.7Before other agents can route mail to you, publish your DID β AgentPubKey binding inside the DNA:
hc sandbox call -- register_my_did '{"did": "did:mycelix:alice"}'You can verify the binding later by calling resolve_did (CLI support is coming next) or by inspecting the did_index path via hc dump.
- Integrity types (MailMessage, TrustScore, Contact)
- Validation rules
- send_message() / get_inbox() / get_outbox()
- Trust score lookup
- filter_inbox() spam filtering
- Thread support
- Epistemic Charter v2.0 integration
- Python bridge to connect Holochain β 0TML/MATL
- Periodic trust score sync from MATL to DHT
- Spam report feedback loop
- Real-time trust score updates
- SMTP validator nodes
- DAO governance for validators
- Staking mechanism (FLOW tokens)
- Email β Mycelix translator
- Mycelix β Email translator
- DNS configuration for mycelix.net
- Tauri desktop app
- Web interface (via Holo)
- Compose UI
- Contact management
- Settings panel
cd dna
cargo test# Set RUST_LOG for detailed logging
RUST_LOG=debug hc sandbox call -- get_inboxThe trust_filter zome is designed to integrate with your existing MATL system in Mycelix-Core/0TML/. To connect them:
# Create a bridge service
from matl import MATLClient
from holochain_client import HolochainClient
matl = MATLClient(mode="mode1", oracle_endpoint="http://localhost:8080")
hc = HolochainClient("ws://localhost:8888")
# Sync trust scores every 5 minutes
async def sync_trust_scores():
while True:
dids = await get_active_dids() # Query Holochain for active users
for did in dids:
score = await matl.get_composite_trust_score(did)
await hc.call_zome(
"trust_filter",
"update_trust_score",
{
"did": did,
"score": score.final_score,
"last_updated": int(time.time()),
"matl_source": "mode1_oracle"
}
)
await asyncio.sleep(300)Traditional email filters your mail by reading it (surveillance). Mycelix filters by scoring the sender (privacy-preserving).
-
Spammer sends 10,000 messages
- MATL's entropy score detects bot-like behavior (low entropy)
- MATL's TCDM detects cartel coordination (high clustering)
- Spammer gets trust score: 0.05
-
You check your inbox
- You call
filter_inbox(0.3)(minimum trust threshold) - Holochain queries trust scores for all senders
- Messages from score < 0.3 are hidden
- Spam never downloads, never decrypts, never seen
- You call
-
Trusted colleague sends message
- They have high PoGQ (validation accuracy)
- Diverse network connections
- Human-like behavior patterns
- Trust score: 0.85
- Message appears in inbox instantly
- PoGQ (40%): Historical accuracy of their interactions
- TCDM (30%): Are they part of a spam cartel?
- Entropy (30%): Do they behave like a bot or human?
| Attack | Defense |
|---|---|
| Spam (volume) | Trust score < threshold β reject |
| Phishing | DIDs + VCs verify sender identity |
| Sybil | MATL cartel detection |
| Content scanning | E2E encryption, never decrypt suspicious messages |
| Backdoor | Open source, auditable |
- Your inbox is yours: Stored on your device (Holochain source chain)
- No one reads your mail: E2E encrypted
- Metadata minimized: Only sender DID + timestamp visible to DHT
- No surveillance: Spam filtering happens at protocol layer, not content
- Send latency: <2s (P2P)
- Inbox query: <500ms (local source chain)
- Trust lookup: <100ms (DHT query)
- Spam filter accuracy: >99%
See CONTRIBUTING.md for guidelines.
- Testing: Write integration tests for zome functions
- MATL Bridge: Implement Python bridge in
smtp-bridge/ - UI: Build Tauri desktop app in
ui/tauri-app/ - SMTP Bridge: Validator implementation
- Build and test the DNA:
cargo build && hc dna pack - Run in sandbox: Verify send_message and filter_inbox work
- Create MATL bridge: Connect to existing 0TML system
- Build simple UI: Tauri desktop app to test real usage
Status: Phase 1 DNA complete β | Phase 2 MATL integration next π§
Questions? Open an issue or contact: tristan.stoltz@evolvingresonantcocreationism.com
π "The best spam filter is one that never sees your mail." π