Skip to main content

Module p64_cartridge

Module p64_cartridge 

Source
Expand description

.p64 Neural Extension Cartridge binary packer, unpacker, and recurrent-state/KV seed bridge.

A .p64 neural extension cartridge attaches to any non-.p64 mechanical CAD assembly or .10d flora/fauna asset and carries two tiers in a single deterministic binary container:

  • Tier 0 (Vendor-Agnostic Universal Payload): compact CBOR-LD PredicateTriggerRule table and NQuin guardrails that any model (Qwen, Gemma, Gemini, etc.) can consume.
  • Tier 1 (Vendor/Model-Keyed Neural Slots): zero-copy aligned byte ranges containing pre-warmed Qwen3.5 GatedDeltaNet recurrent state seeds (f32), KV prefix snapshots, Gemma 4 PLE tables, or LoRA deltas.

Structs§

P64ExtensionHeader
Parsed header of a .p64 neural extension cartridge.

Constants§

P64_EXT_CARTRIDGE_MAGIC

Functions§

encode_trigger_rules_cbor_ld_into
Encode PredicateTriggerRules into the compact 60-byte-per-rule CBOR-LD binary frame (zero-heap).
load_p64_slot_f32_seed_into
Extract the f32 recurrent-state or KV seed payload for a matched P64ExtensionSlot into out_floats (zero-heap).
mount_p64_cartridge_onto_engine
Mount a .p64 neural extension cartridge onto a QTensorEngine when a matching Tier-1 recurrent-state seed slot exists for (preferred_model_id, architecture_id). Even when no Tier-1 vendor slot matches (e.g., running on a cloud or different vendor LLM), the Tier-0 PredicateTriggerRules and NQuin guardrails are unpacked and returned.
pack_p64_extension_cartridge_into
Pack a .p64 neural extension cartridge (Tier-0 CBOR-LD rules + NQuin guardrails + Tier-1 vendor/model slot directory and f32 recurrent-state/KV payloads) into caller-supplied out_bytes.
unpack_p64_extension_cartridge_into
Unpack a .p64 neural extension cartridge into caller-supplied Tier-0 and Tier-1 buffers (zero-heap).