interplane.Get Omega
Read in your language

omega-tool-model

First-party Omega tool-use model source, serving harnesses, and verification records

Brought by drakestapleton

branch main Branches Tags History

omega-tool-model / pack / demo

17 lines · 786 bytes Raw Blame History
1#!/bin/sh
2# The only authorized operation in this example is reading the bundled fixture.
3set -eu
4cd -P "$(dirname "$0")"
5request=$(./model --demo)
6case "$request" in
7 '{"tool":"read_file","path":"jobs/item76666.om"}') ;;
8 *) printf 'Unrecognized model request: %s\n' "$request" >&2; exit 1 ;;
9esac
10printf 'Model requested %s\n' "$request"
11source_text=$(cat jobs/item76666.om)
12reply=$(printf '%s\n' 'Task: Fix the error in this file and confirm its goal.' \
13 'File: jobs/item76666.om' \
14 'Goal: calc starts with x and adds 4 exactly 3 times in a for loop. main calls calc with 70.' \
15 'State: read' 'Source:' "$source_text" 'Tool result: Read succeeded.' 'Answer:' | ./model)
16printf 'Model replied %s\n' "$reply"
17test "$reply" = '{"tool":"omega_check","path":"jobs/item76666.om"}'