← Back to Portal

JIL Sovereign Architecture Reference

Version: DEVNET-GA-1 Last Updated: January 30, 2026 Status: Production Ready (Devnet)

This document provides a comprehensive overview of the JIL Sovereign system architecture, covering the complete technology stack from L1 blockchain to microservices.


Executive Summary

Metric Count Status
Core L1 Components (Rust) 16 ✅ All compiling
Microservices 76+ ✅ All deployable
Deployment Packages 87 ✅ Production ready
Total Tests 53+ ✅ All passing
Jurisdictions 4 CH, SG, ADGM, USA

Table of Contents

  1. System Overview
  2. L1 Blockchain Layer
  3. Compliance & Policy Engine
  4. Proof Layer
  5. Trading & Liquidity
  6. Wallet & Account Management
  7. Security & Cryptography
  8. Deployment Architecture
  9. Documentation Index

1. System Overview

Architecture Diagram

┌─────────────────────────────────────────────────────────────────────────────────┐
│                           JIL SOVEREIGN L1 STACK                                 │
├─────────────────────────────────────────────────────────────────────────────────┤
│                                                                                  │
│  ┌─────────────────────────────────────────────────────────────────────────┐    │
│  │                         APPLICATION LAYER                                │    │
│  │  ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐      │    │
│  │  │wallet-ui │ │wallet-api│ │launchpad │ │explorer  │ │telemetry │      │    │
│  │  │ (Next.js)│ │(Express) │ │   -api   │ │   -api   │ │   -ui    │      │    │
│  │  └──────────┘ └──────────┘ └──────────┘ └──────────┘ └──────────┘      │    │
│  └─────────────────────────────────────────────────────────────────────────┘    │
│                                      │                                           │
│  ┌─────────────────────────────────────────────────────────────────────────┐    │
│  │                           PROOF LAYER (14 services)                      │    │
│  │  proof-gateway │ proof-verifier │ proof-orchestrator │ proof-bulletin   │    │
│  │  proof-mesh    │ proof-capsule  │ proof-redactor     │ zk-receipts      │    │
│  └─────────────────────────────────────────────────────────────────────────┘    │
│                                      │                                           │
│  ┌─────────────────────────────────────────────────────────────────────────┐    │
│  │                        COMPLIANCE LAYER (10 services)                    │    │
│  │  compliance-api │ corridor-switchboard │ consent-killswitch              │    │
│  │  policy-registry│ ledger-compliance    │ fraud-firewall                  │    │
│  └─────────────────────────────────────────────────────────────────────────┘    │
│                                      │                                           │
│  ┌─────────────────────────────────────────────────────────────────────────┐    │
│  │                         TRADING LAYER (11 services)                      │    │
│  │  dex-order-manager │ rfq-service │ settlement-router │ pool-bootstrapper│    │
│  │  liquidity-*       │ ramps-api   │                                       │    │
│  └─────────────────────────────────────────────────────────────────────────┘    │
│                                      │                                           │
│  ┌─────────────────────────────────────────────────────────────────────────┐    │
│  │                      L1 BLOCKCHAIN CORE (Rust)                           │    │
│  │  ┌────────────┐  ┌────────────┐  ┌────────────┐  ┌────────────┐         │    │
│  │  │jil5600-core│  │  jil-abci  │  │   jil-vm   │  │ ammv5-core │         │    │
│  │  │  (State)   │  │(Consensus) │  │    (VM)    │  │   (DEX)    │         │    │
│  │  │  5 tests ✅ │  │ 43 tests ✅ │  │ integrated │  │ integrated │         │    │
│  │  └────────────┘  └────────────┘  └────────────┘  └────────────┘         │    │
│  │  ┌────────────┐  ┌────────────┐  ┌────────────┐  ┌────────────┐         │    │
│  │  │ jil-zones  │  │jil-identity│  │jil-tokens  │  │jil-factory │         │    │
│  │  │  (Policy)  │  │  (KYC/KYB) │  │  (JIL20)   │  │  (Deploy)  │         │    │
│  │  │  5 tests ✅ │  │ integrated │  │ integrated │  │ integrated │         │    │
│  │  └────────────┘  └────────────┘  └────────────┘  └────────────┘         │    │
│  └─────────────────────────────────────────────────────────────────────────┘    │
│                                      │                                           │
│  ┌─────────────────────────────────────────────────────────────────────────┐    │
│  │                        INFRASTRUCTURE                                    │    │
│  │  CometBFT (Consensus) │ Kafka (Events) │ PostgreSQL │ Redis │ Vault     │    │
│  └─────────────────────────────────────────────────────────────────────────┘    │
│                                                                                  │
└─────────────────────────────────────────────────────────────────────────────────┘

Technology Stack

Layer Technology Purpose
Consensus CometBFT/Tendermint Byzantine fault-tolerant consensus
Core Rust L1 state machine, VM, policies
Services TypeScript/Node.js Microservices (76+)
AI/ML Python/PyTorch AI curator, rule engine
Frontend Next.js/React Wallet UI, dashboards
Contracts Solidity Bridge contracts
Infrastructure Kafka, PostgreSQL, Redis Messaging, storage, cache

