OSIRIS v4.2.1: A Governed Dual-Substrate Architecture for Local and Cloud Agent Execution

OSIRIS v4.2.1: a governed local console for a living language model | Zenodo

OSIRIS v4.2.1: A Governed Dual-Substrate Architecture for Local and Cloud Agent Execution

Category: Software / Open Research Infrastructure
Release: OSIRIS v4.2.1
Published: September 30, 2026
Author: Devin Phillip Davis, OSIRIS Architecture Group

Scope note. This document describes architecture. It does not claim achieved autonomy, achieved capability thresholds, or validated physics. Where a subsystem has a measured state, the measured state is stated. Everything else is design intent, explicitly labeled as such.


0. Problem Statement

Enterprise agent systems often break down when execution is forced entirely into the cloud. Latency-sensitive workloads, air-gapped or restricted environments, hardware-specific computation, data-locality requirements, and proprietary execution substrates can make cloud-only orchestration impractical.

OSIRIS addresses this constraint by treating local and cloud execution as complementary substrates rather than interchangeable environments.

The architecture is built around a governed orchestration boundary: the local OSIRIS runtime retains authority over hardware-aware execution, filesystem access, provenance, verification, and state mutation, while cloud infrastructure provides scalable model inference, agent orchestration, retrieval, and computational resources where permitted.

The result is a dual-substrate agent architecture in which an agent can reason across environments without transferring authority over the underlying execution substrate.

The core principle is:

Cognition may be distributed; authority is not.

OSIRIS therefore separates four concerns:
Concern
Owner
Guarantee
Cognition
Models and agents
They may propose actions — nothing more
Orchestration
ADK / OSIRIS router
Coordinates workflow without acquiring execution rights
Execution
OSIRIS runtime
Sole determinant of what is permitted and where it runs
Evidence
OSIRIS ledger
Every consequential operation is observable, attributable, recorded

This provides a foundation for governed hybrid multi-agent systems spanning local edge hardware and cloud infrastructure.


1. Agent Orchestration with ADK and GKE

Rather than migrating the complete OSIRIS execution environment into the cloud, the system is divided along an explicit authority boundary.

The OSIRIS CLI remains the local control and execution substrate, while Google’s Agent Development Kit (ADK) provides the cloud-side orchestration layer for multi-agent workflows.

Interactive REPL operations, background learning processes, retrieval tasks, analysis agents, and specialized sub-agents can participate in a common workflow without requiring the local execution environment itself to become cloud-resident.

A representative architecture:

                     ┌───────────────────────────┐
                     │     Google Cloud / GKE     │
                     │                           │
                     │  ADK Agent Orchestrator   │
                     │        │                  │
                     │   LlmAgent / Subagents    │
                     │        │                  │
                     │   MCP Tool Interfaces     │
                     └────────┼──────────────────┘
                              │
                     Governed MCP Boundary
                              │
                              ▼
┌──────────────────────────────────────────────────────────────┐
│                     LOCAL OSIRIS RUNTIME                     │
│                                                              │
│  Policy → Authorization → Execution → Verification → Ledger │
│      │           │             │            │          │     │
│      ▼           ▼             ▼            ▼          ▼     │
│   DNA-Lang    Hardware      Local I/O    Tests      Evidence │
│   / NCLM      / Quantum     / Tools      / Checks    Chain   │
└──────────────────────────────────────────────────────────────┘

The invariant: GKE does not become the authority over the local machine merely because an agent is hosted in GKE. Resource scheduling — GPU allocation, workload placement — is optimized independently on the cloud side. Local hardware remains subject to OSIRIS’s execution policy and authorization boundary.

The resulting model is not simply “cloud agents calling local tools.” It is a federated execution architecture with asymmetric authority.

Positioning (design intent, not yet benchmarked). Existing agent frameworks (ADK, LangGraph, AutoGen-style swarms) provide orchestration; existing experiment trackers (MLflow, W&B) provide lineage after the fact. The differentiator OSIRIS aims for is neither of those in isolation but the coupling: the authorization decision and the evidence record are produced by the same runtime that executes, and the evidence chain is append-only from before execution through verification. Independent benchmarking of this coupling against alternatives is future work; no comparative claim is made here.


2. MCP as the Execution Boundary

