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 / flash / session.om

86 lines · 1226 bytes Raw Blame History
1note Private pipe transport. All frames use little-endian u32. EOF at a frame boundary closes normally.
2global qwire uchar 8
3fn qwireu n ulong to void
4for j ulong 4
5tkpc and shr n mul 8 j 255
6end
7end
8
9fn qrequest to ulong
10seen = ulong 0
11while lt seen 4 bound 4
12r = read 0 qwire seen sub 4 seen
13if lt r 0
14qwfail 60
15end
16if eq r 0
17if ne seen 0
18qwfail 60
19end
20ret 0
21end
22seen = add seen ulong r
23end
24n = ulong 0
25for i ulong 4
26n = or n shl ulong get qwire i mul 8 i
27end
28if or eq n 0 gt n 1048576
29qwfail 60
30end
31r = enlarge input n
32if lt r 0
33qwfail 60
34end
35seen = ulong 0
36while lt seen n bound 1048576
37r = read 0 input seen sub n seen
38if le r 0
39qwfail 60
40end
41seen = add seen ulong r
42end
43ret n
44end
45
46fn qsessiontoken id ulong to void
47qwireu id
48if or eq id 248044 eq id 248046
49qwireu 0
50else
51if ge id len sizes
52qwfail 57
53end
54w = ulong get sizes id
55if eq w 0
56qwfail 57
57end
58qwireu w
59emitword id
60end
61tkpfl
62end
63
64fn qsession cap ulong to void
65qwireu 827216721
66tkpfl
67while true bound 4294967295
68n = qrequest
69if eq n 0
70ret
71end
72put qnids 0 0
73encodeinput n
74count = get qnids 0
75if or eq count 0 gt add count sub cap 1 2048
76qwfail 56
77end
78qdiskrecheck
79qgenerate count cap
80qwireu 4294967295
81qwireu get qrun 3
82qwireu count
83qwireu get qrun 4
84tkpfl
85end
86end