2. L1 Blockchain Layer

Core Components

Component Location Tests Description
jil5600-core /l1/jil5600-core/ 5 ✅ Core ledger engine with account state, balances, and pool management
jil-abci /l1/jil-abci/ 43 ✅ ABCI++ application for CometBFT with Ed25519 signature verification
jil-vm /l1/jil-vm/ Stack-based VM with policy opcodes (POLICY_CHECK, ZONE_GATE)
jil-zones /l1/jil-zones/ 5 ✅ Zone policy engine (Protected, Unprotected, Quarantine)
jil-identity /l1/jil-identity/ KYC/KYB credential management with DID support
jil-core-policy /l1/jil-core-policy/ Transaction policy enforcement
jil-tokens /l1/jil-tokens/ JIL20 token standard with freeze/compliance hooks
jil-factory /l1/jil-factory/ Permissioned token deployment with KYB verification
ammv5-core /crates/ammv5-core/ Constant product AMM with TWAMM and batch auctions
jil-validator-node-v2 /l1/jil-validator-node-v2/ 1 ✅ Production validator with HTTP APIs

Zone Architecture

pub enum ZoneKind {
    Protected,    // Full KYC, passkey auth, MPC cosigning
    Unprotected,  // Permissionless, crypto-native
    Quarantine,   // Lifeline transfers only
    Internal,     // System accounts
    External,     // Bridge/external chains
}
Zone Auth Required KYC Cosigning Use Case
Protected PasskeyP256 (UV) Yes Above threshold Regulated assets
Unprotected Ed25519/Passkey No No Crypto-native
Quarantine N/A N/A N/A Compromised accounts

Validator Slashing

Violation Slash % Jail Duration
Double Sign 5% 30 days
Downtime 1% 1 day

3. Compliance & Policy Engine

Services

Service Port Description
compliance-api 8100 KYC/KYB verification with ATCE integration
corridor-switchboard 8102 Routes transactions through compliant corridors
consent-killswitch 8425 Emergency shutdown with consent revocation
consent-ledger 8410 User consent tracking (GDPR/CCPA)
fraud-firewall 8104 Real-time fraud scoring
policy-registry 8095 Central policy configuration
policy-timemachine 8390 Historical policy versioning
ledger-compliance 8098 Transaction compliance validation

Policy Decision Flow

Transaction
    │
    ▼
[Zone Policy] ──► Check zone restrictions
    │
    ▼
[Identity Check] ──► Verify KYC/KYB status
    │
    ▼
[Compliance Engine] ──► Evaluate rules
    │
    ├── ALLOW ──► Execute transaction
    ├── DENY ──► Reject with reason
    └── REVIEW ──► Queue for manual review

Containment Levels

Level Effect Release
Frozen All outbound blocked Appeal + guardian approval
Quarantine Lifeline only Containment release ceremony

4. Proof Layer

Services (14 Core)

Service Port Description
proof-gateway 8260 Capability-based proof sharing with TTL
proof-verifier 8230 HMAC signature verification
proof-orchestrator 8310 Evidence package assembly
proof-bulletin 8220 Immutable event ledger with checkpoints
proof-mesh 8270 Cross-jurisdiction mesh attestation
proof-capsule 8280 Deterministic ZIP archives
proof-redactor 8250 Selective disclosure with AES-256-GCM
proof-graph 8350 Proof dependency traversal
proof-score 8370 Trust scoring (0-100, A-F grades)
proof-ledger 8180 Corridor policy epochs
proof-mirror 8360 Cross-zone replication
zk-receipts 8320 Zero-knowledge proof generation
witness-notary 8190 3-of-5 quorum notarization
verifiable-claims 8330 W3C Verifiable Credentials

Proof Pack Structure

proof_pack
├── tx_id
├── corridor_policy
├── policy_chain
├── policy_receipt (signed)
├── policy_anchors
├── external_anchors
├── verification
├── quorum
├── bulletin
└── bulletin_checkpoint

Trust Score Weights

Signal Weight
proof_pack 20
policy_chain 15
corridor_attestation 10
replay_receipt 10
audit_seal 10
VC_verified 10
external_anchor 10
witness_mirror 8
evidence 7

5. Trading & Liquidity

AMM V5 Features

Feature Description
Constant Product x*y=k bonding curve (Uniswap V2 style)
Batch Auctions VRF-randomized for MEV protection
TWAMM Time-weighted orders for large trades
ERC-4626 Vaults Standardized LP accounting
Slippage Protection Per-swap tolerance

Fee Structure

Component BPS Percentage
Total 200 2.00%
LP Fee 100 1.00%
Ops Fee 80 0.80%
Humanity Fee 20 0.20%

Trading Services

Service Port Description
dex-order-manager 8085 Trigger orders (stop-loss, limit)
rfq-service 8091 Institutional OTC quotes
settlement-router 8081 Multi-venue routing
pool-bootstrapper 8097 LP initialization
liquidity-analytics 8903 Real-time metrics
liquidity-risk 8898 Concentration assessment
ramps-api 8802 Fiat on/off-ramp

