Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them.
Page: /drakestapleton/omega-tool-model/blob/main/deployment/workbench/adversarial.om
# omega-tool-model
First-party Omega tool-use model source, serving harnesses, and verification records
Brought by drakestapleton
Sign in to star 0 stars 0 watching
About Files History Releases Proposed changes Issues For developers
branch `main` Branches Tags History
`omega-tool-model / deployment / workbench / adversarial.om`
3080 lines · 60702 bytes Raw Blame History
1 text z0 "fn calc x int to int\n"
2 text z1 "s = x\nfor i ulong "
3 text z2 "\ns = "
4 text z3 "add"
5 text z4 "plus"
6 text z5 " s int "
7 text z6 "\nend\nret s\nend\n"
8 text z7 "ret "
9 text z8 "mul"
10 text z9 "sub"
11 text z10 "times"
12 text z11 " x int "
13 text z12 "\nend\n"
14 text z13 "fn main to int\nret calc int "
15 text z14 "Could not read the practice file."
16 text z15 "Refused unsupported source."
17 text z16 "Could not prepare the test."
18 text z17 "The compiler did not complete."
19 text z18 "Compilation failed."
20 text z19 "The test did not complete."
21 text z20 "{\"type\":\"test\",\"input\":"
22 text z21 ",\"expected\":"
23 text z22 ",\"actual\":"
24 text z23 "}"
25 text z24 "The browser disconnected."
26 text z25 "Test failed: calc("
27 text z26 ") expected "
28 text z27 ", got "
29 text z28 "."
30 text z29 "Tests passed."
31 text z30 "tool"
32 text z31 "path"
33 text z32 "old"
34 text z33 "new"
35 text z34 "replace_text"
36 text z35 "Task: Fix the error in this file and confirm its goal.\nFile: "
37 text z36 "\nGoal: "
38 text z37 "\nState: "
39 text z38 "unread"
40 text z39 "read"
41 text z40 "failed"
42 text z41 "edited"
43 text z42 "checked"
44 text z43 "missing"
45 text z44 "Source:\n"
46 text z45 "Tool result: "
47 text z46 "Answer:\n"
48 text z47 "read_file"
49 text z48 "File not found."
50 text z49 "Read succeeded."
51 text z50 "observation"
52 text z51 "omega_check"
53 text z52 "Edit saved."
54 text z53 "source"
55 text z54 "original"
56 text z55 "The model could not complete this request."
57 text z56 "action"
58 text z57 "The model completed the job and all four checks passed."
59 text z58 "The model claimed success before verification. No success was recorded."
60 text z59 "The model correctly reported the missing practice file."
61 text z60 "The model incorrectly reported a missing file."
62 text z61 "The model returned an unsupported action. The run stopped."
63 text z62 "The model requested the wrong file. The run stopped."
64 text z63 "The requested action was refused or could not finish."
65 text z64 "The model reached the seven-step limit without finishing."
66 text z65 "This practice area accepts only the small arithmetic program shapes shown in the examples. Keep the same main input."
67 text z66 "jobs/item76666.om"
68 text z67 "calc starts with x and adds 4 exactly 3 times in a for loop. main calls calc with 70."
69 text z68 "jobs/item96171.om"
70 text z69 "calc starts with x and adds 3 exactly 3 times in a for loop. main calls calc with 74."
71 text z70 "jobs/item96294.om"
72 text z71 "calc returns x plus 5. main calls calc with 73."
73 text z72 "jobs/item82028.om"
74 text z73 "calc returns x times 1. main calls calc with 72."
75 text z74 "jobs/item82342.om"
76 text z75 "calc starts with x and adds 1 exactly 6 times in a for loop. main calls calc with 72."
77 text z76 "jobs/item85188.om"
78 text z77 "calc starts with x and adds 2 exactly 4 times in a for loop. main calls calc with 70."
79 text z78 "jobs/item83423.om"
80 text z79 "calc starts with x and adds 5 exactly 3 times in a for loop. main calls calc with 71."
81 text z80 "jobs/item80896.om"
82 text z81 "jobs/item99846.om"
83 text z82 "calc returns x plus 1. main calls calc with 70."
84 text z83 "jobs/item86548.om"
85 text z84 "calc returns x plus 1. main calls calc with 72."
86 text z85 "jobs/item73182.om"
87 text z86 "calc returns x times 1. main calls calc with 71."
88 text z87 "jobs/item87470.om"
89 text z88 "calc returns x times 1. main calls calc with 74."
90 text z89 "jobs/item74558.om"
91 text z90 "calc returns x times 1. main calls calc with 73."
92 text z91 "{\"type\":\""
93 text z92 "\",\"text\":"
94 text z93 "{\"type\":\"done\",\"passed\":"
95 text z94 "true"
96 text z95 "false"
97 text z96 ",\"message\":\""
98 text z97 "\",\"source\":"
99 note Private local protocol. No model-generated bytes are executed.
100 global naddr uchar 110
101 global nbuf uchar 8192
102 global nfd int 1
103 global nerr ulong 1
104 text nsock "$HOME/handoffs/omega-tool-deployment-`20261105`/workbench/mock.sock"
105 text nlock "$HOME/.local/share/omega-tool-model/run/model.lock"
106
107 fn naddress to void
108 put naddr 0 1
109 for i ulong len nsock
110 put naddr add i 2 get nsock i
111 end
112 end
113
114 fn nreceive off ulong n ulong timeout long to bool
115 p = ulong 0
116 deadline = add monons timeout
117 while lt p n bound 8192
118 left = sub deadline monons
119 if le left 0
120 ret false
121 end
122 r = waitio get nfd 0 1 left
123 if le r 0
124 ret false
125 end
126 r = recv get nfd 0 nbuf add off p sub n p 64
127 if eq r neg long 11
128 continue
129 end
130 if le r 0
131 ret false
132 end
133 p = add p ulong r
134 end
135 ret true
136 end
137
138 fn nsend off ulong n ulong to bool
139 p = ulong 0
140 deadline = add monons long `2000000000`
141 while lt p n bound 8192
142 left = sub deadline monons
143 if le left 0
144 ret false
145 end
146 r = waitio get nfd 0 4 left
147 if le r 0
148 ret false
149 end
150 r = send get nfd 0 nbuf add off p sub n p 64
151 if eq r neg long 11
152 continue
153 end
154 if le r 0
155 ret false
156 end
157 p = add p ulong r
158 end
159 ret true
160 end
161
162 fn nlength to ulong
163 ret add ulong get nbuf 0 mul ulong get nbuf 1 256
164 end
165
166 fn nheader n ulong to void
167 put nbuf 0 uchar and n 255
168 put nbuf 1 uchar and shr n 8 255
169 end
170
171 fn nstatus code ulong to void
172 if eq code 0
173 nheader 0
174 r = nsend 0 2
175 else
176 nheader 65535
177 put nbuf 2 uchar code
178 r = nsend 0 3
179 end
180 end
181
182 note Private, bounded HTTP adapter. No generated text is executed or interpreted as HTML.
183 global hreq uchar 12288
184 global hbuf uchar 65536
185 global haddr uchar 16
186 global hopt uchar 4
187 global hstat uchar 4
188 global hfd int 1
189 global hcount ulong 1
190 global hend ulong 1
191 global hsize ulong 1
192 global hseen ulong 1
193 global hguard ulong 1
194 global hhost ulong 1
195 global hroute ulong 1
196 text hex "`0123456789abcdef`"
197
198 fn hsend n ulong to bool
199 p = ulong 0
200 deadline = add monons long `3000000000`
201 while lt p n bound 65536
202 left = sub deadline monons
203 if le left 0
204 ret false
205 end
206 r = waitio get hfd 0 4 left
207 if le r 0
208 ret false
209 end
210 r = send get hfd 0 hbuf p sub n p 64
211 if eq r neg long 11
212 continue
213 end
214 if le r 0
215 ret false
216 end
217 p = add p ulong r
218 end
219 ret true
220 end
221
222 fn hfind start ulong total ulong to bool
223 while lt add start 3 total bound 8192
224 if and eq get hreq start 13 eq get hreq add start 1 10
225 if and eq get hreq add start 2 13 eq get hreq add start 3 10
226 put hend 0 add start 4
227 ret true
228 end
229 end
230 start = add start 1
231 end
232 ret false
233 end
234
235 fn hread to bool
236 put hcount 0 0
237 put hend 0 0
238 deadline = add monons long `5000000000`
239 for step ulong 8192
240 n = get hcount 0
241 if ge n 8192
242 ret false
243 end
244 left = sub deadline monons
245 if le left 0
246 ret false
247 end
248 if le waitio get hfd 0 1 left 0
249 ret false
250 end
251 r = recv get hfd 0 hreq n sub 8192 n 64
252 if eq r neg long 11
253 continue
254 end
255 if le r 0
256 ret false
257 end
258 total = add n ulong r
259 put hcount 0 total
260 start = ulong 0
261 if gt n 3
262 start = sub n 3
263 end
264 if hfind start total
265 ret true
266 end
267 end
268 ret false
269 end
270
271 fn hline a ulong b ulong to bool
272 if eq a b
273 ret true
274 end
275 if iscl a b
276 if ne get hseen 0 0
277 ret false
278 end
279 put hseen 0 1
280 p = add a 15
281 while lt p b bound 8192
282 if not or eq get hreq p 32 eq get hreq p 9
283 break
284 end
285 p = add p 1
286 end
287 if eq p b
288 ret false
289 end
290 v = ulong 0
291 while lt p b bound 8192
292 c = get hreq p
293 if or lt c 48 gt c 57
294 ret false
295 end
296 v = add mul v 10 ulong sub c 48
297 if gt v 4000
298 ret false
299 end
300 p = add p 1
301 end
302 put hsize 0 v
303 ret true
304 end
305 if iste a b
306 ret false
307 end
308 if isguard a b
309 put hguard 0 add get hguard 0 1
310 end
311 if ishost a b
312 if not goodhost a b
313 ret false
314 end
315 put hhost 0 add get hhost 0 1
316 end
317 ret true
318 end
319
320 fn hparse to bool
321 put hsize 0 0
322 put hseen 0 0
323 put hguard 0 0
324 put hhost 0 0
325 put hroute 0 0
326 n = get hend 0
327 a = ulong 0
328 first = true
329 for i ulong sub n 1
330 c = get hreq i
331 if and eq c 13 eq get hreq add i 1 10
332 if first
333 if isroot a i
334 put hroute 0 1
335 end
336 if isgen a i
337 put hroute 0 2
338 end
339 if isrepair a i
340 put hroute 0 3
341 end
342 first = false
343 else
344 if not hline a i
345 ret false
346 end
347 end
348 a = add i 2
349 else
350 if not first
351 if and ge c 65 le c 90
352 put hreq i add c 32
353 end
354 end
355 end
356 end
357 ret eq get hhost 0 1
358 end
359
360 fn hbody to bool
361 n = get hsize 0
362 off = get hend 0
363 total = add off n
364 if or eq n 0 gt n 4000
365 ret false
366 end
367 if gt get hcount 0 total
368 ret false
369 end
370 deadline = add monons long `5000000000`
371 while lt get hcount 0 total bound 4000
372 p = get hcount 0
373 left = sub deadline monons
374 if le left 0
375 ret false
376 end
377 if le waitio get hfd 0 1 left 0
378 ret false
379 end
380 r = recv get hfd 0 hreq p sub total p 64
381 if eq r neg long 11
382 continue
383 end
384 if le r 0
385 ret false
386 end
387 put hcount 0 add p ulong r
388 end
389 nheader n
390 for i ulong n
391 c = get hreq add off i
392 if eq c 0
393 ret false
394 end
395 put nbuf add i 2 c
396 end
397 ret true
398 end
399
400 fn hchunk n ulong to bool
401 for i ulong 4
402 shift = mul sub 3 i 4
403 put hbuf i get hex and shr n shift 15
404 end
405 put hbuf 4 13
406 put hbuf 5 10
407 for i ulong n
408 put hbuf add i 6 get nbuf i
409 end
410 put hbuf add n 6 13
411 put hbuf add n 7 10
412 ret hsend add n 8
413 end
414
415 fn hstream to void
416 started = false
417 for frame ulong 1024
418 if not nreceive 0 2 `30000000000`
419 if not started
420 r = respond502
421 end
422 ret
423 end
424 n = nlength
425 if eq n 65535
426 if not started
427 if nreceive 0 1 `2000000000`
428 if eq get nbuf 0 3
429 r = respond422
430 else
431 r = respond502
432 end
433 else
434 r = respond502
435 end
436 end
437 ret
438 end
439 if gt n 4096
440 if not started
441 r = respond502
442 end
443 ret
444 end
445 if not started
446 if not streamhead
447 ret
448 end
449 started = true
450 end
451 if eq n 0
452 r = streamend
453 ret
454 end
455 if not nreceive 0 n `2000000000`
456 ret
457 end
458 if not hchunk n
459 ret
460 end
461 end
462 end
463
464 fn hmodel to void
465 naddress
466 fd = socknew 1 524289 0
467 if lt fd 0
468 r = respond503
469 ret
470 end
471 if ne connect int fd naddr 0 add len nsock 3 0
472 closed = fclose int fd
473 r = respond503
474 ret
475 end
476 put nfd 0 int fd
477 if nsend 0 add get hsize 0 2
478 hstream
479 else
480 r = respond502
481 end
482 closed = fclose int fd
483 end
484
485 fn hserve to void
486 if not hread
487 r = respond400
488 ret
489 end
490 if not hparse
491 r = respond400
492 ret
493 end
494 route = get hroute 0
495 if eq route 1
496 if ne get hsize 0 0
497 r = respond400
498 ret
499 end
500 r = respondpage
501 ret
502 end
503 if or eq route 2 eq route 3
504 if or ne get hguard 0 1 ne get hseen 0 1
505 r = respond400
506 ret
507 end
508 if not hbody
509 r = respond400
510 ret
511 end
512 if eq route 3
513 wrepair
514 else
515 hmodel
516 end
517 else
518 r = respond404
519 end
520 end
521
522 fn main to int
523 put haddr 0 2
524 put haddr 2 70
525 put haddr 2 71
526 put haddr 3 1
527 put haddr 4 127
528 put haddr 7 1
529 put hopt 0 1
530 fd = socknew 2 524289 0
531 if lt fd 0
532 ret 70
533 end
534 r = sockopt int fd 1 2 hopt 0 4
535 if ne bind int fd haddr 0 16 0
536 ret 71
537 end
538 if ne listen int fd 16 0
539 ret 72
540 end
541 active = ulong 0
542 for request ulong `1000000`
543 for reap ulong 16
544 done = waitpid -1 hstat 0 4 1
545 if le done 0
546 break
547 end
548 if gt active 0
549 active = sub active 1
550 end
551 end
552 if ge active 16
553 r = sleepns `10000000`
554 continue
555 end
556 if le waitio int fd 1 `1000000000` 0
557 continue
558 end
559 client = accept int fd 524288
560 if lt client 0
561 continue
562 end
563 pid = fork
564 if eq pid 0
565 r = fclose int fd
566 put hfd 0 int client
567 r = sockopt int client 6 1 hopt 0 4
568 hserve
569 r = fclose int client
570 ret 0
571 end
572 r = fclose int client
573 if gt pid 0
574 active = add active 1
575 end
576 end
577 ret 0
578 end
579
580 note Model-driven tools for one bounded arithmetic practice file. Paths from the model never become OS paths.
581 global wsrc uchar 1024
582 global wslen ulong 1
583 global wobs uchar 1024
584 global wolen ulong 1
585 global wans uchar 4096
586 global walen ulong 1
587 global wpath uchar 128
588 global wplen ulong 1
589 global wgoal uchar 256
590 global wglen ulong 1
591 global wbuf uchar 8192
592 global wlen ulong 1
593 global wjob ulong 5
594 global wstate ulong 1
595 global wvalid ulong 1
596 global wcall ulong 1
597 global wclen ulong 1
598 global wtmp uchar 1024
599 global wtlen ulong 1
600 global wargv uchar 1024
601 global wstat uchar 4
602 global wdir uchar 256
603 global wdlen ulong 1
604 global wout uchar 4096
605 global wused ulong 1
606 global wfld uchar 512
607 global wflen ulong 4
608 global wpos ulong 1
609 global wtok uchar 128
610 global wtkn ulong 1
611 text wprog "program.om"
612 text wtest "test.om"
613 text wexe "test.bin"
614 text werr "check.err"
615 text wrout "run.out"
616 text wbase "$HOME/.local/share/omega-tool-model/practice/"
617 text wcomp "$HOME/handoffs/omega-tool-deployment-`20261105`/workbench/omc"
618 text wexec "./test.bin"
619
620 fn wb c uchar to void
621 if ge get wlen 0 8192
622 exit 90
623 end
624 put wbuf get wlen 0 c
625 put wlen 0 add get wlen 0 1
626 end
627 fn wn n ulong to void
628 if ge n 10
629 wn div n 10
630 end
631 wb uchar add rem n 10 48
632 end
633 fn wz to void
634 put wlen 0 0
635 end
636 fn wbyte mode ulong i ulong to uchar
637 if eq mode 1
638 ret get wsrc i
639 end
640 if eq mode 2
641 ret get wobs i
642 end
643 if eq mode 3
644 ret get wans i
645 end
646 if eq mode 4
647 ret get wpath i
648 end
649 if eq mode 5
650 ret get wgoal i
651 end
652 ret get wfld add mul sub mode 6 128 i
653 end
654 fn wlength mode ulong to ulong
655 if eq mode 1
656 ret get wslen 0
657 end
658 if eq mode 2
659 ret get wolen 0
660 end
661 if eq mode 3
662 ret get walen 0
663 end
664 if eq mode 4
665 ret get wplen 0
666 end
667 if eq mode 5
668 ret get wglen 0
669 end
670 ret get wflen sub mode 6
671 end
672 fn wa mode ulong to void
673 for i ulong wlength mode
674 wb wbyte mode i
675 end
676 end
677 fn wj mode ulong to void
678 wb 34
679 for i ulong wlength mode
680 c = wbyte mode i
681 if or eq c 34 eq c 92
682 wb 92
683 wb c
684 else
685 if eq c 10
686 wb 92
687 wb 110
688 else
689 if eq c 13
690 wb 92
691 wb 114
692 else
693 if eq c 9
694 wb 92
695 wb 116
696 else
697 if lt c 32
698 wb 63
699 else
700 wb c
701 end
702 end
703 end
704 end
705 end
706 end
707 wb 34
708 end
709 fn wobsbuf to void
710 if gt get wlen 0 1024
711 exit 90
712 end
713 put wolen 0 get wlen 0
714 for i ulong get wlen 0
715 put wobs i get wbuf i
716 end
717 end
718 fn wemit to bool
719 wb 10
720 n = get wlen 0
721 for i ulong n
722 put nbuf i get wbuf i
723 end
724 ret hchunk n
725 end
726 fn wsmall at ulong to ulong
727 if ge at get wslen 0
728 ret 10000
729 end
730 c = get wsrc at
731 if or lt c 49 gt c 54
732 ret 10000
733 end
734 ret add at 1
735 end
736 fn wgrammar to bool
737 put wcall 0 0
738 put wclen 0 0
739 p = wconsumec0 0
740 if wmc1 p
741 p = wconsumec2 p
742 p = wsmall p
743 p = wconsumec3 p
744 if wmc4 p
745 p = add p 3
746 else
747 p = wconsumec5 p
748 end
749 p = wconsumec6 p
750 p = wsmall p
751 p = wconsumec7 p
752 else
753 if eq get wjob 0 2
754 ret false
755 end
756 p = wconsumec8 p
757 if or wmc4 p or wmc9 p wmc10 p
758 p = add p 3
759 else
760 if wmc11 p
761 p = add p 4
762 else
763 p = wconsumec12 p
764 end
765 end
766 p = wconsumec13 p
767 p = wsmall p
768 p = wconsumec14 p
769 end
770 p = wconsumec15 p
771 if ge p get wslen 0
772 ret false
773 end
774 put wcall 0 p
775 v = ulong 0
776 start = p
777 while lt p get wslen 0 bound 1024
778 c = get wsrc p
779 if or lt c 48 gt c 57
780 break
781 end
782 v = add mul v 10 ulong sub c 48
783 if gt v 99
784 ret false
785 end
786 p = add p 1
787 end
788 if or eq p start gt sub p start 2
789 ret false
790 end
791 put wclen 0 sub p start
792 if ne v get wjob 1
793 ret false
794 end
795 p = wconsumec14 p
796 ret eq p get wslen 0
797 end
798
799 fn wsave to bool
800 fd = fopen wprog 0 len wprog 524865 384
801 if lt fd 0
802 ret false
803 end
804 n = write int fd wsrc 0 get wslen 0
805 r = fclose int fd
806 ret and eq n long get wslen 0 eq r 0
807 end
808 fn wload to bool
809 fd = fopen wprog 0 len wprog 524288 0
810 if lt fd 0
811 ret false
812 end
813 n = read int fd wsrc 0 1024
814 r = fclose int fd
815 if or le n 0 gt n 600
816 ret false
817 end
818 put wslen 0 ulong n
819 ret eq r 0
820 end
821 fn wmkdir to bool
822 wz
823 wtc16
824 wn ulong getpid
825 wb 45
826 wn ulong monons
827 n = get wlen 0
828 for i ulong n
829 put wdir i get wbuf i
830 end
831 put wdlen 0 n
832 if ne makedir wdir 0 n 448 0
833 ret false
834 end
835 ret eq chdir wdir 0 n 0
836 end
837 fn wclean to void
838 r = unlink wprog 0 len wprog
839 r = unlink wtest 0 len wtest
840 r = unlink wexe 0 len wexe
841 r = unlink werr 0 len werr
842 r = unlink wrout 0 len wrout
843 r = chdir wbase 0 len wbase
844 r = rmdir wdir 0 get wdlen 0
845 end
846 fn wwait pid int timeout long to long
847 deadline = add monons timeout
848 for poll ulong 10000
849 r = waitpid pid wstat 0 4 1
850 if eq r long pid
851 if ne get wstat 0 0
852 ret -2
853 end
854 ret long get wstat 1
855 end
856 if lt r 0
857 ret -3
858 end
859 if ge monons deadline
860 r = killpid pid 9
861 r = waitpid pid wstat 0 4 0
862 ret -1
863 end
864 r = sleepns `1000000`
865 end
866 r = killpid pid 9
867 r = waitpid pid wstat 0 4 0
868 ret -1
869 end
870 fn wlaunch mode ulong ifd int ofd int efd int to long
871 wz
872 if eq mode 0
873 wtc17
874 else
875 wtc18
876 end
877 n = get wlen 0
878 put wargv 0 1
879 put wargv 1 0
880 put wargv 2 uchar and n 255
881 put wargv 3 uchar shr n 8
882 for i ulong n
883 put wargv add i 4 get wbuf i
884 end
885 pid = fork
886 if lt pid 0
887 ret -3
888 end
889 if eq pid 0
890 if ne dupfd ifd 0 0 0
891 exit 98
892 end
893 if ne dupfd ofd 1 0 1
894 exit 98
895 end
896 if ne dupfd efd 2 0 2
897 exit 98
898 end
899 r = execprog wargv 0 add n 4
900 exit 98
901 end
902 ret wwait int pid `2000000000`
903 end
904 fn wcompile to long
905 inf = fopen wtest 0 len wtest 524288 0
906 outf = fopen wexe 0 len wexe 524865 384
907 errf = fopen werr 0 len werr 524865 384
908 if or lt inf 0 or lt outf 0 lt errf 0
909 r = fclose int inf
910 r = fclose int outf
911 r = fclose int errf
912 ret -3
913 end
914 rc = wlaunch 0 int inf int outf int errf
915 r = fclose int inf
916 r = fclose int outf
917 r = fclose int errf
918 ret rc
919 end
920 fn wrun to long
921 inf = fopen wtest 0 len wtest 524288 0
922 outf = fopen wrout 0 len wrout 524865 384
923 errf = fopen werr 0 len werr 524865 384
924 if or lt inf 0 or lt outf 0 lt errf 0
925 r = fclose int inf
926 r = fclose int outf
927 r = fclose int errf
928 ret -3
929 end
930 if ne chmod wexe 0 len wexe 448 0
931 r = fclose int inf
932 r = fclose int outf
933 r = fclose int errf
934 ret -3
935 end
936 rc = wlaunch 1 int inf int outf int errf
937 r = fclose int inf
938 r = fclose int outf
939 r = fclose int errf
940 ret rc
941 end
942 fn wtestsrc x ulong to bool
943 wz
944 for i ulong get wcall 0
945 wb get wsrc i
946 end
947 wn x
948 p = add get wcall 0 get wclen 0
949 while lt p get wslen 0 bound 1024
950 wb get wsrc p
951 p = add p 1
952 end
953 fd = fopen wtest 0 len wtest 524865 384
954 if lt fd 0
955 ret false
956 end
957 n = write int fd wbuf 0 get wlen 0
958 r = fclose int fd
959 ret and eq n long get wlen 0 eq r 0
960 end
961 fn wexpected x ulong to ulong
962 if eq get wjob 0 0
963 ret add x get wjob 2
964 end
965 if eq get wjob 0 1
966 ret mul x get wjob 2
967 end
968 ret add x mul get wjob 2 get wjob 3
969 end
970 fn wcheck to bool
971 if not wload
972 woc19
973 ret false
974 end
975 if not wgrammar
976 woc20
977 ret false
978 end
979 for test ulong 4
980 x = get wjob 1
981 if eq test 1
982 x = 0
983 end
984 if eq test 2
985 x = 3
986 end
987 if eq test 3
988 x = 7
989 end
990 if not wtestsrc x
991 woc21
992 ret false
993 end
994 rc = wcompile
995 if ne rc 0
996 if lt rc 0
997 woc22
998 ret false
999 end
1000 fd = fopen werr 0 len werr 524288 0
1001 n = read int fd wobs 0 1024
1002 r = fclose int fd
1003 if le n 0
1004 woc23
1005 else
1006 put wolen 0 ulong n
1007 while gt get wolen 0 0 bound 1024
1008 p = sub get wolen 0 1
1009 if ne get wobs p 10
1010 break
1011 end
1012 put wolen 0 p
1013 end
1014 end
1015 ret false
1016 end
1017 actual = wrun
1018 if lt actual 0
1019 woc24
1020 ret false
1021 end
1022 want = wexpected x
1023 wz
1024 wtc25
1025 wn x
1026 wtc26
1027 wn want
1028 wtc27
1029 wn ulong actual
1030 wtc28
1031 if not wemit
1032 woc29
1033 ret false
1034 end
1035 if ne ulong actual want
1036 wz
1037 wtc30
1038 wn x
1039 wtc31
1040 wn want
1041 wtc32
1042 wn ulong actual
1043 wtc33
1044 wobsbuf
1045 ret false
1046 end
1047 end
1048 woc34
1049 ret true
1050 end
1051
1052 note Strict JSON object with exactly tool/path, or tool/path/old/new, all bounded strings.
1053 fn wspace to void
1054 while lt get wpos 0 get walen 0 bound 4096
1055 c = get wans get wpos 0
1056 if not or or eq c 32 eq c 10 or eq c 13 eq c 9
1057 ret
1058 end
1059 put wpos 0 add get wpos 0 1
1060 end
1061 end
1062 fn wpunc c uchar to bool
1063 wspace
1064 p = get wpos 0
1065 if ge p get walen 0
1066 ret false
1067 end
1068 if ne get wans p c
1069 ret false
1070 end
1071 put wpos 0 add p 1
1072 ret true
1073 end
1074 fn wstring to bool
1075 put wtkn 0 0
1076 if not wpunc 34
1077 ret false
1078 end
1079 while lt get wpos 0 get walen 0 bound 4096
1080 p = get wpos 0
1081 c = get wans p
1082 put wpos 0 add p 1
1083 if eq c 34
1084 ret true
1085 end
1086 if lt c 32
1087 ret false
1088 end
1089 if eq c 92
1090 p = get wpos 0
1091 if ge p get walen 0
1092 ret false
1093 end
1094 c = get wans p
1095 put wpos 0 add p 1
1096 if eq c 110
1097 c = 10
1098 else
1099 if eq c 114
1100 c = 13
1101 else
1102 if eq c 116
1103 c = 9
1104 else
1105 if not or eq c 34 or eq c 92 eq c 47
1106 ret false
1107 end
1108 end
1109 end
1110 end
1111 end
1112 if ge get wtkn 0 127
1113 ret false
1114 end
1115 put wtok get wtkn 0 c
1116 put wtkn 0 add get wtkn 0 1
1117 end
1118 ret false
1119 end
1120 fn wjson to bool
1121 put wpos 0 0
1122 for i ulong 4
1123 put wflen i 0
1124 end
1125 if not wpunc 123
1126 ret false
1127 end
1128 mask = ulong 0
1129 for field ulong 4
1130 if not wstring
1131 ret false
1132 end
1133 slot = ulong 4
1134 if wtokenc35
1135 slot = 0
1136 end
1137 if wtokenc36
1138 slot = 1
1139 end
1140 if wtokenc37
1141 slot = 2
1142 end
1143 if wtokenc38
1144 slot = 3
1145 end
1146 if eq slot 4
1147 ret false
1148 end
1149 bit = shl ulong 1 slot
1150 if ne and mask bit 0
1151 ret false
1152 end
1153 mask = or mask bit
1154 if not wpunc 58
1155 ret false
1156 end
1157 if not wstring
1158 ret false
1159 end
1160 put wflen slot get wtkn 0
1161 for i ulong get wtkn 0
1162 put wfld add mul slot 128 i get wtok i
1163 end
1164 wspace
1165 p = get wpos 0
1166 if ge p get walen 0
1167 ret false
1168 end
1169 if eq get wans p 125
1170 put wpos 0 add p 1
1171 wspace
1172 if ne get wpos 0 get walen 0
1173 ret false
1174 end
1175 if wfieldc39 0
1176 ret eq mask 15
1177 end
1178 ret eq mask 3
1179 end
1180 if not wpunc 44
1181 ret false
1182 end
1183 end
1184 ret false
1185 end
1186 fn wmatchold at ulong to bool
1187 n = get wflen 2
1188 if gt add at n get wslen 0
1189 ret false
1190 end
1191 for i ulong n
1192 if ne get wsrc add at i get wfld add 256 i
1193 ret false
1194 end
1195 end
1196 ret true
1197 end
1198 fn wpatch to bool
1199 oldn = get wflen 2
1200 newn = get wflen 3
1201 if or eq oldn 0 or gt oldn 40 gt newn 40
1202 ret false
1203 end
1204 count = ulong 0
1205 found = ulong 0
1206 for i ulong get wslen 0
1207 if wmatchold i
1208 count = add count 1
1209 found = i
1210 end
1211 end
1212 if ne count 1
1213 ret false
1214 end
1215 newsize = add sub get wslen 0 oldn newn
1216 if gt newsize 600
1217 ret false
1218 end
1219 put wtlen 0 get wslen 0
1220 for i ulong get wslen 0
1221 put wtmp i get wsrc i
1222 end
1223 p = found
1224 for i ulong newn
1225 put wsrc p get wfld add 384 i
1226 p = add p 1
1227 end
1228 tail = add found oldn
1229 while lt tail get wtlen 0 bound 1024
1230 put wsrc p get wtmp tail
1231 p = add p 1
1232 tail = add tail 1
1233 end
1234 put wslen 0 newsize
1235 if not wgrammar
1236 put wslen 0 get wtlen 0
1237 for i ulong get wtlen 0
1238 put wsrc i get wtmp i
1239 end
1240 ret false
1241 end
1242 ret wsave
1243 end
1244
1245 fn wprompt to void
1246 wz
1247 wtc40
1248 wa 4
1249 wtc41
1250 wa 5
1251 wtc42
1252 s = get wstate 0
1253 if eq s 0
1254 wtc43
1255 end
1256 if eq s 1
1257 wtc44
1258 end
1259 if eq s 2
1260 wtc45
1261 end
1262 if eq s 3
1263 wtc46
1264 end
1265 if eq s 4
1266 wtc47
1267 end
1268 if eq s 5
1269 wtc48
1270 end
1271 wb 10
1272 if and ne s 0 ne s 5
1273 wtc49
1274 wa 1
1275 end
1276 if ne s 0
1277 wtc50
1278 wa 2
1279 wb 10
1280 end
1281 wtc51
1282 end
1283 fn wresponse to bool
1284 put walen 0 0
1285 for frame ulong 1024
1286 if not nreceive 0 2 `30000000000`
1287 ret false
1288 end
1289 n = nlength
1290 if eq n 0
1291 ret true
1292 end
1293 if or eq n 65535 gt n 4096
1294 ret false
1295 end
1296 if gt add get walen 0 n 4096
1297 ret false
1298 end
1299 if not nreceive 0 n `2000000000`
1300 ret false
1301 end
1302 for i ulong n
1303 put wans add get walen 0 i get nbuf i
1304 end
1305 put walen 0 add get walen 0 n
1306 end
1307 ret false
1308 end
1309 fn wask to bool
1310 wprompt
1311 n = get wlen 0
1312 if gt n 4000
1313 ret false
1314 end
1315 nheader n
1316 for i ulong n
1317 put nbuf add i 2 get wbuf i
1318 end
1319 naddress
1320 fd = socknew 1 524289 0
1321 if lt fd 0
1322 ret false
1323 end
1324 if ne connect int fd naddr 0 add len nsock 3 0
1325 r = fclose int fd
1326 ret false
1327 end
1328 put nfd 0 int fd
1329 ok = false
1330 if nsend 0 add n 2
1331 ok = wresponse
1332 end
1333 r = fclose int fd
1334 ret ok
1335 end
1336 fn wrightpath to bool
1337 if ne get wflen 1 get wplen 0
1338 ret false
1339 end
1340 for i ulong get wplen 0
1341 if ne get wfld add 128 i get wpath i
1342 ret false
1343 end
1344 end
1345 ret true
1346 end
1347 fn waction to bool
1348 s = get wstate 0
1349 if and wfieldc52 0 eq s 0
1350 if eq get wjob 4 1
1351 put wslen 0 0
1352 put wstate 0 5
1353 woc53
1354 else
1355 if not wload
1356 ret false
1357 end
1358 put wstate 0 1
1359 woc54
1360 end
1361 ret weventc55 2
1362 end
1363 if and wfieldc56 0 or eq s 1 eq s 3
1364 put wvalid 0 0
1365 if wcheck
1366 put wstate 0 4
1367 put wvalid 0 1
1368 else
1369 put wstate 0 2
1370 end
1371 ret weventc55 2
1372 end
1373 if and wfieldc39 0 eq s 2
1374 if not wpatch
1375 ret false
1376 end
1377 put wstate 0 3
1378 put wvalid 0 0
1379 woc57
1380 if not weventc58 1
1381 ret false
1382 end
1383 ret weventc55 2
1384 end
1385 ret false
1386 end
1387 fn wloop to void
1388 put wstate 0 0
1389 put wvalid 0 0
1390 if not weventc59 1
1391 ret
1392 end
1393 for turn ulong 7
1394 if not wask
1395 wfinishc60 false
1396 ret
1397 end
1398 if not weventc61 3
1399 ret
1400 end
1401 if wanswerc62
1402 if and eq get wstate 0 4 eq get wvalid 0 1
1403 wfinishc63 true
1404 else
1405 wfinishc64 false
1406 end
1407 ret
1408 end
1409 if wanswerc65
1410 if eq get wstate 0 5
1411 wfinishc66 false
1412 else
1413 wfinishc67 false
1414 end
1415 ret
1416 end
1417 if not wjson
1418 wfinishc68 false
1419 ret
1420 end
1421 if not wrightpath
1422 wfinishc69 false
1423 ret
1424 end
1425 if not waction
1426 wfinishc70 false
1427 ret
1428 end
1429 end
1430 wfinishc71 false
1431 end
1432 fn wrepair to void
1433 n = get hsize 0
1434 off = get hend 0
1435 if lt n 2
1436 r = respond400
1437 ret
1438 end
1439 id = get hreq off
1440 if or lt id 65 gt id 77
1441 r = respond400
1442 ret
1443 end
1444 if ne get hreq add off 1 10
1445 r = respond400
1446 ret
1447 end
1448 wjobload ulong sub id 65
1449 if gt sub n 2 600
1450 r = respond400
1451 ret
1452 end
1453 put wslen 0 sub n 2
1454 for i ulong get wslen 0
1455 put wsrc i get hreq add add off 2 i
1456 end
1457 if eq get wjob 4 1
1458 put wslen 0 0
1459 else
1460 if not wgrammar
1461 if streamhead
1462 wfinishc72 false
1463 end
1464 ret
1465 end
1466 end
1467 if not wmkdir
1468 r = respond503
1469 ret
1470 end
1471 if ne get wjob 4 1
1472 if not wsave
1473 wclean
1474 r = respond503
1475 ret
1476 end
1477 end
1478 if streamhead
1479 wloop
1480 end
1481 wclean
1482 end
1483
1484 fn wjobload id ulong to void
1485 if eq id 0
1486 put wjob 0 2
1487 put wjob 1 70
1488 put wjob 2 4
1489 put wjob 3 3
1490 put wjob 4 0
1491 wz
1492 wtc73
1493 put wplen 0 get wlen 0
1494 for i ulong get wlen 0
1495 put wpath i get wbuf i
1496 end
1497 wz
1498 wtc74
1499 put wglen 0 get wlen 0
1500 for i ulong get wlen 0
1501 put wgoal i get wbuf i
1502 end
1503 ret
1504 end
1505 if eq id 1
1506 put wjob 0 2
1507 put wjob 1 74
1508 put wjob 2 3
1509 put wjob 3 3
1510 put wjob 4 0
1511 wz
1512 wtc75
1513 put wplen 0 get wlen 0
1514 for i ulong get wlen 0
1515 put wpath i get wbuf i
1516 end
1517 wz
1518 wtc76
1519 put wglen 0 get wlen 0
1520 for i ulong get wlen 0
1521 put wgoal i get wbuf i
1522 end
1523 ret
1524 end
1525 if eq id 2
1526 put wjob 0 0
1527 put wjob 1 73
1528 put wjob 2 5
1529 put wjob 3 0
1530 put wjob 4 0
1531 wz
1532 wtc77
1533 put wplen 0 get wlen 0
1534 for i ulong get wlen 0
1535 put wpath i get wbuf i
1536 end
1537 wz
1538 wtc78
1539 put wglen 0 get wlen 0
1540 for i ulong get wlen 0
1541 put wgoal i get wbuf i
1542 end
1543 ret
1544 end
1545 if eq id 3
1546 put wjob 0 1
1547 put wjob 1 72
1548 put wjob 2 1
1549 put wjob 3 0
1550 put wjob 4 0
1551 wz
1552 wtc79
1553 put wplen 0 get wlen 0
1554 for i ulong get wlen 0
1555 put wpath i get wbuf i
1556 end
1557 wz
1558 wtc80
1559 put wglen 0 get wlen 0
1560 for i ulong get wlen 0
1561 put wgoal i get wbuf i
1562 end
1563 ret
1564 end
1565 if eq id 4
1566 put wjob 0 2
1567 put wjob 1 72
1568 put wjob 2 1
1569 put wjob 3 6
1570 put wjob 4 0
1571 wz
1572 wtc81
1573 put wplen 0 get wlen 0
1574 for i ulong get wlen 0
1575 put wpath i get wbuf i
1576 end
1577 wz
1578 wtc82
1579 put wglen 0 get wlen 0
1580 for i ulong get wlen 0
1581 put wgoal i get wbuf i
1582 end
1583 ret
1584 end
1585 if eq id 5
1586 put wjob 0 2
1587 put wjob 1 70
1588 put wjob 2 2
1589 put wjob 3 4
1590 put wjob 4 0
1591 wz
1592 wtc83
1593 put wplen 0 get wlen 0
1594 for i ulong get wlen 0
1595 put wpath i get wbuf i
1596 end
1597 wz
1598 wtc84
1599 put wglen 0 get wlen 0
1600 for i ulong get wlen 0
1601 put wgoal i get wbuf i
1602 end
1603 ret
1604 end
1605 if eq id 6
1606 put wjob 0 2
1607 put wjob 1 71
1608 put wjob 2 5
1609 put wjob 3 3
1610 put wjob 4 1
1611 wz
1612 wtc85
1613 put wplen 0 get wlen 0
1614 for i ulong get wlen 0
1615 put wpath i get wbuf i
1616 end
1617 wz
1618 wtc86
1619 put wglen 0 get wlen 0
1620 for i ulong get wlen 0
1621 put wgoal i get wbuf i
1622 end
1623 ret
1624 end
1625 if eq id 7
1626 put wjob 0 0
1627 put wjob 1 73
1628 put wjob 2 5
1629 put wjob 3 0
1630 put wjob 4 0
1631 wz
1632 wtc87
1633 put wplen 0 get wlen 0
1634 for i ulong get wlen 0
1635 put wpath i get wbuf i
1636 end
1637 wz
1638 wtc78
1639 put wglen 0 get wlen 0
1640 for i ulong get wlen 0
1641 put wgoal i get wbuf i
1642 end
1643 ret
1644 end
1645 if eq id 8
1646 put wjob 0 0
1647 put wjob 1 70
1648 put wjob 2 1
1649 put wjob 3 0
1650 put wjob 4 0
1651 wz
1652 wtc88
1653 put wplen 0 get wlen 0
1654 for i ulong get wlen 0
1655 put wpath i get wbuf i
1656 end
1657 wz
1658 wtc89
1659 put wglen 0 get wlen 0
1660 for i ulong get wlen 0
1661 put wgoal i get wbuf i
1662 end
1663 ret
1664 end
1665 if eq id 9
1666 put wjob 0 0
1667 put wjob 1 72
1668 put wjob 2 1
1669 put wjob 3 0
1670 put wjob 4 1
1671 wz
1672 wtc90
1673 put wplen 0 get wlen 0
1674 for i ulong get wlen 0
1675 put wpath i get wbuf i
1676 end
1677 wz
1678 wtc91
1679 put wglen 0 get wlen 0
1680 for i ulong get wlen 0
1681 put wgoal i get wbuf i
1682 end
1683 ret
1684 end
1685 if eq id 10
1686 put wjob 0 1
1687 put wjob 1 71
1688 put wjob 2 1
1689 put wjob 3 0
1690 put wjob 4 0
1691 wz
1692 wtc92
1693 put wplen 0 get wlen 0
1694 for i ulong get wlen 0
1695 put wpath i get wbuf i
1696 end
1697 wz
1698 wtc93
1699 put wglen 0 get wlen 0
1700 for i ulong get wlen 0
1701 put wgoal i get wbuf i
1702 end
1703 ret
1704 end
1705 if eq id 11
1706 put wjob 0 1
1707 put wjob 1 74
1708 put wjob 2 1
1709 put wjob 3 0
1710 put wjob 4 0
1711 wz
1712 wtc94
1713 put wplen 0 get wlen 0
1714 for i ulong get wlen 0
1715 put wpath i get wbuf i
1716 end
1717 wz
1718 wtc95
1719 put wglen 0 get wlen 0
1720 for i ulong get wlen 0
1721 put wgoal i get wbuf i
1722 end
1723 ret
1724 end
1725 if eq id 12
1726 put wjob 0 1
1727 put wjob 1 73
1728 put wjob 2 1
1729 put wjob 3 0
1730 put wjob 4 1
1731 wz
1732 wtc96
1733 put wplen 0 get wlen 0
1734 for i ulong get wlen 0
1735 put wpath i get wbuf i
1736 end
1737 wz
1738 wtc97
1739 put wglen 0 get wlen 0
1740 for i ulong get wlen 0
1741 put wgoal i get wbuf i
1742 end
1743 ret
1744 end
1745 end
1746 text t0 "HTTP/1.1 200 OK\nConnection: close\nCache-Control: no-store\nX-Content-Type-Options: nosniff\nReferrer-Policy: no-referrer\nContent-Security-Policy: default-src 'none'; script-src 'sha256-bWTGATZgaaJeoGYh6ERYnQR4IwNh+uZuPc4WbOr70QM='; style-src 'unsafe-inline'; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'\nContent-Type: text/html; charset=utf-8\nContent-Length: 15473\n\n"
1747 text page "\n
Omega · Your model\n\nOMEGARound 40 · Fast model\n
Give your model a coding job.
\n
Watch your model read a practice file, repair it, and check the result. Start with an example, then try changing its code.
\n
Practice with tools
Real compiler checks
\n
Choose a job. The model will work on a temporary copy and show each step.
\n\n\n
You can change the numbers or try an arithmetic spelling mistake. Keep the same program shape and starting input. Larger programs are not supported here yet.
\n\n
Choose a job and press Run.
\n\n
Current code
\n\n
Ask for a single response
\n\n
Model response
Its response will appear here.
\n\n\n"
1748 fn respondpage to bool
1749 p = ulong 0
1750 for i ulong len t0
1751 c = get t0 i
1752 if eq c 10
1753 put hbuf p 13
1754 p = add p 1
1755 end
1756 put hbuf p c
1757 p = add p 1
1758 end
1759 for i ulong len page
1760 put hbuf p get page i
1761 p = add p 1
1762 end
1763 ret hsend p
1764 end
1765 text t1 "HTTP/1.1 400 Bad Request\nConnection: close\nCache-Control: no-store\nX-Content-Type-Options: nosniff\nReferrer-Policy: no-referrer\nContent-Security-Policy: default-src 'none'; script-src 'sha256-bWTGATZgaaJeoGYh6ERYnQR4IwNh+uZuPc4WbOr70QM='; style-src 'unsafe-inline'; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'\nContent-Type: text/plain; charset=utf-8\nContent-Length: 55\n\nPlease send a short, nonempty request using this page.\n"
1766 fn respond400 to bool
1767 p = ulong 0
1768 for i ulong len t1
1769 c = get t1 i
1770 if eq c 10
1771 put hbuf p 13
1772 p = add p 1
1773 end
1774 put hbuf p c
1775 p = add p 1
1776 end
1777 put hbuf sub p 2 10
1778 p = sub p 1
1779 ret hsend p
1780 end
1781 text t2 "HTTP/1.1 404 Not Found\nConnection: close\nCache-Control: no-store\nX-Content-Type-Options: nosniff\nReferrer-Policy: no-referrer\nContent-Security-Policy: default-src 'none'; script-src 'sha256-bWTGATZgaaJeoGYh6ERYnQR4IwNh+uZuPc4WbOr70QM='; style-src 'unsafe-inline'; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'\nContent-Type: text/plain; charset=utf-8\nContent-Length: 16\n\nPage not found.\n"
1782 fn respond404 to bool
1783 p = ulong 0
1784 for i ulong len t2
1785 c = get t2 i
1786 if eq c 10
1787 put hbuf p 13
1788 p = add p 1
1789 end
1790 put hbuf p c
1791 p = add p 1
1792 end
1793 put hbuf sub p 2 10
1794 p = sub p 1
1795 ret hsend p
1796 end
1797 text t3 "HTTP/1.1 422 Unprocessable Content\nConnection: close\nCache-Control: no-store\nX-Content-Type-Options: nosniff\nReferrer-Policy: no-referrer\nContent-Security-Policy: default-src 'none'; script-src 'sha256-bWTGATZgaaJeoGYh6ERYnQR4IwNh+uZuPc4WbOr70QM='; style-src 'unsafe-inline'; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'\nContent-Type: text/plain; charset=utf-8\nContent-Length: 73\n\nThis request is too long for the model. Please shorten it and try again.\n"
1798 fn respond422 to bool
1799 p = ulong 0
1800 for i ulong len t3
1801 c = get t3 i
1802 if eq c 10
1803 put hbuf p 13
1804 p = add p 1
1805 end
1806 put hbuf p c
1807 p = add p 1
1808 end
1809 put hbuf sub p 2 10
1810 p = sub p 1
1811 ret hsend p
1812 end
1813 text t4 "HTTP/1.1 502 Bad Gateway\nConnection: close\nCache-Control: no-store\nX-Content-Type-Options: nosniff\nReferrer-Policy: no-referrer\nContent-Security-Policy: default-src 'none'; script-src 'sha256-bWTGATZgaaJeoGYh6ERYnQR4IwNh+uZuPc4WbOr70QM='; style-src 'unsafe-inline'; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'\nContent-Type: text/plain; charset=utf-8\nContent-Length: 54\n\nThe model response was interrupted. Please try again.\n"
1814 fn respond502 to bool
1815 p = ulong 0
1816 for i ulong len t4
1817 c = get t4 i
1818 if eq c 10
1819 put hbuf p 13
1820 p = add p 1
1821 end
1822 put hbuf p c
1823 p = add p 1
1824 end
1825 put hbuf sub p 2 10
1826 p = sub p 1
1827 ret hsend p
1828 end
1829 text t5 "HTTP/1.1 503 Service Unavailable\nConnection: close\nCache-Control: no-store\nX-Content-Type-Options: nosniff\nReferrer-Policy: no-referrer\nContent-Security-Policy: default-src 'none'; script-src 'sha256-bWTGATZgaaJeoGYh6ERYnQR4IwNh+uZuPc4WbOr70QM='; style-src 'unsafe-inline'; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'\nContent-Type: text/plain; charset=utf-8\nContent-Length: 60\n\nThe model service is unavailable. Please try again shortly.\n"
1830 fn respond503 to bool
1831 p = ulong 0
1832 for i ulong len t5
1833 c = get t5 i
1834 if eq c 10
1835 put hbuf p 13
1836 p = add p 1
1837 end
1838 put hbuf p c
1839 p = add p 1
1840 end
1841 put hbuf sub p 2 10
1842 p = sub p 1
1843 ret hsend p
1844 end
1845 text t6 "HTTP/1.1 200 OK\nConnection: close\nCache-Control: no-store\nX-Content-Type-Options: nosniff\nReferrer-Policy: no-referrer\nContent-Security-Policy: default-src 'none'; script-src 'sha256-bWTGATZgaaJeoGYh6ERYnQR4IwNh+uZuPc4WbOr70QM='; style-src 'unsafe-inline'; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'\nContent-Type: text/plain; charset=utf-8\nTransfer-Encoding: chunked\nX-Accel-Buffering: no\n\n"
1846 fn streamhead to bool
1847 p = ulong 0
1848 for i ulong len t6
1849 c = get t6 i
1850 if eq c 10
1851 put hbuf p 13
1852 p = add p 1
1853 end
1854 put hbuf p c
1855 p = add p 1
1856 end
1857 ret hsend p
1858 end
1859 text t7 "0\n\n"
1860 fn streamend to bool
1861 p = ulong 0
1862 for i ulong len t7
1863 c = get t7 i
1864 if eq c 10
1865 put hbuf p 13
1866 p = add p 1
1867 end
1868 put hbuf p c
1869 p = add p 1
1870 end
1871 ret hsend p
1872 end
1873 text m0 "GET / HTTP/1.1"
1874 fn isroot a ulong b ulong to bool
1875 if ne sub b a len m0
1876 ret false
1877 end
1878 for i ulong len m0
1879 if ne get hreq add a i get m0 i
1880 ret false
1881 end
1882 end
1883 ret true
1884 end
1885 text m1 "POST /generate HTTP/1.1"
1886 fn isgen a ulong b ulong to bool
1887 if ne sub b a len m1
1888 ret false
1889 end
1890 for i ulong len m1
1891 if ne get hreq add a i get m1 i
1892 ret false
1893 end
1894 end
1895 ret true
1896 end
1897 text m2 "POST /repair HTTP/1.1"
1898 fn isrepair a ulong b ulong to bool
1899 if ne sub b a len m2
1900 ret false
1901 end
1902 for i ulong len m2
1903 if ne get hreq add a i get m2 i
1904 ret false
1905 end
1906 end
1907 ret true
1908 end
1909 text m3 "content-length:"
1910 fn iscl a ulong b ulong to bool
1911 if lt sub b a len m3
1912 ret false
1913 end
1914 for i ulong len m3
1915 if ne get hreq add a i get m3 i
1916 ret false
1917 end
1918 end
1919 ret true
1920 end
1921 text m4 "transfer-encoding:"
1922 fn iste a ulong b ulong to bool
1923 if lt sub b a len m4
1924 ret false
1925 end
1926 for i ulong len m4
1927 if ne get hreq add a i get m4 i
1928 ret false
1929 end
1930 end
1931 ret true
1932 end
1933 text m5 "x-omega-ui: 1"
1934 fn isguard a ulong b ulong to bool
1935 if ne sub b a len m5
1936 ret false
1937 end
1938 for i ulong len m5
1939 if ne get hreq add a i get m5 i
1940 ret false
1941 end
1942 end
1943 ret true
1944 end
1945 text m6 "host:"
1946 fn ishost a ulong b ulong to bool
1947 if lt sub b a len m6
1948 ret false
1949 end
1950 for i ulong len m6
1951 if ne get hreq add a i get m6 i
1952 ret false
1953 end
1954 end
1955 ret true
1956 end
1957 text m7 "host: 127.0.0.1:18177"
1958 fn host0 a ulong b ulong to bool
1959 if ne sub b a len m7
1960 ret false
1961 end
1962 for i ulong len m7
1963 if ne get hreq add a i get m7 i
1964 ret false
1965 end
1966 end
1967 ret true
1968 end
1969 text m8 "host: localhost:18177"
1970 fn host1 a ulong b ulong to bool
1971 if ne sub b a len m8
1972 ret false
1973 end
1974 for i ulong len m8
1975 if ne get hreq add a i get m8 i
1976 ret false
1977 end
1978 end
1979 ret true
1980 end
1981 text m9 "host: 127.0.0.1:18174"
1982 fn host2 a ulong b ulong to bool
1983 if ne sub b a len m9
1984 ret false
1985 end
1986 for i ulong len m9
1987 if ne get hreq add a i get m9 i
1988 ret false
1989 end
1990 end
1991 ret true
1992 end
1993 text m10 "host: localhost:18174"
1994 fn host3 a ulong b ulong to bool
1995 if ne sub b a len m10
1996 ret false
1997 end
1998 for i ulong len m10
1999 if ne get hreq add a i get m10 i
2000 ret false
2001 end
2002 end
2003 ret true
2004 end
2005 fn goodhost a ulong b ulong to bool
2006 ret or or host0 a b host1 a b or host2 a b host3 a b
2007 end
2008 fn wconsumec0 at ulong to ulong
2009 if not wmc98 at
2010 ret 10000
2011 end
2012 ret add at len z0
2013 end
2014
2015 fn wmc1 at ulong to bool
2016 if gt add at len z1 get wslen 0
2017 ret false
2018 end
2019 for i ulong len z1
2020 if ne get wsrc add at i get z1 i
2021 ret false
2022 end
2023 end
2024 ret true
2025 end
2026
2027 fn wconsumec2 at ulong to ulong
2028 if not wmc1 at
2029 ret 10000
2030 end
2031 ret add at len z1
2032 end
2033
2034 fn wconsumec3 at ulong to ulong
2035 if not wmc99 at
2036 ret 10000
2037 end
2038 ret add at len z2
2039 end
2040
2041 fn wmc4 at ulong to bool
2042 if gt add at len z3 get wslen 0
2043 ret false
2044 end
2045 for i ulong len z3
2046 if ne get wsrc add at i get z3 i
2047 ret false
2048 end
2049 end
2050 ret true
2051 end
2052
2053 fn wconsumec5 at ulong to ulong
2054 if not wmc11 at
2055 ret 10000
2056 end
2057 ret add at len z4
2058 end
2059
2060 fn wconsumec6 at ulong to ulong
2061 if not wmc100 at
2062 ret 10000
2063 end
2064 ret add at len z5
2065 end
2066
2067 fn wconsumec7 at ulong to ulong
2068 if not wmc101 at
2069 ret 10000
2070 end
2071 ret add at len z6
2072 end
2073
2074 fn wconsumec8 at ulong to ulong
2075 if not wmc102 at
2076 ret 10000
2077 end
2078 ret add at len z7
2079 end
2080
2081 fn wmc9 at ulong to bool
2082 if gt add at len z8 get wslen 0
2083 ret false
2084 end
2085 for i ulong len z8
2086 if ne get wsrc add at i get z8 i
2087 ret false
2088 end
2089 end
2090 ret true
2091 end
2092
2093 fn wmc10 at ulong to bool
2094 if gt add at len z9 get wslen 0
2095 ret false
2096 end
2097 for i ulong len z9
2098 if ne get wsrc add at i get z9 i
2099 ret false
2100 end
2101 end
2102 ret true
2103 end
2104
2105 fn wmc11 at ulong to bool
2106 if gt add at len z4 get wslen 0
2107 ret false
2108 end
2109 for i ulong len z4
2110 if ne get wsrc add at i get z4 i
2111 ret false
2112 end
2113 end
2114 ret true
2115 end
2116
2117 fn wconsumec12 at ulong to ulong
2118 if not wmc103 at
2119 ret 10000
2120 end
2121 ret add at len z10
2122 end
2123
2124 fn wconsumec13 at ulong to ulong
2125 if not wmc104 at
2126 ret 10000
2127 end
2128 ret add at len z11
2129 end
2130
2131 fn wconsumec14 at ulong to ulong
2132 if not wmc105 at
2133 ret 10000
2134 end
2135 ret add at len z12
2136 end
2137
2138 fn wconsumec15 at ulong to ulong
2139 if not wmc106 at
2140 ret 10000
2141 end
2142 ret add at len z13
2143 end
2144
2145 fn wtc16 to void
2146 for i ulong len wbase
2147 wb get wbase i
2148 end
2149 end
2150
2151 fn wtc17 to void
2152 for i ulong len wcomp
2153 wb get wcomp i
2154 end
2155 end
2156
2157 fn wtc18 to void
2158 for i ulong len wexec
2159 wb get wexec i
2160 end
2161 end
2162
2163 fn woc19 to void
2164 put wolen 0 len z14
2165 for i ulong len z14
2166 put wobs i get z14 i
2167 end
2168 end
2169
2170 fn woc20 to void
2171 put wolen 0 len z15
2172 for i ulong len z15
2173 put wobs i get z15 i
2174 end
2175 end
2176
2177 fn woc21 to void
2178 put wolen 0 len z16
2179 for i ulong len z16
2180 put wobs i get z16 i
2181 end
2182 end
2183
2184 fn woc22 to void
2185 put wolen 0 len z17
2186 for i ulong len z17
2187 put wobs i get z17 i
2188 end
2189 end
2190
2191 fn woc23 to void
2192 put wolen 0 len z18
2193 for i ulong len z18
2194 put wobs i get z18 i
2195 end
2196 end
2197
2198 fn woc24 to void
2199 put wolen 0 len z19
2200 for i ulong len z19
2201 put wobs i get z19 i
2202 end
2203 end
2204
2205 fn wtc25 to void
2206 for i ulong len z20
2207 wb get z20 i
2208 end
2209 end
2210
2211 fn wtc26 to void
2212 for i ulong len z21
2213 wb get z21 i
2214 end
2215 end
2216
2217 fn wtc27 to void
2218 for i ulong len z22
2219 wb get z22 i
2220 end
2221 end
2222
2223 fn wtc28 to void
2224 for i ulong len z23
2225 wb get z23 i
2226 end
2227 end
2228
2229 fn woc29 to void
2230 put wolen 0 len z24
2231 for i ulong len z24
2232 put wobs i get z24 i
2233 end
2234 end
2235
2236 fn wtc30 to void
2237 for i ulong len z25
2238 wb get z25 i
2239 end
2240 end
2241
2242 fn wtc31 to void
2243 for i ulong len z26
2244 wb get z26 i
2245 end
2246 end
2247
2248 fn wtc32 to void
2249 for i ulong len z27
2250 wb get z27 i
2251 end
2252 end
2253
2254 fn wtc33 to void
2255 for i ulong len z28
2256 wb get z28 i
2257 end
2258 end
2259
2260 fn woc34 to void
2261 put wolen 0 len z29
2262 for i ulong len z29
2263 put wobs i get z29 i
2264 end
2265 end
2266
2267 fn wtokenc35 to bool
2268 if ne get wtkn 0 len z30
2269 ret false
2270 end
2271 for i ulong len z30
2272 if ne get wtok i get z30 i
2273 ret false
2274 end
2275 end
2276 ret true
2277 end
2278
2279 fn wtokenc36 to bool
2280 if ne get wtkn 0 len z31
2281 ret false
2282 end
2283 for i ulong len z31
2284 if ne get wtok i get z31 i
2285 ret false
2286 end
2287 end
2288 ret true
2289 end
2290
2291 fn wtokenc37 to bool
2292 if ne get wtkn 0 len z32
2293 ret false
2294 end
2295 for i ulong len z32
2296 if ne get wtok i get z32 i
2297 ret false
2298 end
2299 end
2300 ret true
2301 end
2302
2303 fn wtokenc38 to bool
2304 if ne get wtkn 0 len z33
2305 ret false
2306 end
2307 for i ulong len z33
2308 if ne get wtok i get z33 i
2309 ret false
2310 end
2311 end
2312 ret true
2313 end
2314
2315 fn wfieldc39 slot ulong to bool
2316 if ne get wflen slot len z34
2317 ret false
2318 end
2319 for i ulong len z34
2320 if ne get wfld add mul slot 128 i get z34 i
2321 ret false
2322 end
2323 end
2324 ret true
2325 end
2326
2327 fn wtc40 to void
2328 for i ulong len z35
2329 wb get z35 i
2330 end
2331 end
2332
2333 fn wtc41 to void
2334 for i ulong len z36
2335 wb get z36 i
2336 end
2337 end
2338
2339 fn wtc42 to void
2340 for i ulong len z37
2341 wb get z37 i
2342 end
2343 end
2344
2345 fn wtc43 to void
2346 for i ulong len z38
2347 wb get z38 i
2348 end
2349 end
2350
2351 fn wtc44 to void
2352 for i ulong len z39
2353 wb get z39 i
2354 end
2355 end
2356
2357 fn wtc45 to void
2358 for i ulong len z40
2359 wb get z40 i
2360 end
2361 end
2362
2363 fn wtc46 to void
2364 for i ulong len z41
2365 wb get z41 i
2366 end
2367 end
2368
2369 fn wtc47 to void
2370 for i ulong len z42
2371 wb get z42 i
2372 end
2373 end
2374
2375 fn wtc48 to void
2376 for i ulong len z43
2377 wb get z43 i
2378 end
2379 end
2380
2381 fn wtc49 to void
2382 for i ulong len z44
2383 wb get z44 i
2384 end
2385 end
2386
2387 fn wtc50 to void
2388 for i ulong len z45
2389 wb get z45 i
2390 end
2391 end
2392
2393 fn wtc51 to void
2394 for i ulong len z46
2395 wb get z46 i
2396 end
2397 end
2398
2399 fn wfieldc52 slot ulong to bool
2400 if ne get wflen slot len z47
2401 ret false
2402 end
2403 for i ulong len z47
2404 if ne get wfld add mul slot 128 i get z47 i
2405 ret false
2406 end
2407 end
2408 ret true
2409 end
2410
2411 fn woc53 to void
2412 put wolen 0 len z48
2413 for i ulong len z48
2414 put wobs i get z48 i
2415 end
2416 end
2417
2418 fn woc54 to void
2419 put wolen 0 len z49
2420 for i ulong len z49
2421 put wobs i get z49 i
2422 end
2423 end
2424
2425 fn weventc55 mode ulong to bool
2426 wz
2427 wtc107
2428 wtc108
2429 wtc109
2430 wj mode
2431 wtc28
2432 ret wemit
2433 end
2434
2435 fn wfieldc56 slot ulong to bool
2436 if ne get wflen slot len z51
2437 ret false
2438 end
2439 for i ulong len z51
2440 if ne get wfld add mul slot 128 i get z51 i
2441 ret false
2442 end
2443 end
2444 ret true
2445 end
2446
2447 fn woc57 to void
2448 put wolen 0 len z52
2449 for i ulong len z52
2450 put wobs i get z52 i
2451 end
2452 end
2453
2454 fn weventc58 mode ulong to bool
2455 wz
2456 wtc107
2457 wtc110
2458 wtc109
2459 wj mode
2460 wtc28
2461 ret wemit
2462 end
2463
2464 fn weventc59 mode ulong to bool
2465 wz
2466 wtc107
2467 wtc111
2468 wtc109
2469 wj mode
2470 wtc28
2471 ret wemit
2472 end
2473
2474 fn wfinishc60 ok bool to void
2475 wz
2476 wtc112
2477 if ok
2478 wtc113
2479 else
2480 wtc114
2481 end
2482 wtc115
2483 wtc116
2484 wtc117
2485 wj 1
2486 wtc28
2487 r = wemit
2488 r = streamend
2489 end
2490
2491 note Match exact, host-free line grammar before the compiler is invoked.
2492
2493 fn weventc61 mode ulong to bool
2494 wz
2495 wtc107
2496 wtc118
2497 wtc109
2498 wj mode
2499 wtc28
2500 ret wemit
2501 end
2502
2503 fn wanswerc62 to bool
2504 if ne get walen 0 len z29
2505 ret false
2506 end
2507 for i ulong len z29
2508 if ne get wans i get z29 i
2509 ret false
2510 end
2511 end
2512 ret true
2513 end
2514
2515 fn wfinishc63 ok bool to void
2516 wz
2517 wtc112
2518 if ok
2519 wtc113
2520 else
2521 wtc114
2522 end
2523 wtc115
2524 wtc119
2525 wtc117
2526 wj 1
2527 wtc28
2528 r = wemit
2529 r = streamend
2530 end
2531
2532 note Match exact, host-free line grammar before the compiler is invoked.
2533
2534 fn wfinishc64 ok bool to void
2535 wz
2536 wtc112
2537 if ok
2538 wtc113
2539 else
2540 wtc114
2541 end
2542 wtc115
2543 wtc120
2544 wtc117
2545 wj 1
2546 wtc28
2547 r = wemit
2548 r = streamend
2549 end
2550
2551 note Match exact, host-free line grammar before the compiler is invoked.
2552
2553 fn wanswerc65 to bool
2554 if ne get walen 0 len z48
2555 ret false
2556 end
2557 for i ulong len z48
2558 if ne get wans i get z48 i
2559 ret false
2560 end
2561 end
2562 ret true
2563 end
2564
2565 fn wfinishc66 ok bool to void
2566 wz
2567 wtc112
2568 if ok
2569 wtc113
2570 else
2571 wtc114
2572 end
2573 wtc115
2574 wtc121
2575 wtc117
2576 wj 1
2577 wtc28
2578 r = wemit
2579 r = streamend
2580 end
2581
2582 note Match exact, host-free line grammar before the compiler is invoked.
2583
2584 fn wfinishc67 ok bool to void
2585 wz
2586 wtc112
2587 if ok
2588 wtc113
2589 else
2590 wtc114
2591 end
2592 wtc115
2593 wtc122
2594 wtc117
2595 wj 1
2596 wtc28
2597 r = wemit
2598 r = streamend
2599 end
2600
2601 note Match exact, host-free line grammar before the compiler is invoked.
2602
2603 fn wfinishc68 ok bool to void
2604 wz
2605 wtc112
2606 if ok
2607 wtc113
2608 else
2609 wtc114
2610 end
2611 wtc115
2612 wtc123
2613 wtc117
2614 wj 1
2615 wtc28
2616 r = wemit
2617 r = streamend
2618 end
2619
2620 note Match exact, host-free line grammar before the compiler is invoked.
2621
2622 fn wfinishc69 ok bool to void
2623 wz
2624 wtc112
2625 if ok
2626 wtc113
2627 else
2628 wtc114
2629 end
2630 wtc115
2631 wtc124
2632 wtc117
2633 wj 1
2634 wtc28
2635 r = wemit
2636 r = streamend
2637 end
2638
2639 note Match exact, host-free line grammar before the compiler is invoked.
2640
2641 fn wfinishc70 ok bool to void
2642 wz
2643 wtc112
2644 if ok
2645 wtc113
2646 else
2647 wtc114
2648 end
2649 wtc115
2650 wtc125
2651 wtc117
2652 wj 1
2653 wtc28
2654 r = wemit
2655 r = streamend
2656 end
2657
2658 note Match exact, host-free line grammar before the compiler is invoked.
2659
2660 fn wfinishc71 ok bool to void
2661 wz
2662 wtc112
2663 if ok
2664 wtc113
2665 else
2666 wtc114
2667 end
2668 wtc115
2669 wtc126
2670 wtc117
2671 wj 1
2672 wtc28
2673 r = wemit
2674 r = streamend
2675 end
2676
2677 note Match exact, host-free line grammar before the compiler is invoked.
2678
2679 fn wfinishc72 ok bool to void
2680 wz
2681 wtc112
2682 if ok
2683 wtc113
2684 else
2685 wtc114
2686 end
2687 wtc115
2688 wtc127
2689 wtc117
2690 wj 1
2691 wtc28
2692 r = wemit
2693 r = streamend
2694 end
2695
2696 note Match exact, host-free line grammar before the compiler is invoked.
2697
2698 fn wtc73 to void
2699 for i ulong len z66
2700 wb get z66 i
2701 end
2702 end
2703
2704 fn wtc74 to void
2705 for i ulong len z67
2706 wb get z67 i
2707 end
2708 end
2709
2710 fn wtc75 to void
2711 for i ulong len z68
2712 wb get z68 i
2713 end
2714 end
2715
2716 fn wtc76 to void
2717 for i ulong len z69
2718 wb get z69 i
2719 end
2720 end
2721
2722 fn wtc77 to void
2723 for i ulong len z70
2724 wb get z70 i
2725 end
2726 end
2727
2728 fn wtc78 to void
2729 for i ulong len z71
2730 wb get z71 i
2731 end
2732 end
2733
2734 fn wtc79 to void
2735 for i ulong len z72
2736 wb get z72 i
2737 end
2738 end
2739
2740 fn wtc80 to void
2741 for i ulong len z73
2742 wb get z73 i
2743 end
2744 end
2745
2746 fn wtc81 to void
2747 for i ulong len z74
2748 wb get z74 i
2749 end
2750 end
2751
2752 fn wtc82 to void
2753 for i ulong len z75
2754 wb get z75 i
2755 end
2756 end
2757
2758 fn wtc83 to void
2759 for i ulong len z76
2760 wb get z76 i
2761 end
2762 end
2763
2764 fn wtc84 to void
2765 for i ulong len z77
2766 wb get z77 i
2767 end
2768 end
2769
2770 fn wtc85 to void
2771 for i ulong len z78
2772 wb get z78 i
2773 end
2774 end
2775
2776 fn wtc86 to void
2777 for i ulong len z79
2778 wb get z79 i
2779 end
2780 end
2781
2782 fn wtc87 to void
2783 for i ulong len z80
2784 wb get z80 i
2785 end
2786 end
2787
2788 fn wtc88 to void
2789 for i ulong len z81
2790 wb get z81 i
2791 end
2792 end
2793
2794 fn wtc89 to void
2795 for i ulong len z82
2796 wb get z82 i
2797 end
2798 end
2799
2800 fn wtc90 to void
2801 for i ulong len z83
2802 wb get z83 i
2803 end
2804 end
2805
2806 fn wtc91 to void
2807 for i ulong len z84
2808 wb get z84 i
2809 end
2810 end
2811
2812 fn wtc92 to void
2813 for i ulong len z85
2814 wb get z85 i
2815 end
2816 end
2817
2818 fn wtc93 to void
2819 for i ulong len z86
2820 wb get z86 i
2821 end
2822 end
2823
2824 fn wtc94 to void
2825 for i ulong len z87
2826 wb get z87 i
2827 end
2828 end
2829
2830 fn wtc95 to void
2831 for i ulong len z88
2832 wb get z88 i
2833 end
2834 end
2835
2836 fn wtc96 to void
2837 for i ulong len z89
2838 wb get z89 i
2839 end
2840 end
2841
2842 fn wtc97 to void
2843 for i ulong len z90
2844 wb get z90 i
2845 end
2846 end
2847
2848 fn wmc98 at ulong to bool
2849 if gt add at len z0 get wslen 0
2850 ret false
2851 end
2852 for i ulong len z0
2853 if ne get wsrc add at i get z0 i
2854 ret false
2855 end
2856 end
2857 ret true
2858 end
2859
2860 fn wmc99 at ulong to bool
2861 if gt add at len z2 get wslen 0
2862 ret false
2863 end
2864 for i ulong len z2
2865 if ne get wsrc add at i get z2 i
2866 ret false
2867 end
2868 end
2869 ret true
2870 end
2871
2872 fn wmc100 at ulong to bool
2873 if gt add at len z5 get wslen 0
2874 ret false
2875 end
2876 for i ulong len z5
2877 if ne get wsrc add at i get z5 i
2878 ret false
2879 end
2880 end
2881 ret true
2882 end
2883
2884 fn wmc101 at ulong to bool
2885 if gt add at len z6 get wslen 0
2886 ret false
2887 end
2888 for i ulong len z6
2889 if ne get wsrc add at i get z6 i
2890 ret false
2891 end
2892 end
2893 ret true
2894 end
2895
2896 fn wmc102 at ulong to bool
2897 if gt add at len z7 get wslen 0
2898 ret false
2899 end
2900 for i ulong len z7
2901 if ne get wsrc add at i get z7 i
2902 ret false
2903 end
2904 end
2905 ret true
2906 end
2907
2908 fn wmc103 at ulong to bool
2909 if gt add at len z10 get wslen 0
2910 ret false
2911 end
2912 for i ulong len z10
2913 if ne get wsrc add at i get z10 i
2914 ret false
2915 end
2916 end
2917 ret true
2918 end
2919
2920 fn wmc104 at ulong to bool
2921 if gt add at len z11 get wslen 0
2922 ret false
2923 end
2924 for i ulong len z11
2925 if ne get wsrc add at i get z11 i
2926 ret false
2927 end
2928 end
2929 ret true
2930 end
2931
2932 fn wmc105 at ulong to bool
2933 if gt add at len z12 get wslen 0
2934 ret false
2935 end
2936 for i ulong len z12
2937 if ne get wsrc add at i get z12 i
2938 ret false
2939 end
2940 end
2941 ret true
2942 end
2943
2944 fn wmc106 at ulong to bool
2945 if gt add at len z13 get wslen 0
2946 ret false
2947 end
2948 for i ulong len z13
2949 if ne get wsrc add at i get z13 i
2950 ret false
2951 end
2952 end
2953 ret true
2954 end
2955
2956 fn wtc107 to void
2957 for i ulong len z91
2958 wb get z91 i
2959 end
2960 end
2961
2962 fn wtc108 to void
2963 for i ulong len z50
2964 wb get z50 i
2965 end
2966 end
2967
2968 fn wtc109 to void
2969 for i ulong len z92
2970 wb get z92 i
2971 end
2972 end
2973
2974 fn wtc110 to void
2975 for i ulong len z53
2976 wb get z53 i
2977 end
2978 end
2979
2980 fn wtc111 to void
2981 for i ulong len z54
2982 wb get z54 i
2983 end
2984 end
2985
2986 fn wtc112 to void
2987 for i ulong len z93
2988 wb get z93 i
2989 end
2990 end
2991
2992 fn wtc113 to void
2993 for i ulong len z94
2994 wb get z94 i
2995 end
2996 end
2997
2998 fn wtc114 to void
2999 for i ulong len z95
3000 wb get z95 i
3001 end
3002 end
3003
3004 fn wtc115 to void
3005 for i ulong len z96
3006 wb get z96 i
3007 end
3008 end
3009
3010 fn wtc116 to void
3011 for i ulong len z55
3012 wb get z55 i
3013 end
3014 end
3015
3016 fn wtc117 to void
3017 for i ulong len z97
3018 wb get z97 i
3019 end
3020 end
3021
3022 fn wtc118 to void
3023 for i ulong len z56
3024 wb get z56 i
3025 end
3026 end
3027
3028 fn wtc119 to void
3029 for i ulong len z57
3030 wb get z57 i
3031 end
3032 end
3033
3034 fn wtc120 to void
3035 for i ulong len z58
3036 wb get z58 i
3037 end
3038 end
3039
3040 fn wtc121 to void
3041 for i ulong len z59
3042 wb get z59 i
3043 end
3044 end
3045
3046 fn wtc122 to void
3047 for i ulong len z60
3048 wb get z60 i
3049 end
3050 end
3051
3052 fn wtc123 to void
3053 for i ulong len z61
3054 wb get z61 i
3055 end
3056 end
3057
3058 fn wtc124 to void
3059 for i ulong len z62
3060 wb get z62 i
3061 end
3062 end
3063
3064 fn wtc125 to void
3065 for i ulong len z63
3066 wb get z63 i
3067 end
3068 end
3069
3070 fn wtc126 to void
3071 for i ulong len z64
3072 wb get z64 i
3073 end
3074 end
3075
3076 fn wtc127 to void
3077 for i ulong len z65
3078 wb get z65 i
3079 end
3080 end