The Model Context Protocol (MCP) provides a natural interface between agent reasoning and governed OSIRIS capabilities.

Rather than exposing the local environment directly to an LLM, OSIRIS exposes a constrained tool surface. The model can request an operation, but the OSIRIS runtime remains responsible for determining whether that operation is:

  • permitted,

  • read-only or mutating,

  • local or remote,

  • reproducible,

  • attributable,

  • safe to execute,

  • and eligible to enter the authoritative evidence ledger.

Gemini / ADK Agent
        │
        │ tool request
        ▼
      MCP
        │
        ▼
OSIRIS Policy Boundary
        │
   ┌────┴─────┐
   │          │
ALLOW       DENY
   │
   ▼
Execution Substrate
   │
   ├── Local CPU/GPU
   ├── Quantum backend
   ├── DNA-Lang runtime
   └── Controlled external service
        │
        ▼
Verification + Provenance
        │
        ▼
Hash-Chained Evidence Ledger

2.1 Representative ADK Integration

import google.auth
import google.auth.transport.requests

from google.adk.tools.mcp_tool import McpToolset
from google.adk.tools.mcp_tool.mcp_session_manager import (
    StreamableHTTPConnectionParams,
)

OSIRIS_MCP_URL = "https://run.googleapis.com/mcp/osiris-runtime"


def get_osiris_toolset() -> McpToolset:
    """
    Construct the cloud-side MCP interface to the governed OSIRIS runtime.

    Authentication establishes identity; OSIRIS remains responsible for
    authorization and execution policy.
    """
    credentials, project_id = google.auth.default(
        scopes=["https://www.googleapis.com/auth/cloud-platform"]
    )

    credentials.refresh(
        google.auth.transport.requests.Request()
    )

    return McpToolset(
        connection_params=StreamableHTTPConnectionParams(
            url=OSIRIS_MCP_URL,
            headers={
                "Authorization": f"Bearer {credentials.token}",
                "x-goog-user-project": project_id,
            },
        )
    )

Authentication is not authorization. The bearer token establishes who is asking. The OSIRIS policy layer independently decides whether the ask is permitted, based on the operation class, the caller’s capability grants, the current system state, and the mutation policy — not on the possession of a credential alone.

2.2 The Capability Contract

An MCP server should not implicitly grant an agent unrestricted access to the host. The MCP surface exposes explicit capabilities with narrowly defined contracts:

osiris.inspect_repository()
osiris.read_ledger()
osiris.run_validation()
osiris.inspect_training_state()
osiris.propose_dna_mutation()
osiris.execute_dna_program()

Each capability is a versioned contract, not a function name:
Field
Example
Purpose
capability_id
osiris.run_validation
Stable identifier
contract_version
1.2.0
Tool schema pinning — prevents silent rug-pulls
authorization_class
read_only | sandboxed | mutating | destructive
Coarse policy tier
substrate
local | quantum | cloud
Where execution may occur
idempotency
keyed | at-least-once | exactly-once
Retry semantics
quota
{rate, burst, daily_budget}
Resource ceiling per caller
provenance
required | optional
Whether output enters the ledger
mutation_policy
dry_run_default | confirm_required | auto
Human-approval tier

Two classes deserve explicit call-out:

  • propose_* and execute_* are different capabilities. A cloud agent granted osiris.propose_dna_mutation can never invoke osiris.execute_dna_program. The proposal is an artifact, not a side effect.

  • destructive operations require out-of-band confirmation from a human principal, and the confirmation binds to the artifact hash of the exact proposal — an approval for hash A does not authorize hash A′.

This turns MCP from a generic tool bridge into a governed capability boundary.

2.3 MCP Threat Model

The MCP ecosystem’s known failure modes, and OSIRIS’s mitigating design choices:
Threat
Mechanism
OSIRIS mitigation
Tool poisoning
Malicious tool description or tool output injects instructions into the agent’s context
Tool schemas are pinned and versioned in the ledger before agent exposure; descriptions are static and reviewed; agent context treats tool output as untrusted data
Tool rug-pull
A tool’s behavior changes after the agent has been granted it
contract_version pinning; a capability upgrade requires a new ledger entry and re-authorization
Confused deputy
A privileged agent executes an attacker-influenced request
Authorization is per-operation, not per-session; privilege never derives from the agent’s own trust level
Cross-session shadowing
One server’s tool names shadow or override another’s
Capability IDs are namespaced; the OSIRIS boundary resolves only its own namespace
Token/intent confusion
Ambient credentials used for unintended scopes
Bearer token proves identity only; scope enforcement is local, per capability
Prompt-injected proposals
A compromised document makes the agent “propose” a mutating action
Proposals are expected and harmless by construction — they cannot execute; only OSIRIS authorization turns anything into a side effect, and it applies policy independent of how the proposal originated