6. Wallet & Account Management

Services

Service Port Description
wallet-api 8082 Core wallet with auth, payments, recovery
wallet-ui 3000 Next.js frontend
recovery-ceremony 8130 Multi-guardian recovery
containment-mesh-router 8160 Emergency account lockdown
mpc-cosigner 8120 Institutional MPC custody
guardian-attestor 8140 Ed25519 recovery signatures

Recovery Ceremony

PENDING
    │
    ▼ [Quorum Met: 2-of-3 guardians]
TIMELOCK (30s default)
    │
    ▼ [Timelock Elapsed]
ACTIVATED ──► Key rotation executed

7. Security & Cryptography

Production Safety

All services include production safety checks that block startup with devnet secrets:

const IS_PRODUCTION = ["production", "mainnet", "prod"].includes(
  (process.env.JIL_ENV || process.env.NODE_ENV || "").toLowerCase()
);

function validateSecret(name, value) {
  if (IS_PRODUCTION && value.toLowerCase().includes("devnet")) {
    console.error(`FATAL: Cannot start with devnet secret: ${name}`);
    process.exit(1);
  }
}

Cryptographic Services

Service Port Description
pq-epoch-registry 8440 Post-quantum key epochs (devnet placeholder)
privacy-budget-meter 8430 Differential privacy tracking
device-attestor 8400 WebAuthn passkey attestation

Signature Schemes

Environment Scheme Notes
Devnet HMAC-SHA256 Per-service secrets
Production Ed25519 / Threshold HSM-backed
PQ Ready Hybrid Classical+PQ Dilithium/Falcon planned

8. Deployment Architecture

Directory Structure

deploy/
├── bin/              # 87 pre-compiled services
│   └── <service>/
│       ├── index.js        # Compiled JavaScript
│       ├── package.json    # Dependencies
│       ├── Dockerfile      # Container build
│       ├── docker-compose.yml
│       └── k8s/            # Kubernetes manifests
├── config/           # Environment templates
├── docker/           # Docker build files
├── helm/             # Helm charts
├── k8s/              # Global K8s manifests
├── terraform/        # Infrastructure as code
└── lib/              # Shared libraries
    ├── startup-validation/   # Production safety
    ├── secrets-manager/      # Vault/AWS integration
    └── proof-verification/   # ZK verification

Multi-Jurisdiction Deployment

┌─────────────┐    ┌─────────────┐    ┌─────────────┐    ┌─────────────┐
│ SWITZERLAND │    │  SINGAPORE  │    │    ADGM     │    │     USA     │
│  (Primary)  │    │             │    │             │    │             │
├─────────────┤    ├─────────────┤    ├─────────────┤    ├─────────────┤
│ Ledger (P)  │    │ Validator   │    │ Validator   │    │ Validator   │
│ Compliance  │    │ Wallet API  │    │ Wallet API  │    │ Wallet API  │
│ Proof Store │    │ MPC Node    │    │ MPC Node    │    │ MPC Node    │
└──────┬──────┘    └──────┬──────┘    └──────┬──────┘    └──────┬──────┘
       │                  │                  │                  │
       └──────────────────┼──────────────────┼──────────────────┘
                          │
                   ┌──────┴──────┐
                   │ GLOBAL MESH │
                   │  Kafka/DNS  │
                   └─────────────┘

Service Tiers

Tier Services Scaling
Ledger ledger-service, tx-sink 3+ (Raft)
Validator validator, mpc-cosigner 4+ (1/jurisdiction)
API wallet-api, proof-gateway 10-100+ (stateless)
Compliance consent-*, fraud-firewall 2+ per jurisdiction

9. Documentation Index

Core Guides

Document Location Description
Feature Inventory /docs/JIL_FEATURE_INVENTORY.md Complete feature list with tests
Deployment Guide /deploy/DEPLOYMENT.md Production deployment
Proof Layer /docs/briefs/PROOF_LAYER.md ZK infrastructure
Compliance /docs/briefs/COMPLIANCE.md KYC/AML enforcement
Recovery /docs/briefs/RECOVERY.md Guardian recovery
Liquidity /docs/briefs/LIQUIDITY.md AMM and pools

Key File Locations

Component Path
Core Ledger /l1/jil5600-core/src/
Consensus /l1/jil-abci/src/
Zone Policy /l1/jil-zones/src/
AMM Engine /crates/ammv5-core/src/
Identity /l1/jil-identity/src/
Services /services/*/src/
Deployment /deploy/bin/

Appendix: Test Summary

Component Tests Status Time
jil5600-core 5 ✅ Pass 0.01s
jil-abci 43 ✅ Pass 0.01s
jil-zones 5 ✅ Pass 0.00s
Total 53 ✅ All Pass < 1s

This document is the property of GIC Foundation, Inc. (TX). All Rights Reserved. 2025 Patent Pending.