aien-sovereign-core-mv
AienOS host runtime: inference scheduling, paged KV state, the aien CLI and Spark verification tooling. Its inference engine is in alpha testing (DGX Spark GB10); Omega is the implementation destination.
Brought by drakestapleton
aien-sovereign-core-mv / crates / aien-omega-compose / README.md
| 1 | # aien-omega-compose |
| 2 | |
| 3 | Rust binding to omega COMPOSITION-2 through the rxc_host C ABI |
| 4 | (`src/runtime/rxc_host_abi.h`, archive `build/librx_compose.a`, make target |
| 5 | in omega `mk/rx_compose_lib.mk`). NEXT-PHASE-1 cut 1b. |
| 6 | |
| 7 | ## Building against omega |
| 8 | |
| 9 | The library is built from an omega checkout whose HEAD must equal `omega.lock` |
| 10 | (the same pin aien-omega-gpu uses; since NEXT-PHASE-1 it is omega 62b6a28, which |
| 11 | contains `librx_compose.a`). Default build, no override: |
| 12 | |
| 13 | ```text |
| 14 | AIEN_OMEGA_DIR=<omega checkout at omega.lock> |
| 15 | AIEN_PHYSICS_DIR=<physics checkout at omega physics.lock> |
| 16 | AIEN_AIENOS_LOCK_REPO=<aienos clone> |
| 17 | cargo test -p aien-omega-compose |
| 18 | ``` |
| 19 | |
| 20 | | Variable | Meaning | |
| 21 | |----------|---------| |
| 22 | | `AIEN_OMEGA_DIR` | omega checkout at `omega.lock`; shared with aien-omega-gpu | |
| 23 | | `AIEN_OMEGA_COMPOSE_DIR` | a different omega checkout for this crate only (takes precedence over `AIEN_OMEGA_DIR`) | |
| 24 | | `AIEN_OMEGA_COMPOSE_SHA` | **developer override**: full 40-hex sha the checkout must be at instead of `omega.lock`, for building against an unmerged omega branch. Prints a build warning; never used for a release build or a campaign receipt. | |
| 25 | | `AIEN_PHYSICS_DIR` | physics checkout at omega's `physics.lock` (default `<omega>/../physics`) | |
| 26 | | `AIEN_AIENOS_LOCK_REPO` | aienos clone holding omega's `aienos.lock` commit (passed as `AIENOS_LOCK_REPO`) | |
| 27 | | `AIEN_OMEGA_COMPOSE_LIB` | link a prebuilt `librx_compose.a` instead (not sha-checked) | |
| 28 | | `AIEN_FORCE_CPU_STUB=1` | stub: every call returns `ComposeError::Unavailable` (build time only; for a CPU-only run use `AIEN_BACKEND=cpu`, which makes the daemon refuse a GPU build) | |
| 29 | |
| 30 | With no checkout and no library set the crate builds the stub and prints a warning. |
| 31 | Use `AIEN_OMEGA_COMPOSE_DIR` together with `AIEN_OMEGA_COMPOSE_SHA`, so an override |
| 32 | never changes the checkout aien-omega-gpu checks against `omega.lock`. |
| 33 | |
| 34 | The integration test (`tests/compose.rs`) is ignored in a stub build. |
| 35 | |
| 36 | ## Semantics (from the C header) |
| 37 | |
| 38 | - `open` binds the directory to one AienMachineId (`machine.id`); another |
| 39 | machine is refused. The Cortex journal is `<dir>/cortex.cx`. |
| 40 | - `register_skill` before the first `run`/`recall`/`info`. At most 2 Skills. |
| 41 | Callbacks run on omega World worker threads. |
| 42 | - `run(task, now_us)`: the Skills compete on staged J-Space branches, AEGIS |
| 43 | checks each result with the `set_verify` callback, the winner commits. |
| 44 | The result carries the Cortex record ids, branch count and verdict. |
| 45 | - A reopen appends records; pre-restart records stay an unchanged prefix. |
| 46 | - Torn journal tail: `refuse_torn = true` refuses without touching the file; |
| 47 | otherwise it is repaired when it lies past the last commit, and refused |
| 48 | explicitly (stably) when it lies inside the committed record. |