The Distributed Intelligence Stack β one theory, five systems.
MeshInfer.AI is the central inference fabric that unifies DOSFI, MeshNativeExchange, DOSFI Academy, and DOSFI University into a single, coherent platform for distributed intelligence. This document is the authoritative architectural reference for all five systems.
Unification Status β all five platforms
The Mesh-Native Unifying Theory is structurally enforced across every platform in the Distributed Intelligence Stack. The badge below confirms all 11 theory components are active; the compliance maps that follow show how each of the five systems realizes them.
The Mesh-Native Unifying Theory of Distributed Intelligence
The Mesh-Native Unifying Theory of Distributed Intelligence holds that intelligence β the execution of inference, reasoning, and decision-making β should run on the compute that already exists in the world: in users' devices, in peer networks, and in the cloud as a last resort. The five systems of the Distributed Intelligence Stack are the engineering realization of this theory.
The five-system architecture
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β DISTRIBUTED INTELLIGENCE STACK β LAYER MODEL β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β LAYER 5 Β· EDUCATION & CERTIFICATION β
β βββββββββββββββββββββββββββββββ ββββββββββββββββββββββββββββββββββββββββ β
β β DosfiAcademy.com β β DosfiUniversity.com β β
β β Developer Onboarding β β Enterprise Certification β β
β β SDK labs Β· routing labs β β Architect tiers Β· DIU economics β β
β ββββββββββββββββ¬βββββββββββββββ βββββββββββββββββββ¬βββββββββββββββββββββ β
βββββββββββββββββββΌββββββββββββββββββββββββββββββββββββΌβββββββββββββββββββββββ€
β LAYER 4 Β· ECONOMIC SETTLEMENT β β
β ββββββββββββββββΌββββββββββββββββββββββββββββββββββββββΌβββββββββββββββββββ β
β β MeshNativeExchange.com β β
β β Vital DIU issuance Β· compute spend accounting Β· epoch settlement β β
β ββββββββββββββββββββββββββββββββββ¬ββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββ€
β LAYER 3 Β· INFERENCE FABRIC ββββββΌββββ THIS IS WHERE EVERYTHING FLOWS ββββ β
β ββββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββ β
β β MeshInfer.AI β Central Inference Fabric β β
β β Routing Β· Scheduling Β· Privacy enforcement Β· Metering Β· DIU events β β
β ββββββββββββββββββββββββββββββββββ¬ββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββ€
β LAYER 2 Β· DISTRIBUTED OS β
β ββββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββ β
β β DOSFI.ai β Mesh Operating System β β
β β Runtime Β· Scheduler Β· Identity Β· Privacy model Β· Protocol β β
β ββββββββββββββββββββββββββββββββββ¬ββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββ€
β LAYER 1 Β· COMPUTE β
β ββββββββββββββββ βββββββββββββββ βββββββββββββββ ββββββββββββββββββββββ β
β β Browser β β Desktop β β Mobile β β Server / Cloud β β
β β WebGPU/WASM β β llama.cpp β β CoreML/ β β CUDA / bare-metal β β
β β nodes β β nodes β β NNAPI nodesβ β nodes β β
β ββββββββββββββββ βββββββββββββββ βββββββββββββββ ββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Each system's role β canonical definitions
The Unified Architecture Narrative
The data flow β end to end
Developer App (DOSFI Runtime)
β
βββ "infer(prompt, model, policy)" βββββββββββββββββββββββββββββββββββΊ
β β
β MeshInfer.AI Coordinator β
β βββββββββββββββββββββββββββββββββββ β
β β 1. Identity verification β β
β β (DOSFI identity token) β β
β β 2. Privacy gate β β
β β (policy: local_only/mesh_ok) β β
β β 3. Routing decision β β
β β (local β mesh β cloud) β β
β β 4. Task dispatch to node β β
β β 5. Metering event emitted β β
β β β DIU spend debited β β
β βββββββββββββββββββββββββββββββββββ β
β β β
β Node executes inference β
β βββββββββββββββββββββββββββββββββββ β
β β 6. Tokens generated β β
β β 7. Result returned (encrypted) β β
β β 8. DIU issuance event emitted β β
β βββββββββββββββββββββββββββββββββββ β
β β β
β MeshNativeExchange (hourly epoch) β
β βββββββββββββββββββββββββββββββββββ β
β β 9. Batch issuance events β β
β β 10. Integrity verify β β
β β 11. Commit wallet credits β β
β β 12. Settlement log β AuditLog β β
β βββββββββββββββββββββββββββββββββββ β
ββββββ tokens streamed back βββββββββββββββββββββββββββββββββββββββββββββDOSFI.ai β MeshInfer.AI Integration
Every interaction between DOSFI and MeshInfer is governed by a formal integration contract. The four DOSFI subsystems each have defined responsibilities within the MeshInfer fabric.
DOSFI Runtime β MeshInfer inference routing
| Contract | DOSFI Runtime calls MeshInfer via the @meshinfer/sdk. Every inference call passes through MeshInfer routing β no direct cloud calls are made by the Runtime. |
| Runtime responsibility | Execute inference locally when the routing decision is local. Stream tokens back to the calling application. |
| MeshInfer responsibility | Issue the routing decision (local / mesh / cloud), enforce the privacy gate, and dispatch the task to the selected compute target. |
| Failure handling | If local runtime fails, MeshInfer re-routes to mesh or cloud within the configured fallback policy. DOSFI Runtime reports the failure via the heartbeat. |
DOSFI Scheduler β MeshInfer scheduling
| Contract | DOSFI Scheduler sets per-node task concurrency caps and priority classes. MeshInfer Coordinator respects these caps when dispatching from the NATS task queue. |
| Scheduler responsibility | Report active_tasks count in every heartbeat. NACK tasks that would exceed the cap. Signal preemption readiness for background tasks. |
| MeshInfer responsibility | Dispatch tasks to the correct internal queue partition. Honor NACK responses by immediately re-dispatching to the next-best node. |
| Priority integration | DOSFI Scheduler exposes priority hints (interactive / standard / background) which MeshInfer uses to select queue partition and latency SLO. |
DOSFI Identity & Privacy β MeshInfer enforcement
| Contract | The DOSFI OIDC token is the only accepted authorization credential for MeshInfer. Routing permissions, model access scope, and privacy tiers are all claims within the token. |
| Privacy gate (synchronous) | MeshInfer evaluates the privacy_policy claim from the token BEFORE any I/O β no data ever leaves the device on a local_only policy, regardless of downstream behavior. |
| Node cert binding | NodeID cert must match the identity-bound DeviceID. Mismatched certs result in immediate 401 rejection at the MeshInfer Gateway. |
| Tier enforcement | Subscription tier claim in the token gates model access: developer (local only), startup (mesh routing), growth (BYOM, advanced policies), enterprise (on-prem, HIPAA BAA). |
DOSFI Storage β MeshInfer state transitions
| Inference state | Active task state (task_id, model, tokens_generated, checkpoint) is stored ephemerally by MeshInfer for KV-cache transfer in V3. |
| Model cache | DOSFI Storage layer hosts the local model cache. MeshInfer reads model_warm status from the capability vector β which is derived from the DOSFI Storage inventory. |
| Routing log persistence | MeshInfer writes RoutingLog records (route_decision, node_id, latency_ms, tokens) to the DOSFI-backed entity store for analytics and billing. |
| Audit trail | Every metering, issuance, and settlement event is written to the AuditLog entity β the DOSFI-backed audit store β for SOC 2 compliance. |
MeshNativeExchange.com β MeshInfer.AI Integration
DIU spend triggered by MeshInfer metering
| Trigger | MeshInfer Billing Meter emits a metering_event to Kafka on every completed inference task. |
| Spend calculation | diu_spend = (tokens_out / 1000) Γ RATES[req_class][route_decision]. Rates are set by the DOSFI pricing oracle and updated at each billing period. |
| Wallet debit | OrgID requester wallet is debited atomically with the metering event. Zero DIU balance β task dispatch blocked. No credit β no compute. |
| Exchange role | MeshNativeExchange receives spend events as inputs to the settlement batch. It does not calculate spend β it validates and commits what MeshInfer reports. |
DIU issuance triggered by inference execution
| Trigger | MeshInfer emits a diu_issued event for every successfully completed task. Failed tasks and late tasks (> 3Γ SLO) yield zero issuance. |
| Issuance formula | diu_net is derived from diu_spend, adjusted by the node's reputation and quality multipliers. The gross spend is split between the node wallet, platform infrastructure, and protocol reserve, with the majority going to the node. |
| Exchange role | MeshNativeExchange batches pending issuance events at each hourly epoch, verifies integrity (SHA-256 hash chain), and commits final credits to node wallets. |
| Audit | Every issuance event is written to AuditLog with resource_type: "diu_issued". Settlement records carry an integrity_hash verifiable externally. |
Settlement logs originate from MeshInfer
| Source of truth | MeshInfer is the sole source of settlement input data. MeshNativeExchange is the settlement executor β it does not generate its own compute events. |
| Log fields | settlement_id, epoch_start, epoch_end, node_settlements[], total_diu_issued, total_platform_fee, integrity_hash, committed_at |
| Dispute resolution | If a node disputes a settlement, the dispute references a specific request_id in MeshInfer RoutingLog. MeshInfer logs are the arbitration source. |
DOSFI Academy & University β MeshInfer.AI Integration
DosfiAcademy.com β developer onboarding via MeshInfer
DosfiUniversity.com β enterprise certification via MeshInfer
Cross-System Consistency Layer
The following terminology, architectural language, and system descriptions are the canonical versions. Every document, UI, and communication across all five systems must use these definitions without modification.
Unified terminology guide
Unified navigation & cross-link map
MeshInfer-Centric Integration Map
ββββββββββββββββββββββββββββββββββββββββββββββββββ
β MeshInfer.AI (Central Hub) β
β β
DOSFI.ai βββββββββββββΊβ ββββββββββββ ββββββββββββ βββββββββββββββ β
(Runtime, Scheduler, β β Gateway β β Router β β Task Queue β β
Identity, Storage) β β (CF Edge)β β Engine β β (NATS JS) β β
β ββββββββββββ ββββββββββββ βββββββββββββββ β
DosfiAcademy.com βββββΊβ ββββββββββββ ββββββββββββ βββββββββββββββ β
(SDK labs, routing β β Identity β β Billing β β Reputation β β
tutorials, metering) β β Verifier β β Meter β β Scorer β β
β ββββββββββββ ββββββ¬ββββββ ββββββββ¬βββββββ β
DosfiUniversity.com βββΊβ β β β
(architecture courses, β βΌ βΌ β
certification, DIU) β DIU Spend Node Pool β
β Events β
ββββββββββββββββββββββ¬ββββββββββββββββββββββββββββ
β
ββββββββββββββββββββββΌββββββββββββββββββββββββββββ
β MeshNativeExchange.com β
β Issuance events Β· Epoch settlement Β· Wallets β
ββββββββββββββββββββββββββββββββββββββββββββββββββ
β
ββββββββββββββββββββ¬βββββββββββββββ΄βββββββββββββββ¬βββββββββββββββββββββ
βΌ βΌ βΌ βΌ
node-d01β¦d08 node-b01β¦b06 node-m01β¦m04 node-s01β¦s02
Desktop tier Browser tier Mobile tier Server tier
llama.cpp WebGPU / WASM CoreML / NNAPI CUDA 12+
