omega-harness
Agent skills for operating, encoding and communicating in Omega (.om) and the AIEN repositories
Brought by drakestapleton
GitHub aien-dev/omega-harness#199 (code only)
Apply it
git checkout -b patch-bce6f574f2acddba c32685bcd2adc834d9047d97f102e5233d87ac7d curl -fsSL https://interplane.io/drakestapleton/omega-harness/patches/bce6f574f2acddba.patch | git am
Provenance
github-import 1
aien-dev/omega-harness
199
facc674ebb81d2bd62750f292fd3ff0446cc850e
{"kind":"github-import","owner":"aien-dev","repo":"omega-harness","number":199,"url":"https://github.com/aien-dev/omega-harness/pull/199","export_sha256":"967c79e26a893657b5cdaa45efd442be5dbd2ecfe68e25f9a8c1b5da4d60d452","imported_utc":"2026-11-18T16:39:42Z","metadata":"unavailable","state_derived":true}
Changes
diff --git a/skills/aien-repositories/SKILL.md b/skills/aien-repositories/SKILL.md index a604683..6609a1f 100644 --- a/skills/aien-repositories/SKILL.md +++ b/skills/aien-repositories/SKILL.md @@ -139,7 +139,7 @@ For memory, do not route to an archived repo just because its name sounds right. - [ggml-omega](https://github.com/aien-dev/ggml-omega) (created 2026-10-27, child of omega-bridge, issue omega-bridge#10): a ggml/llama.cpp out-of-tree backend (`GGML_BACKEND_PATH=libggml-omega.so`) whose op kernels are seeded-Omega units; unsupported ops fall back to ggml's CPU backend. PENDING: main holds only a skeleton (README, LICENSE); the backend is open [ggml-omega#1](https://github.com/aien-dev/ggml-omega/pull/1) (branch `omega-backend`, head `90f1e313` on 2026-10-31), and the following describes that branch. `ggml-omega.c` is interim host glue (addressing, loops, staging only; successor: an `.om` loadable object, omega-mv #636/#637). It pins omc, omega-bridge `src/native.om` (sha256) and llama.cpp (commit); `build.sh` refuses mismatches. Status claims come from its CI per-op `test-backend-ops` table, the `add -> sub` mutant and the end-to-end CPU-vs-Omega decode, never from compiling. Nothing from it is posted to ggml-org/llama.cpp. - [omega-bridge](https://github.com/aien-dev/omega-bridge): owns compatibility, not computation or GPU execution. Checked Omega-subset conversion to C/Python (`src/toc.om`), native bindings so foreign callers call compiled Omega (`src/native.om`), framework attachments (PyTorch, llama.cpp/GGML, MAX) and the opt-in GPU artifact boundary (`src/gpu_adapter.om`, which runs no kernel; device runs go through CUDApp). It is an adoption mechanism that makes existing ecosystems optional and must not constrain Omega to them. [Current instructions](https://github.com/aien-dev/omega-bridge/blob/main/AGENTS.md) explicitly refuse universal conversion: Python/C input conversion is not implemented. Adapter admission is not proof of device execution. Do not take a compiler from it; pin omega-mv's (omega-mv#870, open). [omega-bridge #47](https://github.com/aien-dev/omega-bridge/pull/47) (merged 2026-10-31, squash `6ec6dab7`) runs a `.om` matmul inside a MAX 26.7.0 graph as a CPU custom op (`max-cpu/`; one Mojo glue file, `OwnedDLHandle` + dlsym; plain `external_call` cannot resolve the symbol in MAX's kernel JIT). EXERCISED on the Spark host CPU only (`sh max-cpu/run.sh`: `OMEGA MAX CPU: PASS`, controls green and four negative controls refused); no kernel ran on GB10. The graphs are CPU-only, but MAX 26.7.0 `Graph()` still creates a CUDA context whenever a GPU is visible, and `run.sh` at `6ec6dab7` did not hide it: a 2026-10-31 rerun there passed every check and control, then exited 1 when its last measurement failed in `Accelerator()` with `CUDA_ERROR_OUT_OF_MEMORY`. [omega-bridge #51](https://github.com/aien-dev/omega-bridge/pull/51) (merged 2026-10-31, squash `9532044e`) fixes this: `run.sh` exports `CUDA_VISIBLE_DEVICES=` and `omega_max.py` refuses a visible GPU (exit 2). Its requalification at head `5f7492ff` exited 0 with 16 of 16 measurements and no harness process in `nvidia-smi --query-compute-apps` across 77 samples, and a copy of `run.sh` without the export was refused. Run plain `sh max-cpu/run.sh` on main; on the Spark pin it to cores 5-9, never 10-14. When reproducing it, give each run an empty `MODULAR_CACHE_DIR`, because MAX 26.7.0 reuses a compiled custom-op kernel after its Mojo source changes; `max-cpu/mogg-cache-repro.sh` shows this and exits 0 since #51. - x86linux native bindings (merged): since [omega-bridge#44](https://github.com/aien-dev/omega-bridge/pull/44) (merged 2026-10-31, squash `49b69635`) the native generators (`native c` and `native freest`, `src/native.om`) also emit `x86linux` output: the same `.om` units compiled by an `omc` built with `target x86linux`, with the x86 frame and preamble selected from the ELF header, so an x86-64 consumer gets a binding it can assemble instead of the migration-pending stand-in of omega-mv [#940](https://github.com/aien-dev/omega-mv/issues/940) (issue still open). The x86 suite result is EMULATED (qemu-x86_64), not native x86 and not a hardware qualification. -- [omega-mcp](https://github.com/aien-dev/omega-mcp) (created 2026-10-27): an MCP stdio server written in `.om` that lets an agent `compile` and `run` Omega with the pinned seeded omc (omega-mv `e5b32567`, omc sha256 `2c824805…`) in a per-call bwrap+prlimit sandbox, and answers `explain_error` and `lookup` from data checked against that pin. At main `6eba894d87b3486957d03bc62e630723545ac6eb` its smoke session, reference oracle and trust gate (a `~/.local/state` read, a fork bomb, an infinite loop and a 10 GiB write, each with a no-isolation negative control) PASS on the Spark host only: no CI yet, and bwrap and prlimit are recorded host dependencies awaiting Omega namespace and rlimit words. It is agent tooling, not a conversion route: conversion stays with omega-bridge. +- [omega-mcp](https://github.com/aien-dev/omega-mcp) (created 2026-10-27): an MCP stdio server written in `.om` that lets an agent `compile` and `run` Omega with the pinned seeded omc in a per-call bwrap+prlimit sandbox, and answers `explain_error` and `lookup` from data checked against that pin. Since [omega-mcp#6](https://github.com/aien-dev/omega-mcp/pull/6) the pin is omega-mv `f4df8239`, omc sha256 `3ad9f10f…3194` (before: `e5b32567`, `2c824805…`); a server started before that build still runs the old omc, so check `compiler_sha256` in a `compile` result. Its smoke session, reference oracle and trust gate (a `~/.local/state` read, a fork bomb, an infinite loop and a 10 GiB write, each with a no-isolation negative control) run in `.github/workflows/gates.yml` on `ubuntu-24.04-arm` and on the Spark host; bwrap and prlimit are recorded host dependencies awaiting Omega namespace and rlimit words. It is agent tooling, not a conversion route: conversion stays with omega-bridge. - [babel](https://github.com/aien-dev/babel) (created 2026-10-26): the code-translation CLI that goes through Omega. `babel <dir> --to rust|c|python|cpp|zig|go` writes `<dir>.babel/` (input copy, Omega units, target project, differential vectors, REPORT.md/report.json). The driver is `.om`; the translation adapters stay in omega-mv (#624 lanes), so change adapters there, not in babel. Only profile S1 (C17 pure `uint64_t` functions, adapters pinned at `universal/624-g1-integration` `2d4c6407`) is implemented. Everything else is refused or MISSING_IMPLEMENTATION per item. TRANSLATED requires the original C, the Omega unit and the target output to agree byte for byte on every vector. Its README matrix and `tests/run.sh` (with a mutated-oracle negative control) own the status; host CI is not hardware qualification. - PENDING (babel#5, draft, not merged): every run computes a completion record (policy `complete-v1`: walked files, split items, skipped entries such as hidden files and symlinks, and required checks) in `report.json` `"completion"` and REPORT.md; `--complete` makes the exit status 0 COMPLETE, 1 FAILED, 3 PARTIAL, 4 BLOCKED. `--exclude FILE` takes a manifest of `<path> <reason>` lines (exact path or `dir/` prefix, no globs); matched non-source entries stay in the denominator as EXCLUDED (COMPLETE = covered + excluded == denominator), and a line with no reason, a stale entry, a glob, or one naming source (including hidden or symlinked `.c`) exits 2. Until #5 merges, babel main has neither `--complete` nor `--exclude`. - [omnet](https://github.com/aien-dev/omnet): Omega security-critical networking, initially server-side Tailnet Lock. It is not part of the alpha bundle. Its [README](https://github.com/aien-dev/omnet/blob/main/README.md) Status section (main `83f605b`, 2026-10-26) records the Omega daemon with all eight TKA RPCs and isolated end-to-end verification of the Headscale adapter and stock-client control-plane lifecycle, and says this is not deployed tailnet protection, data-plane qualification or a production security audit. Live deployment needs its own evidence. diff --git a/skills/omega-encoding/SKILL.md b/skills/omega-encoding/SKILL.md index 5b4b5a7..94dd8fa 100644 --- a/skills/omega-encoding/SKILL.md +++ b/skills/omega-encoding/SKILL.md @@ -85,13 +85,15 @@ byte-identical to the ones `24caacf4` emits; `abc`, `a` and empty input gave `0b with exit 105. The same `fnv1a32.om` prefixed with `target x86linux` printed `0b e9 47 1a` for `abc` with exit 0 under `qemu-x86_64` 8.2.2: EMULATED, not native x86. -The omega MCP tools (`compile`, `run`) use an older pin: omega-mv `e5b32567`, omc `2c824805…029f`. -Their results do not describe main's omc `3ad9f10f…` (omega-mv `f4df8239`); for main, run -`git show main:seed/out/omc` directly. One visible difference: the MCP omc predates #848, so -`while ... bound 1000000` is `error 8` there (1..999999), while `be8c5130…` and `b4f45121…` compile -it (observed 2026-11-04 and 2026-11-05, host only). It also still has the #775 empty-text defect: -`len` of a `text e ""` passed as `view uchar *` returns a stale register value (exit 36 in the -program recorded under "Empty text" below; 0 with `be8c5130…` and `b4f45121…`). +The omega MCP tools (`compile`, `run`, `lookup`) use the guide pin since omega-mcp +[#6](https://github.com/aien-dev/omega-mcp/pull/6): omega-mv `f4df8239`, omc `3ad9f10f…3194`. +Before that they used omega-mv `e5b32567`, omc `2c824805…029f` (history): that omc predated #848, +so `while ... bound 1000000` was `error 8` there (1..999999), and it still had the #775 empty-text +defect (`len` of a `text e ""` passed as `view uchar *` returned a stale register value, exit 36 in +the program recorded under "Empty text" below). Both are gone at the MCP pin. A server process +started before the repin still runs the old binary: check `compiler_sha256` in a `compile` result. +At this pin `execprog` closes every descriptor at or above 3 (omega-mv #970); omega-mcp #6 moved its +bwrap control pipes to fds 0..2 for that reason. ### Previous pin `3a163bc5` (2026-10-31, history) @@ -446,9 +448,10 @@ Two defects recorded at `e5b32567` are fixed in this compiler (the #904 integrat `fn continue_x` compiles and the program exits 7 (`examples/defect_keyword_prefix.om`); `bitcast int` of `uint 4294967295` compares equal to -1 and `add` 2 returns 1, and `bitcast uint` of `int -1` compares equal to 4294967295. At `2c824805` those three programs were error 16, exit 2 and exit 2, -and `add` 2 trapped 1. `fn continue` is still error 16. The #775 empty-text defect is reproduced at -`2c824805` (see the bullet below); keep the `part e 0 0` workaround while that omc is the pin. Other -"observed at e5b32567" lines below are dated history; the example suite still matches them. +and `add` 2 trapped 1. `fn continue` is still error 16. The #775 empty-text defect was reproduced at +`2c824805` (see the bullet below); it is fixed at the guide and MCP pin, so `part e 0 0` is only +needed for an older vendored omc. Other "observed at e5b32567" lines below are dated history; the +example suite still matches them. ### Historical rerun at omega-mv `e5b32567` (2026-10-27) @@ -561,7 +564,8 @@ Changes and confirmations against the rules below, each observed with a program: makes it exit 60; `ret int f part e 0 0` exits 0. With the guide pin all three exit 0 (`be8c5130…` 2026-11-04, `b4f45121…` 2026-11-05; fixed by the - #904 integration `e2662fff`). On the MCP pin pass `part e 0 0` instead + #904 integration `e2662fff`). The MCP pin has carried the fix since omega-mcp #6. On an older + vendored omc (anything built before `e2662fff`) pass `part e 0 0` instead (`examples/empty_text_part.om`). synapse-mcp hit it: every empty-text record arrived with len 28-60 and positional arguments were refused as too long. - **`and`/`or` are eager everywhere, not only in contracts.** `if and gt n 0 eq get a sub n 1 13` @@ -1412,7 +1416,7 @@ AArch64 host with main `seed/out/omc` (`omc < file`): `seed/omc/om2/s4/v-bad-pre `omc: line 5: error 20` (rc 20); `seed/omc/om2/s4/v-pwrite-text.om` compiles (rc 0) and runs with exit 0, writing `ABC\n` to stdout. Host evidence only. -Historical note: up to omc `2c824805…` (omega-mv `e5b32567`, the omega MCP pin) the check sat on +Historical note: up to omc `2c824805…` (omega-mv `e5b32567`, the omega MCP pin before omega-mcp #6) the check sat on the wrong word: `pwrite` from a `text` was error 20 and `pread` into a `text` compiled and returned `-EFAULT` at run time. Code written for that pin copied a text into a `new` array before `pwrite`. @@ -1469,7 +1473,7 @@ exit 7; launching `/nonexistent/x` printed `PURE_LAUNCH_REFUSED` and exited 2 (E descriptor 3 got EPERM (exit 1) under `execpure`, and EBADF (exit 9) under `execprog` with the parent's descriptor 3 open. The omc of `1db941627^` (`0243e4aff`, sha256 `1578b357…`) refuses `execpure` with error 3, and its `execprog` child read the inherited descriptor 3 (exit 50). Older pins, including the -omega MCP pin `2c824805…`, lack both. +omega MCP pin before omega-mcp #6 (`2c824805…`), lack both; the current MCP pin `3ad9f10f…` has both. - Types: `fd`, flags, modes, pids are `int`; offsets, counts, capacities `ulong`; file positions and intervals `long`; buffers are `uchar` arrays. Every result is `long`. diff --git a/skills/writing-omega/SKILL.md b/skills/writing-omega/SKILL.md index 2882286..c0a2356 100644 --- a/skills/writing-omega/SKILL.md +++ b/skills/writing-omega/SKILL.md @@ -194,7 +194,8 @@ A trap ends the process with exit status 100 + N. Output already written stays w - `for i T K` runs i from 0 to K-1. A number K is unguarded. Any other K (a name or value) with no `bound` traps 4 (exit 104) after 1000000 passes, as a `while` with no bound. `for i T K bound N` takes the same N as `while`, caps every count and traps 4 when K exceeds N (`for_bound.om`, - `trap4_for_bound.om`). The MCP pin (e5b32567) has no `for ... bound` (error 5). + `trap4_for_bound.om`). The MCP pin (`f4df8239`, omc `3ad9f10f…`, since omega-mcp #6) accepts + `for ... bound`; the previous MCP pin `e5b32567` (omc `2c824805…`) refused it with error 5. - `break` and `continue` work in both loops. There is no `else if`: nest an `if` inside `else`. - No loop runs forever and recursion is bounded by the stack.