interplane.Get Omega
Read in your language

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

branch main Branches Tags History

aien-sovereign-core-mv / om / qwen-native / tokenizer / check-table-origin.sh

31 lines · 1803 bytes Raw Blame History
1#!/usr/bin/env bash
2set -eu -o pipefail
3cd "$(dirname "$0")"
4omc=${OMC:-../../../../../evaluator/pins/omc}
5registry=${CARGO_REGISTRY_SRC:-$HOME/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f}
6props=$registry/onig_sys-69.9.3/oniguruma/src/unicode_property_data.c
7norm=$registry/unicode-normalization-alignments-0.1.12/src/tables.rs
8check() { printf '%s %s\n' "$1" "$2" | sha256sum -c >&2; }
9check 34d611ca0415eab1728d3234911d90e74af17ba9ab0c581d559f48274d7ca6d3 "$omc"
10build=$(mktemp -d .build.XXXXXXXX)
11trap 'rm -rf "$build"' EXIT
12cp "$props" "$build/property-data"
13cp "$norm" "$build/normalization-data"
14check 6f69e9852bf746acfc3847c9789225d4ba1f085f1852ca00fcab7fa912982f52 "$build/property-data"
15check 83736e2488e7f5e513317e035dfd476611248227efe0a456fddb8a641fe9ade6 "$build/normalization-data"
16tokdir=${OMEGA_TOK_UNITS:-../../../../../teacher/src/native/omegallm/tok}
17check a9475e559d9ddb1468e26aa3e8553d140cddd646b670fcc045c675949db6b04b "$tokdir/tkio.om"
18check 247d175c3ccf746cd82797f165e17cd3d524649519ecc054b4ebc4a0c329438d "$tokdir/tkcli.om"
19# Extract the unchanged stdout and decimal routines, excluding the OLLMTOK1 CLI.
20{
21 head -1 "$tokdir/tkio.om"
22 sed -n '/^global tkso /p; /^global tksn /p; /^fn tkpfl /,/^note size in bytes/{ /^note size in bytes/!p; }' "$tokdir/tkio.om"
23 sed -n '/^global tcdg /p; /^fn tcpu /,/^note a space/{ /^note a space/!p; }' "$tokdir/tkcli.om"
24} > "$build/tokio.om"
25{ echo om2; cat "$build/tokio.om" tables.om; } > "$build/transcribe.om"
26"$omc" < "$build/transcribe.om" > "$build/transcribe"
27chmod +x "$build/transcribe"
28cat "$build/property-data" "$build/normalization-data" | "$build/transcribe" > "$build/unicode-data.om"
29(cd "$build"; sha256sum unicode-data.om) >&2
30cmp "$build/unicode-data.om" unicode-data.om
31cmp "$build/tokio.om" tokio.om