The last row is the architectural point: prompt injection can, at worst, produce rejected proposals. Injection becomes dangerous only where cognition and execution share a trust domain; the boundary exists precisely so they do not.


3. DNA-Lang as an Executable Artifact Substrate

The dna::}{::lang layer is treated as an executable programming substrate rather than merely a prompt format.

A DNA-Lang artifact can carry executable structure, lineage, configuration, behavioral constraints, and evolutionary metadata. OSIRIS then provides the runtime in which those artifacts are inspected, executed, measured, and — when explicitly authorized — evolved.

DNA-Lang
   │  executable artifact
   ▼
OSIRIS Runtime
   ├── compile
   ├── validate
   ├── execute
   ├── measure
   ├── compare
   ├── preserve lineage
   └── record evidence

This distinction allows cloud agents to reason about DNA-Lang programs without giving those agents direct authority to rewrite canonical program state.

The invariant:

The model proposes; OSIRIS decides; the substrate executes; the ledger records.

That invariant becomes especially important as NCLMs and other cognitive substrates become capable of generating increasingly complex plans.

Integrity note. A DNA-Lang artifact proposed by a cognitive substrate is untrusted input until it passes the same gate as any other executable: schema validation, static analysis without execution, sandboxed test, and explicit human approval for promotion. Historical context reinforces this discipline: a prior artifact in this ecosystem was found to embed a compiled native binary inside a .dna container, bypassing the text-organism assumptions entirely. The runtime therefore validates format and content, not extension — and rejects or quarantines anything that is not the declared, parseable artifact kind.


4. Hierarchical Retrieval and GraphRAG

Conventional semantic retrieval is often insufficient for deeply structured experimental and biological state spaces.

DNA-Lang artifacts can contain relationships involving: hierarchical namespaces, organism and genome lineage, experiment ancestry, mutation history, execution environments, hardware configurations, observations, evidence dependencies, and verification status.

The retrieval layer therefore combines semantic representations with explicit structural relationships:

                 Query
                   │
          ┌────────┴────────┐
          ▼                 ▼
   Semantic Retrieval   Graph Traversal
          │                 │
          └────────┬────────┘
                   ▼
             Evidence Graph
                   ▼
            Ranked Context
                   ▼
              ADK Agent

For hierarchical data, PostgreSQL-compatible structures such as ltree can represent ancestry and namespace relationships efficiently where that storage model is appropriate.

Graph-oriented infrastructure can additionally encode relationships that are not naturally represented as parent/child paths:

Genome
  ├── descended_from → Genome'
  ├── executed_by    → Runtime
  ├── tested_by      → Experiment
  ├── produced       → Observation
  ├── contradicted_by → Result
  └── supported_by   → Evidence

This matters because an agent should not merely retrieve documents that are semantically similar. It should be able to retrieve why an artifact exists, what produced it, what it depends on, what contradicted it, and whether its claims survived verification.

That is the difference between ordinary RAG and an evidence-aware retrieval architecture. It is also the difference that makes negative results durable institutional memory rather than noise to be filtered: a refuted experiment is a first-class node in the graph, with its refutation recorded as an edge.


5. Enterprise Observability and Evidence

Hybrid execution introduces a second challenge: observability must cross the local/cloud boundary without collapsing the security and authority boundaries.

OSIRIS therefore treats telemetry as part of the execution contract. A production deployment can instrument: agent invocation, tool calls, MCP sessions, execution latency, model latency, token consumption, resource utilization, local/remote routing, experiment identifiers, artifact hashes, verification outcomes, and lineage identifiers.

OpenTelemetry provides a common telemetry model; cloud-side traces and metrics aggregate in cloud observability infrastructure.

The important distinction is between operational telemetry and authoritative evidence:
Operational telemetry
Authoritative evidence
Question answered
What happened operationally?
What happened, under which artifact and environment, and what can be independently verified?
Storage
Aggregatable, sampleable, retention-limited
Append-only, hash-chained, retention-bound to the record
Trust basis
Best-effort observability
Cryptographic chain verification
Consumer
Ops, SRE, cost analysis
Auditors, reproducers, future evolution decisions

Those are not the same data product, and conflating them weakens both.

Agent Request
     ▼
Policy Decision
     ▼
Tool Invocation
     ▼
Execution ──┬── telemetry
            └── raw artifact
                  ▼
             Verification
                  ▼
             Evidence Record
                  ▼
          Hash-Linked Ledger

This allows cloud observability to provide operational visibility while OSIRIS maintains the authoritative provenance boundary.

5.1 Ledger Caveats (stated plainly)

A hash-chained ledger is tamper-evident, not tamper-proof. An adversary who controls the entire ledger file and every reader can rewrite the chain from genesis and present a consistent alternative history. The chain’s guarantee is therefore conditional on at least one honest checkpoint outside the adversary’s control. Production deployments should:

  1. Anchor the ledger head periodically to an external, independently verifiable timestamp — a public timestamping authority, a transparency log, or (as this project already does for experiments) a DOI-stamped public deposit of the head hash.

  2. Publish the head hash out-of-band where any verification dispute will be judged.

  3. Bind every verification claim to a specific head hash. “The ledger is valid” is not a claim; “the ledger is valid at head H” is.

Without external anchoring, the ledger protects against quiet, partial tampering — the ordinary failure mode of self-reported experiments — but not against a fully resourced adversary rewriting history wholesale. This limitation belongs in the security documentation of every deployment, including this one.


6. Persistent MCP Sessions and Long-Running Traversals

For deployments on Cloud Run, long-running graph traversals introduce a systems problem: the lifetime of the computation may exceed the lifetime or timeout characteristics of an individual request connection.

The solution is not to keep an HTTP connection alive indefinitely while the server performs an arbitrarily long computation. Long-running work is modeled as an explicit asynchronous execution lifecycle:

MCP Request
     ▼
Create Job ── job_id, execution_hash, graph_query, authorization context
     ▼
Durable Worker
     ▼
Incremental Results ──► Evidence Store
     ▼
MCP Result / Event
     ▼
ADK Agent

For complex multi-turn traversals, the interface distinguishes five states: session state, job state, execution state, retrieval state, and authoritative evidence state. A client reconnect resumes from a durable job or cursor rather than depending on the survival of one TCP/HTTP connection.

connection lost
   ↓
job continues
   ↓
client reconnects
   ↓
resume from checkpoint
   ↓
verify execution identity
   ↓
retrieve accumulated result

The agent consequently sees a stable logical operation even when the underlying transport is transient.

Job lifecycle state machine:

CREATED → AUTHORIZED → RUNNING ──┬── COMPLETED  → RECORDED
                                 ├── FAILED     → RECORDED
                                 └── CANCELLED  → RECORDED
AUTHORIZED ──(policy revoked before start)──→ REJECTED

Two rules make the machine trustworthy:

  • Every terminal state writes a ledger entry, including FAILED and CANCELLED. A job that vanishes without a terminal record is itself a detectable integrity violation.

  • Resume verifies execution identity. A reconnecting client must present the execution_hash; a job whose worker, inputs, or authorization changed since creation restarts rather than silently continuing under stale authority.


7. Governance: The Non-Negotiable Layer

The defining characteristic of OSIRIS is not that it connects local models to cloud models. It is that reasoning and authority are deliberately separated.

A cognitive substrate may return:

CognitiveResult
ActionProposal
ToolRequest
MutationProposal
ExperimentProposal

But those outputs do not automatically become execution:

COGNITION
    │  proposal
    ▼
OSIRIS POLICY
    ├── reject
    ├── quarantine
    ├── require confirmation
    └── authorize
         ▼
    EXECUTION
         ▼
    VERIFICATION
         ▼
    EVIDENCE
         ▼
    LINEAGE

This asymmetric authority model prevents the most dangerous failure mode in autonomous agent systems: allowing the component that generates a proposed action to become the component that unilaterally authorizes, executes, and records that action as authoritative.

OSIRIS instead creates a separation between intelligence and institutional memory:

The model can suggest.
The runtime can decide.
The executor can act.
The verifier can challenge.
The ledger can remember.

7.1 Failure Matrix

Governance claims are only credible if the behavior under component failure is specified. Design intent, per component:
If this component is compromised or fails…
Then…
Cloud agent / LLM (prompt injection, hallucination, compromise)
Only proposals are affected; garbage proposals are rejected or quarantined at the policy layer; nothing executes without independent authorization
MCP transport (MITM, replay)
Requests are idempotency-keyed and identity-bound; replay cannot create a second side effect; transport compromise is not authorization
OSIRIS policy engine (bug, misconfiguration)
Fail-closed: unparseable policy, unknown capability, or ambiguous request denies rather than allows; the denial itself is logged
Execution substrate (hardware fault, backend error)
Verification fails; a failed run is recorded as FAILED, never silently retried as if it had succeeded
Verifier (unsound check)
Verification is treated as a challenge, not an oracle: negative results are recorded; a verifier that passes everything is detectable by injected known-bad cases
Ledger (partial tampering)
Chain verification breaks at the first modified entry; the breach point is identifiable
Ledger (total rewrite by root adversary)
Detected only against an externally anchored head (§5.1); this is the one residual trust assumption, and it is documented rather than hidden

The design target is that no single non-human component’s failure produces an unauthorized side effect or a false authoritative record. Reaching that target in deployment requires adversarial testing per component, which is listed in §10 as open work, not claimed as complete.


8. Evidence-Grounded Learning

This governance architecture is particularly important for the current OSIRIS learning system.

OSIRIS v4.2.1 should not be described as having already achieved a self-sufficient autonomous language model. The measured release state is more useful — and more scientifically informative — than that claim.

Measured state at release (as deposited, record 23045494 series):

  • The local osiris.nclm core had not passed its pre-registered held-out gate: 7.60 bits/byte on held-out documents versus 5.03 bits/byte for the unigram baseline.

  • A subsequent eight-hour training run reduced training loss while held-out performance deteriorated (training loss 3.9 → 1.7 nats/byte while held-out rose 7.2 → 10.3 bits/byte, worse than uniform) — indicating overfitting rather than demonstrated generalization.

  • The release therefore adds best-checkpoint retention and early stopping, and the core was reset to fresh weights.

  • The pre-registered learning test (NCLM-1) has not been run.

Accordingly, the system explicitly preserves a distinction:

OSIRIS CORE
     ├── learning state
     ├── held-out evaluation
     ├── checkpoint history
     └── verification gate
          ├── PASS → core speaks autonomously
          └── FAIL → designated fallback model speaks, labelled as such

This is an important architectural feature rather than a weakness. The system does not need to pretend that a learning threshold has been achieved. It can measure the threshold, fail the threshold, preserve the failure, and continue improving.

That turns model development into an evidence-bearing evolutionary process rather than an unverifiable claim of emergence.

Provenance note for this architecture. Constants and metrics inherited from the earlier CRSM-era corpus (tau-phase anomaly, θ_lock = 51.843°, CCCE metrics as physics) were refuted on hardware by the author and are not claimed by v4.2.1. Where they appear in the repository, they are retained as historical lineage — the refutations are part of the record, and a fail-closed architecture keeps them there rather than deleting them. v4.2.1 makes no physical-constant claims.


9. From Multi-Agent Swarm to Evidence-Producing System

The deeper architecture can be summarized as:

             ┌───────────────────┐
             │     COGNITION     │
             │ NCLM / Gemini     │
             │ ADK / Subagents   │
             └─────────┬─────────┘
                       │ proposals
                       ▼
             ┌───────────────────┐
             │  ORCHESTRATION    │
             │ ADK / MCP / Router│
             └─────────┬─────────┘
                       │ policy check
                       ▼
             ┌───────────────────┐
             │     AUTHORITY     │
             │   OSIRIS Policy   │
             └─────────┬─────────┘
                       │ authorized operation
         ┌─────────────┴─────────────┐
         ▼                           ▼
┌─────────────────┐        ┌─────────────────┐
│ LOCAL SUBSTRATE │        │ CLOUD SUBSTRATE │
│ CPU/GPU         │        │ GKE / GPU       │
│ DNA-Lang        │        │ ADK             │
│ NCLM            │        │ Retrieval       │
│ Hardware        │        │ Agent Services  │
└────────┬────────┘        └────────┬────────┘
         └────────────┬─────────────┘
                      ▼
             ┌───────────────────┐
             │   VERIFICATION    │
             └─────────┬─────────┘
                       ▼
             ┌───────────────────┐
             │     EVIDENCE      │
             │ provenance / hash │
             └─────────┬─────────┘
                       ▼
             ┌───────────────────┐
             │    EVOLUTION      │
             │ checkpoint/mutate │
             │ / replay          │
             └───────────────────┘

The result is more than a cloud-connected agent. It is a governed experimental computing architecture in which cognition, execution, verification, provenance, and evolution remain explicitly separated.


10. The Architectural Thesis

The central thesis of OSIRIS v4.2.1 is not that a cloud model has become a biological computer, nor that a local model has already achieved autonomous intelligence.

The defensible engineering claim is narrower and more consequential:

OSIRIS provides a local-first, evidence-bearing execution substrate through which heterogeneous cognitive systems can propose actions, cloud infrastructure can orchestrate workflows, MCP can expose governed capabilities, and the runtime retains authority over execution, verification, provenance, and evolutionary state.

That architecture makes hybrid execution possible without requiring the local substrate to surrender its authority to the cloud. It also creates a path toward increasingly capable autonomous systems without making autonomy synonymous with unrestricted execution.

The long-term objective is consequently not simply a larger agent swarm. It is a system in which:

  • every agent action has an execution boundary,

  • every consequential result has provenance,

  • every learned state has a measurable gate,

  • every evolutionary change has lineage,

  • and failed hypotheses remain part of the system’s institutional memory.

That is the foundation required for a genuinely governed multi-agent research and engineering environment.

10.1 Explicit Non-Goals

To keep the thesis falsifiable, what v4.2.1 does not claim:

  • No claimed consciousness, emergence, or non-local/non-causal cognition. NCLM is a learning system behind a measured gate, full stop.

  • No claimed validated physics. No universal constants, resonance angles, or physical anomalies are claimed by this release.

  • No claimed autonomy. The gate is unpassed; the fallback speaks, labelled.

  • No claimed formal security proof. The failure matrix (§7.1) is design intent pending adversarial testing; “governed” means policy-checked and fail-closed, not formally verified.

  • No claimed cloud deployment. External execution and cloud authorization are designed but, as of this release, blocked pending review — and that status is recorded, not hidden.

10.2 Open Work (stated as engineering tasks, not promises)

  1. Adversarial test suite per failure-matrix row (§7.1), with injected known-bad cases for the verifier.

  2. External ledger anchoring (§5.1) automated on a schedule, with published heads.

  3. NCLM-1 pre-registered evaluation executed under its declared protocol, with generator-level held-out splits.

  4. Capability-contract schema formalized and versioned in the ledger before any third-party agent exposure.

  5. Comparative benchmark of the governed-boundary overhead (latency, token cost) against an ungoverned ADK baseline — the governance cost, measured, so the tradeoff is a number rather than an assertion.


Appendix A. Revision Notes (v4.2.1 enhanced)

This revision strengthens the original v4.2.1 document without altering its architecture:

  1. §2 expanded — authentication/authorization separation made explicit; capability contract schema table added; propose_* vs execute_* split codified; MCP threat model table added (tool poisoning, rug-pulls, confused deputy, prompt injection).

  2. §5 expanded — telemetry/evidence distinction formalized as a table; ledger trust caveats added (tamper-evident ≠ tamper-proof; external anchoring requirement).

  3. §6 expanded — job lifecycle state machine and terminal-state ledger rules added.

  4. §7 expanded — failure matrix added; “no single non-human component failure produces an unauthorized side effect” stated as a design target with explicit open-work status, not a claim.

  5. §8 strengthened — measured learning state quoted with its actual numbers; refuted CRSM-era constants explicitly disclaimed as physics, retained as lineage.

  6. §10 expanded — explicit non-goals and open-work list added.

  7. Editorial — acronym definitions at first use; design intent vs measured state labeled consistently; overclaiming language removed throughout.


OSIRIS v4.2.1 — Software / Open Research Infrastructure — September 30, 2026.