The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.
TypeScript 3d-modelingagent-frameworkagent-harnessai-agentscadclaude-codecodexcoding-agentsdeveloper-toolsesp32game-developmentmcp-servermulti-agentopen-hardwareopencodeopenharnesspcbroboticsterminaltmux
feat(store): add eight researched studios with local artifact workflows
Dee44aa72ed8f9e
diff --git a/store/agents/ableton-ai/.gitignore b/store/agents/ableton-ai/.gitignorenew file mode 100644index 000000000..97ed7159a--- /dev/null+++ b/store/agents/ableton-ai/.gitignore@@ -0,0 +1,8 @@+upstream/+juce/+.venv/+.build/+.sumo/+__pycache__/+*.pyc+coverage/diff --git a/store/agents/ableton-ai/AGENTS.md b/store/agents/ableton-ai/AGENTS.mdnew file mode 100644index 000000000..90c162cc3--- /dev/null+++ b/store/agents/ableton-ai/AGENTS.md@@ -0,0 +1,18 @@+# Ableton AI workspace++This harness turns a request into a real, inspectable music artifact. Start with+the `ableton-ai` skill. The editable project is `studio.json` plus files in this workspace.+The viewer follows `out/latest.json` and the run history; save small useful changes as you work.++Run `"$STUDIO_TOOLCHAIN/run.sh" render` after a change. The runner validates controls,+records provenance, writes artifacts, and updates `.harness/verdict.json`. Do not hand-edit the+verdict to claim a run succeeded. Inspect the produced artifact before describing the result.++The starter is a local synthesized MIDI sequencer. It writes a standard MIDI file and WAV preview without Ableton. The optional Live action reads a running Ableton AI bridge; it does not overwrite tracks or start transport.++The installed sources are at `$STUDIO_UPSTREAM`. Preserve upstream credit and use the pinned+instructions when extending the domain workflow. Local simulations are the default. Ask before+using a paid generation service or operating physical hardware unless the user already authorized it.++When developing this package itself, keep it independently installable from its folder; shared+runtime copies are synchronized by `store/tools/sync-studios.mjs` and `sync-runtimes.mjs`.diff --git a/store/agents/ableton-ai/INTEGRATION.md b/store/agents/ableton-ai/INTEGRATION.mdnew file mode 100644index 000000000..c996dc04e--- /dev/null+++ b/store/agents/ableton-ai/INTEGRATION.md@@ -0,0 +1,12 @@+# Local MIDI/audio and a read-only Live snapshot++`render` produces a Standard MIDI File, PCM WAV, and explicit note events. The custom sixteen-step mask is stored with the controls. `live` imports the pinned upstream `AbletonConnection` and sends only `get_session_info`. Upstream bridge environment variables select the local host/port. The optional full MCP server is `upstream/src/ableton_ai/server.py`; see the upstream README to enable its Control Surface.++## Verification scope++The local loop works without Ableton. Live snapshots are tested at the transport contract with an isolated local responder; that does not claim a running Ableton application was tested. No existing Live tracks or transport are changed by this wrapper.++The browser acceptance suite lives in `store/viewers/studio-viewer/test/studios.e2e.mjs`.+`TESTING.md` beside that viewer records commands, outcomes, screenshots and coverage.+Upstream source revisions are in `upstream.lock.json`; install-time Python dependencies are+hash-locked in `requirements.lock`. No user application configuration is written by setup.diff --git a/store/agents/ableton-ai/LICENSE b/store/agents/ableton-ai/LICENSEnew file mode 100644index 000000000..a499cd17e--- /dev/null+++ b/store/agents/ableton-ai/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Autonomous, Inc.++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/ableton-ai/LICENSE-upstream b/store/agents/ableton-ai/LICENSE-upstreamnew file mode 100644index 000000000..2e1f19b75--- /dev/null+++ b/store/agents/ableton-ai/LICENSE-upstream@@ -0,0 +1,23 @@+MIT License++Copyright (c) 2025 Siddharth Ahuja+Copyright (c) 2026 Jason Poindexter+Copyright (c) 2026 Freek Van der Herten++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.\ No newline at end of filediff --git a/store/agents/ableton-ai/README.md b/store/agents/ableton-ai/README.mdnew file mode 100644index 000000000..9ce83d092--- /dev/null+++ b/store/agents/ableton-ai/README.md@@ -0,0 +1,49 @@+# Ableton AI · Loop room++A small pattern can become a whole mood. Make a loop, play with its pulse, and keep the happy accidents.++```sh+harness dsh install autonomous/ableton-ai+```++Open a workspace in Harness. Setup fetches upstream sources at the commit in `upstream.lock.json`,+installs a package-local Python 3.11 environment, and verifies the local tools. The starter runs+without credentials or a cloud account. Studio Viewer provides controls, history, downloads,+live agent updates, and failure recovery. Setup never edits an application's preferences.++## What runs here++The starter is a local synthesized MIDI sequencer. It writes a standard MIDI file and WAV preview without Ableton. The optional Live action reads a running Ableton AI bridge; it does not overwrite tracks or start transport.++Edit `studio.json`, then run:++```sh+"$STUDIO_TOOLCHAIN/run.sh" render # Keep this loop+"$STUDIO_TOOLCHAIN/run.sh" live # Read Live session+```++The native command is optional and fails with a useful message when its external runtime is+unavailable. It never silently substitutes sample output. Use the upstream README in `upstream/`+for full native application setup. See `INTEGRATION.md` for the exact bridge and local test scope.++Every successful run owns a new folder under `out/runs/`, a `result.json` with parameters, engine,+source commit, timestamps, measured values, and downloadable artifacts. `.harness/verdict.json`+means the named artifact was produced, not that an engineering or aesthetic claim was certified.+The starter can be regenerated with no network after install.++## Development and testing++Install the shared viewer and this package with `harness dsh install <path> --link`.+`toolchain/doctor.sh` checks the local runtime. The repository's Studio Viewer browser suite+materializes temporary workspaces and exercises each shipped local workflow. Run it from+`store/viewers/studio-viewer` with `npm run test:browser`; exact results live in its `TESTING.md`.++## Credit and stewardship++[Ableton AI](https://github.com/freekmurze/ableton-ai) is maintained by Freek Van der Herten and contributors. Its sources are+fetched unchanged at `2baa8b79c00f48d925b080f3719a7b892f64d86c`. Upstream licensing: MIT; Ableton Live licensed separately.+The original license is preserved in `LICENSE-upstream`; dependency terms still apply.++OpenHarness contributors wrote the MIT wrapper, local starter, and viewer integration. This is+an independent integration, not an upstream endorsement. Upstream bugs belong with the upstream+project; wrapper bugs belong in OpenHarness. Maintainers are welcome to take over this package.diff --git a/store/agents/ableton-ai/THIRD_PARTY_NOTICES.md b/store/agents/ableton-ai/THIRD_PARTY_NOTICES.mdnew file mode 100644index 000000000..239235b53--- /dev/null+++ b/store/agents/ableton-ai/THIRD_PARTY_NOTICES.md@@ -0,0 +1,9 @@+# Third-party notices++Ableton AI — Freek Van der Herten and contributors. https://github.com/freekmurze/ableton-ai++Pinned source: 2baa8b79c00f48d925b080f3719a7b892f64d86c. Fetched at install into ignored `upstream/`, unmodified.+License: MIT; Ableton Live licensed separately. See `LICENSE-upstream` and the fetched source tree.++The original local starter and wrapper are MIT licensed. The native runtime and separately+installed applications retain their own licenses. No upstream endorsement is claimed.diff --git a/store/agents/ableton-ai/VERSIONS b/store/agents/ableton-ai/VERSIONSnew file mode 100644index 000000000..d4df99787--- /dev/null+++ b/store/agents/ableton-ai/VERSIONS@@ -0,0 +1,2 @@+UPSTREAM_COMMIT=2baa8b79c00f48d925b080f3719a7b892f64d86c+PYTHON=3.11diff --git a/store/agents/ableton-ai/harness.json b/store/agents/ableton-ai/harness.jsonnew file mode 100644index 000000000..2cc5fcb07--- /dev/null+++ b/store/agents/ableton-ai/harness.json@@ -0,0 +1,33 @@+{+ "spec": 1,+ "id": "autonomous/ableton-ai",+ "name": "Ableton AI",+ "category": "Music",+ "author": "Freek Van der Herten and contributors",+ "description": "A small pattern can become a whole mood. Make a loop, play with its pulse, and keep the happy accidents.",+ "engine": "codex",+ "workspace": {+ "template": "template",+ "marker": "studio.json",+ "init": "toolchain/init-workspace.sh"+ },+ "agent": {+ "instructions": "AGENTS.md",+ "skills": [+ "skills"+ ],+ "env": {+ "STUDIO_TOOLCHAIN": "${dsh}/toolchain",+ "STUDIO_PYTHON": "${dsh}/.venv/bin/python",+ "STUDIO_UPSTREAM": "${dsh}/upstream"+ }+ },+ "toolchain": {+ "setup": "toolchain/setup.sh",+ "doctor": "toolchain/doctor.sh"+ },+ "viewer": {+ "use": "autonomous/studio-viewer"+ },+ "verdict": ".harness/verdict.json"+}diff --git a/store/agents/ableton-ai/requirements.in b/store/agents/ableton-ai/requirements.innew file mode 100644index 000000000..8b1378917--- /dev/null+++ b/store/agents/ableton-ai/requirements.in@@ -0,0 +1 @@+diff --git a/store/agents/ableton-ai/requirements.lock b/store/agents/ableton-ai/requirements.locknew file mode 100644index 000000000..818dca5c3--- /dev/null+++ b/store/agents/ableton-ai/requirements.lock@@ -0,0 +1,2 @@+# This file was autogenerated by uv via the following command:+# uv pip compile requirements.in --python-version 3.11 --universal --generate-hashes -o requirements.lockdiff --git a/store/agents/ableton-ai/skills/ableton-ai/SKILL.md b/store/agents/ableton-ai/skills/ableton-ai/SKILL.mdnew file mode 100644index 000000000..ef568678a--- /dev/null+++ b/store/agents/ableton-ai/skills/ableton-ai/SKILL.md@@ -0,0 +1,19 @@+---+name: ableton-ai+description: Create and inspect music projects in the Ableton AI Harness workspace, including its local starter and optional upstream integration.+---++# Loop room++Read `studio.json` to understand the current controls; `"$STUDIO_TOOLCHAIN/../studio.config.json"`+describes their ranges. Run `"$STUDIO_TOOLCHAIN/run.sh" render` to make a new result.+Successful artifacts and their measurements are in `out/runs/<id>/`; `out/latest.json` names the+current result. A failed run preserves the last success and records the error in the verdict.++The starter is a local synthesized MIDI sequencer. It writes a standard MIDI file and WAV preview without Ableton. The optional Live action reads a running Ableton AI bridge; it does not overwrite tracks or start transport.++Use `"$STUDIO_TOOLCHAIN/../README.md"` for the integration contract and commands. Read the relevant+files under `$STUDIO_UPSTREAM` before using an upstream API. Keep controls within their documented+ranges, preserve the data needed to reproduce a comparison, and distinguish preview results from+native service or hardware output. The viewer supports history and artifact downloads; tell the+user which run contains the result, and what was actually measured.diff --git a/store/agents/ableton-ai/store.json b/store/agents/ableton-ai/store.jsonnew file mode 100644index 000000000..6c9799c66--- /dev/null+++ b/store/agents/ableton-ai/store.json@@ -0,0 +1,6 @@+{+ "homepage": "https://github.com/freekmurze/ableton-ai",+ "upstream": "https://github.com/freekmurze/ableton-ai",+ "license": "MIT; Ableton Live licensed separately",+ "screenshots": []+}diff --git a/store/agents/ableton-ai/studio.config.json b/store/agents/ableton-ai/studio.config.jsonnew file mode 100644index 000000000..df781d10d--- /dev/null+++ b/store/agents/ableton-ai/studio.config.json@@ -0,0 +1,107 @@+{+ "title": "Loop room",+ "description": "A small pattern can become a whole mood. Make a loop, play with its pulse, and keep the happy accidents.",+ "category": "Music",+ "scene": "A PLACE TO FIND YOUR RHYTHM",+ "hint": "Tap the steps \u00b7 press Play to hear your pattern",+ "tip": "Try half the notes at a slower tempo. Export MIDI to keep working in your DAW.",+ "previewLabel": "Local synth audition \u00b7 Live not connected",+ "controls": [+ {+ "id": "tempo",+ "label": "Tempo",+ "type": "number",+ "value": 96,+ "min": 50,+ "max": 160,+ "step": 1,+ "integer": true,+ "unit": "BPM",+ "hint": ""+ },+ {+ "id": "scale",+ "label": "Mood",+ "type": "select",+ "value": "minor",+ "options": [+ {+ "value": "minor",+ "label": "Moonlit \u00b7 minor"+ },+ {+ "value": "major",+ "label": "Sunroom \u00b7 major"+ },+ {+ "value": "pentatonic",+ "label": "Floating \u00b7 pentatonic"+ }+ ]+ },+ {+ "id": "density",+ "label": "Pattern density",+ "type": "number",+ "value": 6,+ "min": 2,+ "max": 12,+ "step": 1,+ "integer": true,+ "unit": "notes",+ "hint": ""+ },+ {+ "id": "seed",+ "label": "New variation",+ "type": "number",+ "value": 3,+ "min": 1,+ "max": 32,+ "step": 1,+ "integer": true,+ "unit": "",+ "hint": ""+ },+ {+ "id": "swing",+ "label": "Swing",+ "type": "number",+ "value": 0,+ "min": 0,+ "max": 0.3,+ "step": 0.05,+ "integer": false,+ "unit": "",+ "hint": ""+ },+ {+ "id": "pattern",+ "label": "Custom rhythm",+ "type": "text",+ "value": "",+ "maxLength": 16,+ "hidden": true+ }+ ],+ "actions": [+ {+ "id": "render",+ "label": "Keep this loop",+ "description": ""+ },+ {+ "id": "live",+ "label": "Read Live session",+ "description": "Read the connected Ableton session through its local bridge"+ }+ ],+ "credit": "Ableton AI \u00b7 Freek Van der Herten and contributors",+ "empty": "Adjust the controls, then make your first exploration. Every successful run stays in the history.",+ "theme": {+ "accent": "#a75c39",+ "tint": "#efe4d6",+ "stage": "#28211e",+ "stage-accent": "#f2bc88"+ }+}diff --git a/store/agents/ableton-ai/template/studio.json b/store/agents/ableton-ai/template/studio.jsonnew file mode 100644index 000000000..8f0a8e134--- /dev/null+++ b/store/agents/ableton-ai/template/studio.json@@ -0,0 +1,12 @@+{+ "spec": 1,+ "title": "Loop room",+ "parameters": {+ "tempo": 96,+ "scale": "minor",+ "density": 6,+ "seed": 3,+ "swing": 0,+ "pattern": ""+ }+}diff --git a/store/agents/ableton-ai/toolchain/doctor.sh b/store/agents/ableton-ai/toolchain/doctor.shnew file mode 100755index 000000000..aa65239cf--- /dev/null+++ b/store/agents/ableton-ai/toolchain/doctor.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+test -x .venv/bin/python || { echo 'miss run toolchain/setup.sh to install the local runtime'; exit 1; }+.venv/bin/python -c 'import json; json.load(open("studio.config.json")); print("ok Ableton AI local workflow")'+test -f upstream/README.md || { echo "miss pinned upstream sources"; exit 1; }+echo "ok upstream 2baa8b79c00f"diff --git a/store/agents/ableton-ai/toolchain/init-workspace.sh b/store/agents/ableton-ai/toolchain/init-workspace.shnew file mode 100755index 000000000..d68d2d3b3--- /dev/null+++ b/store/agents/ableton-ai/toolchain/init-workspace.sh@@ -0,0 +1,3 @@+#!/usr/bin/env bash+set -euo pipefail+exec "${HARNESS_DSH_DIR:?}/toolchain/run.sh" renderdiff --git a/store/agents/ableton-ai/toolchain/run.sh b/store/agents/ableton-ai/toolchain/run.shnew file mode 100755index 000000000..a9e5df771--- /dev/null+++ b/store/agents/ableton-ai/toolchain/run.sh@@ -0,0 +1,6 @@+#!/usr/bin/env bash+set -euo pipefail+studio_package="$(cd "$(dirname "$0")/.." && pwd)"+export PATH="$studio_package/.venv/bin:$PATH"+export PYTHONUNBUFFERED=1+exec "$studio_package/.venv/bin/python" "$studio_package/toolchain/workflow.py" "$@"diff --git a/store/agents/ableton-ai/toolchain/runtimes.sh b/store/agents/ableton-ai/toolchain/runtimes.shnew file mode 100644index 000000000..7223c78dc--- /dev/null+++ b/store/agents/ableton-ai/toolchain/runtimes.sh@@ -0,0 +1,192 @@+# shellcheck shell=bash+# runtimes.sh — the interpreters a store package runs on, found on this machine or fetched, never+# asked of the person who pressed Get.+#+# Sourced (not run) by a package's setup, doctor and viewer scripts. A new Mac has Apple's Python 3.9,+# no Homebrew and, for most people, no Node on PATH; a package that answers "brew install [email protected]"+# has failed its install. So:+#+# harness_node 18 node >= 18 on PATH, with npm: the machine's own, else the Node Harness+# itself runs on (~/.harness/runtime/current-node, laid down with the CLI)+# harness_uv uv on PATH: the machine's own, else a pinned, checksummed release+# fetched into ~/.harness/runtime+# harness_venv DIR 3.12 [MIN [BELOW]]+# DIR is a venv on CPython 3.12, which uv downloads when the machine+# has none. A venv already there on a Python in [MIN, BELOW) is kept.+# harness_pip DIR PKG… install into that venv, through uv+# harness_micromamba micromamba, pinned and checksummed, for native libraries PyPI has+# no wheel for (pycairo on macOS)+# harness_conda_env DIR SPEC… DIR is a conda-forge environment with those packages+#+# Every function prints `miss …` and returns 1 when it cannot deliver, so `harness_node 18 || exit 1`+# reads like the rest of a setup script. Nothing here touches the user's shell profile; what it+# installs lands in ~/.harness/runtime or the package's own directory (uv keeps its download cache+# where it always does, which a venv does not depend on).+#+# ONE copy is written by hand: store/tools/runtimes.sh in the OpenHarness repository. Each package+# carries an identical copy (a package installs alone, so it cannot reach this one);+# `node store/tools/sync-runtimes.mjs` rewrites them and the CLI's store spec fails when one drifts.++HARNESS_RUNTIME="${ADAPTER_RUNTIME_DIR:-${HOME:-}/.harness/runtime}"+# The Pythons uv downloads live with Harness's other runtimes, not in uv's own ~/.local/share/uv:+# a package's venv points at its interpreter, and `uv python uninstall` there must not break it.+UV_PYTHON_INSTALL_DIR="${UV_PYTHON_INSTALL_DIR:-$HARNESS_RUNTIME/python}"+export UV_PYTHON_INSTALL_DIR+HARNESS_UV_VERSION=0.12.15+HARNESS_MICROMAMBA_VERSION=2.9.0-0++_harness_platform() {+ case "$(uname -s)-$(uname -m)" in+ Darwin-arm64) echo darwin-arm64 ;;+ Darwin-x86_64) echo darwin-x64 ;;+ Linux-x86_64) echo linux-x64 ;;+ Linux-aarch64 | Linux-arm64) echo linux-arm64 ;;+ *) return 1 ;;+ esac+}++_harness_sha256() {+ if command -v shasum >/dev/null 2>&1; then shasum -a 256 "$1" | cut -d' ' -f1+ else sha256sum "$1" | cut -d' ' -f1; fi+}++# _harness_fetch URL DEST SHA256 — DEST exists only if what arrived matches the pinned checksum.+_harness_fetch() {+ local part="$2.part.$$"+ if ! curl -fsSL --retry 3 --connect-timeout 20 --max-time 900 -o "$part" "$1"; then+ rm -f "$part"; echo "miss could not download $1 — check this machine's internet connection"; return 1+ fi+ if [ "$(_harness_sha256 "$part")" != "$3" ]; then+ rm -f "$part"; echo "miss $1 did not match its pinned checksum; nothing was installed"; return 1+ fi+ mv -f "$part" "$2"+}++_harness_node_at_least() {+ command -v node >/dev/null 2>&1 || return 1+ node -e '+ const [a, b = 0] = process.argv[1].split(".").map(Number)+ const [x, y] = process.versions.node.split(".").map(Number)+ process.exit(x > a || (x === a && y >= b) ? 0 : 1)+ ' "$1" >/dev/null 2>&1+}++harness_node() {+ local min="${1:-18}" recorded saved="$PATH" own=0+ _harness_node_at_least "$min" && own=1+ # A node without npm beside it (a distro's nodejs package) cannot run a setup's `npm ci`.+ if [ "$own" = 1 ] && command -v npm >/dev/null 2>&1; then return 0; fi+ recorded="$(cat "$HARNESS_RUNTIME/current-node" 2>/dev/null || true)"+ # Already Harness's own (a second call, or a wrapper calling a script that asks again): nothing to add.+ if [ "$own" = 1 ] && [ -n "$recorded" ] && [ "$(command -v node)" = "${recorded%/*}/node" ]; then return 0; fi+ if [ -n "$recorded" ] && [ -x "${recorded%/*}/node" ]; then+ PATH="${recorded%/*}:$PATH"; export PATH; hash -r 2>/dev/null || true+ _harness_node_at_least "$min" && return 0+ PATH="$saved"; export PATH; hash -r 2>/dev/null || true+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min — this machine's newest is $("${recorded%/*}/node" -v), Harness's own; update Harness"+ return 1+ fi+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min, and Harness's own Node is not in $HARNESS_RUNTIME — run \`harness start\` once to lay it down"+ return 1+}++harness_uv() {+ local dir asset sum tmp+ command -v uv >/dev/null 2>&1 && return 0+ for dir in "${HOME:-}/.local/bin" "${HOME:-}/.cargo/bin"; do+ [ -n "${HOME:-}" ] || break+ if [ -x "$dir/uv" ]; then PATH="$dir:$PATH"; export PATH; return 0; fi+ done+ dir="$HARNESS_RUNTIME/uv-$HARNESS_UV_VERSION"+ if [ ! -x "$dir/uv" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=uv-aarch64-apple-darwin sum=dc304b9ed1b24174572290fba60ac3f6fe63c73a671f0439e62a91375841964d ;;+ darwin-x64) asset=uv-x86_64-apple-darwin sum=e9ca61775532368fe518ab03e7a354c7ecab8ccb3c7d941c775fcc4a362b801b ;;+ linux-x64) asset=uv-x86_64-unknown-linux-gnu sum=f97935763c04be3e692460a7aaeaaab8fc3b78fcf8b389da820b38ae7423a638 ;;+ linux-arm64) asset=uv-aarch64-unknown-linux-gnu sum=0e9a3499b0587d449c9ff684c0160da607826e4af1cee220bc87f378702d3e08 ;;+ *) echo "miss uv — there is no uv release for $(uname -s) $(uname -m); install it from https://docs.astral.sh/uv/"; return 1 ;;+ esac+ echo " fetching uv $HARNESS_UV_VERSION into $HARNESS_RUNTIME (it brings Python and the packages)"+ mkdir -p "$HARNESS_RUNTIME" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ tmp="$(mktemp -d "$HARNESS_RUNTIME/.uv.XXXXXX")" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ if ! _harness_fetch "https://github.com/astral-sh/uv/releases/download/$HARNESS_UV_VERSION/$asset.tar.gz" "$tmp/uv.tar.gz" "$sum"; then+ rm -rf "$tmp"; return 1+ fi+ tar -xzf "$tmp/uv.tar.gz" -C "$tmp" && chmod +x "$tmp/$asset/uv" "$tmp/$asset/uvx" \+ || { rm -rf "$tmp"; echo "miss the uv archive would not unpack"; return 1; }+ # Two installs at once both get here; whichever renames first wins and the other's copy goes.+ # (mv onto a directory that exists would nest the copy inside it, hence the test.)+ [ -e "$dir" ] || mv "$tmp/$asset" "$dir" 2>/dev/null || true+ rm -rf "$tmp"+ [ -x "$dir/uv" ] || { echo "miss uv did not land in $dir"; return 1; }+ fi+ PATH="$dir:$PATH"; export PATH+}++# harness_venv DIR VERSION [MIN [BELOW]] — MIN defaults to VERSION; BELOW is exclusive and optional.+harness_venv() {+ local dir="${1:?harness_venv needs a directory}" want="${2:?harness_venv needs a Python version}"+ local min="${3:-$2}" below="${4:-}"+ if [ -x "$dir/bin/python" ] && "$dir/bin/python" -c '+import sys+at = lambda s: tuple(int(p) for p in s.split("."))+v = sys.version_info[:2]+sys.exit(0 if v >= at(sys.argv[1]) and (not sys.argv[2] or v < at(sys.argv[2])) else 1)+' "$min" "$below" 2>/dev/null; then+ echo "ok $("$dir/bin/python" --version) in $dir"+ return 0+ fi+ harness_uv || return 1+ echo " python $want in $dir (uv downloads it when this machine has none)"+ rm -rf "$dir"+ # only-managed: the same python-build-standalone interpreter on every machine, so a package tested+ # once is tested everywhere — not whichever Homebrew or pyenv Python happened to be first on PATH.+ uv venv --quiet --seed --python "$want" --python-preference only-managed "$dir" \+ || { echo "miss could not make a Python $want environment in $dir"; return 1; }+ echo "ok $("$dir/bin/python" --version) in $dir"+}++harness_pip() {+ local dir="${1:?harness_pip needs a venv}"+ shift+ harness_uv || return 1+ # uv's own error comes first; the miss line is last, so it is the line the store shows.+ uv pip install --quiet --python "$dir/bin/python" "$@" \+ || { echo "miss could not install $* into $dir"; return 1; }+}++harness_micromamba() {+ local dir asset sum+ dir="$HARNESS_RUNTIME/micromamba-$HARNESS_MICROMAMBA_VERSION"+ if [ ! -x "$dir/micromamba" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=micromamba-osx-arm64 sum=ec2a072f028e1a7cf20f3e2e74d5a8127cf5a5f27636375b5359811565f4e5be ;;+ darwin-x64) asset=micromamba-osx-64 sum=1e71054bb3ac9a076e21f7ec48acfef536f9b3f1408f371a942784bf5ef83d8a ;;+ linux-x64) asset=micromamba-linux-64 sum=366cd9cd8be14df1ab8ed50352a82111082a36686b2d389fdb79a92c3fafb3e3 ;;+ linux-arm64) asset=micromamba-linux-aarch64 sum=9f93b974adcb4d166996af969b6cd371287d1a3e52733704727884d9b74cb7a7 ;;+ *) echo "miss micromamba — there is no release for $(uname -s) $(uname -m)"; return 1 ;;+ esac+ echo " fetching micromamba $HARNESS_MICROMAMBA_VERSION into $HARNESS_RUNTIME (native libraries PyPI has no wheel for)"+ mkdir -p "$dir" || { echo "miss cannot write $dir"; return 1; }+ _harness_fetch "https://github.com/mamba-org/micromamba-releases/releases/download/$HARNESS_MICROMAMBA_VERSION/$asset" "$dir/micromamba.$$" "$sum" || return 1+ chmod +x "$dir/micromamba.$$" && mv -f "$dir/micromamba.$$" "$dir/micromamba" \+ || { rm -f "$dir/micromamba.$$"; echo "miss micromamba would not install into $dir"; return 1; }+ fi+ HARNESS_MICROMAMBA="$dir/micromamba"+ export HARNESS_MICROMAMBA+}++# harness_conda_env DIR SPEC… — conda-forge only, packages cached under ~/.harness/runtime/mamba.+harness_conda_env() {+ local dir="${1:?harness_conda_env needs a directory}"+ shift+ # micromamba takes a relative --prefix as a name under its root prefix and "succeeds" there.+ case "$dir" in /*) ;; *) dir="$PWD/$dir" ;; esac+ harness_micromamba || return 1+ MAMBA_ROOT_PREFIX="$HARNESS_RUNTIME/mamba" "$HARNESS_MICROMAMBA" create --yes --quiet \+ --prefix "$dir" --override-channels --channel conda-forge "$@" >/dev/null \+ && [ -d "$dir/conda-meta" ] \+ || { echo "miss could not make the conda-forge environment in $dir ($*)"; return 1; }+}diff --git a/store/agents/ableton-ai/toolchain/setup.sh b/store/agents/ableton-ai/toolchain/setup.shnew file mode 100755index 000000000..efbece7e2--- /dev/null+++ b/store/agents/ableton-ai/toolchain/setup.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+harness_venv .venv 3.11 3.11 3.12+.venv/bin/python toolchain/studio_fetch.py+if [ -s requirements.lock ]; then harness_pip .venv --require-hashes -r requirements.lock; fi+exec toolchain/doctor.shdiff --git a/store/agents/ableton-ai/toolchain/studio_fetch.py b/store/agents/ableton-ai/toolchain/studio_fetch.pynew file mode 100644index 000000000..88a670b25--- /dev/null+++ b/store/agents/ableton-ai/toolchain/studio_fetch.py@@ -0,0 +1,34 @@+"""Fetch reviewed source pins without installing a service or changing user configuration."""+import json+import os+from pathlib import Path+import subprocess++root = Path(__file__).resolve().parent.parent+sources = json.loads((root / "upstream.lock.json").read_text())+for source in sources:+ target = root / source["directory"]+ def git(*args):+ return subprocess.check_output(["git", "-C", str(target), *args], text=True,+ env={**os.environ, "GIT_LFS_SKIP_SMUDGE": "1"}).strip()+ if not (target / ".git").exists():+ target.mkdir(parents=True, exist_ok=True)+ git("init", "-q")+ git("remote", "add", "origin", source["url"])+ if source.get("sparse"):+ git("sparse-checkout", "init", "--cone")+ git("sparse-checkout", "set", *source["sparse"])+ if git("remote", "get-url", "origin") != source["url"]:+ raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])+ try:+ current = git("rev-parse", "HEAD")+ except subprocess.CalledProcessError:+ current = ""+ if current != source["commit"]:+ if current and git("status", "--porcelain"):+ raise SystemExit(f"Save your edits in {target} before changing its source pin")+ git("fetch", "--depth", "1", "--filter=blob:none", "origin", source["commit"])+ git("checkout", "--detach", source["commit"])+ print(f'ok {source["name"]} at {source["commit"][:12]}', flush=True)diff --git a/store/agents/ableton-ai/toolchain/studio_runtime.py b/store/agents/ableton-ai/toolchain/studio_runtime.pynew file mode 100644index 000000000..8b8ea016c--- /dev/null+++ b/store/agents/ableton-ai/toolchain/studio_runtime.py@@ -0,0 +1,132 @@+"""Portable runner copied into each independently installable studio package."""+import json+import math+import os+from pathlib import Path+import subprocess+import sys+import tempfile+import time+import uuid+++def workspace():+ return Path(os.environ.get("HARNESS_WORKSPACE", os.getcwd())).resolve()+++def package():+ return Path(__file__).resolve().parent.parent+++def contained(path):+ target = Path(path).resolve()+ target.relative_to(workspace())+ return target+++def atomic_json(path, data):+ path = contained(path)+ path.parent.mkdir(parents=True, exist_ok=True)+ with tempfile.NamedTemporaryFile(mode="w", dir=path.parent, prefix=".studio-", delete=False) as f:+ json.dump(data, f, indent=2, allow_nan=False)+ f.write("\n")+ temp = f.name+ os.replace(temp, path)+++def command(argv, cwd=None, timeout=120, env=None):+ """No shell interpolation; keep complete logs as output, bound execution time."""+ result = subprocess.run([str(x) for x in argv], cwd=cwd, timeout=timeout,+ env=env, text=True, capture_output=True)+ if result.returncode:+ raise RuntimeError((result.stderr or result.stdout)[-1600:] or f"{argv[0]} exited {result.returncode}")+ return result.stdout+++def parameters(config, values):+ if not isinstance(values, dict) or set(values) - {c["id"] for c in config["controls"]}:+ raise ValueError("Invalid studio controls")+ result = {}+ for c in config["controls"]:+ value = values.get(c["id"], c["value"])+ if c["type"] == "number":+ if type(value) not in (int, float) or not math.isfinite(value) or not c["min"] <= value <= c["max"]:+ raise ValueError(f'{c["label"]} is outside its range')+ if c.get("integer") and value != int(value):+ raise ValueError(f'{c["label"]} must be a whole number')+ elif c["type"] == "select":+ if value not in [o["value"] for o in c["options"]]:+ raise ValueError(f'Unknown {c["label"]}')+ elif not isinstance(value, str) or len(value) > c.get("maxLength", 500):+ raise ValueError(f'Invalid {c["label"]}')+ result[c["id"]] = value+ return result+++def metric(label, value, unit=""):+ return {"label": label, "value": value, "unit": unit}+++def previous_runs():+ base = contained(workspace() / "out/runs")+ rows = []+ for p in sorted(base.glob("*/result.json"))[-100:]:+ try:+ rows.append(json.loads(contained(p).read_text()))+ except (ValueError, OSError):+ continue+ return rows+++def execute(actions):+ root = workspace()+ config = json.loads((package() / "studio.config.json").read_text())+ action = sys.argv[1] if len(sys.argv) > 1 else config["actions"][0]["id"]+ started = time.monotonic()+ verdict_path = root / ".harness/verdict.json"+ verdict = {"spec": 1, "ready": False, "summary": "Preparing the studio run", "findings": [],+ "phases": [{"id": "run", "name": "Make", "state": "active"},+ {"id": "inspect", "name": "Inspect", "state": "pending"}]}+ try:+ if action not in actions:+ raise ValueError(f"Unknown action: {action}")+ source = contained(root / "studio.json")+ if source.stat().st_size > 16384:+ raise ValueError("studio.json is too large")+ project = json.loads(source.read_text())+ p = parameters(config, project["parameters"])+ atomic_json(verdict_path, verdict)+ run_id = time.strftime("%Y%m%dT%H%M%S", time.gmtime()) + "-" + uuid.uuid4().hex[:8]+ output = contained(root / "out/runs" / run_id)+ output.mkdir(parents=True)+ print(f'{config["title"]}: {action}', flush=True)+ result = actions[action](p, output)+ artifacts = []+ for artifact in result.pop("files", []):+ file = contained(output / artifact["name"])+ file.relative_to(output)+ if not file.is_file() or not file.stat().st_size:+ raise ValueError(f'Missing output: {artifact["name"]}')+ artifacts.append({"label": artifact["label"], "path": str(file.relative_to(root))})+ result.update({"spec": 1, "id": run_id, "action": action, "parameters": p,+ "createdAt": time.strftime("%Y-%m-%dT%H:%M:%SZ", time.gmtime()),+ "durationSeconds": round(time.monotonic() - started, 3), "artifacts": artifacts,+ "upstream": json.loads((package() / "upstream.lock.json").read_text())})+ atomic_json(output / "result.json", result)+ atomic_json(root / "out/latest.json", result)+ verdict.update({"ready": True, "summary": f'{result["title"]} · {result["engine"]}',+ "artifact": str((output / "result.json").relative_to(root)),+ "phases": [{"id": "run", "name": "Make", "state": "done"},+ {"id": "inspect", "name": "Inspect", "state": "done"}],+ "updatedAt": result["createdAt"]})+ atomic_json(verdict_path, verdict)+ print(f'Ready: {result["title"]}', flush=True)+ except Exception as exc:+ verdict.update({"summary": str(exc)[:500], "findings": [{"severity": "error", "kind": "run-failed", "message": str(exc)[:1000]}],+ "phases": [{"id": "run", "name": "Make", "state": "failed"}]})+ try:+ atomic_json(verdict_path, verdict)+ except (ValueError, OSError):+ pass+ print(str(exc), file=sys.stderr)+ raise SystemExit(1) from excdiff --git a/store/agents/ableton-ai/toolchain/workflow.py b/store/agents/ableton-ai/toolchain/workflow.pynew file mode 100644index 000000000..37ad92683--- /dev/null+++ b/store/agents/ableton-ai/toolchain/workflow.py@@ -0,0 +1,82 @@+import array+import json+import math+import random+import re+import struct+import sys+import wave+from studio_runtime import execute, metric, package++SCALES = {"minor": [0, 3, 5, 7, 10], "major": [0, 4, 5, 7, 11], "pentatonic": [0, 2, 4, 7, 9]}+++def notes(p):+ rng = random.Random(p["seed"])+ if p["pattern"]:+ if not re.fullmatch('[01]{16}',p["pattern"]):+ raise ValueError('A custom rhythm must contain sixteen steps')+ slots=[i for i,v in enumerate(p["pattern"]) if v=='1']+ else:+ slots = sorted(rng.sample(range(16), p["density"]))+ return [{"step": s, "note": 48 + rng.choice(SCALES[p["scale"]]), "velocity": rng.randint(75, 110),+ "beat": s / 4 + (p["swing"] / 4 if s % 2 else 0), "length": .22} for s in slots]+++def variable_length(value):+ result = [value & 127]+ while value >> 7:+ value >>= 7+ result.insert(0, (value & 127) | 128)+ return bytes(result)+++def render(p, out):+ pattern = notes(p)+ rate = 22050+ duration = 4 * 60 / p["tempo"]+ samples = [0.] * int((duration + .4) * rate)+ events = []+ tempo = round(60_000_000 / p["tempo"])+ for note in pattern:+ start = int(note["beat"] * 60 / p["tempo"] * rate)+ length = int((note["length"] * 60 / p["tempo"] + .15) * rate)+ frequency = 440 * 2 ** ((note["note"] - 69) / 12)+ for i in range(min(length, len(samples)-start)):+ t = i / rate+ envelope = min(1, t / .008) * math.exp(-t * 9)+ samples[start+i] += math.sin(2 * math.pi * frequency * t) * envelope * note["velocity"] / 127 * .32+ tick = round(note["beat"] * 480)+ events.extend([(tick, bytes([0x90,note["note"],note["velocity"]])), (tick+round(note["length"]*480),bytes([0x80,note["note"],0]))])+ raw = array.array('h',[round(max(-.99,min(.99,x))*32767) for x in samples])+ with wave.open(str(out/'loop.wav'),'wb') as f:+ f.setnchannels(1); f.setsampwidth(2); f.setframerate(rate); f.writeframes(raw.tobytes())+ track = b'\x00\xff\x51\x03' + tempo.to_bytes(3,'big')+ previous = 0+ for tick,event in sorted(events,key=lambda v:(v[0],v[1][0])):+ track += variable_length(tick-previous) + event+ previous = tick+ track += variable_length(max(0,1920-previous)) + b'\xff\x2f\x00'+ (out/'loop.mid').write_bytes(b'MThd'+struct.pack('>IHHH',6,0,1,480)+b'MTrk'+struct.pack('>I',len(track))+track)+ (out/'notes.json').write_text(json.dumps(pattern,indent=2))+ return {"title":f'{p["scale"].capitalize()} groove · {p["tempo"]} BPM',+ "description":"A playable local synth sketch. The MIDI keeps the exact notes, timing, velocity, swing and tempo.",+ "engine":"Local MIDI + synthesized audio", "metrics":[metric("Tempo",p["tempo"],"BPM"),metric("Notes",len(pattern)),metric("Loop length",round(duration,2),"s")],+ "data":{"notes":pattern,"duration":duration},"files":[{"label":"MIDI pattern","name":"loop.mid"},{"label":"WAV loop","name":"loop.wav"},{"label":"Note events","name":"notes.json"}]}+++def live(p,out):+ sys.path.insert(0,str(package()/'upstream/src'))+ from ableton_ai.connection import AbletonConnection+ from ableton_ai.config import Settings+ try:+ with AbletonConnection(Settings(max_connect_attempts=1,recv_timeout=3,command_delay=0)) as connection:+ snapshot=connection.send_command('get_session_info',retry=False)+ except Exception as exc:+ raise RuntimeError('Open Ableton Live and enable its AbletonAI Control Surface on port 9877. '+str(exc)) from exc+ (out/'live-session.json').write_text(json.dumps(snapshot,indent=2))+ return {"title":"Live session snapshot","description":"Read directly from Ableton. No tracks or transport were changed.","engine":"Ableton Live · local bridge","metrics":[metric("Tempo",snapshot.get('tempo','—'),"BPM"),metric("Tracks",len(snapshot.get('tracks',[])))],"data":{"session":snapshot},"files":[{"label":"Live snapshot","name":"live-session.json"}]}+++if __name__=='__main__':+ execute({'render':render,'live':live})diff --git a/store/agents/ableton-ai/upstream.lock.json b/store/agents/ableton-ai/upstream.lock.jsonnew file mode 100644index 000000000..656744d52--- /dev/null+++ b/store/agents/ableton-ai/upstream.lock.json@@ -0,0 +1,14 @@+[+ {+ "name": "Ableton AI",+ "url": "https://github.com/freekmurze/ableton-ai.git",+ "commit": "2baa8b79c00f48d925b080f3719a7b892f64d86c",+ "directory": "upstream",+ "sparse": [+ "src",+ "skills",+ "remote_script",+ "rest_api"+ ]+ }+]diff --git a/store/agents/ableton-ai/view.mjs b/store/agents/ableton-ai/view.mjsnew file mode 100644index 000000000..c7bc914c1--- /dev/null+++ b/store/agents/ableton-ai/view.mjs@@ -0,0 +1,17 @@+import {canvas,grid,round,words,circle,toolbar,badge,label,tone} from '/graphics.mjs';+function random(seed){let s=seed;return()=>{s=(s*1664525+1013904223)>>>0;return s/4294967296;};}+export function mount(stage,api){+ let p=api.getParameters(),playing=false,step=0,interval,lastTick=0,selected=new Set(),oldSeed,oldDensity,recording=new Audio(),result;+ label(stage,'Sixteen steps. Endless little possibilities.');badge(stage,'LOCAL SYNTH');+ function pattern(){if(p.pattern)return new Set([...p.pattern].flatMap((v,i)=>v==='1'?[i]:[]));const rnd=random(p.seed),slots=Array.from({length:16},(_,i)=>i);for(let i=15;i>0;i--){const j=Math.floor(rnd()*(i+1));[slots[i],slots[j]]=[slots[j],slots[i]];}return new Set(slots.slice(0,p.density));}+ const screen=canvas(stage,(ctx,w,h,t)=>{grid(ctx,w,h);const gap=8,left=24,cell=(w-2*left-7*gap)/8,top=h*.28,rowh=55;for(let i=0;i<16;i++){const x=left+i%8*(cell+gap),y=top+Math.floor(i/8)*(rowh+12),on=selected.has(i);round(ctx,x,y,cell,rowh,8,on?'#e8af7c':'#ffffff09',step===i&&playing?'#fff2d8':'#ffffff15');if(on)circle(ctx,x+cell/2,y+18,3,'#30231e');words(ctx,String(i+1).padStart(2,'0'),x+8,y+rowh-10,on?'#57402e':'#7e6d63',10);}words(ctx,`${p.tempo} BPM`,24,h*.18,'#f2bc88',25);words(ctx,p.scale.toUpperCase(),w-105,h*.18,'#a59285',10);if(playing){const x=24+(t%1)*(w-48);lineProgress(ctx,x,h-95);}},api.signal);+ function lineProgress(ctx,x,y){ctx.fillStyle='#f2bc8840';ctx.fillRect(24,y,x-24,2);}+ screen.element.setAttribute('aria-label','Sixteen-step sequencer; click a step to toggle it');screen.element.tabIndex=0;+ const toggle=i=>{if(selected.has(i))selected.delete(i);else selected.add(i);api.setParameter('pattern',Array.from({length:16},(_,j)=>selected.has(j)?'1':'0').join(''));api.announce(`Step ${i+1} ${selected.has(i)?'on':'off'}`);};+ screen.element.addEventListener('click',e=>{const box=screen.element.getBoundingClientRect(),x=e.clientX-box.left,y=e.clientY-box.top,cell=(box.width-48-56)/8;const col=Math.floor((x-24)/(cell+8)),row=Math.floor((y-box.height*.28)/67);if(col>=0&&col<8&&row>=0&&row<2)toggle(row*8+col);});+ screen.element.addEventListener('keydown',e=>{if(e.key==='ArrowRight'){step=(step+1)%16;api.announce(`Step ${step+1}`);e.preventDefault();}if(e.key==='ArrowLeft'){step=(step+15)%16;api.announce(`Step ${step+1}`);e.preventDefault();}if(e.key===' '||e.key==='Enter'){toggle(step);e.preventDefault();}});+ function tick(){if(!playing)return;const scales={minor:[0,3,5,7,10],major:[0,4,5,7,11],pentatonic:[0,2,4,7,9]};if(selected.has(step)){const n=scales[p.scale][(step+p.seed)%5];tone(130.8128*2**(n/12),.24,'triangle',.16).catch(()=>api.announce('Audio is unavailable. Download the WAV.'));}step=(step+1)%16;interval=setTimeout(tick,60000/p.tempo/4*(1+(step%2?p.swing:-p.swing)));}+ const bar=toolbar(stage,[['Play loop',b=>{playing=!playing;b.textContent=playing?'Pause loop':'Play loop';b.setAttribute('aria-pressed',String(playing));if(playing)tick();else clearTimeout(interval);}],['New variation',()=>{api.setParameter('pattern','');api.setParameter('seed',p.seed%32+1);}],['Play WAV',async()=>{const file=result?.artifacts.find(a=>a.path.endsWith('.wav'));if(!file){api.announce('Keep a loop first.');return;}recording.src=api.artifactURL(file.path);await recording.play().catch(()=>api.announce('Download the WAV to listen.'));}]]);+ api.signal.addEventListener('abort',()=>{clearTimeout(interval);recording.pause();});+ return {update(params,r,motion){const changed=oldSeed!==undefined&&(oldSeed!==params.seed||oldDensity!==params.density);p=params;result=r;oldSeed=p.seed;oldDensity=p.density;if(changed&&p.pattern){api.setParameter('pattern','');return;}selected=pattern();screen.motion(motion);if(!motion&&playing){playing=false;clearTimeout(interval);bar.firstChild.textContent='Play loop';bar.firstChild.setAttribute('aria-pressed','false');}}};+}diff --git a/store/agents/autoresearch-mlx/.gitignore b/store/agents/autoresearch-mlx/.gitignorenew file mode 100644index 000000000..97ed7159a--- /dev/null+++ b/store/agents/autoresearch-mlx/.gitignore@@ -0,0 +1,8 @@+upstream/+juce/+.venv/+.build/+.sumo/+__pycache__/+*.pyc+coverage/diff --git a/store/agents/autoresearch-mlx/AGENTS.md b/store/agents/autoresearch-mlx/AGENTS.mdnew file mode 100644index 000000000..a3686c59e--- /dev/null+++ b/store/agents/autoresearch-mlx/AGENTS.md@@ -0,0 +1,18 @@+# autoresearch-mlx workspace++This harness turns a request into a real, inspectable science artifact. Start with+the `autoresearch-mlx` skill. The editable project is `studio.json` plus files in this workspace.+The viewer follows `out/latest.json` and the run history; save small useful changes as you work.++Run `"$STUDIO_TOOLCHAIN/run.sh" train` after a change. The runner validates controls,+records provenance, writes artifacts, and updates `.harness/verdict.json`. Do not hand-edit the+verdict to claim a run succeeded. Inspect the produced artifact before describing the result.++The local starter trains a small character transition model with NumPy on a bundled, original text corpus. It uses real training and held-out cross-entropy, not generated metrics. It is a CPU baseline, distinct from upstream MLX transformer training, which requires Apple Silicon and its prepared dataset.++The installed sources are at `$STUDIO_UPSTREAM`. Preserve upstream credit and use the pinned+instructions when extending the domain workflow. Local simulations are the default. Ask before+using a paid generation service or operating physical hardware unless the user already authorized it.++When developing this package itself, keep it independently installable from its folder; shared+runtime copies are synchronized by `store/tools/sync-studios.mjs` and `sync-runtimes.mjs`.diff --git a/store/agents/autoresearch-mlx/INTEGRATION.md b/store/agents/autoresearch-mlx/INTEGRATION.mdnew file mode 100644index 000000000..31afbf2ef--- /dev/null+++ b/store/agents/autoresearch-mlx/INTEGRATION.md@@ -0,0 +1,12 @@+# CPU experiment and optional Apple Silicon MLX++`train` executes the editable workspace `train.py`, then independently loads `model.npz` with pickle disabled and evaluates `holdout.txt`. The model, text and training-source hashes are recorded. Runs are compared only when train/holdout hashes agree. `mlx` runs a prepared workspace `mlx/train.py` with its own `.venv`; use the pinned upstream README for environment/data preparation.++## Verification scope++The Intel Mac acceptance path is the NumPy character model. Native MLX requires Apple Silicon and is separately identified. A best observed score is not a statistical-significance claim.++The browser acceptance suite lives in `store/viewers/studio-viewer/test/studios.e2e.mjs`.+`TESTING.md` beside that viewer records commands, outcomes, screenshots and coverage.+Upstream source revisions are in `upstream.lock.json`; install-time Python dependencies are+hash-locked in `requirements.lock`. No user application configuration is written by setup.diff --git a/store/agents/autoresearch-mlx/LICENSE b/store/agents/autoresearch-mlx/LICENSEnew file mode 100644index 000000000..a499cd17e--- /dev/null+++ b/store/agents/autoresearch-mlx/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Autonomous, Inc.++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/autoresearch-mlx/LICENSE-upstream b/store/agents/autoresearch-mlx/LICENSE-upstreamnew file mode 100644index 000000000..ccd1104a9--- /dev/null+++ b/store/agents/autoresearch-mlx/LICENSE-upstream@@ -0,0 +1,22 @@+MIT License++Copyright (c) 2026 Andrej Karpathy+Copyright (c) 2026 Trevin Peterson++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/autoresearch-mlx/README.md b/store/agents/autoresearch-mlx/README.mdnew file mode 100644index 000000000..5859a2fbc--- /dev/null+++ b/store/agents/autoresearch-mlx/README.md@@ -0,0 +1,49 @@+# autoresearch-mlx · Research notebook++Follow a small idea through a real experiment. Train, compare, and see what the evidence says.++```sh+harness dsh install autonomous/autoresearch-mlx+```++Open a workspace in Harness. Setup fetches upstream sources at the commit in `upstream.lock.json`,+installs a package-local Python 3.11 environment, and verifies the local tools. The starter runs+without credentials or a cloud account. Studio Viewer provides controls, history, downloads,+live agent updates, and failure recovery. Setup never edits an application's preferences.++## What runs here++The local starter trains a small character transition model with NumPy on a bundled, original text corpus. It uses real training and held-out cross-entropy, not generated metrics. It is a CPU baseline, distinct from upstream MLX transformer training, which requires Apple Silicon and its prepared dataset.++Edit `studio.json`, then run:++```sh+"$STUDIO_TOOLCHAIN/run.sh" train # Try an experiment+"$STUDIO_TOOLCHAIN/run.sh" mlx # Run MLX experiment+```++The native command is optional and fails with a useful message when its external runtime is+unavailable. It never silently substitutes sample output. Use the upstream README in `upstream/`+for full native application setup. See `INTEGRATION.md` for the exact bridge and local test scope.++Every successful run owns a new folder under `out/runs/`, a `result.json` with parameters, engine,+source commit, timestamps, measured values, and downloadable artifacts. `.harness/verdict.json`+means the named artifact was produced, not that an engineering or aesthetic claim was certified.+The starter can be regenerated with no network after install.++## Development and testing++Install the shared viewer and this package with `harness dsh install <path> --link`.+`toolchain/doctor.sh` checks the local runtime. The repository's Studio Viewer browser suite+materializes temporary workspaces and exercises each shipped local workflow. Run it from+`store/viewers/studio-viewer` with `npm run test:browser`; exact results live in its `TESTING.md`.++## Credit and stewardship++[autoresearch-mlx](https://github.com/trevin-creator/autoresearch-mlx) is maintained by Trevin creator; Andrej Karpathy. Its sources are+fetched unchanged at `766a25ff22afa799efd8d0aa450a4348e4749df2`. Upstream licensing: MIT.+The original license is preserved in `LICENSE-upstream`; dependency terms still apply.++OpenHarness contributors wrote the MIT wrapper, local starter, and viewer integration. This is+an independent integration, not an upstream endorsement. Upstream bugs belong with the upstream+project; wrapper bugs belong in OpenHarness. Maintainers are welcome to take over this package.diff --git a/store/agents/autoresearch-mlx/THIRD_PARTY_NOTICES.md b/store/agents/autoresearch-mlx/THIRD_PARTY_NOTICES.mdnew file mode 100644index 000000000..ce038d20c--- /dev/null+++ b/store/agents/autoresearch-mlx/THIRD_PARTY_NOTICES.md@@ -0,0 +1,9 @@+# Third-party notices++autoresearch-mlx — Trevin creator; Andrej Karpathy. https://github.com/trevin-creator/autoresearch-mlx++Pinned source: 766a25ff22afa799efd8d0aa450a4348e4749df2. Fetched at install into ignored `upstream/`, unmodified.+License: MIT. See `LICENSE-upstream` and the fetched source tree.++The original local starter and wrapper are MIT licensed. The native runtime and separately+installed applications retain their own licenses. No upstream endorsement is claimed.diff --git a/store/agents/autoresearch-mlx/VERSIONS b/store/agents/autoresearch-mlx/VERSIONSnew file mode 100644index 000000000..91e3c938a--- /dev/null+++ b/store/agents/autoresearch-mlx/VERSIONS@@ -0,0 +1,2 @@+UPSTREAM_COMMIT=766a25ff22afa799efd8d0aa450a4348e4749df2+PYTHON=3.11diff --git a/store/agents/autoresearch-mlx/harness.json b/store/agents/autoresearch-mlx/harness.jsonnew file mode 100644index 000000000..ea322f3ba--- /dev/null+++ b/store/agents/autoresearch-mlx/harness.json@@ -0,0 +1,33 @@+{+ "spec": 1,+ "id": "autonomous/autoresearch-mlx",+ "name": "autoresearch-mlx",+ "category": "Science",+ "author": "Trevin creator; Andrej Karpathy",+ "description": "Follow a small idea through a real experiment. Train, compare, and see what the evidence says.",+ "engine": "codex",+ "workspace": {+ "template": "template",+ "marker": "studio.json",+ "init": "toolchain/init-workspace.sh"+ },+ "agent": {+ "instructions": "AGENTS.md",+ "skills": [+ "skills"+ ],+ "env": {+ "STUDIO_TOOLCHAIN": "${dsh}/toolchain",+ "STUDIO_PYTHON": "${dsh}/.venv/bin/python",+ "STUDIO_UPSTREAM": "${dsh}/upstream"+ }+ },+ "toolchain": {+ "setup": "toolchain/setup.sh",+ "doctor": "toolchain/doctor.sh"+ },+ "viewer": {+ "use": "autonomous/studio-viewer"+ },+ "verdict": ".harness/verdict.json"+}diff --git a/store/agents/autoresearch-mlx/requirements.in b/store/agents/autoresearch-mlx/requirements.innew file mode 100644index 000000000..d59d856f1--- /dev/null+++ b/store/agents/autoresearch-mlx/requirements.in@@ -0,0 +1 @@+numpy==2.3.5diff --git a/store/agents/autoresearch-mlx/requirements.lock b/store/agents/autoresearch-mlx/requirements.locknew file mode 100644index 000000000..327a140ba--- /dev/null+++ b/store/agents/autoresearch-mlx/requirements.lock@@ -0,0 +1,78 @@+# This file was autogenerated by uv via the following command:+# uv pip compile requirements.in --python-version 3.11 --universal --generate-hashes -o requirements.lock+numpy==2.3.5 \+ --hash=sha256:00dc4e846108a382c5869e77c6ed514394bdeb3403461d25a829711041217d5b \+ --hash=sha256:0472f11f6ec23a74a906a00b48a4dcf3849209696dff7c189714511268d103ae \+ --hash=sha256:04822c00b5fd0323c8166d66c701dc31b7fbd252c100acd708c48f763968d6a3 \+ --hash=sha256:052e8c42e0c49d2575621c158934920524f6c5da05a1d3b9bab5d8e259e045f0 \+ --hash=sha256:09a1bea522b25109bf8e6f3027bd810f7c1085c64a0c7ce050c1676ad0ba010b \+ --hash=sha256:0cd00b7b36e35398fa2d16af7b907b65304ef8bb4817a550e06e5012929830fa \+ --hash=sha256:0d8163f43acde9a73c2a33605353a4f1bc4798745a8b1d73183b28e5b435ae28 \+ --hash=sha256:1062fde1dcf469571705945b0f221b73928f34a20c904ffb45db101907c3454e \+ --hash=sha256:11e06aa0af8c0f05104d56450d6093ee639e15f24ecf62d417329d06e522e017 \+ --hash=sha256:17531366a2e3a9e30762c000f2c43a9aaa05728712e25c11ce1dbe700c53ad41 \+ --hash=sha256:1978155dd49972084bd6ef388d66ab70f0c323ddee6f693d539376498720fb7e \+ --hash=sha256:1ed1ec893cff7040a02c8aa1c8611b94d395590d553f6b53629a4461dc7f7b63 \+ --hash=sha256:2dcd0808a421a482a080f89859a18beb0b3d1e905b81e617a188bd80422d62e9 \+ --hash=sha256:2e2eb32ddb9ccb817d620ac1d8dae7c3f641c1e5f55f531a33e8ab97960a75b8 \+ --hash=sha256:2feae0d2c91d46e59fcd62784a3a83b3fb677fead592ce51b5a6fbb4f95965ff \+ --hash=sha256:3095bdb8dd297e5920b010e96134ed91d852d81d490e787beca7e35ae1d89cf7 \+ --hash=sha256:30bc11310e8153ca664b14c5f1b73e94bd0503681fcf136a163de856f3a50139 \+ --hash=sha256:3101e5177d114a593d79dd79658650fe28b5a0d8abeb8ce6f437c0e6df5be1a4 \+ --hash=sha256:396084a36abdb603546b119d96528c2f6263921c50df3c8fd7cb28873a237748 \+ --hash=sha256:3997b5b3c9a771e157f9aae01dd579ee35ad7109be18db0e85dbdbe1de06e952 \+ --hash=sha256:414802f3b97f3c1eef41e530aaba3b3c1620649871d8cb38c6eaff034c2e16bd \+ --hash=sha256:51c1e14eb1e154ebd80e860722f9e6ed6ec89714ad2db2d3aa33c31d7c12179b \+ --hash=sha256:51c55fe3451421f3a6ef9a9c1439e82101c57a2c9eab9feb196a62b1a10b58ce \+ --hash=sha256:5ee6609ac3604fa7780e30a03e5e241a7956f8e2fcfe547d51e3afa5247ac47f \+ --hash=sha256:612a95a17655e213502f60cfb9bf9408efdc9eb1d5f50535cc6eb365d11b42b5 \+ --hash=sha256:6203fdf9f3dc5bdaed7319ad8698e685c7a3be10819f41d32a0723e611733b42 \+ --hash=sha256:63c0e9e7eea69588479ebf4a8a270d5ac22763cc5854e9a7eae952a3908103f7 \+ --hash=sha256:66f85ce62c70b843bab1fb14a05d5737741e74e28c7b8b5a064de10142fad248 \+ --hash=sha256:6cf9b429b21df6b99f4dee7a1218b8b7ffbbe7df8764dc0bd60ce8a0708fed1e \+ --hash=sha256:70b37199913c1bd300ff6e2693316c6f869c7ee16378faf10e4f5e3275b299c3 \+ --hash=sha256:727fd05b57df37dc0bcf1a27767a3d9a78cbbc92822445f32cc3436ba797337b \+ --hash=sha256:74ae7b798248fe62021dbf3c914245ad45d1a6b0cb4a29ecb4b31d0bfbc4cc3e \+ --hash=sha256:784db1dcdab56bf0517743e746dfb0f885fc68d948aba86eeec2cba234bdf1c0 \+ --hash=sha256:86945f2ee6d10cdfd67bcb4069c1662dd711f7e2a4343db5cecec06b87cf31aa \+ --hash=sha256:86d835afea1eaa143012a2d7a3f45a3adce2d7adc8b4961f0b362214d800846a \+ --hash=sha256:872a5cf366aec6bb1147336480fef14c9164b154aeb6542327de4970282cd2f5 \+ --hash=sha256:8b973c57ff8e184109db042c842423ff4f60446239bd585a5131cc47f06f789d \+ --hash=sha256:8cba086a43d54ca804ce711b2a940b16e452807acebe7852ff327f1ecd49b0d4 \+ --hash=sha256:8f7f0e05112916223d3f438f293abf0727e1181b5983f413dfa2fefc4098245c \+ --hash=sha256:900218e456384ea676e24ea6a0417f030a3b07306d29d7ad843957b40a9d8d52 \+ --hash=sha256:93eebbcf1aafdf7e2ddd44c2923e2672e1010bddc014138b229e49725b4d6be5 \+ --hash=sha256:9c75442b2209b8470d6d5d8b1c25714270686f14c749028d2199c54e29f20b4d \+ --hash=sha256:9ee2197ef8c4f0dfe405d835f3b6a14f5fee7782b5de51ba06fb65fc9b36e9f1 \+ --hash=sha256:a414504bef8945eae5f2d7cb7be2d4af77c5d1cb5e20b296c2c25b61dff2900c \+ --hash=sha256:a4b9159734b326535f4dd01d947f919c6eefd2d9827466a696c44ced82dfbc18 \+ --hash=sha256:a80afd79f45f3c4a7d341f13acbe058d1ca8ac017c165d3fa0d3de6bc1a079d7 \+ --hash=sha256:aa5bc7c5d59d831d9773d1170acac7893ce3a5e130540605770ade83280e7188 \+ --hash=sha256:acfd89508504a19ed06ef963ad544ec6664518c863436306153e13e94605c218 \+ --hash=sha256:aeffcab3d4b43712bb7a60b65f6044d444e75e563ff6180af8f98dd4b905dfd2 \+ --hash=sha256:afaffc4393205524af9dfa400fa250143a6c3bc646c08c9f5e25a9f4b4d6a903 \+ --hash=sha256:b0c7088a73aef3d687c4deef8452a3ac7c1be4e29ed8bf3b366c8111128ac60c \+ --hash=sha256:b46b4ec24f7293f23adcd2d146960559aaf8020213de8ad1909dba6c013bf89c \+ --hash=sha256:b501b5fa195cc9e24fe102f21ec0a44dffc231d2af79950b451e0d99cea02234 \+ --hash=sha256:bf06bc2af43fa8d32d30fae16ad965663e966b1a3202ed407b84c989c3221e82 \+ --hash=sha256:c804e3a5aba5460c73955c955bdbd5c08c354954e9270a2c1565f62e866bdc39 \+ --hash=sha256:c8a9958e88b65c3b27e22ca2a076311636850b612d6bbfb76e8d156aacde2aaf \+ --hash=sha256:cc0a57f895b96ec78969c34f682c602bf8da1a0270b09bc65673df2e7638ec20 \+ --hash=sha256:cc8920d2ec5fa99875b670bb86ddeb21e295cb07aa331810d9e486e0b969d946 \+ --hash=sha256:ccc933afd4d20aad3c00bcef049cb40049f7f196e0397f1109dba6fed63267b0 \+ --hash=sha256:ce581db493ea1a96c0556360ede6607496e8bf9b3a8efa66e06477267bc831e9 \+ --hash=sha256:d0f23b44f57077c1ede8c5f26b30f706498b4862d3ff0a7298b8411dd2f043ff \+ --hash=sha256:d21644de1b609825ede2f48be98dfde4656aefc713654eeee280e37cadc4e0ad \+ --hash=sha256:d6889ec4ec662a1a37eb4b4fb26b6100841804dac55bd9df579e326cdc146227 \+ --hash=sha256:de5672f4a7b200c15a4127042170a694d4df43c992948f5e1af57f0174beed10 \+ --hash=sha256:e6a0bc88393d65807d751a614207b7129a310ca4fe76a74e5c7da5fa5671417e \+ --hash=sha256:ed89927b86296067b4f81f108a2271d8926467a8868e554eaf370fc27fa3ccaf \+ --hash=sha256:ee3888d9ff7c14604052b2ca5535a30216aa0a58e948cdd3eeb8d3415f638769 \+ --hash=sha256:f0963b55cdd70fad460fa4c1341f12f976bb26cb66021a5580329bd498988310 \+ --hash=sha256:f16417ec91f12f814b10bafe79ef77e70113a2f5f7018640e7425ff979253425 \+ --hash=sha256:f28620fe26bee16243be2b7b874da327312240a7cdc38b769a697578d2100013 \+ --hash=sha256:f4255143f5160d0de972d28c8f9665d882b5f61309d8362fdd3e103cf7bf010c \+ --hash=sha256:ffac52f28a7849ad7576293c0cb7b9f08304e8f7d738a8cb8a90ec4c55a998eb \+ --hash=sha256:ffe22d2b05504f786c867c8395de703937f934272eb67586817b46188b4ded6d \+ --hash=sha256:fffe29a1ef00883599d1dc2c51aa2e5d80afe49523c261a74933df395c15c520+ # via -r requirements.indiff --git a/store/agents/autoresearch-mlx/skills/autoresearch-mlx/SKILL.md b/store/agents/autoresearch-mlx/skills/autoresearch-mlx/SKILL.mdnew file mode 100644index 000000000..63a1a97e2--- /dev/null+++ b/store/agents/autoresearch-mlx/skills/autoresearch-mlx/SKILL.md@@ -0,0 +1,19 @@+---+name: autoresearch-mlx+description: Create and inspect science projects in the autoresearch-mlx Harness workspace, including its local starter and optional upstream integration.+---++# Research notebook++Read `studio.json` to understand the current controls; `"$STUDIO_TOOLCHAIN/../studio.config.json"`+describes their ranges. Run `"$STUDIO_TOOLCHAIN/run.sh" train` to make a new result.+Successful artifacts and their measurements are in `out/runs/<id>/`; `out/latest.json` names the+current result. A failed run preserves the last success and records the error in the verdict.++The local starter trains a small character transition model with NumPy on a bundled, original text corpus. It uses real training and held-out cross-entropy, not generated metrics. It is a CPU baseline, distinct from upstream MLX transformer training, which requires Apple Silicon and its prepared dataset.++Use `"$STUDIO_TOOLCHAIN/../README.md"` for the integration contract and commands. Read the relevant+files under `$STUDIO_UPSTREAM` before using an upstream API. Keep controls within their documented+ranges, preserve the data needed to reproduce a comparison, and distinguish preview results from+native service or hardware output. The viewer supports history and artifact downloads; tell the+user which run contains the result, and what was actually measured.diff --git a/store/agents/autoresearch-mlx/store.json b/store/agents/autoresearch-mlx/store.jsonnew file mode 100644index 000000000..08e95cd30--- /dev/null+++ b/store/agents/autoresearch-mlx/store.json@@ -0,0 +1,6 @@+{+ "homepage": "https://github.com/trevin-creator/autoresearch-mlx",+ "upstream": "https://github.com/trevin-creator/autoresearch-mlx",+ "license": "MIT",+ "screenshots": []+}diff --git a/store/agents/autoresearch-mlx/studio.config.json b/store/agents/autoresearch-mlx/studio.config.jsonnew file mode 100644index 000000000..93df0d8ef--- /dev/null+++ b/store/agents/autoresearch-mlx/studio.config.json@@ -0,0 +1,79 @@+{+ "title": "Research notebook",+ "description": "Follow a small idea through a real experiment. Train, compare, and see what the evidence says.",+ "category": "Science",+ "scene": "ONE GOOD QUESTION AT A TIME",+ "hint": "Hover the learning curve \u00b7 compare recent experiments",+ "tip": "Change one thing at a time. The held-out text stays fixed so the comparison means something.",+ "previewLabel": "Run an experiment to measure loss",+ "controls": [+ {+ "id": "learning_rate",+ "label": "Learning rate",+ "type": "number",+ "value": 0.5,+ "min": 0.05,+ "max": 1.5,+ "step": 0.05,+ "integer": false,+ "unit": "",+ "hint": ""+ },+ {+ "id": "steps",+ "label": "Training steps",+ "type": "number",+ "value": 120,+ "min": 20,+ "max": 300,+ "step": 20,+ "integer": false,+ "unit": "",+ "hint": ""+ },+ {+ "id": "context",+ "label": "Context length",+ "type": "number",+ "value": 1,+ "min": 1,+ "max": 3,+ "step": 1,+ "integer": true,+ "unit": "characters",+ "hint": ""+ },+ {+ "id": "seed",+ "label": "Random seed",+ "type": "number",+ "value": 7,+ "min": 1,+ "max": 99,+ "step": 1,+ "integer": true,+ "unit": "",+ "hint": ""+ }+ ],+ "actions": [+ {+ "id": "train",+ "label": "Try an experiment",+ "description": ""+ },+ {+ "id": "mlx",+ "label": "Run MLX experiment",+ "description": "Run upstream train.py on an Apple Silicon machine after data preparation"+ }+ ],+ "credit": "autoresearch-mlx \u00b7 Trevin creator; Andrej Karpathy",+ "empty": "Adjust the controls, then make your first exploration. Every successful run stays in the history.",+ "theme": {+ "accent": "#3d7289",+ "tint": "#e0e9ea",+ "stage": "#152830",+ "stage-accent": "#95d9dd"+ }+}diff --git a/store/agents/autoresearch-mlx/template/holdout.txt b/store/agents/autoresearch-mlx/template/holdout.txtnew file mode 100644index 000000000..c3bb572df--- /dev/null+++ b/store/agents/autoresearch-mlx/template/holdout.txt@@ -0,0 +1,3 @@+the light finds a path through the window. a bird moves across the garden. we watch the water turn.+a new idea begins with a question. we make one change and measure the result. the notebook keeps the evidence.+the small room holds a quiet song. the city waits for morning. a leaf follows the river around a stone.diff --git a/store/agents/autoresearch-mlx/template/studio.json b/store/agents/autoresearch-mlx/template/studio.jsonnew file mode 100644index 000000000..78cee03d2--- /dev/null+++ b/store/agents/autoresearch-mlx/template/studio.json@@ -0,0 +1,10 @@+{+ "spec": 1,+ "title": "Research notebook",+ "parameters": {+ "learning_rate": 0.5,+ "steps": 120,+ "context": 1,+ "seed": 7+ }+}diff --git a/store/agents/autoresearch-mlx/template/train.py b/store/agents/autoresearch-mlx/template/train.pynew file mode 100644index 000000000..7a774be1a--- /dev/null+++ b/store/agents/autoresearch-mlx/template/train.py@@ -0,0 +1,28 @@+"""Editable CPU experiment: fit a character transition model by gradient descent."""+import json+from pathlib import Path+import sys+import numpy as np++def fit(text, p, output):+ vocab=sorted(set(text));index={c:i for i,c in enumerate(vocab)};n=p['context']+ contexts=['']+sorted(set(text[i-n:i] for i in range(n,len(text))))+ rows={c:i for i,c in enumerate(contexts)}+ counts=np.full((len(contexts),len(vocab)),.01)+ for i in range(n,len(text)):+ counts[rows[text[i-n:i]],index[text[i]]]+=1+ counts[0,index[text[i]]]+=1+ targets=counts/counts.sum(axis=1,keepdims=True)+ rng=np.random.default_rng(p['seed']);logits=rng.normal(0,.03,counts.shape)+ curve=[]+ for step in range(p['steps']+1):+ values=np.exp(logits-logits.max(axis=1,keepdims=True));probabilities=values/values.sum(axis=1,keepdims=True)+ if step%10==0 or step==p['steps']:+ loss=float(-(counts*np.log2(probabilities)).sum()/counts.sum())+ curve.append([step,loss])+ logits-=p['learning_rate']*(probabilities-targets)+ np.savez_compressed(output/'model.npz',probabilities=probabilities,contexts=np.array(contexts),vocab=np.array(vocab),context=np.array(n))+ (output/'training.json').write_text(json.dumps({'curve':curve}))++if __name__=='__main__':+ fit(Path('train.txt').read_text(),json.loads(Path('studio.json').read_text())['parameters'],Path(sys.argv[1]))diff --git a/store/agents/autoresearch-mlx/template/train.txt b/store/agents/autoresearch-mlx/template/train.txtnew file mode 100644index 000000000..001c5fcf2--- /dev/null+++ b/store/agents/autoresearch-mlx/template/train.txt@@ -0,0 +1,12 @@+the garden opens in the morning. light moves across the stone wall. a small bird finds a quiet branch.+we make a little room for an idea. we try a shape and watch it change. every experiment leaves a trace.+the river carries a leaf around the bend. the leaf turns slowly in the water. the water finds a way.+a simple song begins with one note. another note answers it. the rhythm moves through the room.+the robot follows a path through the garden. it stops at the wall and finds another path. the map grows.+we measure the result and write it down. a result can surprise us. a careful question makes a better experiment.+the evening light is warm. the windows frame the garden. the room is quiet and the work can wait.+one small change can make a difference. keep the old result and compare the new one. evidence matters.+the city wakes to the sound of a train. people cross the square. the traffic waits for the light.+a seed grows into a tree. a thought grows into a project. a sketch becomes something you can hold.+the studio has a table and a window. on the table there is a notebook. the notebook holds a question.+we leave a little space for a happy accident. we look again. the shape has something new to show us.diff --git a/store/agents/autoresearch-mlx/toolchain/doctor.sh b/store/agents/autoresearch-mlx/toolchain/doctor.shnew file mode 100755index 000000000..c36d70a2c--- /dev/null+++ b/store/agents/autoresearch-mlx/toolchain/doctor.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+test -x .venv/bin/python || { echo 'miss run toolchain/setup.sh to install the local runtime'; exit 1; }+.venv/bin/python -c 'import numpy; import json; json.load(open("studio.config.json")); print("ok autoresearch-mlx local workflow")'+test -f upstream/README.md || { echo "miss pinned upstream sources"; exit 1; }+echo "ok upstream 766a25ff22af"diff --git a/store/agents/autoresearch-mlx/toolchain/init-workspace.sh b/store/agents/autoresearch-mlx/toolchain/init-workspace.shnew file mode 100755index 000000000..ac35ff86d--- /dev/null+++ b/store/agents/autoresearch-mlx/toolchain/init-workspace.sh@@ -0,0 +1,3 @@+#!/usr/bin/env bash+set -euo pipefail+exec "${HARNESS_DSH_DIR:?}/toolchain/run.sh" traindiff --git a/store/agents/autoresearch-mlx/toolchain/run.sh b/store/agents/autoresearch-mlx/toolchain/run.shnew file mode 100755index 000000000..a9e5df771--- /dev/null+++ b/store/agents/autoresearch-mlx/toolchain/run.sh@@ -0,0 +1,6 @@+#!/usr/bin/env bash+set -euo pipefail+studio_package="$(cd "$(dirname "$0")/.." && pwd)"+export PATH="$studio_package/.venv/bin:$PATH"+export PYTHONUNBUFFERED=1+exec "$studio_package/.venv/bin/python" "$studio_package/toolchain/workflow.py" "$@"diff --git a/store/agents/autoresearch-mlx/toolchain/runtimes.sh b/store/agents/autoresearch-mlx/toolchain/runtimes.shnew file mode 100644index 000000000..7223c78dc--- /dev/null+++ b/store/agents/autoresearch-mlx/toolchain/runtimes.sh@@ -0,0 +1,192 @@+# shellcheck shell=bash+# runtimes.sh — the interpreters a store package runs on, found on this machine or fetched, never+# asked of the person who pressed Get.+#+# Sourced (not run) by a package's setup, doctor and viewer scripts. A new Mac has Apple's Python 3.9,+# no Homebrew and, for most people, no Node on PATH; a package that answers "brew install [email protected]"+# has failed its install. So:+#+# harness_node 18 node >= 18 on PATH, with npm: the machine's own, else the Node Harness+# itself runs on (~/.harness/runtime/current-node, laid down with the CLI)+# harness_uv uv on PATH: the machine's own, else a pinned, checksummed release+# fetched into ~/.harness/runtime+# harness_venv DIR 3.12 [MIN [BELOW]]+# DIR is a venv on CPython 3.12, which uv downloads when the machine+# has none. A venv already there on a Python in [MIN, BELOW) is kept.+# harness_pip DIR PKG… install into that venv, through uv+# harness_micromamba micromamba, pinned and checksummed, for native libraries PyPI has+# no wheel for (pycairo on macOS)+# harness_conda_env DIR SPEC… DIR is a conda-forge environment with those packages+#+# Every function prints `miss …` and returns 1 when it cannot deliver, so `harness_node 18 || exit 1`+# reads like the rest of a setup script. Nothing here touches the user's shell profile; what it+# installs lands in ~/.harness/runtime or the package's own directory (uv keeps its download cache+# where it always does, which a venv does not depend on).+#+# ONE copy is written by hand: store/tools/runtimes.sh in the OpenHarness repository. Each package+# carries an identical copy (a package installs alone, so it cannot reach this one);+# `node store/tools/sync-runtimes.mjs` rewrites them and the CLI's store spec fails when one drifts.++HARNESS_RUNTIME="${ADAPTER_RUNTIME_DIR:-${HOME:-}/.harness/runtime}"+# The Pythons uv downloads live with Harness's other runtimes, not in uv's own ~/.local/share/uv:+# a package's venv points at its interpreter, and `uv python uninstall` there must not break it.+UV_PYTHON_INSTALL_DIR="${UV_PYTHON_INSTALL_DIR:-$HARNESS_RUNTIME/python}"+export UV_PYTHON_INSTALL_DIR+HARNESS_UV_VERSION=0.12.15+HARNESS_MICROMAMBA_VERSION=2.9.0-0++_harness_platform() {+ case "$(uname -s)-$(uname -m)" in+ Darwin-arm64) echo darwin-arm64 ;;+ Darwin-x86_64) echo darwin-x64 ;;+ Linux-x86_64) echo linux-x64 ;;+ Linux-aarch64 | Linux-arm64) echo linux-arm64 ;;+ *) return 1 ;;+ esac+}++_harness_sha256() {+ if command -v shasum >/dev/null 2>&1; then shasum -a 256 "$1" | cut -d' ' -f1+ else sha256sum "$1" | cut -d' ' -f1; fi+}++# _harness_fetch URL DEST SHA256 — DEST exists only if what arrived matches the pinned checksum.+_harness_fetch() {+ local part="$2.part.$$"+ if ! curl -fsSL --retry 3 --connect-timeout 20 --max-time 900 -o "$part" "$1"; then+ rm -f "$part"; echo "miss could not download $1 — check this machine's internet connection"; return 1+ fi+ if [ "$(_harness_sha256 "$part")" != "$3" ]; then+ rm -f "$part"; echo "miss $1 did not match its pinned checksum; nothing was installed"; return 1+ fi+ mv -f "$part" "$2"+}++_harness_node_at_least() {+ command -v node >/dev/null 2>&1 || return 1+ node -e '+ const [a, b = 0] = process.argv[1].split(".").map(Number)+ const [x, y] = process.versions.node.split(".").map(Number)+ process.exit(x > a || (x === a && y >= b) ? 0 : 1)+ ' "$1" >/dev/null 2>&1+}++harness_node() {+ local min="${1:-18}" recorded saved="$PATH" own=0+ _harness_node_at_least "$min" && own=1+ # A node without npm beside it (a distro's nodejs package) cannot run a setup's `npm ci`.+ if [ "$own" = 1 ] && command -v npm >/dev/null 2>&1; then return 0; fi+ recorded="$(cat "$HARNESS_RUNTIME/current-node" 2>/dev/null || true)"+ # Already Harness's own (a second call, or a wrapper calling a script that asks again): nothing to add.+ if [ "$own" = 1 ] && [ -n "$recorded" ] && [ "$(command -v node)" = "${recorded%/*}/node" ]; then return 0; fi+ if [ -n "$recorded" ] && [ -x "${recorded%/*}/node" ]; then+ PATH="${recorded%/*}:$PATH"; export PATH; hash -r 2>/dev/null || true+ _harness_node_at_least "$min" && return 0+ PATH="$saved"; export PATH; hash -r 2>/dev/null || true+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min — this machine's newest is $("${recorded%/*}/node" -v), Harness's own; update Harness"+ return 1+ fi+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min, and Harness's own Node is not in $HARNESS_RUNTIME — run \`harness start\` once to lay it down"+ return 1+}++harness_uv() {+ local dir asset sum tmp+ command -v uv >/dev/null 2>&1 && return 0+ for dir in "${HOME:-}/.local/bin" "${HOME:-}/.cargo/bin"; do+ [ -n "${HOME:-}" ] || break+ if [ -x "$dir/uv" ]; then PATH="$dir:$PATH"; export PATH; return 0; fi+ done+ dir="$HARNESS_RUNTIME/uv-$HARNESS_UV_VERSION"+ if [ ! -x "$dir/uv" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=uv-aarch64-apple-darwin sum=dc304b9ed1b24174572290fba60ac3f6fe63c73a671f0439e62a91375841964d ;;+ darwin-x64) asset=uv-x86_64-apple-darwin sum=e9ca61775532368fe518ab03e7a354c7ecab8ccb3c7d941c775fcc4a362b801b ;;+ linux-x64) asset=uv-x86_64-unknown-linux-gnu sum=f97935763c04be3e692460a7aaeaaab8fc3b78fcf8b389da820b38ae7423a638 ;;+ linux-arm64) asset=uv-aarch64-unknown-linux-gnu sum=0e9a3499b0587d449c9ff684c0160da607826e4af1cee220bc87f378702d3e08 ;;+ *) echo "miss uv — there is no uv release for $(uname -s) $(uname -m); install it from https://docs.astral.sh/uv/"; return 1 ;;+ esac+ echo " fetching uv $HARNESS_UV_VERSION into $HARNESS_RUNTIME (it brings Python and the packages)"+ mkdir -p "$HARNESS_RUNTIME" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ tmp="$(mktemp -d "$HARNESS_RUNTIME/.uv.XXXXXX")" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ if ! _harness_fetch "https://github.com/astral-sh/uv/releases/download/$HARNESS_UV_VERSION/$asset.tar.gz" "$tmp/uv.tar.gz" "$sum"; then+ rm -rf "$tmp"; return 1+ fi+ tar -xzf "$tmp/uv.tar.gz" -C "$tmp" && chmod +x "$tmp/$asset/uv" "$tmp/$asset/uvx" \+ || { rm -rf "$tmp"; echo "miss the uv archive would not unpack"; return 1; }+ # Two installs at once both get here; whichever renames first wins and the other's copy goes.+ # (mv onto a directory that exists would nest the copy inside it, hence the test.)+ [ -e "$dir" ] || mv "$tmp/$asset" "$dir" 2>/dev/null || true+ rm -rf "$tmp"+ [ -x "$dir/uv" ] || { echo "miss uv did not land in $dir"; return 1; }+ fi+ PATH="$dir:$PATH"; export PATH+}++# harness_venv DIR VERSION [MIN [BELOW]] — MIN defaults to VERSION; BELOW is exclusive and optional.+harness_venv() {+ local dir="${1:?harness_venv needs a directory}" want="${2:?harness_venv needs a Python version}"+ local min="${3:-$2}" below="${4:-}"+ if [ -x "$dir/bin/python" ] && "$dir/bin/python" -c '+import sys+at = lambda s: tuple(int(p) for p in s.split("."))+v = sys.version_info[:2]+sys.exit(0 if v >= at(sys.argv[1]) and (not sys.argv[2] or v < at(sys.argv[2])) else 1)+' "$min" "$below" 2>/dev/null; then+ echo "ok $("$dir/bin/python" --version) in $dir"+ return 0+ fi+ harness_uv || return 1+ echo " python $want in $dir (uv downloads it when this machine has none)"+ rm -rf "$dir"+ # only-managed: the same python-build-standalone interpreter on every machine, so a package tested+ # once is tested everywhere — not whichever Homebrew or pyenv Python happened to be first on PATH.+ uv venv --quiet --seed --python "$want" --python-preference only-managed "$dir" \+ || { echo "miss could not make a Python $want environment in $dir"; return 1; }+ echo "ok $("$dir/bin/python" --version) in $dir"+}++harness_pip() {+ local dir="${1:?harness_pip needs a venv}"+ shift+ harness_uv || return 1+ # uv's own error comes first; the miss line is last, so it is the line the store shows.+ uv pip install --quiet --python "$dir/bin/python" "$@" \+ || { echo "miss could not install $* into $dir"; return 1; }+}++harness_micromamba() {+ local dir asset sum+ dir="$HARNESS_RUNTIME/micromamba-$HARNESS_MICROMAMBA_VERSION"+ if [ ! -x "$dir/micromamba" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=micromamba-osx-arm64 sum=ec2a072f028e1a7cf20f3e2e74d5a8127cf5a5f27636375b5359811565f4e5be ;;+ darwin-x64) asset=micromamba-osx-64 sum=1e71054bb3ac9a076e21f7ec48acfef536f9b3f1408f371a942784bf5ef83d8a ;;+ linux-x64) asset=micromamba-linux-64 sum=366cd9cd8be14df1ab8ed50352a82111082a36686b2d389fdb79a92c3fafb3e3 ;;+ linux-arm64) asset=micromamba-linux-aarch64 sum=9f93b974adcb4d166996af969b6cd371287d1a3e52733704727884d9b74cb7a7 ;;+ *) echo "miss micromamba — there is no release for $(uname -s) $(uname -m)"; return 1 ;;+ esac+ echo " fetching micromamba $HARNESS_MICROMAMBA_VERSION into $HARNESS_RUNTIME (native libraries PyPI has no wheel for)"+ mkdir -p "$dir" || { echo "miss cannot write $dir"; return 1; }+ _harness_fetch "https://github.com/mamba-org/micromamba-releases/releases/download/$HARNESS_MICROMAMBA_VERSION/$asset" "$dir/micromamba.$$" "$sum" || return 1+ chmod +x "$dir/micromamba.$$" && mv -f "$dir/micromamba.$$" "$dir/micromamba" \+ || { rm -f "$dir/micromamba.$$"; echo "miss micromamba would not install into $dir"; return 1; }+ fi+ HARNESS_MICROMAMBA="$dir/micromamba"+ export HARNESS_MICROMAMBA+}++# harness_conda_env DIR SPEC… — conda-forge only, packages cached under ~/.harness/runtime/mamba.+harness_conda_env() {+ local dir="${1:?harness_conda_env needs a directory}"+ shift+ # micromamba takes a relative --prefix as a name under its root prefix and "succeeds" there.+ case "$dir" in /*) ;; *) dir="$PWD/$dir" ;; esac+ harness_micromamba || return 1+ MAMBA_ROOT_PREFIX="$HARNESS_RUNTIME/mamba" "$HARNESS_MICROMAMBA" create --yes --quiet \+ --prefix "$dir" --override-channels --channel conda-forge "$@" >/dev/null \+ && [ -d "$dir/conda-meta" ] \+ || { echo "miss could not make the conda-forge environment in $dir ($*)"; return 1; }+}diff --git a/store/agents/autoresearch-mlx/toolchain/setup.sh b/store/agents/autoresearch-mlx/toolchain/setup.shnew file mode 100755index 000000000..efbece7e2--- /dev/null+++ b/store/agents/autoresearch-mlx/toolchain/setup.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+harness_venv .venv 3.11 3.11 3.12+.venv/bin/python toolchain/studio_fetch.py+if [ -s requirements.lock ]; then harness_pip .venv --require-hashes -r requirements.lock; fi+exec toolchain/doctor.shdiff --git a/store/agents/autoresearch-mlx/toolchain/studio_fetch.py b/store/agents/autoresearch-mlx/toolchain/studio_fetch.pynew file mode 100644index 000000000..88a670b25--- /dev/null+++ b/store/agents/autoresearch-mlx/toolchain/studio_fetch.py@@ -0,0 +1,34 @@+"""Fetch reviewed source pins without installing a service or changing user configuration."""+import json+import os+from pathlib import Path+import subprocess++root = Path(__file__).resolve().parent.parent+sources = json.loads((root / "upstream.lock.json").read_text())+for source in sources:+ target = root / source["directory"]+ def git(*args):+ return subprocess.check_output(["git", "-C", str(target), *args], text=True,+ env={**os.environ, "GIT_LFS_SKIP_SMUDGE": "1"}).strip()+ if not (target / ".git").exists():+ target.mkdir(parents=True, exist_ok=True)+ git("init", "-q")+ git("remote", "add", "origin", source["url"])+ if source.get("sparse"):+ git("sparse-checkout", "init", "--cone")+ git("sparse-checkout", "set", *source["sparse"])+ if git("remote", "get-url", "origin") != source["url"]:+ raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])+ try:+ current = git("rev-parse", "HEAD")+ except subprocess.CalledProcessError:+ current = ""+ if current != source["commit"]:+ if current and git("status", "--porcelain"):+ raise SystemExit(f"Save your edits in {target} before changing its source pin")+ git("fetch", "--depth", "1", "--filter=blob:none", "origin", source["commit"])+ git("checkout", "--detach", source["commit"])+ print(f'ok {source["name"]} at {source["commit"][:12]}', flush=True)diff --git a/store/agents/autoresearch-mlx/toolchain/studio_runtime.py b/store/agents/autoresearch-mlx/toolchain/studio_runtime.pynew file mode 100644index 000000000..8b8ea016c--- /dev/null+++ b/store/agents/autoresearch-mlx/toolchain/studio_runtime.py@@ -0,0 +1,132 @@+"""Portable runner copied into each independently installable studio package."""+import json+import math+import os+from pathlib import Path+import subprocess+import sys+import tempfile+import time+import uuid+++def workspace():+ return Path(os.environ.get("HARNESS_WORKSPACE", os.getcwd())).resolve()+++def package():+ return Path(__file__).resolve().parent.parent+++def contained(path):+ target = Path(path).resolve()+ target.relative_to(workspace())+ return target+++def atomic_json(path, data):+ path = contained(path)+ path.parent.mkdir(parents=True, exist_ok=True)+ with tempfile.NamedTemporaryFile(mode="w", dir=path.parent, prefix=".studio-", delete=False) as f:+ json.dump(data, f, indent=2, allow_nan=False)+ f.write("\n")+ temp = f.name+ os.replace(temp, path)+++def command(argv, cwd=None, timeout=120, env=None):+ """No shell interpolation; keep complete logs as output, bound execution time."""+ result = subprocess.run([str(x) for x in argv], cwd=cwd, timeout=timeout,+ env=env, text=True, capture_output=True)+ if result.returncode:+ raise RuntimeError((result.stderr or result.stdout)[-1600:] or f"{argv[0]} exited {result.returncode}")+ return result.stdout+++def parameters(config, values):+ if not isinstance(values, dict) or set(values) - {c["id"] for c in config["controls"]}:+ raise ValueError("Invalid studio controls")+ result = {}+ for c in config["controls"]:+ value = values.get(c["id"], c["value"])+ if c["type"] == "number":+ if type(value) not in (int, float) or not math.isfinite(value) or not c["min"] <= value <= c["max"]:+ raise ValueError(f'{c["label"]} is outside its range')+ if c.get("integer") and value != int(value):+ raise ValueError(f'{c["label"]} must be a whole number')+ elif c["type"] == "select":+ if value not in [o["value"] for o in c["options"]]:+ raise ValueError(f'Unknown {c["label"]}')+ elif not isinstance(value, str) or len(value) > c.get("maxLength", 500):+ raise ValueError(f'Invalid {c["label"]}')+ result[c["id"]] = value+ return result+++def metric(label, value, unit=""):+ return {"label": label, "value": value, "unit": unit}+++def previous_runs():+ base = contained(workspace() / "out/runs")+ rows = []+ for p in sorted(base.glob("*/result.json"))[-100:]:+ try:+ rows.append(json.loads(contained(p).read_text()))+ except (ValueError, OSError):+ continue+ return rows+++def execute(actions):+ root = workspace()+ config = json.loads((package() / "studio.config.json").read_text())+ action = sys.argv[1] if len(sys.argv) > 1 else config["actions"][0]["id"]+ started = time.monotonic()+ verdict_path = root / ".harness/verdict.json"+ verdict = {"spec": 1, "ready": False, "summary": "Preparing the studio run", "findings": [],+ "phases": [{"id": "run", "name": "Make", "state": "active"},+ {"id": "inspect", "name": "Inspect", "state": "pending"}]}+ try:+ if action not in actions:+ raise ValueError(f"Unknown action: {action}")+ source = contained(root / "studio.json")+ if source.stat().st_size > 16384:+ raise ValueError("studio.json is too large")+ project = json.loads(source.read_text())+ p = parameters(config, project["parameters"])+ atomic_json(verdict_path, verdict)+ run_id = time.strftime("%Y%m%dT%H%M%S", time.gmtime()) + "-" + uuid.uuid4().hex[:8]+ output = contained(root / "out/runs" / run_id)+ output.mkdir(parents=True)+ print(f'{config["title"]}: {action}', flush=True)+ result = actions[action](p, output)+ artifacts = []+ for artifact in result.pop("files", []):+ file = contained(output / artifact["name"])+ file.relative_to(output)+ if not file.is_file() or not file.stat().st_size:+ raise ValueError(f'Missing output: {artifact["name"]}')+ artifacts.append({"label": artifact["label"], "path": str(file.relative_to(root))})+ result.update({"spec": 1, "id": run_id, "action": action, "parameters": p,+ "createdAt": time.strftime("%Y-%m-%dT%H:%M:%SZ", time.gmtime()),+ "durationSeconds": round(time.monotonic() - started, 3), "artifacts": artifacts,+ "upstream": json.loads((package() / "upstream.lock.json").read_text())})+ atomic_json(output / "result.json", result)+ atomic_json(root / "out/latest.json", result)+ verdict.update({"ready": True, "summary": f'{result["title"]} · {result["engine"]}',+ "artifact": str((output / "result.json").relative_to(root)),+ "phases": [{"id": "run", "name": "Make", "state": "done"},+ {"id": "inspect", "name": "Inspect", "state": "done"}],+ "updatedAt": result["createdAt"]})+ atomic_json(verdict_path, verdict)+ print(f'Ready: {result["title"]}', flush=True)+ except Exception as exc:+ verdict.update({"summary": str(exc)[:500], "findings": [{"severity": "error", "kind": "run-failed", "message": str(exc)[:1000]}],+ "phases": [{"id": "run", "name": "Make", "state": "failed"}]})+ try:+ atomic_json(verdict_path, verdict)+ except (ValueError, OSError):+ pass+ print(str(exc), file=sys.stderr)+ raise SystemExit(1) from excdiff --git a/store/agents/autoresearch-mlx/toolchain/workflow.py b/store/agents/autoresearch-mlx/toolchain/workflow.pynew file mode 100644index 000000000..963f0c3a0--- /dev/null+++ b/store/agents/autoresearch-mlx/toolchain/workflow.py@@ -0,0 +1,62 @@+import hashlib+import json+import math+import platform+import shutil+import sys+import numpy as np+from studio_runtime import execute, metric, command, workspace, package, contained, previous_runs+++def evaluate(model, text):+ probabilities=model['probabilities'];contexts=model['contexts'].tolist();vocab=model['vocab'].tolist();n=int(model['context'])+ if probabilities.shape!=(len(contexts),len(vocab)) or not np.isfinite(probabilities).all() or np.min(probabilities)<=0 or not np.allclose(probabilities.sum(axis=1),1):+ raise ValueError('The saved model has invalid probabilities')+ rows={c:i for i,c in enumerate(contexts)};characters={c:i for i,c in enumerate(vocab)}+ losses=[]+ for i in range(n,len(text)):+ probability=float(probabilities[rows.get(text[i-n:i],0),characters[text[i]]]) if text[i] in characters else 1e-8+ losses.append(-math.log2(probability))+ if not losses:raise ValueError('The held-out text is too short')+ return sum(losses)/len(losses)+++def train(p,out):+ for name in ['train.py','train.txt','holdout.txt']:+ if not contained(workspace()/name).is_file():raise RuntimeError(f'The workspace needs {name}')+ print('Training the CPU experiment…',flush=True)+ command([sys.executable,workspace()/'train.py',out],cwd=workspace(),timeout=90)+ model=np.load(out/'model.npz',allow_pickle=False)+ heldout=(workspace()/'holdout.txt').read_text()+ loss=evaluate(model,heldout)+ training=json.loads((out/'training.json').read_text())+ if not training['curve'] or not all(len(row)==2 and all(math.isfinite(v) for v in row) for row in training['curve']):+ raise ValueError('The training curve is invalid')+ hashes={name:hashlib.sha256((workspace()/name).read_bytes()).hexdigest() for name in ['train.py','train.txt','holdout.txt']}+ prior=[r for r in previous_runs() if r.get('action')=='train' and r.get('data',{}).get('hashes',{}).get('holdout.txt')==hashes['holdout.txt'] and r.get('data',{}).get('hashes',{}).get('train.txt')==hashes['train.txt']]+ best=min([r['data']['heldoutBpc'] for r in prior],default=None)+ delta=loss-best if best is not None else None+ status='First baseline' if best is None else ('New best' if loss<best else 'Keep exploring')+ data={'curve':training['curve'],'heldoutBpc':loss,'previousBest':best,'delta':delta,'hashes':hashes,'status':status}+ (out/'evaluation.json').write_text(json.dumps(data,indent=2,allow_nan=False))+ (out/'learning.csv').write_text('step,training_bits_per_character\n'+'\n'.join(f'{step},{value:.8f}' for step,value in training['curve'])+'\n')+ return {'title':f'{status} · {loss:.3f} bits/char','description':'The saved model was independently evaluated against the unchanged holdout text. One run is a measurement, not a significance test.','engine':'CPU character model · NumPy','metrics':[metric('Held-out loss',round(loss,3),'bits/char'),metric('Training steps',p['steps']),metric('Against best',f'{delta:+.3f}' if delta is not None else 'baseline','bits/char' if delta is not None else '')], 'data':data,+ 'files':[{'label':'Model checkpoint','name':'model.npz'},{'label':'Evaluation record','name':'evaluation.json'},{'label':'Learning curve','name':'learning.csv'}]}+++def mlx(p,out):+ if platform.system()!='Darwin' or platform.machine()!='arm64':+ raise RuntimeError('Upstream MLX needs Apple Silicon. This machine can run the CPU experiment above.')+ root=contained(workspace()/'mlx')+ if not (root/'train.py').is_file() or not (root/'.venv/bin/python').is_file():+ raise RuntimeError('Prepare a workspace mlx/ checkout and its data using the pinned upstream README before a native experiment.')+ print('Running the fixed-budget upstream MLX experiment…',flush=True)+ log=command([root/'.venv/bin/python','train.py'],cwd=root,timeout=600)+ (out/'mlx.log').write_text(log)+ import re+ match=re.search(r'val_bpb:\s*([0-9.]+)',log)+ if not match:raise RuntimeError('MLX did not report val_bpb. Inspect the training output.')+ return {'title':'Native MLX experiment','description':'The upstream training script completed on this Apple Silicon machine. Repeat before treating a small improvement as real.','engine':'Native MLX','metrics':[metric('Validation loss',float(match[1]),'bits/byte')],'data':{},'files':[{'label':'MLX training log','name':'mlx.log'}]}+++if __name__=='__main__':execute({'train':train,'mlx':mlx})diff --git a/store/agents/autoresearch-mlx/upstream.lock.json b/store/agents/autoresearch-mlx/upstream.lock.jsonnew file mode 100644index 000000000..3124c7476--- /dev/null+++ b/store/agents/autoresearch-mlx/upstream.lock.json@@ -0,0 +1,9 @@+[+ {+ "name": "autoresearch-mlx",+ "url": "https://github.com/trevin-creator/autoresearch-mlx.git",+ "commit": "766a25ff22afa799efd8d0aa450a4348e4749df2",+ "directory": "upstream",+ "sparse": []+ }+]diff --git a/store/agents/autoresearch-mlx/view.mjs b/store/agents/autoresearch-mlx/view.mjsnew file mode 100644index 000000000..ce807dab7--- /dev/null+++ b/store/agents/autoresearch-mlx/view.mjs@@ -0,0 +1,20 @@+import {canvas,grid,line,circle,words,toolbar,badge,label} from '/graphics.mjs';+export function mount(stage,api){+ let result,hover=-1,showHoldout=true,p=api.getParameters();+ const info=label(stage,'The interesting part is what actually happened.'),tag=badge(stage,'CPU EXPERIMENT');+ const screen=canvas(stage,(ctx,w,h)=>{+ const left=58,right=w-28,top=52,bottom=h-80,curve=result?.data?.curve;+ if(!curve){grid(ctx,w,h);words(ctx,'An experiment is a question you can measure.',30,h/2,'#b2d8d9',14);return;}+ const values=curve.map(row=>row[1]),held=result.data.heldoutBpc,low=Math.min(...values,held)-.2,high=Math.max(...values,held)+.2,maxStep=curve.at(-1)[0];+ const x=step=>left+step/maxStep*(right-left),y=value=>bottom-(value-low)/(high-low)*(bottom-top);+ for(let i=0;i<5;i++){const value=low+(high-low)*i/4;line(ctx,[[left,y(value)],[right,y(value)]],'#ffffff12',1);words(ctx,value.toFixed(1),19,y(value)+4,'#88a7ab',10);}+ words(ctx,'BITS / CHARACTER',18,26,'#88a7ab',9);for(let i=0;i<5;i++)words(ctx,String(Math.round(maxStep*i/4)),x(maxStep*i/4)-5,bottom+23,'#88a7ab',10);+ const points=curve.map(row=>[x(row[0]),y(row[1])]);ctx.beginPath();ctx.moveTo(left,bottom);points.forEach(pt=>ctx.lineTo(...pt));ctx.lineTo(right,bottom);ctx.closePath();const gradient=ctx.createLinearGradient(0,top,0,bottom);gradient.addColorStop(0,'#9fe1dc30');gradient.addColorStop(1,'#9fe1dc00');ctx.fillStyle=gradient;ctx.fill();line(ctx,points,'#a0e0da',2.5);+ if(showHoldout){ctx.setLineDash([5,5]);line(ctx,[[left,y(held)],[right,y(held)]],'#dfb986',1);ctx.setLineDash([]);words(ctx,'HELD-OUT · FINAL EVALUATION',left+8,y(held)-8,'#dfb986',9);}+ const i=hover>=0?Math.min(hover,curve.length-1):curve.length-1,pt=points[i];circle(ctx,...pt,5,'#a0e0da');circle(ctx,...pt,10,'#a0e0da25');words(ctx,`Step ${curve[i][0]} · ${curve[i][1].toFixed(3)} bits/char`,left,bottom+43,'#c4e9e5',11);+ },api.signal);screen.element.setAttribute('aria-label','Measured training loss curve and final held-out loss');screen.element.tabIndex=0;+ screen.element.addEventListener('pointermove',e=>{if(!result?.data?.curve)return;const b=screen.element.getBoundingClientRect();hover=Math.max(0,Math.min(result.data.curve.length-1,Math.round((e.clientX-b.left-58)/(b.width-86)*(result.data.curve.length-1))));});+ screen.element.addEventListener('keydown',e=>{if(!result?.data?.curve)return;if(e.key==='ArrowLeft'||e.key==='ArrowRight'){hover=Math.max(0,Math.min(result.data.curve.length-1,(hover<0?0:hover)+(e.key==='ArrowRight'?1:-1)));api.announce(`Step ${result.data.curve[hover][0]}, loss ${result.data.curve[hover][1].toFixed(3)}`);e.preventDefault();}});+ toolbar(stage,[['Hide held-out score',b=>{showHoldout=!showHoldout;b.textContent=showHoldout?'Hide held-out score':'Show held-out score';b.setAttribute('aria-pressed',String(showHoldout));}],['Try another seed',()=>api.setParameter('seed',p.seed%99+1)]]);+ return {update(params,r,motion){p=params;result=r;screen.motion(motion);info.textContent=r?.data?.status??'Change one thing. Run. Follow the evidence.';tag.textContent=r?.engine==='Native MLX'?'MLX EXPERIMENT':'CPU EXPERIMENT';}};+}diff --git a/store/agents/bonsai-mcp/.gitignore b/store/agents/bonsai-mcp/.gitignorenew file mode 100644index 000000000..97ed7159a--- /dev/null+++ b/store/agents/bonsai-mcp/.gitignore@@ -0,0 +1,8 @@+upstream/+juce/+.venv/+.build/+.sumo/+__pycache__/+*.pyc+coverage/diff --git a/store/agents/bonsai-mcp/AGENTS.md b/store/agents/bonsai-mcp/AGENTS.mdnew file mode 100644index 000000000..1d3c84f57--- /dev/null+++ b/store/agents/bonsai-mcp/AGENTS.md@@ -0,0 +1,18 @@+# Bonsai MCP workspace++This harness turns a request into a real, inspectable architecture artifact. Start with+the `bonsai-mcp` skill. The editable project is `studio.json` plus files in this workspace.+The viewer follows `out/latest.json` and the run history; save small useful changes as you work.++Run `"$STUDIO_TOOLCHAIN/run.sh" build` after a change. The runner validates controls,+records provenance, writes artifacts, and updates `.harness/verdict.json`. Do not hand-edit the+verdict to claim a run succeeded. Inspect the produced artifact before describing the result.++The local workflow creates and reopens a real IFC4 building with IfcOpenShell, including storeys, slabs, walls, spaces and quantities. The in-pane drawing is a schematic model inspector. It does not certify structural adequacy or code compliance. Blender/Bonsai editing remains available through the pinned optional bridge.++The installed sources are at `$STUDIO_UPSTREAM`. Preserve upstream credit and use the pinned+instructions when extending the domain workflow. Local simulations are the default. Ask before+using a paid generation service or operating physical hardware unless the user already authorized it.++When developing this package itself, keep it independently installable from its folder; shared+runtime copies are synchronized by `store/tools/sync-studios.mjs` and `sync-runtimes.mjs`.diff --git a/store/agents/bonsai-mcp/INTEGRATION.md b/store/agents/bonsai-mcp/INTEGRATION.mdnew file mode 100644index 000000000..1f4e66eb4--- /dev/null+++ b/store/agents/bonsai-mcp/INTEGRATION.md@@ -0,0 +1,12 @@+# Real IFC4 authoring and an optional Bonsai scene snapshot++`build` uses IfcOpenShell to create storeys, slabs, walls, window openings/fillings and spaces with quantities. It reopens `building.ifc` and reads its quantity sets to produce the CSV. The canvas is a schematic inspector; the IFC is the portable source artifact. `bonsai` imports the pinned `BlenderBridgeClient` and sends only `get_scene_info` to the local bridge.++## Verification scope++IFC creation and read-back work headlessly without Blender. The native scene snapshot has isolated local protocol tests; the Blender/Bonsai application itself is optional. Geometry is not a structural or code-compliance assessment.++The browser acceptance suite lives in `store/viewers/studio-viewer/test/studios.e2e.mjs`.+`TESTING.md` beside that viewer records commands, outcomes, screenshots and coverage.+Upstream source revisions are in `upstream.lock.json`; install-time Python dependencies are+hash-locked in `requirements.lock`. No user application configuration is written by setup.diff --git a/store/agents/bonsai-mcp/LICENSE b/store/agents/bonsai-mcp/LICENSEnew file mode 100644index 000000000..a499cd17e--- /dev/null+++ b/store/agents/bonsai-mcp/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Autonomous, Inc.++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/bonsai-mcp/LICENSE-upstream b/store/agents/bonsai-mcp/LICENSE-upstreamnew file mode 100644index 000000000..1d407d88c--- /dev/null+++ b/store/agents/bonsai-mcp/LICENSE-upstream@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Show2Instruct++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/bonsai-mcp/README.md b/store/agents/bonsai-mcp/README.mdnew file mode 100644index 000000000..e7e7466b8--- /dev/null+++ b/store/agents/bonsai-mcp/README.md@@ -0,0 +1,49 @@+# Bonsai MCP · House of ideas++Make room for a new idea. Shape a small building, inspect its spaces, and open the real IFC model anywhere.++```sh+harness dsh install autonomous/bonsai-mcp+```++Open a workspace in Harness. Setup fetches upstream sources at the commit in `upstream.lock.json`,+installs a package-local Python 3.11 environment, and verifies the local tools. The starter runs+without credentials or a cloud account. Studio Viewer provides controls, history, downloads,+live agent updates, and failure recovery. Setup never edits an application's preferences.++## What runs here++The local workflow creates and reopens a real IFC4 building with IfcOpenShell, including storeys, slabs, walls, spaces and quantities. The in-pane drawing is a schematic model inspector. It does not certify structural adequacy or code compliance. Blender/Bonsai editing remains available through the pinned optional bridge.++Edit `studio.json`, then run:++```sh+"$STUDIO_TOOLCHAIN/run.sh" build # Make this building+"$STUDIO_TOOLCHAIN/run.sh" bonsai # Read Bonsai scene+```++The native command is optional and fails with a useful message when its external runtime is+unavailable. It never silently substitutes sample output. Use the upstream README in `upstream/`+for full native application setup. See `INTEGRATION.md` for the exact bridge and local test scope.++Every successful run owns a new folder under `out/runs/`, a `result.json` with parameters, engine,+source commit, timestamps, measured values, and downloadable artifacts. `.harness/verdict.json`+means the named artifact was produced, not that an engineering or aesthetic claim was certified.+The starter can be regenerated with no network after install.++## Development and testing++Install the shared viewer and this package with `harness dsh install <path> --link`.+`toolchain/doctor.sh` checks the local runtime. The repository's Studio Viewer browser suite+materializes temporary workspaces and exercises each shipped local workflow. Run it from+`store/viewers/studio-viewer` with `npm run test:browser`; exact results live in its `TESTING.md`.++## Credit and stewardship++[Bonsai MCP](https://github.com/Show2Instruct/bonsai-mcp) is maintained by Show2Instruct. Its sources are+fetched unchanged at `12cf135f6985cd042a6205c163bdfacdca23de3a`. Upstream licensing: MIT; IfcOpenShell LGPL-3.0.+The original license is preserved in `LICENSE-upstream`; dependency terms still apply.++OpenHarness contributors wrote the MIT wrapper, local starter, and viewer integration. This is+an independent integration, not an upstream endorsement. Upstream bugs belong with the upstream+project; wrapper bugs belong in OpenHarness. Maintainers are welcome to take over this package.diff --git a/store/agents/bonsai-mcp/THIRD_PARTY_NOTICES.md b/store/agents/bonsai-mcp/THIRD_PARTY_NOTICES.mdnew file mode 100644index 000000000..def8b378d--- /dev/null+++ b/store/agents/bonsai-mcp/THIRD_PARTY_NOTICES.md@@ -0,0 +1,9 @@+# Third-party notices++Bonsai MCP — Show2Instruct. https://github.com/Show2Instruct/bonsai-mcp++Pinned source: 12cf135f6985cd042a6205c163bdfacdca23de3a. Fetched at install into ignored `upstream/`, unmodified.+License: MIT; IfcOpenShell LGPL-3.0. See `LICENSE-upstream` and the fetched source tree.++The original local starter and wrapper are MIT licensed. The native runtime and separately+installed applications retain their own licenses. No upstream endorsement is claimed.diff --git a/store/agents/bonsai-mcp/VERSIONS b/store/agents/bonsai-mcp/VERSIONSnew file mode 100644index 000000000..f1bca7013--- /dev/null+++ b/store/agents/bonsai-mcp/VERSIONS@@ -0,0 +1,2 @@+UPSTREAM_COMMIT=12cf135f6985cd042a6205c163bdfacdca23de3a+PYTHON=3.11diff --git a/store/agents/bonsai-mcp/harness.json b/store/agents/bonsai-mcp/harness.jsonnew file mode 100644index 000000000..d73704d07--- /dev/null+++ b/store/agents/bonsai-mcp/harness.json@@ -0,0 +1,33 @@+{+ "spec": 1,+ "id": "autonomous/bonsai-mcp",+ "name": "Bonsai MCP",+ "category": "Architecture",+ "author": "Show2Instruct",+ "description": "Make room for a new idea. Shape a small building, inspect its spaces, and open the real IFC model anywhere.",+ "engine": "codex",+ "workspace": {+ "template": "template",+ "marker": "studio.json",+ "init": "toolchain/init-workspace.sh"+ },+ "agent": {+ "instructions": "AGENTS.md",+ "skills": [+ "skills"+ ],+ "env": {+ "STUDIO_TOOLCHAIN": "${dsh}/toolchain",+ "STUDIO_PYTHON": "${dsh}/.venv/bin/python",+ "STUDIO_UPSTREAM": "${dsh}/upstream"+ }+ },+ "toolchain": {+ "setup": "toolchain/setup.sh",+ "doctor": "toolchain/doctor.sh"+ },+ "viewer": {+ "use": "autonomous/studio-viewer"+ },+ "verdict": ".harness/verdict.json"+}diff --git a/store/agents/bonsai-mcp/requirements.in b/store/agents/bonsai-mcp/requirements.innew file mode 100644index 000000000..7574b0c51--- /dev/null+++ b/store/agents/bonsai-mcp/requirements.in@@ -0,0 +1,3 @@+ifcopenshell==0.8.5+numpy==2.3.5+pydantic==2.12.5diff --git a/store/agents/bonsai-mcp/requirements.lock b/store/agents/bonsai-mcp/requirements.locknew file mode 100644index 000000000..7615933ab--- /dev/null+++ b/store/agents/bonsai-mcp/requirements.lock@@ -0,0 +1,326 @@+# This file was autogenerated by uv via the following command:+# uv pip compile requirements.in --python-version 3.11 --universal --generate-hashes -o requirements.lock+annotated-types==0.8.0 \+ --hash=sha256:13b2beaad985e05e2d6407ee4c4f35590b11f8d693a258a561055cac8f64cab7 \+ --hash=sha256:f072f4d804ea359e4eaf198b1af7a8b0943881a87f31bb764f8bf219bb9419e0+ # via pydantic+ifcopenshell==0.8.5 \+ --hash=sha256:005dced5aaa45064e73287c75ed9cf5f8ba54bce80c496fd76404313833cd62e \+ --hash=sha256:13a5992dc07e69c0c78df5479e1ff9635e6ce9fa70c841d9ce2931e8481eabb9 \+ --hash=sha256:15b488347efce0d7f5ab5b6d5561cf30428353b6ee8c7c8a53724f4b10ad4ac6 \+ --hash=sha256:233e2afd81456ac278f2dd21360c509999498d0b8dc207230eb05e3063f87860 \+ --hash=sha256:38f63e13cf326b195e2b9ac4ed45396cdda9b3ad29318ce04d7c4a401f7a3921 \+ --hash=sha256:3b1c5a2ea655d96914ddafd258aa6183f29fb7a08b2b10a329b204b8deca7226 \+ --hash=sha256:487189a6a70f9c688ae58efa075312d0dbba3e83839abaafbfe669bbfdb66e2a \+ --hash=sha256:612e955ab0975bbc4134fe26c4c36d71a12525fd5c4b391573e6df3cd81713ec \+ --hash=sha256:6dd40d29b21d1c92104a4585a1ee6a31811305b68f5e3f7ee991f89f4d386366 \+ --hash=sha256:7927921dbfd18024f44780880c37e48460bbca7476da3b0c2607e044b31521d5 \+ --hash=sha256:7dba9a0348600bd59ceb9222333e493b9b1c49fc69251a73bc707e77a445007d \+ --hash=sha256:86b60a3fba3c5b3c5a152a71b1a5038a78384fcaa0bab61297bf363c8bedd325 \+ --hash=sha256:89e60dbe8ea7014174ab332b6caad25465c446c118a896435f594ab24602a10a \+ --hash=sha256:8cf1f7fd49367aeba75eb56682f1454b2f353a979c6111a165bc05bc62148600 \+ --hash=sha256:8de53ba37e762f2e2ba7cf502f15504b886233f681c30245ae7b4ed82087445d \+ --hash=sha256:9444ed9b924eaa76037653c56261098846bffa2f4732eefa8b83687163addecd \+ --hash=sha256:a5183ae0431a9b87d89ca2e880dae986e4140f088293c3872a88ed3177e7308d \+ --hash=sha256:a994cb398aa822b0153ace11fc19deea108706d3a10339de9ac9dc13da21076d \+ --hash=sha256:ba916b73a1dd011abeee564b2bb0027c3dc679d77733d44f2f38009b70d413b5 \+ --hash=sha256:beb9e761ea9b6678c5edff4d6ab31e40a771fffca3bc295810045de564f1b018 \+ --hash=sha256:c03c47abbfd0afddcbc91b510d984d7c017a222877460da5e0a6496d89f185e4 \+ --hash=sha256:dd154b121815e25bc4890f030bf2bdd8d99b059448e0d1205ac81388a3d321f4 \+ --hash=sha256:e568a859b489ba43013795c3d682758d1ee905fe08919d2c96b5c5676167b243 \+ --hash=sha256:f8abac2bd3a3eb11009beb290834d8a5a2330d59a8600dede0faf7ddf8a8f16f \+ --hash=sha256:f9e35e2df5397c795b320421192fcdb006573d1b36524f420d2474a4f9d842cf+ # via -r requirements.in+isodate==0.7.2 \+ --hash=sha256:28009937d8031054830160fce6d409ed342816b543597cece116d966c6d99e15 \+ --hash=sha256:4cd1aa0f43ca76f4a6c6c0292a85f40b35ec2e43e315b59f06e6d32171a953e6+ # via ifcopenshell+lark==1.3.1 \+ --hash=sha256:b426a7a6d6d53189d318f2b6236ab5d6429eaf09259f1ca33eb716eed10d2905 \+ --hash=sha256:c629b661023a014c37da873b4ff58a817398d12635d3bbb2c5a03be7fe5d1e12+ # via ifcopenshell+numpy==2.3.5 \+ --hash=sha256:00dc4e846108a382c5869e77c6ed514394bdeb3403461d25a829711041217d5b \+ --hash=sha256:0472f11f6ec23a74a906a00b48a4dcf3849209696dff7c189714511268d103ae \+ --hash=sha256:04822c00b5fd0323c8166d66c701dc31b7fbd252c100acd708c48f763968d6a3 \+ --hash=sha256:052e8c42e0c49d2575621c158934920524f6c5da05a1d3b9bab5d8e259e045f0 \+ --hash=sha256:09a1bea522b25109bf8e6f3027bd810f7c1085c64a0c7ce050c1676ad0ba010b \+ --hash=sha256:0cd00b7b36e35398fa2d16af7b907b65304ef8bb4817a550e06e5012929830fa \+ --hash=sha256:0d8163f43acde9a73c2a33605353a4f1bc4798745a8b1d73183b28e5b435ae28 \+ --hash=sha256:1062fde1dcf469571705945b0f221b73928f34a20c904ffb45db101907c3454e \+ --hash=sha256:11e06aa0af8c0f05104d56450d6093ee639e15f24ecf62d417329d06e522e017 \+ --hash=sha256:17531366a2e3a9e30762c000f2c43a9aaa05728712e25c11ce1dbe700c53ad41 \+ --hash=sha256:1978155dd49972084bd6ef388d66ab70f0c323ddee6f693d539376498720fb7e \+ --hash=sha256:1ed1ec893cff7040a02c8aa1c8611b94d395590d553f6b53629a4461dc7f7b63 \+ --hash=sha256:2dcd0808a421a482a080f89859a18beb0b3d1e905b81e617a188bd80422d62e9 \+ --hash=sha256:2e2eb32ddb9ccb817d620ac1d8dae7c3f641c1e5f55f531a33e8ab97960a75b8 \+ --hash=sha256:2feae0d2c91d46e59fcd62784a3a83b3fb677fead592ce51b5a6fbb4f95965ff \+ --hash=sha256:3095bdb8dd297e5920b010e96134ed91d852d81d490e787beca7e35ae1d89cf7 \+ --hash=sha256:30bc11310e8153ca664b14c5f1b73e94bd0503681fcf136a163de856f3a50139 \+ --hash=sha256:3101e5177d114a593d79dd79658650fe28b5a0d8abeb8ce6f437c0e6df5be1a4 \+ --hash=sha256:396084a36abdb603546b119d96528c2f6263921c50df3c8fd7cb28873a237748 \+ --hash=sha256:3997b5b3c9a771e157f9aae01dd579ee35ad7109be18db0e85dbdbe1de06e952 \+ --hash=sha256:414802f3b97f3c1eef41e530aaba3b3c1620649871d8cb38c6eaff034c2e16bd \+ --hash=sha256:51c1e14eb1e154ebd80e860722f9e6ed6ec89714ad2db2d3aa33c31d7c12179b \+ --hash=sha256:51c55fe3451421f3a6ef9a9c1439e82101c57a2c9eab9feb196a62b1a10b58ce \+ --hash=sha256:5ee6609ac3604fa7780e30a03e5e241a7956f8e2fcfe547d51e3afa5247ac47f \+ --hash=sha256:612a95a17655e213502f60cfb9bf9408efdc9eb1d5f50535cc6eb365d11b42b5 \+ --hash=sha256:6203fdf9f3dc5bdaed7319ad8698e685c7a3be10819f41d32a0723e611733b42 \+ --hash=sha256:63c0e9e7eea69588479ebf4a8a270d5ac22763cc5854e9a7eae952a3908103f7 \+ --hash=sha256:66f85ce62c70b843bab1fb14a05d5737741e74e28c7b8b5a064de10142fad248 \+ --hash=sha256:6cf9b429b21df6b99f4dee7a1218b8b7ffbbe7df8764dc0bd60ce8a0708fed1e \+ --hash=sha256:70b37199913c1bd300ff6e2693316c6f869c7ee16378faf10e4f5e3275b299c3 \+ --hash=sha256:727fd05b57df37dc0bcf1a27767a3d9a78cbbc92822445f32cc3436ba797337b \+ --hash=sha256:74ae7b798248fe62021dbf3c914245ad45d1a6b0cb4a29ecb4b31d0bfbc4cc3e \+ --hash=sha256:784db1dcdab56bf0517743e746dfb0f885fc68d948aba86eeec2cba234bdf1c0 \+ --hash=sha256:86945f2ee6d10cdfd67bcb4069c1662dd711f7e2a4343db5cecec06b87cf31aa \+ --hash=sha256:86d835afea1eaa143012a2d7a3f45a3adce2d7adc8b4961f0b362214d800846a \+ --hash=sha256:872a5cf366aec6bb1147336480fef14c9164b154aeb6542327de4970282cd2f5 \+ --hash=sha256:8b973c57ff8e184109db042c842423ff4f60446239bd585a5131cc47f06f789d \+ --hash=sha256:8cba086a43d54ca804ce711b2a940b16e452807acebe7852ff327f1ecd49b0d4 \+ --hash=sha256:8f7f0e05112916223d3f438f293abf0727e1181b5983f413dfa2fefc4098245c \+ --hash=sha256:900218e456384ea676e24ea6a0417f030a3b07306d29d7ad843957b40a9d8d52 \+ --hash=sha256:93eebbcf1aafdf7e2ddd44c2923e2672e1010bddc014138b229e49725b4d6be5 \+ --hash=sha256:9c75442b2209b8470d6d5d8b1c25714270686f14c749028d2199c54e29f20b4d \+ --hash=sha256:9ee2197ef8c4f0dfe405d835f3b6a14f5fee7782b5de51ba06fb65fc9b36e9f1 \+ --hash=sha256:a414504bef8945eae5f2d7cb7be2d4af77c5d1cb5e20b296c2c25b61dff2900c \+ --hash=sha256:a4b9159734b326535f4dd01d947f919c6eefd2d9827466a696c44ced82dfbc18 \+ --hash=sha256:a80afd79f45f3c4a7d341f13acbe058d1ca8ac017c165d3fa0d3de6bc1a079d7 \+ --hash=sha256:aa5bc7c5d59d831d9773d1170acac7893ce3a5e130540605770ade83280e7188 \+ --hash=sha256:acfd89508504a19ed06ef963ad544ec6664518c863436306153e13e94605c218 \+ --hash=sha256:aeffcab3d4b43712bb7a60b65f6044d444e75e563ff6180af8f98dd4b905dfd2 \+ --hash=sha256:afaffc4393205524af9dfa400fa250143a6c3bc646c08c9f5e25a9f4b4d6a903 \+ --hash=sha256:b0c7088a73aef3d687c4deef8452a3ac7c1be4e29ed8bf3b366c8111128ac60c \+ --hash=sha256:b46b4ec24f7293f23adcd2d146960559aaf8020213de8ad1909dba6c013bf89c \+ --hash=sha256:b501b5fa195cc9e24fe102f21ec0a44dffc231d2af79950b451e0d99cea02234 \+ --hash=sha256:bf06bc2af43fa8d32d30fae16ad965663e966b1a3202ed407b84c989c3221e82 \+ --hash=sha256:c804e3a5aba5460c73955c955bdbd5c08c354954e9270a2c1565f62e866bdc39 \+ --hash=sha256:c8a9958e88b65c3b27e22ca2a076311636850b612d6bbfb76e8d156aacde2aaf \+ --hash=sha256:cc0a57f895b96ec78969c34f682c602bf8da1a0270b09bc65673df2e7638ec20 \+ --hash=sha256:cc8920d2ec5fa99875b670bb86ddeb21e295cb07aa331810d9e486e0b969d946 \+ --hash=sha256:ccc933afd4d20aad3c00bcef049cb40049f7f196e0397f1109dba6fed63267b0 \+ --hash=sha256:ce581db493ea1a96c0556360ede6607496e8bf9b3a8efa66e06477267bc831e9 \+ --hash=sha256:d0f23b44f57077c1ede8c5f26b30f706498b4862d3ff0a7298b8411dd2f043ff \+ --hash=sha256:d21644de1b609825ede2f48be98dfde4656aefc713654eeee280e37cadc4e0ad \+ --hash=sha256:d6889ec4ec662a1a37eb4b4fb26b6100841804dac55bd9df579e326cdc146227 \+ --hash=sha256:de5672f4a7b200c15a4127042170a694d4df43c992948f5e1af57f0174beed10 \+ --hash=sha256:e6a0bc88393d65807d751a614207b7129a310ca4fe76a74e5c7da5fa5671417e \+ --hash=sha256:ed89927b86296067b4f81f108a2271d8926467a8868e554eaf370fc27fa3ccaf \+ --hash=sha256:ee3888d9ff7c14604052b2ca5535a30216aa0a58e948cdd3eeb8d3415f638769 \+ --hash=sha256:f0963b55cdd70fad460fa4c1341f12f976bb26cb66021a5580329bd498988310 \+ --hash=sha256:f16417ec91f12f814b10bafe79ef77e70113a2f5f7018640e7425ff979253425 \+ --hash=sha256:f28620fe26bee16243be2b7b874da327312240a7cdc38b769a697578d2100013 \+ --hash=sha256:f4255143f5160d0de972d28c8f9665d882b5f61309d8362fdd3e103cf7bf010c \+ --hash=sha256:ffac52f28a7849ad7576293c0cb7b9f08304e8f7d738a8cb8a90ec4c55a998eb \+ --hash=sha256:ffe22d2b05504f786c867c8395de703937f934272eb67586817b46188b4ded6d \+ --hash=sha256:fffe29a1ef00883599d1dc2c51aa2e5d80afe49523c261a74933df395c15c520+ # via+ # -r requirements.in+ # ifcopenshell+ # shapely+pydantic==2.12.5 \+ --hash=sha256:4d351024c75c0f085a9febbb665ce8c0c6ec5d30e903bdb6394b7ede26aebb49 \+ --hash=sha256:e561593fccf61e8a20fc46dfc2dfe075b8be7d0188df33f221ad1f0139180f9d+ # via -r requirements.in+pydantic-core==2.41.5 \+ --hash=sha256:0177272f88ab8312479336e1d777f6b124537d47f2123f89cb37e0accea97f90 \+ --hash=sha256:01a3d0ab748ee531f4ea6c3e48ad9dac84ddba4b0d82291f87248f2f9de8d740 \+ --hash=sha256:0384e2e1021894b1ff5a786dbf94771e2986ebe2869533874d7e43bc79c6f504 \+ --hash=sha256:03b77d184b9eb40240ae9fd676ca364ce1085f203e1b1256f8ab9984dca80a84 \+ --hash=sha256:03ca43e12fab6023fc79d28ca6b39b05f794ad08ec2feccc59a339b02f2b3d33 \+ --hash=sha256:05a2c8852530ad2812cb7914dc61a1125dc4e06252ee98e5638a12da6cc6fb6c \+ --hash=sha256:070259a8818988b9a84a449a2a7337c7f430a22acc0859c6b110aa7212a6d9c0 \+ --hash=sha256:08daa51ea16ad373ffd5e7606252cc32f07bc72b28284b6bc9c6df804816476e \+ --hash=sha256:0cbaad15cb0c90aa221d43c00e77bb33c93e8d36e0bf74760cd00e732d10a6a0 \+ --hash=sha256:100baa204bb412b74fe285fb0f3a385256dad1d1879f0a5cb1499ed2e83d132a \+ --hash=sha256:112e305c3314f40c93998e567879e887a3160bb8689ef3d2c04b6cc62c33ac34 \+ --hash=sha256:16f80f7abe3351f8ea6858914ddc8c77e02578544a0ebc15b4c2e1a0e813b0b2 \+ --hash=sha256:1746d4a3d9a794cacae06a5eaaccb4b8643a131d45fbc9af23e353dc0a5ba5c3 \+ --hash=sha256:1962293292865bca8e54702b08a4f26da73adc83dd1fcf26fbc875b35d81c815 \+ --hash=sha256:1d1d9764366c73f996edd17abb6d9d7649a7eb690006ab6adbda117717099b14 \+ --hash=sha256:1f8d33a7f4d5a7889e60dc39856d76d09333d8a6ed0f5f1190635cbec70ec4ba \+ --hash=sha256:22f0fb8c1c583a3b6f24df2470833b40207e907b90c928cc8d3594b76f874375 \+ --hash=sha256:239edca560d05757817c13dc17c50766136d21f7cd0fac50295499ae24f90fdf \+ --hash=sha256:242a206cd0318f95cd21bdacff3fcc3aab23e79bba5cac3db5a841c9ef9c6963 \+ --hash=sha256:25e1c2af0fce638d5f1988b686f3b3ea8cd7de5f244ca147c777769e798a9cd1 \+ --hash=sha256:266fb4cbf5e3cbd0b53669a6d1b039c45e3ce651fd5442eff4d07c2cc8d66808 \+ --hash=sha256:2782c870e99878c634505236d81e5443092fba820f0373997ff75f90f68cd553 \+ --hash=sha256:287dad91cfb551c363dc62899a80e9e14da1f0e2b6ebde82c806612ca2a13ef1 \+ --hash=sha256:29452c56df2ed968d18d7e21f4ab0ac55e71dc59524872f6fc57dcf4a3249ed2 \+ --hash=sha256:299e0a22e7ae2b85c1a57f104538b2656e8ab1873511fd718a1c1c6f149b77b5 \+ --hash=sha256:2a5e06546e19f24c6a96a129142a75cee553cc018ffee48a460059b1185f4470 \+ --hash=sha256:2b761d210c9ea91feda40d25b4efe82a1707da2ef62901466a42492c028553a2 \+ --hash=sha256:2c010c6ded393148374c0f6f0bf89d206bf3217f201faa0635dcd56bd1520f6b \+ --hash=sha256:2ff4321e56e879ee8d2a879501c8e469414d948f4aba74a2d4593184eb326660 \+ --hash=sha256:3006c3dd9ba34b0c094c544c6006cc79e87d8612999f1a5d43b769b89181f23c \+ --hash=sha256:33cb885e759a705b426baada1fe68cbb0a2e68e34c5d0d0289a364cf01709093 \+ --hash=sha256:346285d28e4c8017da95144c7f3acd42740d637ff41946af5ce6e5e420502dd5 \+ --hash=sha256:34a64bc3441dc1213096a20fe27e8e128bd3ff89921706e83c0b1ac971276594 \+ --hash=sha256:35b44f37a3199f771c3eaa53051bc8a70cd7b54f333531c59e29fd4db5d15008 \+ --hash=sha256:378bec5c66998815d224c9ca994f1e14c0c21cb95d2f52b6021cc0b2a58f2a5a \+ --hash=sha256:3f37a19d7ebcdd20b96485056ba9e8b304e27d9904d233d7b1015db320e51f0a \+ --hash=sha256:3f84d5c1b4ab906093bdc1ff10484838aca54ef08de4afa9de0f5f14d69639cd \+ --hash=sha256:4009935984bd36bd2c774e13f9a09563ce8de4abaa7226f5108262fa3e637284 \+ --hash=sha256:406bf18d345822d6c21366031003612b9c77b3e29ffdb0f612367352aab7d586 \+ --hash=sha256:4819fa52133c9aa3c387b3328f25c1facc356491e6135b459f1de698ff64d869 \+ --hash=sha256:482c982f814460eabe1d3bb0adfdc583387bd4691ef00b90575ca0d2b6fe2294 \+ --hash=sha256:4bc36bbc0b7584de96561184ad7f012478987882ebf9f9c389b23f432ea3d90f \+ --hash=sha256:506d766a8727beef16b7adaeb8ee6217c64fc813646b424d0804d67c16eddb66 \+ --hash=sha256:56121965f7a4dc965bff783d70b907ddf3d57f6eba29b6d2e5dabfaf07799c51 \+ --hash=sha256:58133647260ea01e4d0500089a8c4f07bd7aa6ce109682b1426394988d8aaacc \+ --hash=sha256:5921a4d3ca3aee735d9fd163808f5e8dd6c6972101e4adbda9a4667908849b97 \+ --hash=sha256:5a4e67afbc95fa5c34cf27d9089bca7fcab4e51e57278d710320a70b956d1b9a \+ --hash=sha256:5cb1b2f9742240e4bb26b652a5aeb840aa4b417c7748b6f8387927bc6e45e40d \+ --hash=sha256:62de39db01b8d593e45871af2af9e497295db8d73b085f6bfd0b18c83c70a8f9 \+ --hash=sha256:634e8609e89ceecea15e2d61bc9ac3718caaaa71963717bf3c8f38bfde64242c \+ --hash=sha256:63510af5e38f8955b8ee5687740d6ebf7c2a0886d15a6d65c32814613681bc07 \+ --hash=sha256:650ae77860b45cfa6e2cdafc42618ceafab3a2d9a3811fcfbd3bbf8ac3c40d36 \+ --hash=sha256:6561e94ba9dacc9c61bce40e2d6bdc3bfaa0259d3ff36ace3b1e6901936d2e3e \+ --hash=sha256:65840751b72fbfd82c3c640cff9284545342a4f1eb1586ad0636955b261b0b05 \+ --hash=sha256:6cb58b9c66f7e4179a2d5e0f849c48eff5c1fca560994d6eb6543abf955a149e \+ --hash=sha256:6f52298fbd394f9ed112d56f3d11aabd0d5bd27beb3084cc3d8ad069483b8941 \+ --hash=sha256:707625ef0983fcfb461acfaf14de2067c5942c6bb0f3b4c99158bed6fedd3cf3 \+ --hash=sha256:72f6c8b11857a856bcfa48c86f5368439f74453563f951e473514579d44aa612 \+ --hash=sha256:753e230374206729bf0a807954bcc6c150d3743928a73faffee51ac6557a03c3 \+ --hash=sha256:76d0819de158cd855d1cbb8fcafdf6f5cf1eb8e470abe056d5d161106e38062b \+ --hash=sha256:76ee27c6e9c7f16f47db7a94157112a2f3a00e958bc626e2f4ee8bec5c328fbe \+ --hash=sha256:77b63866ca88d804225eaa4af3e664c5faf3568cea95360d21f4725ab6e07146 \+ --hash=sha256:79ec52ec461e99e13791ec6508c722742ad745571f234ea6255bed38c6480f11 \+ --hash=sha256:7b93a4d08587e2b7e7882de461e82b6ed76d9026ce91ca7915e740ecc7855f60 \+ --hash=sha256:7da7087d756b19037bc2c06edc6c170eeef3c3bafcb8f532ff17d64dc427adfd \+ --hash=sha256:7f3bf998340c6d4b0c9a2f02d6a400e51f123b59565d74dc60d252ce888c260b \+ --hash=sha256:80aa89cad80b32a912a65332f64a4450ed00966111b6615ca6816153d3585a8c \+ --hash=sha256:8566def80554c3faa0e65ac30ab0932b9e3a5cd7f8323764303d468e5c37595a \+ --hash=sha256:873e0d5b4fb9b89ef7c2d2a963ea7d02879d9da0da8d9d4933dee8ee86a8b460 \+ --hash=sha256:88942d3a3dff3afc8288c21e565e476fc278902ae4d6d134f1eeda118cc830b1 \+ --hash=sha256:8bfeaf8735be79f225f3fefab7f941c712aaca36f1128c9d7e2352ee1aa87bdf \+ --hash=sha256:8e7c86f27c585ef37c35e56a96363ab8de4e549a95512445b85c96d3e2f7c1bf \+ --hash=sha256:915c3d10f81bec3a74fbd4faebe8391013ba61e5a1a8d48c4455b923bdda7858 \+ --hash=sha256:93e8740d7503eb008aa2df04d3b9735f845d43ae845e6dcd2be0b55a2da43cd2 \+ --hash=sha256:941103c9be18ac8daf7b7adca8228f8ed6bb7a1849020f643b3a14d15b1924d9 \+ --hash=sha256:97aeba56665b4c3235a0e52b2c2f5ae9cd071b8a8310ad27bddb3f7fb30e9aa2 \+ --hash=sha256:a39455728aabd58ceabb03c90e12f71fd30fa69615760a075b9fec596456ccc3 \+ --hash=sha256:a3a52f6156e73e7ccb0f8cced536adccb7042be67cb45f9562e12b319c119da6 \+ --hash=sha256:a668ce24de96165bb239160b3d854943128f4334822900534f2fe947930e5770 \+ --hash=sha256:a75dafbf87d6276ddc5b2bf6fae5254e3d0876b626eb24969a574fff9149ee5d \+ --hash=sha256:aabf5777b5c8ca26f7824cb4a120a740c9588ed58df9b2d196ce92fba42ff8dc \+ --hash=sha256:aec5cf2fd867b4ff45b9959f8b20ea3993fc93e63c7363fe6851424c8a7e7c23 \+ --hash=sha256:b2379fa7ed44ddecb5bfe4e48577d752db9fc10be00a6b7446e9663ba143de26 \+ --hash=sha256:b4ececa40ac28afa90871c2cc2b9ffd2ff0bf749380fbdf57d165fd23da353aa \+ --hash=sha256:b5819cd790dbf0c5eb9f82c73c16b39a65dd6dd4d1439dcdea7816ec9adddab8 \+ --hash=sha256:b74557b16e390ec12dca509bce9264c3bbd128f8a2c376eaa68003d7f327276d \+ --hash=sha256:b80aa5095cd3109962a298ce14110ae16b8c1aece8b72f9dafe81cf597ad80b3 \+ --hash=sha256:b93590ae81f7010dbe380cdeab6f515902ebcbefe0b9327cc4804d74e93ae69d \+ --hash=sha256:b96d5f26b05d03cc60f11a7761a5ded1741da411e7fe0909e27a5e6a0cb7b034 \+ --hash=sha256:bd3d54f38609ff308209bd43acea66061494157703364ae40c951f83ba99a1a9 \+ --hash=sha256:bfea2a5f0b4d8d43adf9d7b8bf019fb46fdd10a2e5cde477fbcb9d1fa08c68e1 \+ --hash=sha256:c007fe8a43d43b3969e8469004e9845944f1a80e6acd47c150856bb87f230c56 \+ --hash=sha256:c1df3d34aced70add6f867a8cf413e299177e0c22660cc767218373d0779487b \+ --hash=sha256:c23e27686783f60290e36827f9c626e63154b82b116d7fe9adba1fda36da706c \+ --hash=sha256:c8d8b4eb992936023be7dee581270af5c6e0697a8559895f527f5b7105ecd36a \+ --hash=sha256:c9e19dd6e28fdcaa5a1de679aec4141f691023916427ef9bae8584f9c2fb3b0e \+ --hash=sha256:d0d2568a8c11bf8225044aa94409e21da0cb09dcdafe9ecd10250b2baad531a9 \+ --hash=sha256:d38548150c39b74aeeb0ce8ee1d8e82696f4a4e16ddc6de7b1d8823f7de4b9b5 \+ --hash=sha256:d3a978c4f57a597908b7e697229d996d77a6d3c94901e9edee593adada95ce1a \+ --hash=sha256:d5160812ea7a8a2ffbe233d8da666880cad0cbaf5d4de74ae15c313213d62556 \+ --hash=sha256:dc799088c08fa04e43144b164feb0c13f9a0bc40503f8df3e9fde58a3c0c101e \+ --hash=sha256:df3959765b553b9440adfd3c795617c352154e497a4eaf3752555cfb5da8fc49 \+ --hash=sha256:dfa8a0c812ac681395907e71e1274819dec685fec28273a28905df579ef137e2 \+ --hash=sha256:e25c479382d26a2a41b7ebea1043564a937db462816ea07afa8a44c0866d52f9 \+ --hash=sha256:e4f4a984405e91527a0d62649ee21138f8e3d0ef103be488c1dc11a80d7f184b \+ --hash=sha256:e536c98a7626a98feb2d3eaf75944ef6f3dbee447e1f841eae16f2f0a72d8ddc \+ --hash=sha256:e56ba91f47764cc14f1daacd723e3e82d1a89d783f0f5afe9c364b8bb491ccdb \+ --hash=sha256:e672ba74fbc2dc8eea59fb6d4aed6845e6905fc2a8afe93175d94a83ba2a01a0 \+ --hash=sha256:e7b576130c69225432866fe2f4a469a85a54ade141d96fd396dffcf607b558f8 \+ --hash=sha256:e8465ab91a4bd96d36dde3263f06caa6a8a6019e4113f24dc753d79a8b3a3f82 \+ --hash=sha256:e96cea19e34778f8d59fe40775a7a574d95816eb150850a85a7a4c8f4b94ac69 \+ --hash=sha256:ece5c59f0ce7d001e017643d8d24da587ea1f74f6993467d85ae8a5ef9d4f42b \+ --hash=sha256:eceb81a8d74f9267ef4081e246ffd6d129da5d87e37a77c9bde550cb04870c1c \+ --hash=sha256:ed2e99c456e3fadd05c991f8f437ef902e00eedf34320ba2b0842bd1c3ca3a75 \+ --hash=sha256:f0cd744688278965817fd0839c4a4116add48d23890d468bc436f78beb28abf5 \+ --hash=sha256:f14f8f046c14563f8eb3f45f499cc658ab8d10072961e07225e507adb700e93f \+ --hash=sha256:f15489ba13d61f670dcc96772e733aad1a6f9c429cc27574c6cdaed82d0146ad \+ --hash=sha256:f31d95a179f8d64d90f6831d71fa93290893a33148d890ba15de25642c5d075b \+ --hash=sha256:f41a7489d32336dbf2199c8c0a215390a751c5b014c2c1c5366e817202e9cdf7 \+ --hash=sha256:f41eb9797986d6ebac5e8edff36d5cef9de40def462311b3eb3eeded1431e425 \+ --hash=sha256:f547144f2966e1e16ae626d8ce72b4cfa0caedc7fa28052001c94fb2fcaa1c52+ # via pydantic+python-dateutil==2.9.0.post0 \+ --hash=sha256:37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3 \+ --hash=sha256:a8b2bc7bffae282281c8140a97d3aa9c14da0b136dfe83f850eea9a5f7470427+ # via ifcopenshell+shapely==2.1.2 \+ --hash=sha256:0036ac886e0923417932c2e6369b6c52e38e0ff5d9120b90eef5cd9a5fc5cae9 \+ --hash=sha256:01d0d304b25634d60bd7cf291828119ab55a3bab87dc4af1e44b07fb225f188b \+ --hash=sha256:0bd308103340030feef6c111d3eb98d50dc13feea33affc8a6f9fa549e9458a3 \+ --hash=sha256:136ab87b17e733e22f0961504d05e77e7be8c9b5a8184f685b4a91a84efe3c26 \+ --hash=sha256:16a9c722ba774cf50b5d4541242b4cce05aafd44a015290c82ba8a16931ff63d \+ --hash=sha256:16c5d0fc45d3aa0a69074979f4f1928ca2734fb2e0dde8af9611e134e46774e7 \+ --hash=sha256:19efa3611eef966e776183e338b2d7ea43569ae99ab34f8d17c2c054d3205cc0 \+ --hash=sha256:1d0bfb4b8f661b3b4ec3565fa36c340bfb1cda82087199711f86a88647d26b2f \+ --hash=sha256:1e7d4d7ad262a48bb44277ca12c7c78cb1b0f56b32c10734ec9a1d30c0b0c54b \+ --hash=sha256:1f2f33f486777456586948e333a56ae21f35ae273be99255a191f5c1fa302eb4 \+ --hash=sha256:1ff629e00818033b8d71139565527ced7d776c269a49bd78c9df84e8f852190c \+ --hash=sha256:21952dc00df38a2c28375659b07a3979d22641aeb104751e769c3ee825aadecf \+ --hash=sha256:2d93d23bdd2ed9dc157b46bc2f19b7da143ca8714464249bef6771c679d5ff40 \+ --hash=sha256:2ed4ecb28320a433db18a5bf029986aa8afcfd740745e78847e330d5d94922a9 \+ --hash=sha256:2fa78b49485391224755a856ed3b3bd91c8455f6121fee0db0e71cefb07d0ef6 \+ --hash=sha256:346ec0c1a0fcd32f57f00e4134d1200e14bf3f5ae12af87ba83ca275c502498c \+ --hash=sha256:361b6d45030b4ac64ddd0a26046906c8202eb60d0f9f53085f5179f1d23021a0 \+ --hash=sha256:40d784101f5d06a1fd30b55fc11ea58a61be23f930d934d86f19a180909908a4 \+ --hash=sha256:4a44bc62a10d84c11a7a3d7c1c4fe857f7477c3506e24c9062da0db0ae0c449c \+ --hash=sha256:5860eb9f00a1d49ebb14e881f5caf6c2cf472c7fd38bd7f253bbd34f934eb076 \+ --hash=sha256:5ebe3f84c6112ad3d4632b1fd2290665aa75d4cef5f6c5d77c4c95b324527c6a \+ --hash=sha256:61edcd8d0d17dd99075d320a1dd39c0cb9616f7572f10ef91b4b5b00c4aeb566 \+ --hash=sha256:6305993a35989391bd3476ee538a5c9a845861462327efe00dd11a5c8c709a99 \+ --hash=sha256:6ddc759f72b5b2b0f54a7e7cde44acef680a55019eb52ac63a7af2cf17cb9cd2 \+ --hash=sha256:743044b4cfb34f9a67205cee9279feaf60ba7d02e69febc2afc609047cb49179 \+ --hash=sha256:7ae48c236c0324b4e139bea88a306a04ca630f49be66741b340729d380d8f52f \+ --hash=sha256:7ed1a5bbfb386ee8332713bf7508bc24e32d24b74fc9a7b9f8529a55db9f4ee6 \+ --hash=sha256:8cff473e81017594d20ec55d86b54bc635544897e13a7cfc12e36909c5309a2a \+ --hash=sha256:8d8382dd120d64b03698b7298b89611a6ea6f55ada9d39942838b79c9bc89801 \+ --hash=sha256:9111274b88e4d7b54a95218e243282709b330ef52b7b86bc6aaf4f805306f454 \+ --hash=sha256:91121757b0a36c9aac3427a651a7e6567110a4a67c97edf04f8d55d4765f6618 \+ --hash=sha256:980c777c612514c0cf99bc8a9de6d286f5e186dcaf9091252fcd444e5638193d \+ --hash=sha256:9a522f460d28e2bf4e12396240a5fc1518788b2fcd73535166d748399ef0c223 \+ --hash=sha256:9c3a3c648aedc9f99c09263b39f2d8252f199cb3ac154fadc173283d7d111350 \+ --hash=sha256:a1fd0ea855b2cf7c9cddaf25543e914dd75af9de08785f20ca3085f2c9ca60b0 \+ --hash=sha256:a444e7afccdb0999e203b976adb37ea633725333e5b119ad40b1ca291ecf311c \+ --hash=sha256:a84e0582858d841d54355246ddfcbd1fce3179f185da7470f41ce39d001ee1af \+ --hash=sha256:b510dda1a3672d6879beb319bc7c5fd302c6c354584690973c838f46ec3e0fa8 \+ --hash=sha256:b54df60f1fbdecc8ebc2c5b11870461a6417b3d617f555e5033f1505d36e5735 \+ --hash=sha256:b705c99c76695702656327b819c9660768ec33f5ce01fa32b2af62b56ba400a1 \+ --hash=sha256:ba4d1333cc0bc94381d6d4308d2e4e008e0bd128bdcff5573199742ee3634359 \+ --hash=sha256:c64d5c97b2f47e3cd9b712eaced3b061f2b71234b3fc263e0fcf7d889c6559dc \+ --hash=sha256:c8876673449f3401f278c86eb33224c5764582f72b653a415d0e6672fde887bf \+ --hash=sha256:ca2591bff6645c216695bdf1614fca9c82ea1144d4a7591a466fef64f28f0715 \+ --hash=sha256:cc4f7397459b12c0b196c9efe1f9d7e92463cbba142632b4cc6d8bbbbd3e2b09 \+ --hash=sha256:cf831a13e0d5a7eb519e96f58ec26e049b1fad411fc6fc23b162a7ce04d9cffc \+ --hash=sha256:dc3487447a43d42adcdf52d7ac73804f2312cbfa5d433a7d2c506dcab0033dfd \+ --hash=sha256:df90e2db118c3671a0754f38e36802db75fe0920d211a27481daf50a711fdf26 \+ --hash=sha256:e38a190442aacc67ff9f75ce60aec04893041f16f97d242209106d502486a142 \+ --hash=sha256:e9eddfe513096a71896441a7c37db72da0687b34752c4e193577a145c71736fc \+ --hash=sha256:eba6710407f1daa8e7602c347dfc94adc02205ec27ed956346190d66579eb9ea \+ --hash=sha256:ef4a456cc8b7b3d50ccec29642aa4aeda959e9da2fe9540a92754770d5f0cf1f \+ --hash=sha256:f67b34271dedc3c653eba4e3d7111aa421d5be9b4c4c7d38d30907f796cb30df \+ --hash=sha256:f6f6cd5819c50d9bcf921882784586aab34a4bd53e7553e175dece6db513a6f0 \+ --hash=sha256:fe2533caae6a91a543dec62e8360fe86ffcdc42a7c55f9dfd0128a977a896b94 \+ --hash=sha256:fe7b77dc63d707c09726b7908f575fc04ff1d1ad0f3fb92aec212396bc6cfe5e \+ --hash=sha256:fe9627c39c59e553c90f5bc3128252cb85dc3b3be8189710666d2f8bc3a5503e+ # via ifcopenshell+six==1.17.0 \+ --hash=sha256:4721f391ed90541fddacab5acf947aa0d3dc7d27b2e1e8eda2be8970586c3274 \+ --hash=sha256:ff70335d468e7eb6ec65b95b99d3a2836546063f63acc5171de367e834932a81+ # via python-dateutil+typing-extensions==4.16.0 \+ --hash=sha256:481caa481374e813c1b176ada14e97f1f67a4539ce9cfeb3f350d78d6370c2e8 \+ --hash=sha256:dc983d19a509c94dba722ee6abd33940f7c05a89e243c47e907eb4db6f1a43e5+ # via+ # ifcopenshell+ # pydantic+ # pydantic-core+ # typing-inspection+typing-inspection==0.4.4 \+ --hash=sha256:547274fa6b0a561ccf549cc9524b999a578e737d015d8709d021f9d0d13bea47 \+ --hash=sha256:65b8397ba37ccbce054456aaccddfc91e6e3083c92824df348d96ca832f3f147+ # via pydanticdiff --git a/store/agents/bonsai-mcp/skills/bonsai-mcp/SKILL.md b/store/agents/bonsai-mcp/skills/bonsai-mcp/SKILL.mdnew file mode 100644index 000000000..9ba2e0e63--- /dev/null+++ b/store/agents/bonsai-mcp/skills/bonsai-mcp/SKILL.md@@ -0,0 +1,19 @@+---+name: bonsai-mcp+description: Create and inspect architecture projects in the Bonsai MCP Harness workspace, including its local starter and optional upstream integration.+---++# House of ideas++Read `studio.json` to understand the current controls; `"$STUDIO_TOOLCHAIN/../studio.config.json"`+describes their ranges. Run `"$STUDIO_TOOLCHAIN/run.sh" build` to make a new result.+Successful artifacts and their measurements are in `out/runs/<id>/`; `out/latest.json` names the+current result. A failed run preserves the last success and records the error in the verdict.++The local workflow creates and reopens a real IFC4 building with IfcOpenShell, including storeys, slabs, walls, spaces and quantities. The in-pane drawing is a schematic model inspector. It does not certify structural adequacy or code compliance. Blender/Bonsai editing remains available through the pinned optional bridge.++Use `"$STUDIO_TOOLCHAIN/../README.md"` for the integration contract and commands. Read the relevant+files under `$STUDIO_UPSTREAM` before using an upstream API. Keep controls within their documented+ranges, preserve the data needed to reproduce a comparison, and distinguish preview results from+native service or hardware output. The viewer supports history and artifact downloads; tell the+user which run contains the result, and what was actually measured.diff --git a/store/agents/bonsai-mcp/store.json b/store/agents/bonsai-mcp/store.jsonnew file mode 100644index 000000000..e21f5fb8c--- /dev/null+++ b/store/agents/bonsai-mcp/store.json@@ -0,0 +1,6 @@+{+ "homepage": "https://github.com/Show2Instruct/bonsai-mcp",+ "upstream": "https://github.com/Show2Instruct/bonsai-mcp",+ "license": "MIT; IfcOpenShell LGPL-3.0",+ "screenshots": []+}diff --git a/store/agents/bonsai-mcp/studio.config.json b/store/agents/bonsai-mcp/studio.config.jsonnew file mode 100644index 000000000..27f2070f8--- /dev/null+++ b/store/agents/bonsai-mcp/studio.config.json@@ -0,0 +1,89 @@+{+ "title": "House of ideas",+ "description": "Make room for a new idea. Shape a small building, inspect its spaces, and open the real IFC model anywhere.",+ "category": "Architecture",+ "scene": "A SMALL SPACE WITH POSSIBILITIES",+ "hint": "Drag to orbit \u00b7 choose a room \u00b7 switch to floor plan",+ "tip": "Try a wider studio or an extra storey. The quantities come from the exported IFC model.",+ "previewLabel": "Building preview \u00b7 export to inspect IFC",+ "controls": [+ {+ "id": "width",+ "label": "Building width",+ "type": "number",+ "value": 10,+ "min": 6,+ "max": 18,+ "step": 0.5,+ "integer": false,+ "unit": "m",+ "hint": ""+ },+ {+ "id": "depth",+ "label": "Building depth",+ "type": "number",+ "value": 8,+ "min": 5,+ "max": 14,+ "step": 0.5,+ "integer": false,+ "unit": "m",+ "hint": ""+ },+ {+ "id": "storeys",+ "label": "Storeys",+ "type": "number",+ "value": 2,+ "min": 1,+ "max": 4,+ "step": 1,+ "integer": true,+ "unit": "",+ "hint": ""+ },+ {+ "id": "height",+ "label": "Ceiling height",+ "type": "number",+ "value": 3,+ "min": 2.5,+ "max": 4,+ "step": 0.1,+ "integer": false,+ "unit": "m",+ "hint": ""+ },+ {+ "id": "use",+ "label": "Ground floor",+ "type": "select",+ "value": "studio",+ "options": [+ {+ "value": "studio",+ "label": "Creative studio"+ },+ {+ "value": "home",+ "label": "Quiet home"+ }+ ]+ }+ ],+ "actions": [+ {+ "id": "build",+ "label": "Make this building",+ "description": ""+ },+ {+ "id": "bonsai",+ "label": "Read Bonsai scene",+ "description": "Read the local Blender/Bonsai bridge without changing its model"+ }+ ],+ "credit": "Bonsai MCP \u00b7 Show2Instruct",+ "empty": "Adjust the controls, then make your first exploration. Every successful run stays in the history."+}diff --git a/store/agents/bonsai-mcp/template/studio.json b/store/agents/bonsai-mcp/template/studio.jsonnew file mode 100644index 000000000..b37bd0420--- /dev/null+++ b/store/agents/bonsai-mcp/template/studio.json@@ -0,0 +1,11 @@+{+ "spec": 1,+ "title": "House of ideas",+ "parameters": {+ "width": 10,+ "depth": 8,+ "storeys": 2,+ "height": 3,+ "use": "studio"+ }+}diff --git a/store/agents/bonsai-mcp/toolchain/doctor.sh b/store/agents/bonsai-mcp/toolchain/doctor.shnew file mode 100755index 000000000..8a8bd586d--- /dev/null+++ b/store/agents/bonsai-mcp/toolchain/doctor.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+test -x .venv/bin/python || { echo 'miss run toolchain/setup.sh to install the local runtime'; exit 1; }+.venv/bin/python -c 'import ifcopenshell; import json; json.load(open("studio.config.json")); print("ok Bonsai MCP local workflow")'+test -f upstream/README.md || { echo "miss pinned upstream sources"; exit 1; }+echo "ok upstream 12cf135f6985"diff --git a/store/agents/bonsai-mcp/toolchain/init-workspace.sh b/store/agents/bonsai-mcp/toolchain/init-workspace.shnew file mode 100755index 000000000..1dbd51500--- /dev/null+++ b/store/agents/bonsai-mcp/toolchain/init-workspace.sh@@ -0,0 +1,3 @@+#!/usr/bin/env bash+set -euo pipefail+exec "${HARNESS_DSH_DIR:?}/toolchain/run.sh" builddiff --git a/store/agents/bonsai-mcp/toolchain/run.sh b/store/agents/bonsai-mcp/toolchain/run.shnew file mode 100755index 000000000..a9e5df771--- /dev/null+++ b/store/agents/bonsai-mcp/toolchain/run.sh@@ -0,0 +1,6 @@+#!/usr/bin/env bash+set -euo pipefail+studio_package="$(cd "$(dirname "$0")/.." && pwd)"+export PATH="$studio_package/.venv/bin:$PATH"+export PYTHONUNBUFFERED=1+exec "$studio_package/.venv/bin/python" "$studio_package/toolchain/workflow.py" "$@"diff --git a/store/agents/bonsai-mcp/toolchain/runtimes.sh b/store/agents/bonsai-mcp/toolchain/runtimes.shnew file mode 100644index 000000000..7223c78dc--- /dev/null+++ b/store/agents/bonsai-mcp/toolchain/runtimes.sh@@ -0,0 +1,192 @@+# shellcheck shell=bash+# runtimes.sh — the interpreters a store package runs on, found on this machine or fetched, never+# asked of the person who pressed Get.+#+# Sourced (not run) by a package's setup, doctor and viewer scripts. A new Mac has Apple's Python 3.9,+# no Homebrew and, for most people, no Node on PATH; a package that answers "brew install [email protected]"+# has failed its install. So:+#+# harness_node 18 node >= 18 on PATH, with npm: the machine's own, else the Node Harness+# itself runs on (~/.harness/runtime/current-node, laid down with the CLI)+# harness_uv uv on PATH: the machine's own, else a pinned, checksummed release+# fetched into ~/.harness/runtime+# harness_venv DIR 3.12 [MIN [BELOW]]+# DIR is a venv on CPython 3.12, which uv downloads when the machine+# has none. A venv already there on a Python in [MIN, BELOW) is kept.+# harness_pip DIR PKG… install into that venv, through uv+# harness_micromamba micromamba, pinned and checksummed, for native libraries PyPI has+# no wheel for (pycairo on macOS)+# harness_conda_env DIR SPEC… DIR is a conda-forge environment with those packages+#+# Every function prints `miss …` and returns 1 when it cannot deliver, so `harness_node 18 || exit 1`+# reads like the rest of a setup script. Nothing here touches the user's shell profile; what it+# installs lands in ~/.harness/runtime or the package's own directory (uv keeps its download cache+# where it always does, which a venv does not depend on).+#+# ONE copy is written by hand: store/tools/runtimes.sh in the OpenHarness repository. Each package+# carries an identical copy (a package installs alone, so it cannot reach this one);+# `node store/tools/sync-runtimes.mjs` rewrites them and the CLI's store spec fails when one drifts.++HARNESS_RUNTIME="${ADAPTER_RUNTIME_DIR:-${HOME:-}/.harness/runtime}"+# The Pythons uv downloads live with Harness's other runtimes, not in uv's own ~/.local/share/uv:+# a package's venv points at its interpreter, and `uv python uninstall` there must not break it.+UV_PYTHON_INSTALL_DIR="${UV_PYTHON_INSTALL_DIR:-$HARNESS_RUNTIME/python}"+export UV_PYTHON_INSTALL_DIR+HARNESS_UV_VERSION=0.12.15+HARNESS_MICROMAMBA_VERSION=2.9.0-0++_harness_platform() {+ case "$(uname -s)-$(uname -m)" in+ Darwin-arm64) echo darwin-arm64 ;;+ Darwin-x86_64) echo darwin-x64 ;;+ Linux-x86_64) echo linux-x64 ;;+ Linux-aarch64 | Linux-arm64) echo linux-arm64 ;;+ *) return 1 ;;+ esac+}++_harness_sha256() {+ if command -v shasum >/dev/null 2>&1; then shasum -a 256 "$1" | cut -d' ' -f1+ else sha256sum "$1" | cut -d' ' -f1; fi+}++# _harness_fetch URL DEST SHA256 — DEST exists only if what arrived matches the pinned checksum.+_harness_fetch() {+ local part="$2.part.$$"+ if ! curl -fsSL --retry 3 --connect-timeout 20 --max-time 900 -o "$part" "$1"; then+ rm -f "$part"; echo "miss could not download $1 — check this machine's internet connection"; return 1+ fi+ if [ "$(_harness_sha256 "$part")" != "$3" ]; then+ rm -f "$part"; echo "miss $1 did not match its pinned checksum; nothing was installed"; return 1+ fi+ mv -f "$part" "$2"+}++_harness_node_at_least() {+ command -v node >/dev/null 2>&1 || return 1+ node -e '+ const [a, b = 0] = process.argv[1].split(".").map(Number)+ const [x, y] = process.versions.node.split(".").map(Number)+ process.exit(x > a || (x === a && y >= b) ? 0 : 1)+ ' "$1" >/dev/null 2>&1+}++harness_node() {+ local min="${1:-18}" recorded saved="$PATH" own=0+ _harness_node_at_least "$min" && own=1+ # A node without npm beside it (a distro's nodejs package) cannot run a setup's `npm ci`.+ if [ "$own" = 1 ] && command -v npm >/dev/null 2>&1; then return 0; fi+ recorded="$(cat "$HARNESS_RUNTIME/current-node" 2>/dev/null || true)"+ # Already Harness's own (a second call, or a wrapper calling a script that asks again): nothing to add.+ if [ "$own" = 1 ] && [ -n "$recorded" ] && [ "$(command -v node)" = "${recorded%/*}/node" ]; then return 0; fi+ if [ -n "$recorded" ] && [ -x "${recorded%/*}/node" ]; then+ PATH="${recorded%/*}:$PATH"; export PATH; hash -r 2>/dev/null || true+ _harness_node_at_least "$min" && return 0+ PATH="$saved"; export PATH; hash -r 2>/dev/null || true+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min — this machine's newest is $("${recorded%/*}/node" -v), Harness's own; update Harness"+ return 1+ fi+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min, and Harness's own Node is not in $HARNESS_RUNTIME — run \`harness start\` once to lay it down"+ return 1+}++harness_uv() {+ local dir asset sum tmp+ command -v uv >/dev/null 2>&1 && return 0+ for dir in "${HOME:-}/.local/bin" "${HOME:-}/.cargo/bin"; do+ [ -n "${HOME:-}" ] || break+ if [ -x "$dir/uv" ]; then PATH="$dir:$PATH"; export PATH; return 0; fi+ done+ dir="$HARNESS_RUNTIME/uv-$HARNESS_UV_VERSION"+ if [ ! -x "$dir/uv" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=uv-aarch64-apple-darwin sum=dc304b9ed1b24174572290fba60ac3f6fe63c73a671f0439e62a91375841964d ;;+ darwin-x64) asset=uv-x86_64-apple-darwin sum=e9ca61775532368fe518ab03e7a354c7ecab8ccb3c7d941c775fcc4a362b801b ;;+ linux-x64) asset=uv-x86_64-unknown-linux-gnu sum=f97935763c04be3e692460a7aaeaaab8fc3b78fcf8b389da820b38ae7423a638 ;;+ linux-arm64) asset=uv-aarch64-unknown-linux-gnu sum=0e9a3499b0587d449c9ff684c0160da607826e4af1cee220bc87f378702d3e08 ;;+ *) echo "miss uv — there is no uv release for $(uname -s) $(uname -m); install it from https://docs.astral.sh/uv/"; return 1 ;;+ esac+ echo " fetching uv $HARNESS_UV_VERSION into $HARNESS_RUNTIME (it brings Python and the packages)"+ mkdir -p "$HARNESS_RUNTIME" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ tmp="$(mktemp -d "$HARNESS_RUNTIME/.uv.XXXXXX")" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ if ! _harness_fetch "https://github.com/astral-sh/uv/releases/download/$HARNESS_UV_VERSION/$asset.tar.gz" "$tmp/uv.tar.gz" "$sum"; then+ rm -rf "$tmp"; return 1+ fi+ tar -xzf "$tmp/uv.tar.gz" -C "$tmp" && chmod +x "$tmp/$asset/uv" "$tmp/$asset/uvx" \+ || { rm -rf "$tmp"; echo "miss the uv archive would not unpack"; return 1; }+ # Two installs at once both get here; whichever renames first wins and the other's copy goes.+ # (mv onto a directory that exists would nest the copy inside it, hence the test.)+ [ -e "$dir" ] || mv "$tmp/$asset" "$dir" 2>/dev/null || true+ rm -rf "$tmp"+ [ -x "$dir/uv" ] || { echo "miss uv did not land in $dir"; return 1; }+ fi+ PATH="$dir:$PATH"; export PATH+}++# harness_venv DIR VERSION [MIN [BELOW]] — MIN defaults to VERSION; BELOW is exclusive and optional.+harness_venv() {+ local dir="${1:?harness_venv needs a directory}" want="${2:?harness_venv needs a Python version}"+ local min="${3:-$2}" below="${4:-}"+ if [ -x "$dir/bin/python" ] && "$dir/bin/python" -c '+import sys+at = lambda s: tuple(int(p) for p in s.split("."))+v = sys.version_info[:2]+sys.exit(0 if v >= at(sys.argv[1]) and (not sys.argv[2] or v < at(sys.argv[2])) else 1)+' "$min" "$below" 2>/dev/null; then+ echo "ok $("$dir/bin/python" --version) in $dir"+ return 0+ fi+ harness_uv || return 1+ echo " python $want in $dir (uv downloads it when this machine has none)"+ rm -rf "$dir"+ # only-managed: the same python-build-standalone interpreter on every machine, so a package tested+ # once is tested everywhere — not whichever Homebrew or pyenv Python happened to be first on PATH.+ uv venv --quiet --seed --python "$want" --python-preference only-managed "$dir" \+ || { echo "miss could not make a Python $want environment in $dir"; return 1; }+ echo "ok $("$dir/bin/python" --version) in $dir"+}++harness_pip() {+ local dir="${1:?harness_pip needs a venv}"+ shift+ harness_uv || return 1+ # uv's own error comes first; the miss line is last, so it is the line the store shows.+ uv pip install --quiet --python "$dir/bin/python" "$@" \+ || { echo "miss could not install $* into $dir"; return 1; }+}++harness_micromamba() {+ local dir asset sum+ dir="$HARNESS_RUNTIME/micromamba-$HARNESS_MICROMAMBA_VERSION"+ if [ ! -x "$dir/micromamba" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=micromamba-osx-arm64 sum=ec2a072f028e1a7cf20f3e2e74d5a8127cf5a5f27636375b5359811565f4e5be ;;+ darwin-x64) asset=micromamba-osx-64 sum=1e71054bb3ac9a076e21f7ec48acfef536f9b3f1408f371a942784bf5ef83d8a ;;+ linux-x64) asset=micromamba-linux-64 sum=366cd9cd8be14df1ab8ed50352a82111082a36686b2d389fdb79a92c3fafb3e3 ;;+ linux-arm64) asset=micromamba-linux-aarch64 sum=9f93b974adcb4d166996af969b6cd371287d1a3e52733704727884d9b74cb7a7 ;;+ *) echo "miss micromamba — there is no release for $(uname -s) $(uname -m)"; return 1 ;;+ esac+ echo " fetching micromamba $HARNESS_MICROMAMBA_VERSION into $HARNESS_RUNTIME (native libraries PyPI has no wheel for)"+ mkdir -p "$dir" || { echo "miss cannot write $dir"; return 1; }+ _harness_fetch "https://github.com/mamba-org/micromamba-releases/releases/download/$HARNESS_MICROMAMBA_VERSION/$asset" "$dir/micromamba.$$" "$sum" || return 1+ chmod +x "$dir/micromamba.$$" && mv -f "$dir/micromamba.$$" "$dir/micromamba" \+ || { rm -f "$dir/micromamba.$$"; echo "miss micromamba would not install into $dir"; return 1; }+ fi+ HARNESS_MICROMAMBA="$dir/micromamba"+ export HARNESS_MICROMAMBA+}++# harness_conda_env DIR SPEC… — conda-forge only, packages cached under ~/.harness/runtime/mamba.+harness_conda_env() {+ local dir="${1:?harness_conda_env needs a directory}"+ shift+ # micromamba takes a relative --prefix as a name under its root prefix and "succeeds" there.+ case "$dir" in /*) ;; *) dir="$PWD/$dir" ;; esac+ harness_micromamba || return 1+ MAMBA_ROOT_PREFIX="$HARNESS_RUNTIME/mamba" "$HARNESS_MICROMAMBA" create --yes --quiet \+ --prefix "$dir" --override-channels --channel conda-forge "$@" >/dev/null \+ && [ -d "$dir/conda-meta" ] \+ || { echo "miss could not make the conda-forge environment in $dir ($*)"; return 1; }+}diff --git a/store/agents/bonsai-mcp/toolchain/setup.sh b/store/agents/bonsai-mcp/toolchain/setup.shnew file mode 100755index 000000000..efbece7e2--- /dev/null+++ b/store/agents/bonsai-mcp/toolchain/setup.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+harness_venv .venv 3.11 3.11 3.12+.venv/bin/python toolchain/studio_fetch.py+if [ -s requirements.lock ]; then harness_pip .venv --require-hashes -r requirements.lock; fi+exec toolchain/doctor.shdiff --git a/store/agents/bonsai-mcp/toolchain/studio_fetch.py b/store/agents/bonsai-mcp/toolchain/studio_fetch.pynew file mode 100644index 000000000..88a670b25--- /dev/null+++ b/store/agents/bonsai-mcp/toolchain/studio_fetch.py@@ -0,0 +1,34 @@+"""Fetch reviewed source pins without installing a service or changing user configuration."""+import json+import os+from pathlib import Path+import subprocess++root = Path(__file__).resolve().parent.parent+sources = json.loads((root / "upstream.lock.json").read_text())+for source in sources:+ target = root / source["directory"]+ def git(*args):+ return subprocess.check_output(["git", "-C", str(target), *args], text=True,+ env={**os.environ, "GIT_LFS_SKIP_SMUDGE": "1"}).strip()+ if not (target / ".git").exists():+ target.mkdir(parents=True, exist_ok=True)+ git("init", "-q")+ git("remote", "add", "origin", source["url"])+ if source.get("sparse"):+ git("sparse-checkout", "init", "--cone")+ git("sparse-checkout", "set", *source["sparse"])+ if git("remote", "get-url", "origin") != source["url"]:+ raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])+ try:+ current = git("rev-parse", "HEAD")+ except subprocess.CalledProcessError:+ current = ""+ if current != source["commit"]:+ if current and git("status", "--porcelain"):+ raise SystemExit(f"Save your edits in {target} before changing its source pin")+ git("fetch", "--depth", "1", "--filter=blob:none", "origin", source["commit"])+ git("checkout", "--detach", source["commit"])+ print(f'ok {source["name"]} at {source["commit"][:12]}', flush=True)diff --git a/store/agents/bonsai-mcp/toolchain/studio_runtime.py b/store/agents/bonsai-mcp/toolchain/studio_runtime.pynew file mode 100644index 000000000..8b8ea016c--- /dev/null+++ b/store/agents/bonsai-mcp/toolchain/studio_runtime.py@@ -0,0 +1,132 @@+"""Portable runner copied into each independently installable studio package."""+import json+import math+import os+from pathlib import Path+import subprocess+import sys+import tempfile+import time+import uuid+++def workspace():+ return Path(os.environ.get("HARNESS_WORKSPACE", os.getcwd())).resolve()+++def package():+ return Path(__file__).resolve().parent.parent+++def contained(path):+ target = Path(path).resolve()+ target.relative_to(workspace())+ return target+++def atomic_json(path, data):+ path = contained(path)+ path.parent.mkdir(parents=True, exist_ok=True)+ with tempfile.NamedTemporaryFile(mode="w", dir=path.parent, prefix=".studio-", delete=False) as f:+ json.dump(data, f, indent=2, allow_nan=False)+ f.write("\n")+ temp = f.name+ os.replace(temp, path)+++def command(argv, cwd=None, timeout=120, env=None):+ """No shell interpolation; keep complete logs as output, bound execution time."""+ result = subprocess.run([str(x) for x in argv], cwd=cwd, timeout=timeout,+ env=env, text=True, capture_output=True)+ if result.returncode:+ raise RuntimeError((result.stderr or result.stdout)[-1600:] or f"{argv[0]} exited {result.returncode}")+ return result.stdout+++def parameters(config, values):+ if not isinstance(values, dict) or set(values) - {c["id"] for c in config["controls"]}:+ raise ValueError("Invalid studio controls")+ result = {}+ for c in config["controls"]:+ value = values.get(c["id"], c["value"])+ if c["type"] == "number":+ if type(value) not in (int, float) or not math.isfinite(value) or not c["min"] <= value <= c["max"]:+ raise ValueError(f'{c["label"]} is outside its range')+ if c.get("integer") and value != int(value):+ raise ValueError(f'{c["label"]} must be a whole number')+ elif c["type"] == "select":+ if value not in [o["value"] for o in c["options"]]:+ raise ValueError(f'Unknown {c["label"]}')+ elif not isinstance(value, str) or len(value) > c.get("maxLength", 500):+ raise ValueError(f'Invalid {c["label"]}')+ result[c["id"]] = value+ return result+++def metric(label, value, unit=""):+ return {"label": label, "value": value, "unit": unit}+++def previous_runs():+ base = contained(workspace() / "out/runs")+ rows = []+ for p in sorted(base.glob("*/result.json"))[-100:]:+ try:+ rows.append(json.loads(contained(p).read_text()))+ except (ValueError, OSError):+ continue+ return rows+++def execute(actions):+ root = workspace()+ config = json.loads((package() / "studio.config.json").read_text())+ action = sys.argv[1] if len(sys.argv) > 1 else config["actions"][0]["id"]+ started = time.monotonic()+ verdict_path = root / ".harness/verdict.json"+ verdict = {"spec": 1, "ready": False, "summary": "Preparing the studio run", "findings": [],+ "phases": [{"id": "run", "name": "Make", "state": "active"},+ {"id": "inspect", "name": "Inspect", "state": "pending"}]}+ try:+ if action not in actions:+ raise ValueError(f"Unknown action: {action}")+ source = contained(root / "studio.json")+ if source.stat().st_size > 16384:+ raise ValueError("studio.json is too large")+ project = json.loads(source.read_text())+ p = parameters(config, project["parameters"])+ atomic_json(verdict_path, verdict)+ run_id = time.strftime("%Y%m%dT%H%M%S", time.gmtime()) + "-" + uuid.uuid4().hex[:8]+ output = contained(root / "out/runs" / run_id)+ output.mkdir(parents=True)+ print(f'{config["title"]}: {action}', flush=True)+ result = actions[action](p, output)+ artifacts = []+ for artifact in result.pop("files", []):+ file = contained(output / artifact["name"])+ file.relative_to(output)+ if not file.is_file() or not file.stat().st_size:+ raise ValueError(f'Missing output: {artifact["name"]}')+ artifacts.append({"label": artifact["label"], "path": str(file.relative_to(root))})+ result.update({"spec": 1, "id": run_id, "action": action, "parameters": p,+ "createdAt": time.strftime("%Y-%m-%dT%H:%M:%SZ", time.gmtime()),+ "durationSeconds": round(time.monotonic() - started, 3), "artifacts": artifacts,+ "upstream": json.loads((package() / "upstream.lock.json").read_text())})+ atomic_json(output / "result.json", result)+ atomic_json(root / "out/latest.json", result)+ verdict.update({"ready": True, "summary": f'{result["title"]} · {result["engine"]}',+ "artifact": str((output / "result.json").relative_to(root)),+ "phases": [{"id": "run", "name": "Make", "state": "done"},+ {"id": "inspect", "name": "Inspect", "state": "done"}],+ "updatedAt": result["createdAt"]})+ atomic_json(verdict_path, verdict)+ print(f'Ready: {result["title"]}', flush=True)+ except Exception as exc:+ verdict.update({"summary": str(exc)[:500], "findings": [{"severity": "error", "kind": "run-failed", "message": str(exc)[:1000]}],+ "phases": [{"id": "run", "name": "Make", "state": "failed"}]})+ try:+ atomic_json(verdict_path, verdict)+ except (ValueError, OSError):+ pass+ print(str(exc), file=sys.stderr)+ raise SystemExit(1) from excdiff --git a/store/agents/bonsai-mcp/toolchain/workflow.py b/store/agents/bonsai-mcp/toolchain/workflow.pynew file mode 100644index 000000000..e617c0205--- /dev/null+++ b/store/agents/bonsai-mcp/toolchain/workflow.py@@ -0,0 +1,78 @@+import csv+import json+import math+import sys+import ifcopenshell+import ifcopenshell.api+import ifcopenshell.util.element+import numpy as np+from studio_runtime import execute, metric, package+++def build(p,out):+ f=ifcopenshell.file(schema='IFC4')+ def api(operation,**args):return ifcopenshell.api.run(operation,f,**args)+ def entity(kind,name):return api('root.create_entity',ifc_class=kind,name=name)+ project=entity('IfcProject','House of ideas')+ api('unit.assign_unit',units=[api('unit.add_si_unit',unit_type='LENGTHUNIT'),api('unit.add_si_unit',unit_type='AREAUNIT'),api('unit.add_si_unit',unit_type='VOLUMEUNIT')])+ model=api('context.add_context',context_type='Model')+ context=api('context.add_context',context_type='Model',context_identifier='Body',target_view='MODEL_VIEW',parent=model)+ site=entity('IfcSite','Studio garden');building=entity('IfcBuilding','A small possibility')+ api('aggregate.assign_object',products=[site],relating_object=project)+ api('aggregate.assign_object',products=[building],relating_object=site)+ width,depth,height=p['width'],p['depth'],p['height'];spaces=[];elements=[]+ def place(product,x,y,z,angle=0):+ a=math.radians(angle);m=np.eye(4);m[:2,:2]=[[math.cos(a),-math.sin(a)],[math.sin(a),math.cos(a)]];m[:3,3]=[x,y,z]+ api('geometry.edit_object_placement',product=product,matrix=m,is_si=True)+ def geometry(product,representation):api('geometry.assign_representation',product=product,representation=representation)+ for level in range(p['storeys']):+ z=level*(height+.2);storey=entity('IfcBuildingStorey',f'Level {level+1}');storey.Elevation=z+ api('aggregate.assign_object',products=[storey],relating_object=building);place(storey,0,0,z)+ slab=entity('IfcSlab',f'Floor {level+1}');api('spatial.assign_container',products=[slab],relating_structure=storey)+ geometry(slab,api('geometry.add_slab_representation',context=context,depth=.2,polyline=[(0.,0.),(width,0.),(width,depth),(0.,depth),(0.,0.)]));place(slab,0,0,z)+ elements.append({'id':slab.GlobalId,'kind':'slab','x':0,'y':0,'z':z,'width':width,'depth':depth,'height':.2,'level':level})+ walls=[]+ for label,x,y,length,angle in [('South',0,0,width,0),('East',width,0,depth,90),('North',width,depth,width,180),('West',0,depth,depth,270),('Partition',width*.55,0,depth,90)]:+ wall=entity('IfcWall',f'{label} wall · level {level+1}');api('spatial.assign_container',products=[wall],relating_structure=storey)+ geometry(wall,api('geometry.add_wall_representation',context=context,length=length,height=height,thickness=.2));place(wall,x,y,z+.2,angle);walls.append(wall)+ elements.append({'id':wall.GlobalId,'kind':'wall','x':x,'y':y,'z':z+.2,'length':length,'height':height,'angle':angle,'level':level})+ opening=entity('IfcOpeningElement',f'Garden window opening {level+1}')+ geometry(opening,api('geometry.add_wall_representation',context=context,length=1.8,height=1.4,thickness=.4));place(opening,1,-.1,z+1)+ api('feature.add_feature',feature=opening,element=walls[0])+ window=entity('IfcWindow',f'Garden window {level+1}');window.OverallHeight=1.4;window.OverallWidth=1.8+ api('spatial.assign_container',products=[window],relating_structure=storey)+ geometry(window,api('geometry.add_wall_representation',context=context,length=1.8,height=1.4,thickness=.06));place(window,1,.07,z+1)+ api('feature.add_filling',opening=opening,element=window)+ names=['Studio','Reading room'] if p['use']=='studio' else ['Living room','Bedroom']+ for room,(x,roomwidth) in enumerate([(.2,width*.55-.4),(width*.55+.2,width*.45-.4)]):+ roomdepth=depth-.4;space=entity('IfcSpace',f'{names[room]} · level {level+1}')+ api('aggregate.assign_object',products=[space],relating_object=storey)+ profile=f.create_entity('IfcRectangleProfileDef',ProfileType='AREA',XDim=roomwidth,YDim=roomdepth)+ geometry(space,api('geometry.add_profile_representation',context=context,profile=profile,depth=height));place(space,x+roomwidth/2,.2+roomdepth/2,z+.2)+ qto=api('pset.add_qto',product=space,name='Qto_SpaceBaseQuantities')+ api('pset.edit_qto',qto=qto,properties={'NetFloorArea':roomwidth*roomdepth,'NetVolume':roomwidth*roomdepth*height,'Height':height})+ spaces.append({'id':space.GlobalId,'name':space.Name,'x':x,'y':.2,'width':roomwidth,'depth':roomdepth,'level':level})+ f.write(out/'building.ifc')+ # Read quantities back from the actual saved IFC, rather than trusting UI dimensions.+ checked=ifcopenshell.open(out/'building.ifc');total=0;rows=[]+ for space in checked.by_type('IfcSpace'):+ q=ifcopenshell.util.element.get_psets(space,qtos_only=True)['Qto_SpaceBaseQuantities'];total+=q['NetFloorArea'];rows.append([space.GlobalId,space.Name,q['NetFloorArea'],q['NetVolume']])+ if len(rows)!=2*p['storeys'] or len(checked.by_type('IfcOpeningElement'))!=p['storeys']:raise RuntimeError('The IFC read-back did not match the building.')+ with (out/'quantities.csv').open('w',newline='') as stream:+ writer=csv.writer(stream);writer.writerow(['global_id','room','net_area_m2','net_volume_m3']);writer.writerows(rows)+ data={'spaces':spaces,'elements':elements,'width':width,'depth':depth,'height':height,'storeys':p['storeys'],'area':total}+ (out/'building.json').write_text(json.dumps(data,indent=2))+ return {'title':f'{p["storeys"]}-storey {p["use"]} · {total:.1f} m²','description':'A real IFC4 model with walls, slabs, spaces and window openings. Quantities were read back from the saved file; the viewer is a schematic inspector.','engine':f'IfcOpenShell {ifcopenshell.version} · IFC4','metrics':[metric('Net floor area',round(total,1),'m²'),metric('Rooms',len(rows)),metric('Storeys',p['storeys'])],'data':data,'files':[{'label':'IFC building','name':'building.ifc'},{'label':'Room quantities','name':'quantities.csv'},{'label':'Viewer geometry','name':'building.json'}]}+++def bonsai(p,out):+ sys.path.insert(0,str(package()/'upstream/src'))+ from bonsai_mcp.blender_client import BlenderBridgeClient+ client=BlenderBridgeClient(timeout=3)+ try:scene=client.send('get_scene_info',{'limit':50})+ finally:client.close()+ (out/'bonsai-scene.json').write_text(json.dumps(scene,indent=2))+ return {'title':'Bonsai scene snapshot','description':'Read directly from the Blender/Bonsai bridge. No geometry was changed.','engine':'Native Bonsai MCP bridge','metrics':[],'data':{'scene':scene},'files':[{'label':'Scene snapshot','name':'bonsai-scene.json'}]}+++if __name__=='__main__':execute({'build':build,'bonsai':bonsai})diff --git a/store/agents/bonsai-mcp/upstream.lock.json b/store/agents/bonsai-mcp/upstream.lock.jsonnew file mode 100644index 000000000..01fb9b1e8--- /dev/null+++ b/store/agents/bonsai-mcp/upstream.lock.json@@ -0,0 +1,14 @@+[+ {+ "name": "Bonsai MCP",+ "url": "https://github.com/Show2Instruct/bonsai-mcp.git",+ "commit": "12cf135f6985cd042a6205c163bdfacdca23de3a",+ "directory": "upstream",+ "sparse": [+ "src",+ "blender_addon",+ "docs",+ "scripts"+ ]+ }+]diff --git a/store/agents/bonsai-mcp/view.mjs b/store/agents/bonsai-mcp/view.mjsnew file mode 100644index 000000000..73e4e2662--- /dev/null+++ b/store/agents/bonsai-mcp/view.mjs@@ -0,0 +1,35 @@+import {canvas,grid,line,words,toolbar,badge,label,el} from '/graphics.mjs';+function inside(point,poly){let hit=false;for(let i=0,j=poly.length-1;i<poly.length;j=i++){const [xi,yi]=poly[i],[xj,yj]=poly[j];if((yi>point[1])!==(yj>point[1])&&point[0]<(xj-xi)*(point[1]-yi)/(yj-yi)+xi)hit=!hit;}return hit;}+export function mount(stage,api){+ let p=api.getParameters(),result,angle=-.65,plan=false,explode=false,selected=0,drag=null,hitAreas=[],level=0;+ const info=label(stage,'A place to think, make, and let the light in.'),tag=badge(stage,'IFC SCHEMATIC');+ const screen=canvas(stage,(ctx,w,h)=>{+ grid(ctx,w,h,34);const bw=p.width,bd=p.depth,levels=p.storeys;const scale=Math.min((w-80)/(bw+bd), (h-115)/(bw*.4+bd*.4+(plan?0:levels*p.height*.8+(explode?levels*1.4:0))))*1.2;+ const project=(x,y,z)=>{x-=bw/2;y-=bd/2;if(plan)return [w/2+x*scale,h/2+y*scale];const a=x*Math.cos(angle)-y*Math.sin(angle),b=x*Math.sin(angle)+y*Math.cos(angle);return [w/2+a*scale,h*.64+b*scale*.46-z*scale*.72];};+ const polygon=(points,fill,stroke='#dce7c255')=>{ctx.beginPath();points.forEach((pt,i)=>i?ctx.lineTo(...pt):ctx.moveTo(...pt));ctx.closePath();ctx.fillStyle=fill;ctx.fill();ctx.strokeStyle=stroke;ctx.lineWidth=1;ctx.stroke();};+ hitAreas=[];+ for(let floor=0;floor<levels;floor++){+ if(plan&&floor!==level)continue;+ const z=floor*(p.height+.2+(explode?1.8:0));const corners=[[0,0],[bw,0],[bw,bd],[0,bd]];+ polygon(corners.map(([x,y])=>project(x,y,z)),floor===level?'#b4c69b':'#8d9d80');+ for(let room=0;room<2;room++){+ const x0=room?bw*.55+.2:.2,x1=room?bw-.2:bw*.55-.2;const id=floor*2+room;+ const poly=[[x0,.2],[x1,.2],[x1,bd-.2],[x0,bd-.2]].map(([x,y])=>project(x,y,z+.02));polygon(poly,selected===id?'#d6e5ad':'#a5b78d');hitAreas.push({poly,id});+ if(plan){const name=p.use==='studio'?['Studio','Reading room'][room]:['Living room','Bedroom'][room];const pt=project((x0+x1)/2,bd/2,z);words(ctx,name,pt[0]-30,pt[1]-4,'#324832',11);words(ctx,`${((x1-x0)*(bd-.4)).toFixed(1)} m²`,pt[0]-24,pt[1]+14,'#566b45',10);}+ }+ if(!plan){+ for(const [[x0,y0],[x1,y1]] of [[corners[0],corners[1]],[corners[1],corners[2]],[corners[2],corners[3]]])polygon([project(x0,y0,z),project(x1,y1,z),project(x1,y1,z+p.height),project(x0,y0,z+p.height)],'#cdd7ba50');+ polygon([project(1,0,z+.8),project(2.8,0,z+.8),project(2.8,0,z+2.2),project(1,0,z+2.2)],'#8ab3b477','#a7d4cd');+ line(ctx,[project(bw*.55,0,z),project(bw*.55,bd,z)],'#e8f0d1',2);+ }+ }+ const names=p.use==='studio'?['Studio','Reading room']:['Living room','Bedroom'];words(ctx,`${names[selected%2]} · level ${Math.floor(selected/2)+1}`,24,h-70,'#dcebc1',13);+ words(ctx,plan?'PLAN VIEW':'DRAG TO ORBIT',24,24,'#93af85',9);+ },api.signal);screen.element.setAttribute('aria-label','Interactive building schematic; drag or use arrow keys to orbit');screen.element.tabIndex=0;+ screen.element.addEventListener('pointerdown',e=>{drag={x:e.clientX,y:e.clientY,startX:e.clientX,startY:e.clientY};screen.element.setPointerCapture(e.pointerId);});+ screen.element.addEventListener('pointermove',e=>{if(!drag||plan)return;angle+=(e.clientX-drag.x)*.008;drag.x=e.clientX;});+ screen.element.addEventListener('pointerup',e=>{if(drag&&Math.hypot(e.clientX-drag.startX,e.clientY-drag.startY)<5){const box=screen.element.getBoundingClientRect(),hit=hitAreas.findLast(h=>inside([e.clientX-box.left,e.clientY-box.top],h.poly));if(hit){selected=hit.id;api.announce(`Room ${selected%2+1}, level ${Math.floor(selected/2)+1}`);}}drag=null;});+ screen.element.addEventListener('keydown',e=>{if(e.key==='ArrowLeft'||e.key==='ArrowRight'){angle+=e.key==='ArrowRight'?.2:-.2;e.preventDefault();}if(e.key==='Enter'){selected=(selected+1)%(p.storeys*2);api.announce(`Room ${selected%2+1}, level ${Math.floor(selected/2)+1}`);}});+ const bar=toolbar(stage,[['Floor plan',b=>{plan=!plan;b.textContent=plan?'Orbit view':'Floor plan';b.setAttribute('aria-pressed',String(plan));}],['Separate floors',b=>{explode=!explode;b.textContent=explode?'Bring together':'Separate floors';b.setAttribute('aria-pressed',String(explode));}],['Next room',()=>{selected=(selected+1)%(p.storeys*2);level=Math.floor(selected/2);api.announce(`Room ${selected%2+1}, level ${level+1}`);}]]);+ return {update(params,r,motion){p=params;result=r;selected=Math.min(selected,p.storeys*2-1);level=Math.min(level,p.storeys-1);screen.motion(motion);tag.textContent=r?.data?.spaces&&Object.keys(p).every(k=>p[k]===r.parameters[k])?'SAVED IFC MODEL':'DESIGN PREVIEW';}};+}diff --git a/store/agents/comfy-mcp/.gitignore b/store/agents/comfy-mcp/.gitignorenew file mode 100644index 000000000..97ed7159a--- /dev/null+++ b/store/agents/comfy-mcp/.gitignore@@ -0,0 +1,8 @@+upstream/+juce/+.venv/+.build/+.sumo/+__pycache__/+*.pyc+coverage/diff --git a/store/agents/comfy-mcp/AGENTS.md b/store/agents/comfy-mcp/AGENTS.mdnew file mode 100644index 000000000..98388fd4f--- /dev/null+++ b/store/agents/comfy-mcp/AGENTS.md@@ -0,0 +1,18 @@+# Comfy MCP workspace++This harness turns a request into a real, inspectable generative media artifact. Start with+the `comfy-mcp` skill. The editable project is `studio.json` plus files in this workspace.+The viewer follows `out/latest.json` and the run history; save small useful changes as you work.++Run `"$STUDIO_TOOLCHAIN/run.sh" generate` after a change. The runner validates controls,+records provenance, writes artifacts, and updates `.harness/verdict.json`. Do not hand-edit the+verdict to claim a run succeeded. Inspect the produced artifact before describing the result.++The local starter creates deterministic procedural SVG artwork and a contact sheet. It is not diffusion or an AI-generated image claim. The native action submits the saved API workflow to an existing local ComfyUI, polls its result, and collects actual output images. The supplied native workflow uses no model and no paid API.++The installed sources are at `$STUDIO_UPSTREAM`. Preserve upstream credit and use the pinned+instructions when extending the domain workflow. Local simulations are the default. Ask before+using a paid generation service or operating physical hardware unless the user already authorized it.++When developing this package itself, keep it independently installable from its folder; shared+runtime copies are synchronized by `store/tools/sync-studios.mjs` and `sync-runtimes.mjs`.diff --git a/store/agents/comfy-mcp/INTEGRATION.md b/store/agents/comfy-mcp/INTEGRATION.mdnew file mode 100644index 000000000..c0416fe28--- /dev/null+++ b/store/agents/comfy-mcp/INTEGRATION.md@@ -0,0 +1,12 @@+# Procedural local studies and optional ComfyUI execution++`generate` writes deterministic original SVG artwork and a recipe with file hashes. It makes no model/API calls. `comfy` submits `workflow.json` to loopback ComfyUI, checks rejection/execution/timeout states, and collects returned PNG files. The supplied workflow uses EmptyImage and SaveImage and needs no weights or paid nodes. Change the workflow to use models already installed in your own ComfyUI. The official MCP source is pinned in `upstream/`; its README documents the optional `comfy-mcp` and `comfy` CLI setup.++## Verification scope++Local procedural generation, gallery inspection, recipes and downloads form the offline acceptance path. An isolated ComfyUI protocol responder tests job handling and output collection; it is not a diffusion-model benchmark or a live ComfyUI installation.++The browser acceptance suite lives in `store/viewers/studio-viewer/test/studios.e2e.mjs`.+`TESTING.md` beside that viewer records commands, outcomes, screenshots and coverage.+Upstream source revisions are in `upstream.lock.json`; install-time Python dependencies are+hash-locked in `requirements.lock`. No user application configuration is written by setup.diff --git a/store/agents/comfy-mcp/LICENSE b/store/agents/comfy-mcp/LICENSEnew file mode 100644index 000000000..a499cd17e--- /dev/null+++ b/store/agents/comfy-mcp/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Autonomous, Inc.++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/comfy-mcp/LICENSE-upstream b/store/agents/comfy-mcp/LICENSE-upstreamnew file mode 100644index 000000000..4aa016bf6--- /dev/null+++ b/store/agents/comfy-mcp/LICENSE-upstream@@ -0,0 +1,682 @@+Comfy MCP is dual-licensed.++You may use, modify, and distribute Comfy MCP under EITHER of the+following licenses, at your option:++ (a) The GNU Affero General Public License, version 3 or (at your option)+ any later version ("AGPL-3.0-or-later"), the full text of which is+ reproduced below. Use under this option requires you to comply with+ the AGPL's copyleft terms, including the network-use source-disclosure+ obligation in section 13.++ (b) A commercial license from Comfy Org, for users who do not wish to+ comply with the AGPL (for example, to embed Comfy MCP in a+ proprietary product or offer it as a hosted service without+ releasing source). To obtain a commercial license, contact++Copyright (c) Comfy Org. All rights reserved.++--------------------------------------------------------------------------++ GNU AFFERO GENERAL PUBLIC LICENSE+ Version 3, 19 November 2007++ Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>+ Everyone is permitted to copy and distribute verbatim copies+ of this license document, but changing it is not allowed.++ Preamble++ The GNU Affero General Public License is a free, copyleft license for+software and other kinds of works, specifically designed to ensure+cooperation with the community in the case of network server software.++ The licenses for most software and other practical works are designed+to take away your freedom to share and change the works. By contrast,+our General Public Licenses are intended to guarantee your freedom to+share and change all versions of a program--to make sure it remains free+software for all its users.++ When we speak of free software, we are referring to freedom, not+price. Our General Public Licenses are designed to make sure that you+have the freedom to distribute copies of free software (and charge for+them if you wish), that you receive source code or can get it if you+want it, that you can change the software or use pieces of it in new+free programs, and that you know you can do these things.++ Developers that use our General Public Licenses protect your rights+with two steps: (1) assert copyright on the software, and (2) offer+you this License which gives you legal permission to copy, distribute+and/or modify the software.++ A secondary benefit of defending all users' freedom is that+improvements made in alternate versions of the program, if they+receive widespread use, become available for other developers to+incorporate. Many developers of free software are heartened and+encouraged by the resulting cooperation. However, in the case of+software used on network servers, this result may fail to come about.+The GNU General Public License permits making a modified version and+letting the public access it on a server without ever releasing its+source code to the public.++ The GNU Affero General Public License is designed specifically to+ensure that, in such cases, the modified source code becomes available+to the community. It requires the operator of a network server to+provide the source code of the modified version running there to the+users of that server. Therefore, public use of a modified version, on+a publicly accessible server, gives the public access to the source+code of the modified version.++ An older license, called the Affero General Public License and+published by Affero, was designed to accomplish similar goals. This is+a different license, not a version of the Affero GPL, but Affero has+released a new version of the Affero GPL which permits relicensing under+this license.++ The precise terms and conditions for copying, distribution and+modification follow.++ TERMS AND CONDITIONS++ 0. Definitions.++ "This License" refers to version 3 of the GNU Affero General Public License.++ "Copyright" also means copyright-like laws that apply to other kinds of+works, such as semiconductor masks.++ "The Program" refers to any copyrightable work licensed under this+License. Each licensee is addressed as "you". "Licensees" and+"recipients" may be individuals or organizations.++ To "modify" a work means to copy from or adapt all or part of the work+in a fashion requiring copyright permission, other than the making of an+exact copy. The resulting work is called a "modified version" of the+earlier work or a work "based on" the earlier work.++ A "covered work" means either the unmodified Program or a work based+on the Program.++ To "propagate" a work means to do anything with it that, without+permission, would make you directly or secondarily liable for+infringement under applicable copyright law, except executing it on a+computer or modifying a private copy. Propagation includes copying,+distribution (with or without modification), making available to the+public, and in some countries other activities as well.++ To "convey" a work means any kind of propagation that enables other+parties to make or receive copies. Mere interaction with a user through+a computer network, with no transfer of a copy, is not conveying.++ An interactive user interface displays "Appropriate Legal Notices"+to the extent that it includes a convenient and prominently visible+feature that (1) displays an appropriate copyright notice, and (2)+tells the user that there is no warranty for the work (except to the+extent that warranties are provided), that licensees may convey the+work under this License, and how to view a copy of this License. If+the interface presents a list of user commands or options, such as a+menu, a prominent item in the list meets this criterion.++ 1. Source Code.++ The "source code" for a work means the preferred form of the work+for making modifications to it. "Object code" means any non-source+form of a work.++ A "Standard Interface" means an interface that either is an official+standard defined by a recognized standards body, or, in the case of+interfaces specified for a particular programming language, one that+is widely used among developers working in that language.++ The "System Libraries" of an executable work include anything, other+than the work as a whole, that (a) is included in the normal form of+packaging a Major Component, but which is not part of that Major+Component, and (b) serves only to enable use of the work with that+Major Component, or to implement a Standard Interface for which an+implementation is available to the public in source code form. A+"Major Component", in this context, means a major essential component+(kernel, window system, and so on) of the specific operating system+(if any) on which the executable work runs, or a compiler used to+produce the work, or an object code interpreter used to run it.++ The "Corresponding Source" for a work in object code form means all+the source code needed to generate, install, and (for an executable+work) run the object code and to modify the work, including scripts to+control those activities. However, it does not include the work's+System Libraries, or general-purpose tools or generally available free+programs which are used unmodified in performing those activities but+which are not part of the work. For example, Corresponding Source+includes interface definition files associated with source files for+the work, and the source code for shared libraries and dynamically+linked subprograms that the work is specifically designed to require,+such as by intimate data communication or control flow between those+subprograms and other parts of the work.++ The Corresponding Source need not include anything that users+can regenerate automatically from other parts of the Corresponding+Source.++ The Corresponding Source for a work in source code form is that+same work.++ 2. Basic Permissions.++ All rights granted under this License are granted for the term of+copyright on the Program, and are irrevocable provided the stated+conditions are met. This License explicitly affirms your unlimited+permission to run the unmodified Program. The output from running a+covered work is covered by this License only if the output, given its+content, constitutes a covered work. This License acknowledges your+rights of fair use or other equivalent, as provided by copyright law.++ You may make, run and propagate covered works that you do not+convey, without conditions so long as your license otherwise remains+in force. You may convey covered works to others for the sole purpose+of having them make modifications exclusively for you, or provide you+with facilities for running those works, provided that you comply with+the terms of this License in conveying all material for which you do+not control copyright. Those thus making or running the covered works+for you must do so exclusively on your behalf, under your direction+and control, on terms that prohibit them from making any copies of+your copyrighted material outside their relationship with you.++ Conveying under any other circumstances is permitted solely under+the conditions stated below. Sublicensing is not allowed; section 10+makes it unnecessary.++ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.++ No covered work shall be deemed part of an effective technological+measure under any applicable law fulfilling obligations under article+11 of the WIPO copyright treaty adopted on 20 December 1996, or+similar laws prohibiting or restricting circumvention of such+measures.++ When you convey a covered work, you waive any legal power to forbid+circumvention of technological measures to the extent such circumvention+is effected by exercising rights under this License with respect to+the covered work, and you disclaim any intention to limit operation or+modification of the work as a means of enforcing, against the work's+users, your or third parties' legal rights to forbid circumvention of+technological measures.++ 4. Conveying Verbatim Copies.++ You may convey verbatim copies of the Program's source code as you+receive it, in any medium, provided that you conspicuously and+appropriately publish on each copy an appropriate copyright notice;+keep intact all notices stating that this License and any+non-permissive terms added in accord with section 7 apply to the code;+keep intact all notices of the absence of any warranty; and give all+recipients a copy of this License along with the Program.++ You may charge any price or no price for each copy that you convey,+and you may offer support or warranty protection for a fee.++ 5. Conveying Modified Source Versions.++ You may convey a work based on the Program, or the modifications to+produce it from the Program, in the form of source code under the+terms of section 4, provided that you also meet all of these conditions:++ a) The work must carry prominent notices stating that you modified+ it, and giving a relevant date.++ b) The work must carry prominent notices stating that it is+ released under this License and any conditions added under section+ 7. This requirement modifies the requirement in section 4 to+ "keep intact all notices".++ c) You must license the entire work, as a whole, under this+ License to anyone who comes into possession of a copy. This+ License will therefore apply, along with any applicable section 7+ additional terms, to the whole of the work, and all its parts,+ regardless of how they are packaged. This License gives no+ permission to license the work in any other way, but it does not+ invalidate such permission if you have separately received it.++ d) If the work has interactive user interfaces, each must display+ Appropriate Legal Notices; however, if the Program has interactive+ interfaces that do not display Appropriate Legal Notices, your+ work need not make them do so.++ A compilation of a covered work with other separate and independent+works, which are not by their nature extensions of the covered work,+and which are not combined with it such as to form a larger program,+in or on a volume of a storage or distribution medium, is called an+"aggregate" if the compilation and its resulting copyright are not+used to limit the access or legal rights of the compilation's users+beyond what the individual works permit. Inclusion of a covered work+in an aggregate does not cause this License to apply to the other+parts of the aggregate.++ 6. Conveying Non-Source Forms.++ You may convey a covered work in object code form under the terms+of sections 4 and 5, provided that you also convey the+machine-readable Corresponding Source under the terms of this License,+in one of these ways:++ a) Convey the object code in, or embodied in, a physical product+ (including a physical distribution medium), accompanied by the+ Corresponding Source fixed on a durable physical medium+ customarily used for software interchange.++ b) Convey the object code in, or embodied in, a physical product+ (including a physical distribution medium), accompanied by a+ written offer, valid for at least three years and valid for as+ long as you offer spare parts or customer support for that product+ model, to give anyone who possesses the object code either (1) a+ copy of the Corresponding Source for all the software in the+ product that is covered by this License, on a durable physical+ medium customarily used for software interchange, for a price no+ more than your reasonable cost of physically performing this+ conveying of source, or (2) access to copy the+ Corresponding Source from a network server at no charge.++ c) Convey individual copies of the object code with a copy of the+ written offer to provide the Corresponding Source. This+ alternative is allowed only occasionally and noncommercially, and+ only if you received the object code with such an offer, in accord+ with subsection 6b.++ d) Convey the object code by offering access from a designated+ place (gratis or for a charge), and offer equivalent access to the+ Corresponding Source in the same way through the same place at no+ further charge. You need not require recipients to copy the+ Corresponding Source along with the object code. If the place to+ copy the object code is a network server, the Corresponding Source+ may be on a different server (operated by you or a third party)+ that supports equivalent copying facilities, provided you maintain+ clear directions next to the object code saying where to find the+ Corresponding Source. Regardless of what server hosts the+ Corresponding Source, you remain obligated to ensure that it is+ available for as long as needed to satisfy these requirements.++ e) Convey the object code using peer-to-peer transmission, provided+ you inform other peers where the object code and Corresponding+ Source of the work are being offered to the general public at no+ charge under subsection 6d.++ A separable portion of the object code, whose source code is excluded+from the Corresponding Source as a System Library, need not be+included in conveying the object code work.++ A "User Product" is either (1) a "consumer product", which means any+tangible personal property which is normally used for personal, family,+or household purposes, or (2) anything designed or sold for incorporation+into a dwelling. In determining whether a product is a consumer product,+doubtful cases shall be resolved in favor of coverage. For a particular+product received by a particular user, "normally used" refers to a+typical or common use of that class of product, regardless of the status+of the particular user or of the way in which the particular user+actually uses, or expects or is expected to use, the product. A product+is a consumer product regardless of whether the product has substantial+commercial, industrial or non-consumer uses, unless such uses represent+the only significant mode of use of the product.++ "Installation Information" for a User Product means any methods,+procedures, authorization keys, or other information required to install+and execute modified versions of a covered work in that User Product from+a modified version of its Corresponding Source. The information must+suffice to ensure that the continued functioning of the modified object+code is in no case prevented or interfered with solely because+modification has been made.++ If you convey an object code work under this section in, or with, or+specifically for use in, a User Product, and the conveying occurs as+part of a transaction in which the right of possession and use of the+User Product is transferred to the recipient in perpetuity or for a+fixed term (regardless of how the transaction is characterized), the+Corresponding Source conveyed under this section must be accompanied+by the Installation Information. But this requirement does not apply+if neither you nor any third party retains the ability to install+modified object code on the User Product (for example, the work has+been installed in ROM).++ The requirement to provide Installation Information does not include a+requirement to continue to provide support service, warranty, or updates+for a work that has been modified or installed by the recipient, or for+the User Product in which it has been modified or installed. Access to a+network may be denied when the modification itself materially and+adversely affects the operation of the network or violates the rules and+protocols for communication across the network.++ Corresponding Source conveyed, and Installation Information provided,+in accord with this section must be in a format that is publicly+documented (and with an implementation available to the public in+source code form), and must require no special password or key for+unpacking, reading or copying.++ 7. Additional Terms.++ "Additional permissions" are terms that supplement the terms of this+License by making exceptions from one or more of its conditions.+Additional permissions that are applicable to the entire Program shall+be treated as though they were included in this License, to the extent+that they are valid under applicable law. If additional permissions+apply only to part of the Program, that part may be used separately+under those permissions, but the entire Program remains governed by+this License without regard to the additional permissions.++ When you convey a copy of a covered work, you may at your option+remove any additional permissions from that copy, or from any part of+it. (Additional permissions may be written to require their own+removal in certain cases when you modify the work.) You may place+additional permissions on material, added by you to a covered work,+for which you have or can give appropriate copyright permission.++ Notwithstanding any other provision of this License, for material you+add to a covered work, you may (if authorized by the copyright holders of+that material) supplement the terms of this License with terms:++ a) Disclaiming warranty or limiting liability differently from the+ terms of sections 15 and 16 of this License; or++ b) Requiring preservation of specified reasonable legal notices or+ author attributions in that material or in the Appropriate Legal+ Notices displayed by works containing it; or++ c) Prohibiting misrepresentation of the origin of that material, or+ requiring that modified versions of such material be marked in+ reasonable ways as different from the original version; or++ d) Limiting the use for publicity purposes of names of licensors or+ authors of the material; or++ e) Declining to grant rights under trademark law for use of some+ trade names, trademarks, or service marks; or++ f) Requiring indemnification of licensors and authors of that+ material by anyone who conveys the material (or modified versions of+ it) with contractual assumptions of liability to the recipient, for+ any liability that these contractual assumptions directly impose on+ those licensors and authors.++ All other non-permissive additional terms are considered "further+restrictions" within the meaning of section 10. If the Program as you+received it, or any part of it, contains a notice stating that it is+governed by this License along with a term that is a further+restriction, you may remove that term. If a license document contains+a further restriction but permits relicensing or conveying under this+License, you may add to a covered work material governed by the terms+of that license document, provided that the further restriction does+not survive such relicensing or conveying.++ If you add terms to a covered work in accord with this section, you+must place, in the relevant source files, a statement of the+additional terms that apply to those files, or a notice indicating+where to find the applicable terms.++ Additional terms, permissive or non-permissive, may be stated in the+form of a separately written license, or stated as exceptions;+the above requirements apply either way.++ 8. Termination.++ You may not propagate or modify a covered work except as expressly+provided under this License. Any attempt otherwise to propagate or+modify it is void, and will automatically terminate your rights under+this License (including any patent licenses granted under the third+paragraph of section 11).++ However, if you cease all violation of this License, then your+license from a particular copyright holder is reinstated (a)+provisionally, unless and until the copyright holder explicitly and+finally terminates your license, and (b) permanently, if the copyright+holder fails to notify you of the violation by some reasonable means+prior to 60 days after the cessation.++ Moreover, your license from a particular copyright holder is+reinstated permanently if the copyright holder notifies you of the+violation by some reasonable means, this is the first time you have+received notice of violation of this License (for any work) from that+copyright holder, and you cure the violation prior to 30 days after+your receipt of the notice.++ Termination of your rights under this section does not terminate the+licenses of parties who have received copies or rights from you under+this License. If your rights have been terminated and not permanently+reinstated, you do not qualify to receive new licenses for the same+material under section 10.++ 9. Acceptance Not Required for Having Copies.++ You are not required to accept this License in order to receive or+run a copy of the Program. Ancillary propagation of a covered work+occurring solely as a consequence of using peer-to-peer transmission+to receive a copy likewise does not require acceptance. However,+nothing other than this License grants you permission to propagate or+modify any covered work. These actions infringe copyright if you do+not accept this License. Therefore, by modifying or propagating a+covered work, you indicate your acceptance of this License to do so.++ 10. Automatic Licensing of Downstream Recipients.++ Each time you convey a covered work, the recipient automatically+receives a license from the original licensors, to run, modify and+propagate that work, subject to this License. You are not responsible+for enforcing compliance by third parties with this License.++ An "entity transaction" is a transaction transferring control of an+organization, or substantially all assets of one, or subdividing an+organization, or merging organizations. If propagation of a covered+work results from an entity transaction, each party to that+transaction who receives a copy of the work also receives whatever+licenses to the work the party's predecessor in interest had or could+give under the previous paragraph, plus a right to possession of the+Corresponding Source of the work from the predecessor in interest, if+the predecessor has it or can get it with reasonable efforts.++ You may not impose any further restrictions on the exercise of the+rights granted or affirmed under this License. For example, you may+not impose a license fee, royalty, or other charge for exercise of+rights granted under this License, and you may not initiate litigation+(including a cross-claim or counterclaim in a lawsuit) alleging that+any patent claim is infringed by making, using, selling, offering for+sale, or importing the Program or any portion of it.++ 11. Patents.++ A "contributor" is a copyright holder who authorizes use under this+License of the Program or a work on which the Program is based. The+work thus licensed is called the contributor's "contributor version".++ A contributor's "essential patent claims" are all patent claims+owned or controlled by the contributor, whether already acquired or+hereafter acquired, that would be infringed by some manner, permitted+by this License, of making, using, or selling its contributor version,+but do not include claims that would be infringed only as a+consequence of further modification of the contributor version. For+purposes of this definition, "control" includes the right to grant+patent sublicenses in a manner consistent with the requirements of+this License.++ Each contributor grants you a non-exclusive, worldwide, royalty-free+patent license under the contributor's essential patent claims, to+make, use, sell, offer for sale, import and otherwise run, modify and+propagate the contents of its contributor version.++ In the following three paragraphs, a "patent license" is any express+agreement or commitment, however denominated, not to enforce a patent+(such as an express permission to practice a patent or covenant not to+sue for patent infringement). To "grant" such a patent license to a+party means to make such an agreement or commitment not to enforce a+patent against the party.++ If you convey a covered work, knowingly relying on a patent license,+and the Corresponding Source of the work is not available for anyone+to copy, free of charge and under the terms of this License, through a+publicly available network server or other readily accessible means,+then you must either (1) cause the Corresponding Source to be so+available, or (2) arrange to deprive yourself of the benefit of the+patent license for this particular work, or (3) arrange, in a manner+consistent with the requirements of this License, to extend the patent+license to downstream recipients. "Knowingly relying" means you have+actual knowledge that, but for the patent license, your conveying the+covered work in a country, or your recipient's use of the covered work+in a country, would infringe one or more identifiable patents in that+country that you have reason to believe are valid.++ If, pursuant to or in connection with a single transaction or+arrangement, you convey, or propagate by procuring conveyance of, a+covered work, and grant a patent license to some of the parties+receiving the covered work authorizing them to use, propagate, modify+or convey a specific copy of the covered work, then the patent license+you grant is automatically extended to all recipients of the covered+work and works based on it.++ A patent license is "discriminatory" if it does not include within+the scope of its coverage, prohibits the exercise of, or is+conditioned on the non-exercise of one or more of the rights that are+specifically granted under this License. You may not convey a covered+work if you are a party to an arrangement with a third party that is+in the business of distributing software, under which you make payment+to the third party based on the extent of your activity of conveying+the work, and under which the third party grants, to any of the+parties who would receive the covered work from you, a discriminatory+patent license (a) in connection with copies of the covered work+conveyed by you (or copies made from those copies), or (b) primarily+for and in connection with specific products or compilations that+contain the covered work, unless you entered into that arrangement,+or that patent license was granted, prior to 28 March 2007.++ Nothing in this License shall be construed as excluding or limiting+any implied license or other defenses to infringement that may+otherwise be available to you under applicable patent law.++ 12. No Surrender of Others' Freedom.++ If conditions are imposed on you (whether by court order, agreement or+otherwise) that contradict the conditions of this License, they do not+excuse you from the conditions of this License. If you cannot convey a+covered work so as to satisfy simultaneously your obligations under this+License and any other pertinent obligations, then as a consequence you may+not convey it at all. For example, if you agree to terms that obligate you+to collect a royalty for further conveying from those to whom you convey+the Program, the only way you could satisfy both those terms and this+License would be to refrain entirely from conveying the Program.++ 13. Remote Network Interaction; Use with the GNU General Public License.++ Notwithstanding any other provision of this License, if you modify the+Program, your modified version must prominently offer all users+interacting with it remotely through a computer network (if your version+supports such interaction) an opportunity to receive the Corresponding+Source of your version by providing access to the Corresponding Source+from a network server at no charge, through some standard or customary+means of facilitating copying of software. This Corresponding Source+shall include the Corresponding Source for any work covered by version 3+of the GNU General Public License that is incorporated pursuant to the+following paragraph.++ Notwithstanding any other provision of this License, you have+permission to link or combine any covered work with a work licensed+under version 3 of the GNU General Public License into a single+combined work, and to convey the resulting work. The terms of this+License will continue to apply to the part which is the covered work,+but the work with which it is combined will remain governed by version+3 of the GNU General Public License.++ 14. Revised Versions of this License.++ The Free Software Foundation may publish revised and/or new versions of+the GNU Affero General Public License from time to time. Such new versions+will be similar in spirit to the present version, but may differ in detail to+address new problems or concerns.++ Each version is given a distinguishing version number. If the+Program specifies that a certain numbered version of the GNU Affero General+Public License "or any later version" applies to it, you have the+option of following the terms and conditions either of that numbered+version or of any later version published by the Free Software+Foundation. If the Program does not specify a version number of the+GNU Affero General Public License, you may choose any version ever published+by the Free Software Foundation.++ If the Program specifies that a proxy can decide which future+versions of the GNU Affero General Public License can be used, that proxy's+public statement of acceptance of a version permanently authorizes you+to choose that version for the Program.++ Later license versions may give you additional or different+permissions. However, no additional obligations are imposed on any+author or copyright holder as a result of your choosing to follow a+later version.++ 15. Disclaimer of Warranty.++ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.++ 16. Limitation of Liability.++ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF+SUCH DAMAGES.++ 17. Interpretation of Sections 15 and 16.++ If the disclaimer of warranty and limitation of liability provided+above cannot be given local legal effect according to their terms,+reviewing courts shall apply local law that most closely approximates+an absolute waiver of all civil liability in connection with the+Program, unless a warranty or assumption of liability accompanies a+copy of the Program in return for a fee.++ END OF TERMS AND CONDITIONS++ How to Apply These Terms to Your New Programs++ If you develop a new program, and you want it to be of the greatest+possible use to the public, the best way to achieve this is to make it+free software which everyone can redistribute and change under these terms.++ To do so, attach the following notices to the program. It is safest+to attach them to the start of each source file to most effectively+state the exclusion of warranty; and each file should have at least+the "copyright" line and a pointer to where the full notice is found.++ <one line to give the program's name and a brief idea of what it does.>+ Copyright (C) <year> <name of author>++ This program is free software: you can redistribute it and/or modify+ it under the terms of the GNU Affero General Public License as published by+ the Free Software Foundation, either version 3 of the License, or+ (at your option) any later version.++ This program is distributed in the hope that it will be useful,+ but WITHOUT ANY WARRANTY; without even the implied warranty of+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+ GNU Affero General Public License for more details.++ You should have received a copy of the GNU Affero General Public License+ along with this program. If not, see <https://www.gnu.org/licenses/>.++Also add information on how to contact you by electronic and paper mail.++ If your software can interact with users remotely through a computer+network, you should also make sure that it provides a way for users to+get its source. For example, if your program is a web application, its+interface could display a "Source" link that leads users to an archive+of the code. There are many ways you could offer source, and different+solutions will be better for different programs; see section 13 for the+specific requirements.++ You should also get your employer (if you work as a programmer) or school,+if any, to sign a "copyright disclaimer" for the program, if necessary.+For more information on this, and how to apply and follow the GNU AGPL, see+<https://www.gnu.org/licenses/>.diff --git a/store/agents/comfy-mcp/README.md b/store/agents/comfy-mcp/README.mdnew file mode 100644index 000000000..16112995e--- /dev/null+++ b/store/agents/comfy-mcp/README.md@@ -0,0 +1,49 @@+# Comfy MCP · Variation garden++Follow a visual thread. Explore a family of forms, collect your favourites, and keep the recipe with every image.++```sh+harness dsh install autonomous/comfy-mcp+```++Open a workspace in Harness. Setup fetches upstream sources at the commit in `upstream.lock.json`,+installs a package-local Python 3.11 environment, and verifies the local tools. The starter runs+without credentials or a cloud account. Studio Viewer provides controls, history, downloads,+live agent updates, and failure recovery. Setup never edits an application's preferences.++## What runs here++The local starter creates deterministic procedural SVG artwork and a contact sheet. It is not diffusion or an AI-generated image claim. The native action submits the saved API workflow to an existing local ComfyUI, polls its result, and collects actual output images. The supplied native workflow uses no model and no paid API.++Edit `studio.json`, then run:++```sh+"$STUDIO_TOOLCHAIN/run.sh" generate # Grow variations+"$STUDIO_TOOLCHAIN/run.sh" comfy # Run ComfyUI workflow+```++The native command is optional and fails with a useful message when its external runtime is+unavailable. It never silently substitutes sample output. Use the upstream README in `upstream/`+for full native application setup. See `INTEGRATION.md` for the exact bridge and local test scope.++Every successful run owns a new folder under `out/runs/`, a `result.json` with parameters, engine,+source commit, timestamps, measured values, and downloadable artifacts. `.harness/verdict.json`+means the named artifact was produced, not that an engineering or aesthetic claim was certified.+The starter can be regenerated with no network after install.++## Development and testing++Install the shared viewer and this package with `harness dsh install <path> --link`.+`toolchain/doctor.sh` checks the local runtime. The repository's Studio Viewer browser suite+materializes temporary workspaces and exercises each shipped local workflow. Run it from+`store/viewers/studio-viewer` with `npm run test:browser`; exact results live in its `TESTING.md`.++## Credit and stewardship++[Comfy MCP](https://github.com/Comfy-Org/comfy-mcp) is maintained by Comfy Org. Its sources are+fetched unchanged at `d067bf7dc44b497d88f20c9cd227c64f2ac3e2af`. Upstream licensing: AGPL-3.0-or-later or commercial; wrapper MIT.+The original license is preserved in `LICENSE-upstream`; dependency terms still apply.++OpenHarness contributors wrote the MIT wrapper, local starter, and viewer integration. This is+an independent integration, not an upstream endorsement. Upstream bugs belong with the upstream+project; wrapper bugs belong in OpenHarness. Maintainers are welcome to take over this package.diff --git a/store/agents/comfy-mcp/THIRD_PARTY_NOTICES.md b/store/agents/comfy-mcp/THIRD_PARTY_NOTICES.mdnew file mode 100644index 000000000..f78f96ae1--- /dev/null+++ b/store/agents/comfy-mcp/THIRD_PARTY_NOTICES.md@@ -0,0 +1,9 @@+# Third-party notices++Comfy MCP — Comfy Org. https://github.com/Comfy-Org/comfy-mcp++Pinned source: d067bf7dc44b497d88f20c9cd227c64f2ac3e2af. Fetched at install into ignored `upstream/`, unmodified.+License: AGPL-3.0-or-later or commercial; wrapper MIT. See `LICENSE-upstream` and the fetched source tree.++The original local starter and wrapper are MIT licensed. The native runtime and separately+installed applications retain their own licenses. No upstream endorsement is claimed.diff --git a/store/agents/comfy-mcp/VERSIONS b/store/agents/comfy-mcp/VERSIONSnew file mode 100644index 000000000..f7e37b676--- /dev/null+++ b/store/agents/comfy-mcp/VERSIONS@@ -0,0 +1,2 @@+UPSTREAM_COMMIT=d067bf7dc44b497d88f20c9cd227c64f2ac3e2af+PYTHON=3.11diff --git a/store/agents/comfy-mcp/harness.json b/store/agents/comfy-mcp/harness.jsonnew file mode 100644index 000000000..0affa1d39--- /dev/null+++ b/store/agents/comfy-mcp/harness.json@@ -0,0 +1,33 @@+{+ "spec": 1,+ "id": "autonomous/comfy-mcp",+ "name": "Comfy MCP",+ "category": "Generative media",+ "author": "Comfy Org",+ "description": "Follow a visual thread. Explore a family of forms, collect your favourites, and keep the recipe with every image.",+ "engine": "codex",+ "workspace": {+ "template": "template",+ "marker": "studio.json",+ "init": "toolchain/init-workspace.sh"+ },+ "agent": {+ "instructions": "AGENTS.md",+ "skills": [+ "skills"+ ],+ "env": {+ "STUDIO_TOOLCHAIN": "${dsh}/toolchain",+ "STUDIO_PYTHON": "${dsh}/.venv/bin/python",+ "STUDIO_UPSTREAM": "${dsh}/upstream"+ }+ },+ "toolchain": {+ "setup": "toolchain/setup.sh",+ "doctor": "toolchain/doctor.sh"+ },+ "viewer": {+ "use": "autonomous/studio-viewer"+ },+ "verdict": ".harness/verdict.json"+}diff --git a/store/agents/comfy-mcp/requirements.in b/store/agents/comfy-mcp/requirements.innew file mode 100644index 000000000..8b1378917--- /dev/null+++ b/store/agents/comfy-mcp/requirements.in@@ -0,0 +1 @@+diff --git a/store/agents/comfy-mcp/requirements.lock b/store/agents/comfy-mcp/requirements.locknew file mode 100644index 000000000..818dca5c3--- /dev/null+++ b/store/agents/comfy-mcp/requirements.lock@@ -0,0 +1,2 @@+# This file was autogenerated by uv via the following command:+# uv pip compile requirements.in --python-version 3.11 --universal --generate-hashes -o requirements.lockdiff --git a/store/agents/comfy-mcp/skills/comfy-mcp/SKILL.md b/store/agents/comfy-mcp/skills/comfy-mcp/SKILL.mdnew file mode 100644index 000000000..c2b372060--- /dev/null+++ b/store/agents/comfy-mcp/skills/comfy-mcp/SKILL.md@@ -0,0 +1,19 @@+---+name: comfy-mcp+description: Create and inspect generative media projects in the Comfy MCP Harness workspace, including its local starter and optional upstream integration.+---++# Variation garden++Read `studio.json` to understand the current controls; `"$STUDIO_TOOLCHAIN/../studio.config.json"`+describes their ranges. Run `"$STUDIO_TOOLCHAIN/run.sh" generate` to make a new result.+Successful artifacts and their measurements are in `out/runs/<id>/`; `out/latest.json` names the+current result. A failed run preserves the last success and records the error in the verdict.++The local starter creates deterministic procedural SVG artwork and a contact sheet. It is not diffusion or an AI-generated image claim. The native action submits the saved API workflow to an existing local ComfyUI, polls its result, and collects actual output images. The supplied native workflow uses no model and no paid API.++Use `"$STUDIO_TOOLCHAIN/../README.md"` for the integration contract and commands. Read the relevant+files under `$STUDIO_UPSTREAM` before using an upstream API. Keep controls within their documented+ranges, preserve the data needed to reproduce a comparison, and distinguish preview results from+native service or hardware output. The viewer supports history and artifact downloads; tell the+user which run contains the result, and what was actually measured.diff --git a/store/agents/comfy-mcp/store.json b/store/agents/comfy-mcp/store.jsonnew file mode 100644index 000000000..8cd3fcf82--- /dev/null+++ b/store/agents/comfy-mcp/store.json@@ -0,0 +1,6 @@+{+ "homepage": "https://github.com/Comfy-Org/comfy-mcp",+ "upstream": "https://github.com/Comfy-Org/comfy-mcp",+ "license": "MIT; AGPL-3.0+ / commercial upstream",+ "screenshots": []+}diff --git a/store/agents/comfy-mcp/studio.config.json b/store/agents/comfy-mcp/studio.config.jsonnew file mode 100644index 000000000..93001f24b--- /dev/null+++ b/store/agents/comfy-mcp/studio.config.json@@ -0,0 +1,87 @@+{+ "title": "Variation garden",+ "description": "Follow a visual thread. Explore a family of forms, collect your favourites, and keep the recipe with every image.",+ "category": "Generative media",+ "scene": "SOMETHING NEW IS GROWING",+ "hint": "Choose an image to inspect it \u00b7 every variation keeps its seed",+ "tip": "A fixed seed makes a useful comparison. The local starter is procedural; connect ComfyUI for model-based work.",+ "previewLabel": "Procedural study \u00b7 no model needed",+ "controls": [+ {+ "id": "palette",+ "label": "Palette",+ "type": "select",+ "value": "orchard",+ "options": [+ {+ "value": "orchard",+ "label": "Orchard \u00b7 warm green"+ },+ {+ "value": "dusk",+ "label": "Dusk \u00b7 violet blue"+ },+ {+ "value": "citrus",+ "label": "Citrus \u00b7 coral gold"+ }+ ]+ },+ {+ "id": "seed",+ "label": "Seed",+ "type": "number",+ "value": 24,+ "min": 1,+ "max": 1000,+ "step": 1,+ "integer": true,+ "unit": "",+ "hint": ""+ },+ {+ "id": "complexity",+ "label": "Petals",+ "type": "number",+ "value": 6,+ "min": 3,+ "max": 12,+ "step": 1,+ "integer": true,+ "unit": "",+ "hint": ""+ },+ {+ "id": "variations",+ "label": "Variations",+ "type": "number",+ "value": 4,+ "min": 2,+ "max": 6,+ "step": 1,+ "integer": true,+ "unit": "",+ "hint": ""+ }+ ],+ "actions": [+ {+ "id": "generate",+ "label": "Grow variations",+ "description": ""+ },+ {+ "id": "comfy",+ "label": "Run ComfyUI workflow",+ "description": "Run workspace workflow.json against local ComfyUI on port 8188"+ }+ ],+ "credit": "Comfy MCP \u00b7 Comfy Org",+ "empty": "Adjust the controls, then make your first exploration. Every successful run stays in the history.",+ "theme": {+ "accent": "#896390",+ "tint": "#ece1ed",+ "stage": "#272032",+ "stage-accent": "#dcc2ec"+ }+}diff --git a/store/agents/comfy-mcp/template/studio.json b/store/agents/comfy-mcp/template/studio.jsonnew file mode 100644index 000000000..eaed2e3d3--- /dev/null+++ b/store/agents/comfy-mcp/template/studio.json@@ -0,0 +1,10 @@+{+ "spec": 1,+ "title": "Variation garden",+ "parameters": {+ "palette": "orchard",+ "seed": 24,+ "complexity": 6,+ "variations": 4+ }+}diff --git a/store/agents/comfy-mcp/template/workflow.json b/store/agents/comfy-mcp/template/workflow.jsonnew file mode 100644index 000000000..a8b07e08b--- /dev/null+++ b/store/agents/comfy-mcp/template/workflow.json@@ -0,0 +1,4 @@+{+ "1": { "class_type": "EmptyImage", "inputs": { "width": 512, "height": 512, "batch_size": 1, "color": 12640216 } },+ "2": { "class_type": "SaveImage", "inputs": { "images": ["1", 0], "filename_prefix": "Harness/local-workflow-check" } }+}diff --git a/store/agents/comfy-mcp/toolchain/doctor.sh b/store/agents/comfy-mcp/toolchain/doctor.shnew file mode 100755index 000000000..25955de0c--- /dev/null+++ b/store/agents/comfy-mcp/toolchain/doctor.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+test -x .venv/bin/python || { echo 'miss run toolchain/setup.sh to install the local runtime'; exit 1; }+.venv/bin/python -c 'import json; json.load(open("studio.config.json")); print("ok Comfy MCP local workflow")'+test -f upstream/README.md || { echo "miss pinned upstream sources"; exit 1; }+echo "ok upstream d067bf7dc44b"diff --git a/store/agents/comfy-mcp/toolchain/init-workspace.sh b/store/agents/comfy-mcp/toolchain/init-workspace.shnew file mode 100755index 000000000..1d2e53b34--- /dev/null+++ b/store/agents/comfy-mcp/toolchain/init-workspace.sh@@ -0,0 +1,3 @@+#!/usr/bin/env bash+set -euo pipefail+exec "${HARNESS_DSH_DIR:?}/toolchain/run.sh" generatediff --git a/store/agents/comfy-mcp/toolchain/run.sh b/store/agents/comfy-mcp/toolchain/run.shnew file mode 100755index 000000000..a9e5df771--- /dev/null+++ b/store/agents/comfy-mcp/toolchain/run.sh@@ -0,0 +1,6 @@+#!/usr/bin/env bash+set -euo pipefail+studio_package="$(cd "$(dirname "$0")/.." && pwd)"+export PATH="$studio_package/.venv/bin:$PATH"+export PYTHONUNBUFFERED=1+exec "$studio_package/.venv/bin/python" "$studio_package/toolchain/workflow.py" "$@"diff --git a/store/agents/comfy-mcp/toolchain/runtimes.sh b/store/agents/comfy-mcp/toolchain/runtimes.shnew file mode 100644index 000000000..7223c78dc--- /dev/null+++ b/store/agents/comfy-mcp/toolchain/runtimes.sh@@ -0,0 +1,192 @@+# shellcheck shell=bash+# runtimes.sh — the interpreters a store package runs on, found on this machine or fetched, never+# asked of the person who pressed Get.+#+# Sourced (not run) by a package's setup, doctor and viewer scripts. A new Mac has Apple's Python 3.9,+# no Homebrew and, for most people, no Node on PATH; a package that answers "brew install [email protected]"+# has failed its install. So:+#+# harness_node 18 node >= 18 on PATH, with npm: the machine's own, else the Node Harness+# itself runs on (~/.harness/runtime/current-node, laid down with the CLI)+# harness_uv uv on PATH: the machine's own, else a pinned, checksummed release+# fetched into ~/.harness/runtime+# harness_venv DIR 3.12 [MIN [BELOW]]+# DIR is a venv on CPython 3.12, which uv downloads when the machine+# has none. A venv already there on a Python in [MIN, BELOW) is kept.+# harness_pip DIR PKG… install into that venv, through uv+# harness_micromamba micromamba, pinned and checksummed, for native libraries PyPI has+# no wheel for (pycairo on macOS)+# harness_conda_env DIR SPEC… DIR is a conda-forge environment with those packages+#+# Every function prints `miss …` and returns 1 when it cannot deliver, so `harness_node 18 || exit 1`+# reads like the rest of a setup script. Nothing here touches the user's shell profile; what it+# installs lands in ~/.harness/runtime or the package's own directory (uv keeps its download cache+# where it always does, which a venv does not depend on).+#+# ONE copy is written by hand: store/tools/runtimes.sh in the OpenHarness repository. Each package+# carries an identical copy (a package installs alone, so it cannot reach this one);+# `node store/tools/sync-runtimes.mjs` rewrites them and the CLI's store spec fails when one drifts.++HARNESS_RUNTIME="${ADAPTER_RUNTIME_DIR:-${HOME:-}/.harness/runtime}"+# The Pythons uv downloads live with Harness's other runtimes, not in uv's own ~/.local/share/uv:+# a package's venv points at its interpreter, and `uv python uninstall` there must not break it.+UV_PYTHON_INSTALL_DIR="${UV_PYTHON_INSTALL_DIR:-$HARNESS_RUNTIME/python}"+export UV_PYTHON_INSTALL_DIR+HARNESS_UV_VERSION=0.12.15+HARNESS_MICROMAMBA_VERSION=2.9.0-0++_harness_platform() {+ case "$(uname -s)-$(uname -m)" in+ Darwin-arm64) echo darwin-arm64 ;;+ Darwin-x86_64) echo darwin-x64 ;;+ Linux-x86_64) echo linux-x64 ;;+ Linux-aarch64 | Linux-arm64) echo linux-arm64 ;;+ *) return 1 ;;+ esac+}++_harness_sha256() {+ if command -v shasum >/dev/null 2>&1; then shasum -a 256 "$1" | cut -d' ' -f1+ else sha256sum "$1" | cut -d' ' -f1; fi+}++# _harness_fetch URL DEST SHA256 — DEST exists only if what arrived matches the pinned checksum.+_harness_fetch() {+ local part="$2.part.$$"+ if ! curl -fsSL --retry 3 --connect-timeout 20 --max-time 900 -o "$part" "$1"; then+ rm -f "$part"; echo "miss could not download $1 — check this machine's internet connection"; return 1+ fi+ if [ "$(_harness_sha256 "$part")" != "$3" ]; then+ rm -f "$part"; echo "miss $1 did not match its pinned checksum; nothing was installed"; return 1+ fi+ mv -f "$part" "$2"+}++_harness_node_at_least() {+ command -v node >/dev/null 2>&1 || return 1+ node -e '+ const [a, b = 0] = process.argv[1].split(".").map(Number)+ const [x, y] = process.versions.node.split(".").map(Number)+ process.exit(x > a || (x === a && y >= b) ? 0 : 1)+ ' "$1" >/dev/null 2>&1+}++harness_node() {+ local min="${1:-18}" recorded saved="$PATH" own=0+ _harness_node_at_least "$min" && own=1+ # A node without npm beside it (a distro's nodejs package) cannot run a setup's `npm ci`.+ if [ "$own" = 1 ] && command -v npm >/dev/null 2>&1; then return 0; fi+ recorded="$(cat "$HARNESS_RUNTIME/current-node" 2>/dev/null || true)"+ # Already Harness's own (a second call, or a wrapper calling a script that asks again): nothing to add.+ if [ "$own" = 1 ] && [ -n "$recorded" ] && [ "$(command -v node)" = "${recorded%/*}/node" ]; then return 0; fi+ if [ -n "$recorded" ] && [ -x "${recorded%/*}/node" ]; then+ PATH="${recorded%/*}:$PATH"; export PATH; hash -r 2>/dev/null || true+ _harness_node_at_least "$min" && return 0+ PATH="$saved"; export PATH; hash -r 2>/dev/null || true+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min — this machine's newest is $("${recorded%/*}/node" -v), Harness's own; update Harness"+ return 1+ fi+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min, and Harness's own Node is not in $HARNESS_RUNTIME — run \`harness start\` once to lay it down"+ return 1+}++harness_uv() {+ local dir asset sum tmp+ command -v uv >/dev/null 2>&1 && return 0+ for dir in "${HOME:-}/.local/bin" "${HOME:-}/.cargo/bin"; do+ [ -n "${HOME:-}" ] || break+ if [ -x "$dir/uv" ]; then PATH="$dir:$PATH"; export PATH; return 0; fi+ done+ dir="$HARNESS_RUNTIME/uv-$HARNESS_UV_VERSION"+ if [ ! -x "$dir/uv" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=uv-aarch64-apple-darwin sum=dc304b9ed1b24174572290fba60ac3f6fe63c73a671f0439e62a91375841964d ;;+ darwin-x64) asset=uv-x86_64-apple-darwin sum=e9ca61775532368fe518ab03e7a354c7ecab8ccb3c7d941c775fcc4a362b801b ;;+ linux-x64) asset=uv-x86_64-unknown-linux-gnu sum=f97935763c04be3e692460a7aaeaaab8fc3b78fcf8b389da820b38ae7423a638 ;;+ linux-arm64) asset=uv-aarch64-unknown-linux-gnu sum=0e9a3499b0587d449c9ff684c0160da607826e4af1cee220bc87f378702d3e08 ;;+ *) echo "miss uv — there is no uv release for $(uname -s) $(uname -m); install it from https://docs.astral.sh/uv/"; return 1 ;;+ esac+ echo " fetching uv $HARNESS_UV_VERSION into $HARNESS_RUNTIME (it brings Python and the packages)"+ mkdir -p "$HARNESS_RUNTIME" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ tmp="$(mktemp -d "$HARNESS_RUNTIME/.uv.XXXXXX")" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ if ! _harness_fetch "https://github.com/astral-sh/uv/releases/download/$HARNESS_UV_VERSION/$asset.tar.gz" "$tmp/uv.tar.gz" "$sum"; then+ rm -rf "$tmp"; return 1+ fi+ tar -xzf "$tmp/uv.tar.gz" -C "$tmp" && chmod +x "$tmp/$asset/uv" "$tmp/$asset/uvx" \+ || { rm -rf "$tmp"; echo "miss the uv archive would not unpack"; return 1; }+ # Two installs at once both get here; whichever renames first wins and the other's copy goes.+ # (mv onto a directory that exists would nest the copy inside it, hence the test.)+ [ -e "$dir" ] || mv "$tmp/$asset" "$dir" 2>/dev/null || true+ rm -rf "$tmp"+ [ -x "$dir/uv" ] || { echo "miss uv did not land in $dir"; return 1; }+ fi+ PATH="$dir:$PATH"; export PATH+}++# harness_venv DIR VERSION [MIN [BELOW]] — MIN defaults to VERSION; BELOW is exclusive and optional.+harness_venv() {+ local dir="${1:?harness_venv needs a directory}" want="${2:?harness_venv needs a Python version}"+ local min="${3:-$2}" below="${4:-}"+ if [ -x "$dir/bin/python" ] && "$dir/bin/python" -c '+import sys+at = lambda s: tuple(int(p) for p in s.split("."))+v = sys.version_info[:2]+sys.exit(0 if v >= at(sys.argv[1]) and (not sys.argv[2] or v < at(sys.argv[2])) else 1)+' "$min" "$below" 2>/dev/null; then+ echo "ok $("$dir/bin/python" --version) in $dir"+ return 0+ fi+ harness_uv || return 1+ echo " python $want in $dir (uv downloads it when this machine has none)"+ rm -rf "$dir"+ # only-managed: the same python-build-standalone interpreter on every machine, so a package tested+ # once is tested everywhere — not whichever Homebrew or pyenv Python happened to be first on PATH.+ uv venv --quiet --seed --python "$want" --python-preference only-managed "$dir" \+ || { echo "miss could not make a Python $want environment in $dir"; return 1; }+ echo "ok $("$dir/bin/python" --version) in $dir"+}++harness_pip() {+ local dir="${1:?harness_pip needs a venv}"+ shift+ harness_uv || return 1+ # uv's own error comes first; the miss line is last, so it is the line the store shows.+ uv pip install --quiet --python "$dir/bin/python" "$@" \+ || { echo "miss could not install $* into $dir"; return 1; }+}++harness_micromamba() {+ local dir asset sum+ dir="$HARNESS_RUNTIME/micromamba-$HARNESS_MICROMAMBA_VERSION"+ if [ ! -x "$dir/micromamba" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=micromamba-osx-arm64 sum=ec2a072f028e1a7cf20f3e2e74d5a8127cf5a5f27636375b5359811565f4e5be ;;+ darwin-x64) asset=micromamba-osx-64 sum=1e71054bb3ac9a076e21f7ec48acfef536f9b3f1408f371a942784bf5ef83d8a ;;+ linux-x64) asset=micromamba-linux-64 sum=366cd9cd8be14df1ab8ed50352a82111082a36686b2d389fdb79a92c3fafb3e3 ;;+ linux-arm64) asset=micromamba-linux-aarch64 sum=9f93b974adcb4d166996af969b6cd371287d1a3e52733704727884d9b74cb7a7 ;;+ *) echo "miss micromamba — there is no release for $(uname -s) $(uname -m)"; return 1 ;;+ esac+ echo " fetching micromamba $HARNESS_MICROMAMBA_VERSION into $HARNESS_RUNTIME (native libraries PyPI has no wheel for)"+ mkdir -p "$dir" || { echo "miss cannot write $dir"; return 1; }+ _harness_fetch "https://github.com/mamba-org/micromamba-releases/releases/download/$HARNESS_MICROMAMBA_VERSION/$asset" "$dir/micromamba.$$" "$sum" || return 1+ chmod +x "$dir/micromamba.$$" && mv -f "$dir/micromamba.$$" "$dir/micromamba" \+ || { rm -f "$dir/micromamba.$$"; echo "miss micromamba would not install into $dir"; return 1; }+ fi+ HARNESS_MICROMAMBA="$dir/micromamba"+ export HARNESS_MICROMAMBA+}++# harness_conda_env DIR SPEC… — conda-forge only, packages cached under ~/.harness/runtime/mamba.+harness_conda_env() {+ local dir="${1:?harness_conda_env needs a directory}"+ shift+ # micromamba takes a relative --prefix as a name under its root prefix and "succeeds" there.+ case "$dir" in /*) ;; *) dir="$PWD/$dir" ;; esac+ harness_micromamba || return 1+ MAMBA_ROOT_PREFIX="$HARNESS_RUNTIME/mamba" "$HARNESS_MICROMAMBA" create --yes --quiet \+ --prefix "$dir" --override-channels --channel conda-forge "$@" >/dev/null \+ && [ -d "$dir/conda-meta" ] \+ || { echo "miss could not make the conda-forge environment in $dir ($*)"; return 1; }+}diff --git a/store/agents/comfy-mcp/toolchain/setup.sh b/store/agents/comfy-mcp/toolchain/setup.shnew file mode 100755index 000000000..efbece7e2--- /dev/null+++ b/store/agents/comfy-mcp/toolchain/setup.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+harness_venv .venv 3.11 3.11 3.12+.venv/bin/python toolchain/studio_fetch.py+if [ -s requirements.lock ]; then harness_pip .venv --require-hashes -r requirements.lock; fi+exec toolchain/doctor.shdiff --git a/store/agents/comfy-mcp/toolchain/studio_fetch.py b/store/agents/comfy-mcp/toolchain/studio_fetch.pynew file mode 100644index 000000000..88a670b25--- /dev/null+++ b/store/agents/comfy-mcp/toolchain/studio_fetch.py@@ -0,0 +1,34 @@+"""Fetch reviewed source pins without installing a service or changing user configuration."""+import json+import os+from pathlib import Path+import subprocess++root = Path(__file__).resolve().parent.parent+sources = json.loads((root / "upstream.lock.json").read_text())+for source in sources:+ target = root / source["directory"]+ def git(*args):+ return subprocess.check_output(["git", "-C", str(target), *args], text=True,+ env={**os.environ, "GIT_LFS_SKIP_SMUDGE": "1"}).strip()+ if not (target / ".git").exists():+ target.mkdir(parents=True, exist_ok=True)+ git("init", "-q")+ git("remote", "add", "origin", source["url"])+ if source.get("sparse"):+ git("sparse-checkout", "init", "--cone")+ git("sparse-checkout", "set", *source["sparse"])+ if git("remote", "get-url", "origin") != source["url"]:+ raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])+ try:+ current = git("rev-parse", "HEAD")+ except subprocess.CalledProcessError:+ current = ""+ if current != source["commit"]:+ if current and git("status", "--porcelain"):+ raise SystemExit(f"Save your edits in {target} before changing its source pin")+ git("fetch", "--depth", "1", "--filter=blob:none", "origin", source["commit"])+ git("checkout", "--detach", source["commit"])+ print(f'ok {source["name"]} at {source["commit"][:12]}', flush=True)diff --git a/store/agents/comfy-mcp/toolchain/studio_runtime.py b/store/agents/comfy-mcp/toolchain/studio_runtime.pynew file mode 100644index 000000000..8b8ea016c--- /dev/null+++ b/store/agents/comfy-mcp/toolchain/studio_runtime.py@@ -0,0 +1,132 @@+"""Portable runner copied into each independently installable studio package."""+import json+import math+import os+from pathlib import Path+import subprocess+import sys+import tempfile+import time+import uuid+++def workspace():+ return Path(os.environ.get("HARNESS_WORKSPACE", os.getcwd())).resolve()+++def package():+ return Path(__file__).resolve().parent.parent+++def contained(path):+ target = Path(path).resolve()+ target.relative_to(workspace())+ return target+++def atomic_json(path, data):+ path = contained(path)+ path.parent.mkdir(parents=True, exist_ok=True)+ with tempfile.NamedTemporaryFile(mode="w", dir=path.parent, prefix=".studio-", delete=False) as f:+ json.dump(data, f, indent=2, allow_nan=False)+ f.write("\n")+ temp = f.name+ os.replace(temp, path)+++def command(argv, cwd=None, timeout=120, env=None):+ """No shell interpolation; keep complete logs as output, bound execution time."""+ result = subprocess.run([str(x) for x in argv], cwd=cwd, timeout=timeout,+ env=env, text=True, capture_output=True)+ if result.returncode:+ raise RuntimeError((result.stderr or result.stdout)[-1600:] or f"{argv[0]} exited {result.returncode}")+ return result.stdout+++def parameters(config, values):+ if not isinstance(values, dict) or set(values) - {c["id"] for c in config["controls"]}:+ raise ValueError("Invalid studio controls")+ result = {}+ for c in config["controls"]:+ value = values.get(c["id"], c["value"])+ if c["type"] == "number":+ if type(value) not in (int, float) or not math.isfinite(value) or not c["min"] <= value <= c["max"]:+ raise ValueError(f'{c["label"]} is outside its range')+ if c.get("integer") and value != int(value):+ raise ValueError(f'{c["label"]} must be a whole number')+ elif c["type"] == "select":+ if value not in [o["value"] for o in c["options"]]:+ raise ValueError(f'Unknown {c["label"]}')+ elif not isinstance(value, str) or len(value) > c.get("maxLength", 500):+ raise ValueError(f'Invalid {c["label"]}')+ result[c["id"]] = value+ return result+++def metric(label, value, unit=""):+ return {"label": label, "value": value, "unit": unit}+++def previous_runs():+ base = contained(workspace() / "out/runs")+ rows = []+ for p in sorted(base.glob("*/result.json"))[-100:]:+ try:+ rows.append(json.loads(contained(p).read_text()))+ except (ValueError, OSError):+ continue+ return rows+++def execute(actions):+ root = workspace()+ config = json.loads((package() / "studio.config.json").read_text())+ action = sys.argv[1] if len(sys.argv) > 1 else config["actions"][0]["id"]+ started = time.monotonic()+ verdict_path = root / ".harness/verdict.json"+ verdict = {"spec": 1, "ready": False, "summary": "Preparing the studio run", "findings": [],+ "phases": [{"id": "run", "name": "Make", "state": "active"},+ {"id": "inspect", "name": "Inspect", "state": "pending"}]}+ try:+ if action not in actions:+ raise ValueError(f"Unknown action: {action}")+ source = contained(root / "studio.json")+ if source.stat().st_size > 16384:+ raise ValueError("studio.json is too large")+ project = json.loads(source.read_text())+ p = parameters(config, project["parameters"])+ atomic_json(verdict_path, verdict)+ run_id = time.strftime("%Y%m%dT%H%M%S", time.gmtime()) + "-" + uuid.uuid4().hex[:8]+ output = contained(root / "out/runs" / run_id)+ output.mkdir(parents=True)+ print(f'{config["title"]}: {action}', flush=True)+ result = actions[action](p, output)+ artifacts = []+ for artifact in result.pop("files", []):+ file = contained(output / artifact["name"])+ file.relative_to(output)+ if not file.is_file() or not file.stat().st_size:+ raise ValueError(f'Missing output: {artifact["name"]}')+ artifacts.append({"label": artifact["label"], "path": str(file.relative_to(root))})+ result.update({"spec": 1, "id": run_id, "action": action, "parameters": p,+ "createdAt": time.strftime("%Y-%m-%dT%H:%M:%SZ", time.gmtime()),+ "durationSeconds": round(time.monotonic() - started, 3), "artifacts": artifacts,+ "upstream": json.loads((package() / "upstream.lock.json").read_text())})+ atomic_json(output / "result.json", result)+ atomic_json(root / "out/latest.json", result)+ verdict.update({"ready": True, "summary": f'{result["title"]} · {result["engine"]}',+ "artifact": str((output / "result.json").relative_to(root)),+ "phases": [{"id": "run", "name": "Make", "state": "done"},+ {"id": "inspect", "name": "Inspect", "state": "done"}],+ "updatedAt": result["createdAt"]})+ atomic_json(verdict_path, verdict)+ print(f'Ready: {result["title"]}', flush=True)+ except Exception as exc:+ verdict.update({"summary": str(exc)[:500], "findings": [{"severity": "error", "kind": "run-failed", "message": str(exc)[:1000]}],+ "phases": [{"id": "run", "name": "Make", "state": "failed"}]})+ try:+ atomic_json(verdict_path, verdict)+ except (ValueError, OSError):+ pass+ print(str(exc), file=sys.stderr)+ raise SystemExit(1) from excdiff --git a/store/agents/comfy-mcp/toolchain/workflow.py b/store/agents/comfy-mcp/toolchain/workflow.pynew file mode 100644index 000000000..dd513ec0e--- /dev/null+++ b/store/agents/comfy-mcp/toolchain/workflow.py@@ -0,0 +1,96 @@+import hashlib+import json+import math+import os+from pathlib import Path+import random+import time+import urllib.error+import urllib.parse+import urllib.request+from studio_runtime import execute, metric, workspace, contained++PALETTES={'orchard':['#ecefdc','#47764e','#b8cf79','#d6a877','#253e31'],+ 'dusk':['#e8e2f0','#7163a7','#afa9d8','#dba8ae','#302741'],+ 'citrus':['#faead4','#cf6e51','#f1c579','#e6a79a','#623d36']}+++def artwork(p,seed):+ rng=random.Random(seed);palette=PALETTES[p['palette']]+ parts=[f'<svg xmlns="http://www.w3.org/2000/svg" width="640" height="640" viewBox="0 0 640 640"><rect width="640" height="640" fill="{palette[0]}"/>',+ '<defs><filter id="shadow"><feGaussianBlur stdDeviation="9"/></filter></defs>',+ f'<ellipse cx="326" cy="490" rx="128" ry="22" fill="{palette[4]}" opacity=".12" filter="url(#shadow)"/>']+ center=(320+rng.uniform(-25,25),310+rng.uniform(-20,20))+ for ring in [1,.62]:+ for i in range(p['complexity']):+ angle=i*360/p['complexity']+rng.uniform(-10,10);x=center[0]+math.cos(math.radians(angle))*85*ring;y=center[1]+math.sin(math.radians(angle))*85*ring+ color=palette[1+(i+seed)%3]+ parts.append(f'<ellipse cx="{x:.2f}" cy="{y:.2f}" rx="{75*ring:.2f}" ry="{132*ring:.2f}" transform="rotate({angle+90:.2f} {x:.2f} {y:.2f})" fill="{color}" opacity=".83"/>')+ parts.append(f'<circle cx="{center[0]:.2f}" cy="{center[1]:.2f}" r="39" fill="{palette[4]}"/>')+ for i in range(65):+ angle=rng.random()*math.tau;distance=rng.random()**.5*32+ parts.append(f'<circle cx="{center[0]+math.cos(angle)*distance:.2f}" cy="{center[1]+math.sin(angle)*distance:.2f}" r="{rng.uniform(.5,1.8):.2f}" fill="{palette[0]}" opacity=".55"/>')+ parts.extend([f'<path d="M320 451 Q335 504 308 545" stroke="{palette[1]}" fill="none" stroke-width="3"/>',+ f'<path d="M320 501 Q359 477 372 503 Q337 524 320 501" fill="{palette[2]}"/>',+ f'<text x="35" y="42" font-family="sans-serif" font-size="10" letter-spacing="3" fill="{palette[4]}">VARIATION GARDEN</text>',+ f'<text x="35" y="602" font-family="sans-serif" font-size="12" fill="{palette[4]}">STUDY {seed:04d}</text>',+ f'<text x="488" y="602" font-family="sans-serif" font-size="10" fill="{palette[4]}">{p["palette"].upper()}</text></svg>'])+ return ''.join(parts)+++def generate(p,out):+ images=[];files=[]+ for i in range(p['variations']):+ seed=p['seed']+i;name=f'study-{seed}.svg';content=artwork(p,seed);(out/name).write_text(content)+ images.append({'seed':seed,'name':name,'sha256':hashlib.sha256(content.encode()).hexdigest()})+ files.append({'label':f'Study {seed} · SVG','name':name})+ (out/'recipe.json').write_text(json.dumps({'engine':'Original procedural SVG generator','parameters':p,'images':images},indent=2))+ files.append({'label':'Reproduction recipe','name':'recipe.json'})+ return {'title':f'{p["palette"].capitalize()} · {len(images)} new possibilities','description':'Original procedural vector studies, each with a reproducible seed. These are local generative graphics; no diffusion model or paid service was used.','engine':'Local procedural SVG · deterministic seeds','metrics':[metric('Variations',len(images)),metric('First seed',p['seed']),metric('Canvas',640,'× 640')],'data':{'images':images},'files':files}+++def comfy(p,out):+ base=os.environ.get('COMFYUI_URL','http://127.0.0.1:8188').rstrip('/')+ url=urllib.parse.urlparse(base)+ if url.scheme!='http' or url.hostname not in ('127.0.0.1','localhost','::1') or url.username or url.password or url.path:+ raise ValueError('This local studio expects COMFYUI_URL to be a loopback HTTP address.')+ path=contained(workspace()/'workflow.json')+ if path.stat().st_size>1_000_000:raise ValueError('workflow.json is too large')+ workflow=json.loads(path.read_text())+ if not isinstance(workflow,dict) or not workflow or any(not isinstance(v,dict) or not isinstance(v.get('class_type'),str) for v in workflow.values()):+ raise ValueError('Save an API-format ComfyUI workflow in workflow.json.')+ def request(endpoint,data=None):+ req=urllib.request.Request(base+endpoint,data=json.dumps(data).encode() if data is not None else None,headers={'Content-Type':'application/json'})+ try:+ with urllib.request.urlopen(req,timeout=5) as response:+ return json.loads(response.read(2_000_000))+ except urllib.error.URLError as exc:+ raise RuntimeError('Start local ComfyUI on port 8188, then run again. '+str(exc)) from exc+ response=request('/prompt',{'prompt':workflow,'client_id':'harness-studio'})+ if response.get('node_errors') or not response.get('prompt_id'):+ raise RuntimeError('ComfyUI rejected the workflow: '+json.dumps(response.get('node_errors',response))[:800])+ prompt_id=response['prompt_id'];deadline=time.monotonic()+float(os.environ.get('STUDIO_COMFY_TIMEOUT','90'));job=None+ print('ComfyUI accepted the workflow. Waiting for its outputs…',flush=True)+ while time.monotonic()<deadline:+ history=request('/history/'+urllib.parse.quote(prompt_id,safe=''))+ job=history.get(prompt_id)+ if job:+ if job.get('status',{}).get('status_str')=='error':raise RuntimeError('ComfyUI execution failed: '+json.dumps(job['status'])[:800])+ if job.get('outputs'):break+ time.sleep(.5)+ else:raise RuntimeError('ComfyUI did not finish before the local time limit. Check its queue; the remote job may still be running.')+ images=[];files=[]+ for output in job['outputs'].values():+ for asset in output.get('images',[]):+ query=urllib.parse.urlencode({k:asset[k] for k in ['filename','subfolder','type'] if k in asset})+ with urllib.request.urlopen(base+'/view?'+query,timeout=10) as response:+ content=response.read(32*1024*1024+1)+ if len(content)>32*1024*1024:raise RuntimeError('A ComfyUI image exceeded the local download limit.')+ if not content.startswith(b'\x89PNG\r\n\x1a\n'):raise RuntimeError('This image workflow must produce PNG outputs.')+ name=f'comfy-{len(images)+1}.png';(out/name).write_bytes(content);images.append({'seed':None,'name':name});files.append({'label':f'ComfyUI image {len(images)}','name':name})+ if not images:raise RuntimeError('The workflow produced no images. Use SaveImage in workflow.json.')+ (out/'comfy-history.json').write_text(json.dumps(job,indent=2));files.append({'label':'ComfyUI run record','name':'comfy-history.json'})+ return {'title':f'ComfyUI · {len(images)} image outputs','description':'These images were returned by the saved workflow running on local ComfyUI. Model and node requirements belong to that workflow.','engine':'Native ComfyUI · local workflow','metrics':[metric('Images',len(images))],'data':{'images':images,'promptId':prompt_id},'files':files}+++if __name__=='__main__':execute({'generate':generate,'comfy':comfy})diff --git a/store/agents/comfy-mcp/upstream.lock.json b/store/agents/comfy-mcp/upstream.lock.jsonnew file mode 100644index 000000000..4c0956235--- /dev/null+++ b/store/agents/comfy-mcp/upstream.lock.json@@ -0,0 +1,11 @@+[+ {+ "name": "Comfy MCP",+ "url": "https://github.com/Comfy-Org/comfy-mcp.git",+ "commit": "d067bf7dc44b497d88f20c9cd227c64f2ac3e2af",+ "directory": "upstream",+ "sparse": [+ "src"+ ]+ }+]diff --git a/store/agents/comfy-mcp/view.mjs b/store/agents/comfy-mcp/view.mjsnew file mode 100644index 000000000..733f039a8--- /dev/null+++ b/store/agents/comfy-mcp/view.mjs@@ -0,0 +1,11 @@+import {el,toolbar,badge,label} from '/graphics.mjs';+export function mount(stage,api){+ let p=api.getParameters(),result,selected=-1,last='',dialog;+ const tag=badge(stage,'PROCEDURAL STUDIES'),info=label(stage,'A family of forms. Pick the one that speaks to you.');+ const gallery=el('div','','gallery');stage.append(gallery);+ function close(){dialog?.remove();dialog=null;}+ function inspect(index){const img=result?.data?.images?.[index];if(!img)return;close();selected=index;dialog=el('div','','domain-dialog');dialog.setAttribute('role','dialog');dialog.setAttribute('aria-label','Inspect study');const b=el('button','Close');b.addEventListener('click',()=>{close();gallery.children[index]?.focus();});const picture=el('img');picture.src=api.artifactURL(result.artifacts.find(a=>a.path.endsWith('/'+img.name)).path);picture.alt=img.seed===null?'ComfyUI workflow output':`Procedural study ${img.seed}`;dialog.append(b,el('h2',img.seed===null?'ComfyUI output':`Study ${String(img.seed).padStart(4,'0')}`),picture,el('p',img.seed===null?'Produced by your saved ComfyUI workflow.':`Reproduce this study with seed ${img.seed} and the saved recipe.`));stage.append(dialog);b.focus();api.announce('Study opened.');}+ stage.addEventListener('keydown',e=>{if(e.key==='Escape')close();});+ toolbar(stage,[['Another family',()=>api.setParameter('seed',p.seed%980+7)],['Inspect favourite',()=>inspect(selected<0?0:selected)]]);+ return {update(params,r){p=params;result=r;if(!r?.data?.images){gallery.replaceChildren(el('div','Grow a family of variations to explore.','domain-empty'));return;}if(r.id===last)return;last=r.id;close();gallery.replaceChildren();tag.textContent=r.engine.startsWith('Native')?'COMFYUI OUTPUTS':'PROCEDURAL STUDIES';r.data.images.forEach((img,i)=>{const file=r.artifacts.find(a=>a.path.endsWith('/'+img.name));if(!file)return;const button=el('button');button.type='button';button.setAttribute('aria-label',img.seed===null?`Inspect image ${i+1}`:`Inspect study ${img.seed}`);const image=el('img');image.src=api.artifactURL(file.path);image.alt=img.seed===null?'ComfyUI output':`A ${r.parameters.palette} procedural flower, seed ${img.seed}`;const caption=el('figcaption',img.seed===null?`Output ${i+1}`:`No. ${String(img.seed).padStart(4,'0')} ↗`);button.append(image,caption);button.addEventListener('click',()=>inspect(i));gallery.append(button);});}};+}diff --git a/store/agents/dimos/.gitignore b/store/agents/dimos/.gitignorenew file mode 100644index 000000000..97ed7159a--- /dev/null+++ b/store/agents/dimos/.gitignore@@ -0,0 +1,8 @@+upstream/+juce/+.venv/+.build/+.sumo/+__pycache__/+*.pyc+coverage/diff --git a/store/agents/dimos/AGENTS.md b/store/agents/dimos/AGENTS.mdnew file mode 100644index 000000000..faed85c29--- /dev/null+++ b/store/agents/dimos/AGENTS.md@@ -0,0 +1,18 @@+# DimOS workspace++This harness turns a request into a real, inspectable robotics artifact. Start with+the `dimos` skill. The editable project is `studio.json` plus files in this workspace.+The viewer follows `out/latest.json` and the run history; save small useful changes as you work.++Run `"$STUDIO_TOOLCHAIN/run.sh" simulate` after a change. The runner validates controls,+records provenance, writes artifacts, and updates `.harness/verdict.json`. Do not hand-edit the+verdict to claim a run succeeded. Inspect the produced artifact before describing the result.++The starter performs A* route planning and real MuJoCo dynamics in an original two-dimensional office rover model. It is not a Unitree robot or physical execution. DimOS is fetched at a pinned source commit; its full daemon and perception stack are an optional, larger installation.++The installed sources are at `$STUDIO_UPSTREAM`. Preserve upstream credit and use the pinned+instructions when extending the domain workflow. Local simulations are the default. Ask before+using a paid generation service or operating physical hardware unless the user already authorized it.++When developing this package itself, keep it independently installable from its folder; shared+runtime copies are synchronized by `store/tools/sync-studios.mjs` and `sync-runtimes.mjs`.diff --git a/store/agents/dimos/INTEGRATION.md b/store/agents/dimos/INTEGRATION.mdnew file mode 100644index 000000000..4798071b6--- /dev/null+++ b/store/agents/dimos/INTEGRATION.md@@ -0,0 +1,12 @@+# A* navigation and MuJoCo dynamics++`simulate` creates an original rover/world MJCF, plans on an inflated obstacle grid, executes velocity controls in MuJoCo, and records positions, contacts and arrival. Viewer playback uses those positions. The `dimos` action only runs `dimos status` if that executable is available. The full pinned DimOS source and agent instructions are available under `upstream/`; its installer and perception extras are separate from the small local runtime.++## Verification scope++The local mission is actual MuJoCo simulation with no physical hardware. It is not a Unitree model or a claim of physical mission completion. MuJoCo 3.3.7 is pinned because it provides an Intel Mac wheel.++The browser acceptance suite lives in `store/viewers/studio-viewer/test/studios.e2e.mjs`.+`TESTING.md` beside that viewer records commands, outcomes, screenshots and coverage.+Upstream source revisions are in `upstream.lock.json`; install-time Python dependencies are+hash-locked in `requirements.lock`. No user application configuration is written by setup.diff --git a/store/agents/dimos/LICENSE b/store/agents/dimos/LICENSEnew file mode 100644index 000000000..a499cd17e--- /dev/null+++ b/store/agents/dimos/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Autonomous, Inc.++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/dimos/LICENSE-upstream b/store/agents/dimos/LICENSE-upstreamnew file mode 100644index 000000000..5e2927e3a--- /dev/null+++ b/store/agents/dimos/LICENSE-upstream@@ -0,0 +1,17 @@+ Apache License+ Version 2.0, January 2004+ http://www.apache.org/licenses/++ Copyright 2025 Dimensional Inc.++ Licensed under the Apache License, Version 2.0 (the "License");+ you may not use this file except in compliance with the License.+ You may obtain a copy of the License at++ http://www.apache.org/licenses/LICENSE-2.0++ Unless required by applicable law or agreed to in writing, software+ distributed under the License is distributed on an "AS IS" BASIS,+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+ See the License for the specific language governing permissions and+ limitations under the License.diff --git a/store/agents/dimos/README.md b/store/agents/dimos/README.mdnew file mode 100644index 000000000..296f704dd--- /dev/null+++ b/store/agents/dimos/README.md@@ -0,0 +1,49 @@+# DimOS · Mission control++Send a little rover on a small adventure. Pick a destination, watch it find a way, and replay the journey.++```sh+harness dsh install autonomous/dimos+```++Open a workspace in Harness. Setup fetches upstream sources at the commit in `upstream.lock.json`,+installs a package-local Python 3.11 environment, and verifies the local tools. The starter runs+without credentials or a cloud account. Studio Viewer provides controls, history, downloads,+live agent updates, and failure recovery. Setup never edits an application's preferences.++## What runs here++The starter performs A* route planning and real MuJoCo dynamics in an original two-dimensional office rover model. It is not a Unitree robot or physical execution. DimOS is fetched at a pinned source commit; its full daemon and perception stack are an optional, larger installation.++Edit `studio.json`, then run:++```sh+"$STUDIO_TOOLCHAIN/run.sh" simulate # Send the rover+"$STUDIO_TOOLCHAIN/run.sh" dimos # Read DimOS status+```++The native command is optional and fails with a useful message when its external runtime is+unavailable. It never silently substitutes sample output. Use the upstream README in `upstream/`+for full native application setup. See `INTEGRATION.md` for the exact bridge and local test scope.++Every successful run owns a new folder under `out/runs/`, a `result.json` with parameters, engine,+source commit, timestamps, measured values, and downloadable artifacts. `.harness/verdict.json`+means the named artifact was produced, not that an engineering or aesthetic claim was certified.+The starter can be regenerated with no network after install.++## Development and testing++Install the shared viewer and this package with `harness dsh install <path> --link`.+`toolchain/doctor.sh` checks the local runtime. The repository's Studio Viewer browser suite+materializes temporary workspaces and exercises each shipped local workflow. Run it from+`store/viewers/studio-viewer` with `npm run test:browser`; exact results live in its `TESTING.md`.++## Credit and stewardship++[DimOS](https://github.com/dimensionalOS/dimos) is maintained by Dimensional. Its sources are+fetched unchanged at `7da08fb303d354e72cd09cd7e0236fa515675665`. Upstream licensing: Apache-2.0; wrapper MIT.+The original license is preserved in `LICENSE-upstream`; dependency terms still apply.++OpenHarness contributors wrote the MIT wrapper, local starter, and viewer integration. This is+an independent integration, not an upstream endorsement. Upstream bugs belong with the upstream+project; wrapper bugs belong in OpenHarness. Maintainers are welcome to take over this package.diff --git a/store/agents/dimos/THIRD_PARTY_NOTICES.md b/store/agents/dimos/THIRD_PARTY_NOTICES.mdnew file mode 100644index 000000000..4a6f16511--- /dev/null+++ b/store/agents/dimos/THIRD_PARTY_NOTICES.md@@ -0,0 +1,9 @@+# Third-party notices++DimOS — Dimensional. https://github.com/dimensionalOS/dimos++Pinned source: 7da08fb303d354e72cd09cd7e0236fa515675665. Fetched at install into ignored `upstream/`, unmodified.+License: Apache-2.0; wrapper MIT. See `LICENSE-upstream` and the fetched source tree.++The original local starter and wrapper are MIT licensed. The native runtime and separately+installed applications retain their own licenses. No upstream endorsement is claimed.diff --git a/store/agents/dimos/VERSIONS b/store/agents/dimos/VERSIONSnew file mode 100644index 000000000..ce58267bb--- /dev/null+++ b/store/agents/dimos/VERSIONS@@ -0,0 +1,2 @@+UPSTREAM_COMMIT=7da08fb303d354e72cd09cd7e0236fa515675665+PYTHON=3.11diff --git a/store/agents/dimos/harness.json b/store/agents/dimos/harness.jsonnew file mode 100644index 000000000..5615b1e31--- /dev/null+++ b/store/agents/dimos/harness.json@@ -0,0 +1,33 @@+{+ "spec": 1,+ "id": "autonomous/dimos",+ "name": "DimOS",+ "category": "Robotics",+ "author": "Dimensional",+ "description": "Send a little rover on a small adventure. Pick a destination, watch it find a way, and replay the journey.",+ "engine": "codex",+ "workspace": {+ "template": "template",+ "marker": "studio.json",+ "init": "toolchain/init-workspace.sh"+ },+ "agent": {+ "instructions": "AGENTS.md",+ "skills": [+ "skills"+ ],+ "env": {+ "STUDIO_TOOLCHAIN": "${dsh}/toolchain",+ "STUDIO_PYTHON": "${dsh}/.venv/bin/python",+ "STUDIO_UPSTREAM": "${dsh}/upstream"+ }+ },+ "toolchain": {+ "setup": "toolchain/setup.sh",+ "doctor": "toolchain/doctor.sh"+ },+ "viewer": {+ "use": "autonomous/studio-viewer"+ },+ "verdict": ".harness/verdict.json"+}diff --git a/store/agents/dimos/requirements.in b/store/agents/dimos/requirements.innew file mode 100644index 000000000..b60ff6102--- /dev/null+++ b/store/agents/dimos/requirements.in@@ -0,0 +1,2 @@+numpy==2.3.5+mujoco==3.3.7diff --git a/store/agents/dimos/requirements.lock b/store/agents/dimos/requirements.locknew file mode 100644index 000000000..3523c9543--- /dev/null+++ b/store/agents/dimos/requirements.lock@@ -0,0 +1,143 @@+# This file was autogenerated by uv via the following command:+# uv pip compile requirements.in --python-version 3.11 --universal --generate-hashes -o requirements.lock+absl-py==2.5.0 \+ --hash=sha256:0c996f25c0490700fadabe6351630f6111534fa0ae252cc6d2014ea3b141135f \+ --hash=sha256:0f17b89f2a4eaaedc4f28c622998aa690564b3012a396a4ffad0821007fe03ba+ # via mujoco+etils==1.14.0 \+ --hash=sha256:8136e7f4c4173cd0af0ca5481c4475152f0b8686192951eefa60ee8711e1ede4 \+ --hash=sha256:b5df7341f54dbe1405a4450b2741207b4a8c279780402b45f87202b94dfc52b4+ # via mujoco+fsspec==2026.7.0 \+ --hash=sha256:b57ddbafedfaef7018c1ecab32aa200a9d7ca26b77965f64e48b70061249d279 \+ --hash=sha256:c803c40f4cf860b49dea58ee3e1c33cb9c790520e233537e1340049f89b82a88+ # via etils+glfw==2.10.2 \+ --hash=sha256:0ffe2b48b51f37b05e8f027f57c0b8cd213affaf22fc83401bd9621692d4c6c8 \+ --hash=sha256:15fd0666cd8f1b0ecb535c3abb712b8ddda053bf8d16de2353b1c6ced0e65402 \+ --hash=sha256:5d2cf97c66bc42a6b583be0e307eae5a3945438322e2ed0c5e4f14dc251d693d \+ --hash=sha256:7604425ec95665cc6a25c3ed7d07e9660d394a34472ceffaec0843c844e7b649 \+ --hash=sha256:82daf1f87b2a48815637dc6f6720d4a55a57ba1d3683322dc20dc28065754f97 \+ --hash=sha256:a04d25bb535a3a29e173ea1abd658e161681b5d3816e00bc51c122f74cd7fa3a \+ --hash=sha256:a94aefe8c48886fd83cd6e11e936846166a4b5b94abf1f4bf599d984774b0b1b \+ --hash=sha256:b860de3ca0686182483f98f3ddd12e660acf25b3e0d521450ec9a3f999f72a65 \+ --hash=sha256:c000b8a5e5fb4374b2c18d12347255ccb92001b9bcf80ef74c56072acbb98fe3+ # via mujoco+mujoco==3.3.7 \+ --hash=sha256:06cad1108dba827f3845b6c09153dac51f318f7b625cc02f7ad1f2a64187ceb6 \+ --hash=sha256:11f3f6154aa7f72f5929f150800c7098904f91eb0b7cdefacb6fdf7edd3704f8 \+ --hash=sha256:1657312f4f4591ade7c7a21187065e3ab16e6a45d9c8c6abe8772fdc4b585789 \+ --hash=sha256:19ece543ab1fba444d0b33d42740bd1b0c212445ddcbdb51bf81b6989dd21349 \+ --hash=sha256:1afdf8880badccc6fdbef33e09967b6d8feeed3b951da881c4cc41addd1ecde9 \+ --hash=sha256:205b6915d30c7d1927e942d8940678e86e564838bc26b921920a023c8f428e2b \+ --hash=sha256:40bbff7bd701003f3a528a7246fedf43c9feebc965510b81a5a23ed23cfdc887 \+ --hash=sha256:49e6410175c1b1c17e10ad4ca536114fa1e04b86288d6279be41f26055d1e080 \+ --hash=sha256:4a53c0035c559173d6f3c413541e59421cc3293b1a637c69cbb2c9f2251060f6 \+ --hash=sha256:75bc1f23b590da7a56fba076785d8019ff5ffa15949bf849a245c88d7cda1b6c \+ --hash=sha256:771923e71faa19749fed8dae1329b70b77d1cd9cef699d0e0ad984e00ee05c0a \+ --hash=sha256:7b844d21b25c550a17c08fdf29dc3e00b8ac4156d59332f438d6cfb810310650 \+ --hash=sha256:898ff5b28069b06ee654011b88fbde8633ec540a854f82f49cd0472fe9224b5c \+ --hash=sha256:8cafd4fef9dcdd7287bb72fe4184382d8172e400892b34512bf8b6e94145eaad \+ --hash=sha256:9203d50fc1900bcaae98de88fc032f87193aca15eb696718f74396ea7bd77ea3 \+ --hash=sha256:9371506f0df2d82152685fc8d38465843abcea8d371745ea7c125001e8f3f2d8 \+ --hash=sha256:9381bf5364eb2da86f0b1388c98b57e706123c8370660f977004fb5f94ef900f \+ --hash=sha256:970dbc44013371c2de645f9c37a9b41f18b4fc368adc8c5f8057988121be610b \+ --hash=sha256:9c6a3260756b65c79cecb68d67d97518bba3fa45c66097a2dc598bc59c566372 \+ --hash=sha256:b3aadc804eae9a4932c2476883018acab38257df40384d79a90bd95f5e5b04c4 \+ --hash=sha256:bc98adebab38cd5e10e7072a724fbeaa2815a09de323d15a5d319a608bdda13a \+ --hash=sha256:bf1c83c1afc3a5ece0dd5e202fa2164fb5e6fa72c6e2d7cb2453931c44dc4105 \+ --hash=sha256:cc640062891fb54f1f1606bb5748b239f1616de38487c777f09d1775ccdcacc3 \+ --hash=sha256:d9445023a1f00a960b9fa8a6a7ebd4e050a5d1ec586434df0abc21ab8d9a73a5 \+ --hash=sha256:e9c845f5eabd43caea6064be5d6605fab7865ac5c7812c612fd4aee9ff7f5e30 \+ --hash=sha256:ed83d9f1b7d90af6b2047efabd874ed4aeca2fb4babcd0467cee39c1c56bf993+ # via -r requirements.in+numpy==2.3.5 \+ --hash=sha256:00dc4e846108a382c5869e77c6ed514394bdeb3403461d25a829711041217d5b \+ --hash=sha256:0472f11f6ec23a74a906a00b48a4dcf3849209696dff7c189714511268d103ae \+ --hash=sha256:04822c00b5fd0323c8166d66c701dc31b7fbd252c100acd708c48f763968d6a3 \+ --hash=sha256:052e8c42e0c49d2575621c158934920524f6c5da05a1d3b9bab5d8e259e045f0 \+ --hash=sha256:09a1bea522b25109bf8e6f3027bd810f7c1085c64a0c7ce050c1676ad0ba010b \+ --hash=sha256:0cd00b7b36e35398fa2d16af7b907b65304ef8bb4817a550e06e5012929830fa \+ --hash=sha256:0d8163f43acde9a73c2a33605353a4f1bc4798745a8b1d73183b28e5b435ae28 \+ --hash=sha256:1062fde1dcf469571705945b0f221b73928f34a20c904ffb45db101907c3454e \+ --hash=sha256:11e06aa0af8c0f05104d56450d6093ee639e15f24ecf62d417329d06e522e017 \+ --hash=sha256:17531366a2e3a9e30762c000f2c43a9aaa05728712e25c11ce1dbe700c53ad41 \+ --hash=sha256:1978155dd49972084bd6ef388d66ab70f0c323ddee6f693d539376498720fb7e \+ --hash=sha256:1ed1ec893cff7040a02c8aa1c8611b94d395590d553f6b53629a4461dc7f7b63 \+ --hash=sha256:2dcd0808a421a482a080f89859a18beb0b3d1e905b81e617a188bd80422d62e9 \+ --hash=sha256:2e2eb32ddb9ccb817d620ac1d8dae7c3f641c1e5f55f531a33e8ab97960a75b8 \+ --hash=sha256:2feae0d2c91d46e59fcd62784a3a83b3fb677fead592ce51b5a6fbb4f95965ff \+ --hash=sha256:3095bdb8dd297e5920b010e96134ed91d852d81d490e787beca7e35ae1d89cf7 \+ --hash=sha256:30bc11310e8153ca664b14c5f1b73e94bd0503681fcf136a163de856f3a50139 \+ --hash=sha256:3101e5177d114a593d79dd79658650fe28b5a0d8abeb8ce6f437c0e6df5be1a4 \+ --hash=sha256:396084a36abdb603546b119d96528c2f6263921c50df3c8fd7cb28873a237748 \+ --hash=sha256:3997b5b3c9a771e157f9aae01dd579ee35ad7109be18db0e85dbdbe1de06e952 \+ --hash=sha256:414802f3b97f3c1eef41e530aaba3b3c1620649871d8cb38c6eaff034c2e16bd \+ --hash=sha256:51c1e14eb1e154ebd80e860722f9e6ed6ec89714ad2db2d3aa33c31d7c12179b \+ --hash=sha256:51c55fe3451421f3a6ef9a9c1439e82101c57a2c9eab9feb196a62b1a10b58ce \+ --hash=sha256:5ee6609ac3604fa7780e30a03e5e241a7956f8e2fcfe547d51e3afa5247ac47f \+ --hash=sha256:612a95a17655e213502f60cfb9bf9408efdc9eb1d5f50535cc6eb365d11b42b5 \+ --hash=sha256:6203fdf9f3dc5bdaed7319ad8698e685c7a3be10819f41d32a0723e611733b42 \+ --hash=sha256:63c0e9e7eea69588479ebf4a8a270d5ac22763cc5854e9a7eae952a3908103f7 \+ --hash=sha256:66f85ce62c70b843bab1fb14a05d5737741e74e28c7b8b5a064de10142fad248 \+ --hash=sha256:6cf9b429b21df6b99f4dee7a1218b8b7ffbbe7df8764dc0bd60ce8a0708fed1e \+ --hash=sha256:70b37199913c1bd300ff6e2693316c6f869c7ee16378faf10e4f5e3275b299c3 \+ --hash=sha256:727fd05b57df37dc0bcf1a27767a3d9a78cbbc92822445f32cc3436ba797337b \+ --hash=sha256:74ae7b798248fe62021dbf3c914245ad45d1a6b0cb4a29ecb4b31d0bfbc4cc3e \+ --hash=sha256:784db1dcdab56bf0517743e746dfb0f885fc68d948aba86eeec2cba234bdf1c0 \+ --hash=sha256:86945f2ee6d10cdfd67bcb4069c1662dd711f7e2a4343db5cecec06b87cf31aa \+ --hash=sha256:86d835afea1eaa143012a2d7a3f45a3adce2d7adc8b4961f0b362214d800846a \+ --hash=sha256:872a5cf366aec6bb1147336480fef14c9164b154aeb6542327de4970282cd2f5 \+ --hash=sha256:8b973c57ff8e184109db042c842423ff4f60446239bd585a5131cc47f06f789d \+ --hash=sha256:8cba086a43d54ca804ce711b2a940b16e452807acebe7852ff327f1ecd49b0d4 \+ --hash=sha256:8f7f0e05112916223d3f438f293abf0727e1181b5983f413dfa2fefc4098245c \+ --hash=sha256:900218e456384ea676e24ea6a0417f030a3b07306d29d7ad843957b40a9d8d52 \+ --hash=sha256:93eebbcf1aafdf7e2ddd44c2923e2672e1010bddc014138b229e49725b4d6be5 \+ --hash=sha256:9c75442b2209b8470d6d5d8b1c25714270686f14c749028d2199c54e29f20b4d \+ --hash=sha256:9ee2197ef8c4f0dfe405d835f3b6a14f5fee7782b5de51ba06fb65fc9b36e9f1 \+ --hash=sha256:a414504bef8945eae5f2d7cb7be2d4af77c5d1cb5e20b296c2c25b61dff2900c \+ --hash=sha256:a4b9159734b326535f4dd01d947f919c6eefd2d9827466a696c44ced82dfbc18 \+ --hash=sha256:a80afd79f45f3c4a7d341f13acbe058d1ca8ac017c165d3fa0d3de6bc1a079d7 \+ --hash=sha256:aa5bc7c5d59d831d9773d1170acac7893ce3a5e130540605770ade83280e7188 \+ --hash=sha256:acfd89508504a19ed06ef963ad544ec6664518c863436306153e13e94605c218 \+ --hash=sha256:aeffcab3d4b43712bb7a60b65f6044d444e75e563ff6180af8f98dd4b905dfd2 \+ --hash=sha256:afaffc4393205524af9dfa400fa250143a6c3bc646c08c9f5e25a9f4b4d6a903 \+ --hash=sha256:b0c7088a73aef3d687c4deef8452a3ac7c1be4e29ed8bf3b366c8111128ac60c \+ --hash=sha256:b46b4ec24f7293f23adcd2d146960559aaf8020213de8ad1909dba6c013bf89c \+ --hash=sha256:b501b5fa195cc9e24fe102f21ec0a44dffc231d2af79950b451e0d99cea02234 \+ --hash=sha256:bf06bc2af43fa8d32d30fae16ad965663e966b1a3202ed407b84c989c3221e82 \+ --hash=sha256:c804e3a5aba5460c73955c955bdbd5c08c354954e9270a2c1565f62e866bdc39 \+ --hash=sha256:c8a9958e88b65c3b27e22ca2a076311636850b612d6bbfb76e8d156aacde2aaf \+ --hash=sha256:cc0a57f895b96ec78969c34f682c602bf8da1a0270b09bc65673df2e7638ec20 \+ --hash=sha256:cc8920d2ec5fa99875b670bb86ddeb21e295cb07aa331810d9e486e0b969d946 \+ --hash=sha256:ccc933afd4d20aad3c00bcef049cb40049f7f196e0397f1109dba6fed63267b0 \+ --hash=sha256:ce581db493ea1a96c0556360ede6607496e8bf9b3a8efa66e06477267bc831e9 \+ --hash=sha256:d0f23b44f57077c1ede8c5f26b30f706498b4862d3ff0a7298b8411dd2f043ff \+ --hash=sha256:d21644de1b609825ede2f48be98dfde4656aefc713654eeee280e37cadc4e0ad \+ --hash=sha256:d6889ec4ec662a1a37eb4b4fb26b6100841804dac55bd9df579e326cdc146227 \+ --hash=sha256:de5672f4a7b200c15a4127042170a694d4df43c992948f5e1af57f0174beed10 \+ --hash=sha256:e6a0bc88393d65807d751a614207b7129a310ca4fe76a74e5c7da5fa5671417e \+ --hash=sha256:ed89927b86296067b4f81f108a2271d8926467a8868e554eaf370fc27fa3ccaf \+ --hash=sha256:ee3888d9ff7c14604052b2ca5535a30216aa0a58e948cdd3eeb8d3415f638769 \+ --hash=sha256:f0963b55cdd70fad460fa4c1341f12f976bb26cb66021a5580329bd498988310 \+ --hash=sha256:f16417ec91f12f814b10bafe79ef77e70113a2f5f7018640e7425ff979253425 \+ --hash=sha256:f28620fe26bee16243be2b7b874da327312240a7cdc38b769a697578d2100013 \+ --hash=sha256:f4255143f5160d0de972d28c8f9665d882b5f61309d8362fdd3e103cf7bf010c \+ --hash=sha256:ffac52f28a7849ad7576293c0cb7b9f08304e8f7d738a8cb8a90ec4c55a998eb \+ --hash=sha256:ffe22d2b05504f786c867c8395de703937f934272eb67586817b46188b4ded6d \+ --hash=sha256:fffe29a1ef00883599d1dc2c51aa2e5d80afe49523c261a74933df395c15c520+ # via+ # -r requirements.in+ # mujoco+pyopengl==3.1.10 \+ --hash=sha256:794a943daced39300879e4e47bd94525280685f42dbb5a998d336cfff151d74f \+ --hash=sha256:c4a02d6866b54eb119c8e9b3fb04fa835a95ab802dd96607ab4cdb0012df8335+ # via mujoco+typing-extensions==4.16.0 \+ --hash=sha256:481caa481374e813c1b176ada14e97f1f67a4539ce9cfeb3f350d78d6370c2e8 \+ --hash=sha256:dc983d19a509c94dba722ee6abd33940f7c05a89e243c47e907eb4db6f1a43e5+ # via etils+zipp==4.1.0 \+ --hash=sha256:25ad4e16390cd314347dd8f1de67a2ac538ae658ed4ab9db16029c07c188e97f \+ --hash=sha256:4cb57381f544315db7688e976e922a2b18cdb513d21cc194eb42232ba2a3e602+ # via etilsdiff --git a/store/agents/dimos/skills/dimos/SKILL.md b/store/agents/dimos/skills/dimos/SKILL.mdnew file mode 100644index 000000000..6f598841b--- /dev/null+++ b/store/agents/dimos/skills/dimos/SKILL.md@@ -0,0 +1,19 @@+---+name: dimos+description: Create and inspect robotics projects in the DimOS Harness workspace, including its local starter and optional upstream integration.+---++# Mission control++Read `studio.json` to understand the current controls; `"$STUDIO_TOOLCHAIN/../studio.config.json"`+describes their ranges. Run `"$STUDIO_TOOLCHAIN/run.sh" simulate` to make a new result.+Successful artifacts and their measurements are in `out/runs/<id>/`; `out/latest.json` names the+current result. A failed run preserves the last success and records the error in the verdict.++The starter performs A* route planning and real MuJoCo dynamics in an original two-dimensional office rover model. It is not a Unitree robot or physical execution. DimOS is fetched at a pinned source commit; its full daemon and perception stack are an optional, larger installation.++Use `"$STUDIO_TOOLCHAIN/../README.md"` for the integration contract and commands. Read the relevant+files under `$STUDIO_UPSTREAM` before using an upstream API. Keep controls within their documented+ranges, preserve the data needed to reproduce a comparison, and distinguish preview results from+native service or hardware output. The viewer supports history and artifact downloads; tell the+user which run contains the result, and what was actually measured.diff --git a/store/agents/dimos/store.json b/store/agents/dimos/store.jsonnew file mode 100644index 000000000..bdfbf3cbd--- /dev/null+++ b/store/agents/dimos/store.json@@ -0,0 +1,6 @@+{+ "homepage": "https://github.com/dimensionalOS/dimos",+ "upstream": "https://github.com/dimensionalOS/dimos",+ "license": "Apache-2.0; wrapper MIT",+ "screenshots": []+}diff --git a/store/agents/dimos/studio.config.json b/store/agents/dimos/studio.config.jsonnew file mode 100644index 000000000..1ff8c7023--- /dev/null+++ b/store/agents/dimos/studio.config.json@@ -0,0 +1,77 @@+{+ "title": "Mission control",+ "description": "Send a little rover on a small adventure. Pick a destination, watch it find a way, and replay the journey.",+ "category": "Robotics",+ "scene": "SMALL ROBOT, BIG CURIOSITY",+ "hint": "Click the map to choose a destination \u00b7 run and replay",+ "tip": "The rover plans around walls before moving. A goal inside a wall gives a useful failure, not a pretend success.",+ "previewLabel": "Mission preview \u00b7 simulation only",+ "controls": [+ {+ "id": "goal_x",+ "label": "Destination east",+ "type": "number",+ "value": 8,+ "min": 1,+ "max": 9,+ "step": 0.5,+ "integer": false,+ "unit": "m",+ "hint": ""+ },+ {+ "id": "goal_y",+ "label": "Destination north",+ "type": "number",+ "value": 7,+ "min": 1,+ "max": 9,+ "step": 0.5,+ "integer": false,+ "unit": "m",+ "hint": ""+ },+ {+ "id": "speed",+ "label": "Travel speed",+ "type": "number",+ "value": 0.8,+ "min": 0.4,+ "max": 1.4,+ "step": 0.1,+ "integer": false,+ "unit": "m/s",+ "hint": ""+ },+ {+ "id": "layout",+ "label": "Place",+ "type": "select",+ "value": "office",+ "options": [+ {+ "value": "office",+ "label": "The small office"+ },+ {+ "value": "gallery",+ "label": "The sculpture gallery"+ }+ ]+ }+ ],+ "actions": [+ {+ "id": "simulate",+ "label": "Send the rover",+ "description": ""+ },+ {+ "id": "dimos",+ "label": "Read DimOS status",+ "description": "Read the local DimOS daemon status without commanding hardware"+ }+ ],+ "credit": "DimOS \u00b7 Dimensional",+ "empty": "Adjust the controls, then make your first exploration. Every successful run stays in the history."+}diff --git a/store/agents/dimos/template/studio.json b/store/agents/dimos/template/studio.jsonnew file mode 100644index 000000000..946503575--- /dev/null+++ b/store/agents/dimos/template/studio.json@@ -0,0 +1,10 @@+{+ "spec": 1,+ "title": "Mission control",+ "parameters": {+ "goal_x": 8,+ "goal_y": 7,+ "speed": 0.8,+ "layout": "office"+ }+}diff --git a/store/agents/dimos/toolchain/doctor.sh b/store/agents/dimos/toolchain/doctor.shnew file mode 100755index 000000000..7e275b16a--- /dev/null+++ b/store/agents/dimos/toolchain/doctor.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+test -x .venv/bin/python || { echo 'miss run toolchain/setup.sh to install the local runtime'; exit 1; }+.venv/bin/python -c 'import mujoco; import numpy; import json; json.load(open("studio.config.json")); print("ok DimOS local workflow")'+test -f upstream/README.md || { echo "miss pinned upstream sources"; exit 1; }+echo "ok upstream 7da08fb303d3"diff --git a/store/agents/dimos/toolchain/init-workspace.sh b/store/agents/dimos/toolchain/init-workspace.shnew file mode 100755index 000000000..8749f6568--- /dev/null+++ b/store/agents/dimos/toolchain/init-workspace.sh@@ -0,0 +1,3 @@+#!/usr/bin/env bash+set -euo pipefail+exec "${HARNESS_DSH_DIR:?}/toolchain/run.sh" simulatediff --git a/store/agents/dimos/toolchain/run.sh b/store/agents/dimos/toolchain/run.shnew file mode 100755index 000000000..a9e5df771--- /dev/null+++ b/store/agents/dimos/toolchain/run.sh@@ -0,0 +1,6 @@+#!/usr/bin/env bash+set -euo pipefail+studio_package="$(cd "$(dirname "$0")/.." && pwd)"+export PATH="$studio_package/.venv/bin:$PATH"+export PYTHONUNBUFFERED=1+exec "$studio_package/.venv/bin/python" "$studio_package/toolchain/workflow.py" "$@"diff --git a/store/agents/dimos/toolchain/runtimes.sh b/store/agents/dimos/toolchain/runtimes.shnew file mode 100644index 000000000..7223c78dc--- /dev/null+++ b/store/agents/dimos/toolchain/runtimes.sh@@ -0,0 +1,192 @@+# shellcheck shell=bash+# runtimes.sh — the interpreters a store package runs on, found on this machine or fetched, never+# asked of the person who pressed Get.+#+# Sourced (not run) by a package's setup, doctor and viewer scripts. A new Mac has Apple's Python 3.9,+# no Homebrew and, for most people, no Node on PATH; a package that answers "brew install [email protected]"+# has failed its install. So:+#+# harness_node 18 node >= 18 on PATH, with npm: the machine's own, else the Node Harness+# itself runs on (~/.harness/runtime/current-node, laid down with the CLI)+# harness_uv uv on PATH: the machine's own, else a pinned, checksummed release+# fetched into ~/.harness/runtime+# harness_venv DIR 3.12 [MIN [BELOW]]+# DIR is a venv on CPython 3.12, which uv downloads when the machine+# has none. A venv already there on a Python in [MIN, BELOW) is kept.+# harness_pip DIR PKG… install into that venv, through uv+# harness_micromamba micromamba, pinned and checksummed, for native libraries PyPI has+# no wheel for (pycairo on macOS)+# harness_conda_env DIR SPEC… DIR is a conda-forge environment with those packages+#+# Every function prints `miss …` and returns 1 when it cannot deliver, so `harness_node 18 || exit 1`+# reads like the rest of a setup script. Nothing here touches the user's shell profile; what it+# installs lands in ~/.harness/runtime or the package's own directory (uv keeps its download cache+# where it always does, which a venv does not depend on).+#+# ONE copy is written by hand: store/tools/runtimes.sh in the OpenHarness repository. Each package+# carries an identical copy (a package installs alone, so it cannot reach this one);+# `node store/tools/sync-runtimes.mjs` rewrites them and the CLI's store spec fails when one drifts.++HARNESS_RUNTIME="${ADAPTER_RUNTIME_DIR:-${HOME:-}/.harness/runtime}"+# The Pythons uv downloads live with Harness's other runtimes, not in uv's own ~/.local/share/uv:+# a package's venv points at its interpreter, and `uv python uninstall` there must not break it.+UV_PYTHON_INSTALL_DIR="${UV_PYTHON_INSTALL_DIR:-$HARNESS_RUNTIME/python}"+export UV_PYTHON_INSTALL_DIR+HARNESS_UV_VERSION=0.12.15+HARNESS_MICROMAMBA_VERSION=2.9.0-0++_harness_platform() {+ case "$(uname -s)-$(uname -m)" in+ Darwin-arm64) echo darwin-arm64 ;;+ Darwin-x86_64) echo darwin-x64 ;;+ Linux-x86_64) echo linux-x64 ;;+ Linux-aarch64 | Linux-arm64) echo linux-arm64 ;;+ *) return 1 ;;+ esac+}++_harness_sha256() {+ if command -v shasum >/dev/null 2>&1; then shasum -a 256 "$1" | cut -d' ' -f1+ else sha256sum "$1" | cut -d' ' -f1; fi+}++# _harness_fetch URL DEST SHA256 — DEST exists only if what arrived matches the pinned checksum.+_harness_fetch() {+ local part="$2.part.$$"+ if ! curl -fsSL --retry 3 --connect-timeout 20 --max-time 900 -o "$part" "$1"; then+ rm -f "$part"; echo "miss could not download $1 — check this machine's internet connection"; return 1+ fi+ if [ "$(_harness_sha256 "$part")" != "$3" ]; then+ rm -f "$part"; echo "miss $1 did not match its pinned checksum; nothing was installed"; return 1+ fi+ mv -f "$part" "$2"+}++_harness_node_at_least() {+ command -v node >/dev/null 2>&1 || return 1+ node -e '+ const [a, b = 0] = process.argv[1].split(".").map(Number)+ const [x, y] = process.versions.node.split(".").map(Number)+ process.exit(x > a || (x === a && y >= b) ? 0 : 1)+ ' "$1" >/dev/null 2>&1+}++harness_node() {+ local min="${1:-18}" recorded saved="$PATH" own=0+ _harness_node_at_least "$min" && own=1+ # A node without npm beside it (a distro's nodejs package) cannot run a setup's `npm ci`.+ if [ "$own" = 1 ] && command -v npm >/dev/null 2>&1; then return 0; fi+ recorded="$(cat "$HARNESS_RUNTIME/current-node" 2>/dev/null || true)"+ # Already Harness's own (a second call, or a wrapper calling a script that asks again): nothing to add.+ if [ "$own" = 1 ] && [ -n "$recorded" ] && [ "$(command -v node)" = "${recorded%/*}/node" ]; then return 0; fi+ if [ -n "$recorded" ] && [ -x "${recorded%/*}/node" ]; then+ PATH="${recorded%/*}:$PATH"; export PATH; hash -r 2>/dev/null || true+ _harness_node_at_least "$min" && return 0+ PATH="$saved"; export PATH; hash -r 2>/dev/null || true+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min — this machine's newest is $("${recorded%/*}/node" -v), Harness's own; update Harness"+ return 1+ fi+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min, and Harness's own Node is not in $HARNESS_RUNTIME — run \`harness start\` once to lay it down"+ return 1+}++harness_uv() {+ local dir asset sum tmp+ command -v uv >/dev/null 2>&1 && return 0+ for dir in "${HOME:-}/.local/bin" "${HOME:-}/.cargo/bin"; do+ [ -n "${HOME:-}" ] || break+ if [ -x "$dir/uv" ]; then PATH="$dir:$PATH"; export PATH; return 0; fi+ done+ dir="$HARNESS_RUNTIME/uv-$HARNESS_UV_VERSION"+ if [ ! -x "$dir/uv" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=uv-aarch64-apple-darwin sum=dc304b9ed1b24174572290fba60ac3f6fe63c73a671f0439e62a91375841964d ;;+ darwin-x64) asset=uv-x86_64-apple-darwin sum=e9ca61775532368fe518ab03e7a354c7ecab8ccb3c7d941c775fcc4a362b801b ;;+ linux-x64) asset=uv-x86_64-unknown-linux-gnu sum=f97935763c04be3e692460a7aaeaaab8fc3b78fcf8b389da820b38ae7423a638 ;;+ linux-arm64) asset=uv-aarch64-unknown-linux-gnu sum=0e9a3499b0587d449c9ff684c0160da607826e4af1cee220bc87f378702d3e08 ;;+ *) echo "miss uv — there is no uv release for $(uname -s) $(uname -m); install it from https://docs.astral.sh/uv/"; return 1 ;;+ esac+ echo " fetching uv $HARNESS_UV_VERSION into $HARNESS_RUNTIME (it brings Python and the packages)"+ mkdir -p "$HARNESS_RUNTIME" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ tmp="$(mktemp -d "$HARNESS_RUNTIME/.uv.XXXXXX")" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ if ! _harness_fetch "https://github.com/astral-sh/uv/releases/download/$HARNESS_UV_VERSION/$asset.tar.gz" "$tmp/uv.tar.gz" "$sum"; then+ rm -rf "$tmp"; return 1+ fi+ tar -xzf "$tmp/uv.tar.gz" -C "$tmp" && chmod +x "$tmp/$asset/uv" "$tmp/$asset/uvx" \+ || { rm -rf "$tmp"; echo "miss the uv archive would not unpack"; return 1; }+ # Two installs at once both get here; whichever renames first wins and the other's copy goes.+ # (mv onto a directory that exists would nest the copy inside it, hence the test.)+ [ -e "$dir" ] || mv "$tmp/$asset" "$dir" 2>/dev/null || true+ rm -rf "$tmp"+ [ -x "$dir/uv" ] || { echo "miss uv did not land in $dir"; return 1; }+ fi+ PATH="$dir:$PATH"; export PATH+}++# harness_venv DIR VERSION [MIN [BELOW]] — MIN defaults to VERSION; BELOW is exclusive and optional.+harness_venv() {+ local dir="${1:?harness_venv needs a directory}" want="${2:?harness_venv needs a Python version}"+ local min="${3:-$2}" below="${4:-}"+ if [ -x "$dir/bin/python" ] && "$dir/bin/python" -c '+import sys+at = lambda s: tuple(int(p) for p in s.split("."))+v = sys.version_info[:2]+sys.exit(0 if v >= at(sys.argv[1]) and (not sys.argv[2] or v < at(sys.argv[2])) else 1)+' "$min" "$below" 2>/dev/null; then+ echo "ok $("$dir/bin/python" --version) in $dir"+ return 0+ fi+ harness_uv || return 1+ echo " python $want in $dir (uv downloads it when this machine has none)"+ rm -rf "$dir"+ # only-managed: the same python-build-standalone interpreter on every machine, so a package tested+ # once is tested everywhere — not whichever Homebrew or pyenv Python happened to be first on PATH.+ uv venv --quiet --seed --python "$want" --python-preference only-managed "$dir" \+ || { echo "miss could not make a Python $want environment in $dir"; return 1; }+ echo "ok $("$dir/bin/python" --version) in $dir"+}++harness_pip() {+ local dir="${1:?harness_pip needs a venv}"+ shift+ harness_uv || return 1+ # uv's own error comes first; the miss line is last, so it is the line the store shows.+ uv pip install --quiet --python "$dir/bin/python" "$@" \+ || { echo "miss could not install $* into $dir"; return 1; }+}++harness_micromamba() {+ local dir asset sum+ dir="$HARNESS_RUNTIME/micromamba-$HARNESS_MICROMAMBA_VERSION"+ if [ ! -x "$dir/micromamba" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=micromamba-osx-arm64 sum=ec2a072f028e1a7cf20f3e2e74d5a8127cf5a5f27636375b5359811565f4e5be ;;+ darwin-x64) asset=micromamba-osx-64 sum=1e71054bb3ac9a076e21f7ec48acfef536f9b3f1408f371a942784bf5ef83d8a ;;+ linux-x64) asset=micromamba-linux-64 sum=366cd9cd8be14df1ab8ed50352a82111082a36686b2d389fdb79a92c3fafb3e3 ;;+ linux-arm64) asset=micromamba-linux-aarch64 sum=9f93b974adcb4d166996af969b6cd371287d1a3e52733704727884d9b74cb7a7 ;;+ *) echo "miss micromamba — there is no release for $(uname -s) $(uname -m)"; return 1 ;;+ esac+ echo " fetching micromamba $HARNESS_MICROMAMBA_VERSION into $HARNESS_RUNTIME (native libraries PyPI has no wheel for)"+ mkdir -p "$dir" || { echo "miss cannot write $dir"; return 1; }+ _harness_fetch "https://github.com/mamba-org/micromamba-releases/releases/download/$HARNESS_MICROMAMBA_VERSION/$asset" "$dir/micromamba.$$" "$sum" || return 1+ chmod +x "$dir/micromamba.$$" && mv -f "$dir/micromamba.$$" "$dir/micromamba" \+ || { rm -f "$dir/micromamba.$$"; echo "miss micromamba would not install into $dir"; return 1; }+ fi+ HARNESS_MICROMAMBA="$dir/micromamba"+ export HARNESS_MICROMAMBA+}++# harness_conda_env DIR SPEC… — conda-forge only, packages cached under ~/.harness/runtime/mamba.+harness_conda_env() {+ local dir="${1:?harness_conda_env needs a directory}"+ shift+ # micromamba takes a relative --prefix as a name under its root prefix and "succeeds" there.+ case "$dir" in /*) ;; *) dir="$PWD/$dir" ;; esac+ harness_micromamba || return 1+ MAMBA_ROOT_PREFIX="$HARNESS_RUNTIME/mamba" "$HARNESS_MICROMAMBA" create --yes --quiet \+ --prefix "$dir" --override-channels --channel conda-forge "$@" >/dev/null \+ && [ -d "$dir/conda-meta" ] \+ || { echo "miss could not make the conda-forge environment in $dir ($*)"; return 1; }+}diff --git a/store/agents/dimos/toolchain/setup.sh b/store/agents/dimos/toolchain/setup.shnew file mode 100755index 000000000..efbece7e2--- /dev/null+++ b/store/agents/dimos/toolchain/setup.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+harness_venv .venv 3.11 3.11 3.12+.venv/bin/python toolchain/studio_fetch.py+if [ -s requirements.lock ]; then harness_pip .venv --require-hashes -r requirements.lock; fi+exec toolchain/doctor.shdiff --git a/store/agents/dimos/toolchain/studio_fetch.py b/store/agents/dimos/toolchain/studio_fetch.pynew file mode 100644index 000000000..88a670b25--- /dev/null+++ b/store/agents/dimos/toolchain/studio_fetch.py@@ -0,0 +1,34 @@+"""Fetch reviewed source pins without installing a service or changing user configuration."""+import json+import os+from pathlib import Path+import subprocess++root = Path(__file__).resolve().parent.parent+sources = json.loads((root / "upstream.lock.json").read_text())+for source in sources:+ target = root / source["directory"]+ def git(*args):+ return subprocess.check_output(["git", "-C", str(target), *args], text=True,+ env={**os.environ, "GIT_LFS_SKIP_SMUDGE": "1"}).strip()+ if not (target / ".git").exists():+ target.mkdir(parents=True, exist_ok=True)+ git("init", "-q")+ git("remote", "add", "origin", source["url"])+ if source.get("sparse"):+ git("sparse-checkout", "init", "--cone")+ git("sparse-checkout", "set", *source["sparse"])+ if git("remote", "get-url", "origin") != source["url"]:+ raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])+ try:+ current = git("rev-parse", "HEAD")+ except subprocess.CalledProcessError:+ current = ""+ if current != source["commit"]:+ if current and git("status", "--porcelain"):+ raise SystemExit(f"Save your edits in {target} before changing its source pin")+ git("fetch", "--depth", "1", "--filter=blob:none", "origin", source["commit"])+ git("checkout", "--detach", source["commit"])+ print(f'ok {source["name"]} at {source["commit"][:12]}', flush=True)diff --git a/store/agents/dimos/toolchain/studio_runtime.py b/store/agents/dimos/toolchain/studio_runtime.pynew file mode 100644index 000000000..8b8ea016c--- /dev/null+++ b/store/agents/dimos/toolchain/studio_runtime.py@@ -0,0 +1,132 @@+"""Portable runner copied into each independently installable studio package."""+import json+import math+import os+from pathlib import Path+import subprocess+import sys+import tempfile+import time+import uuid+++def workspace():+ return Path(os.environ.get("HARNESS_WORKSPACE", os.getcwd())).resolve()+++def package():+ return Path(__file__).resolve().parent.parent+++def contained(path):+ target = Path(path).resolve()+ target.relative_to(workspace())+ return target+++def atomic_json(path, data):+ path = contained(path)+ path.parent.mkdir(parents=True, exist_ok=True)+ with tempfile.NamedTemporaryFile(mode="w", dir=path.parent, prefix=".studio-", delete=False) as f:+ json.dump(data, f, indent=2, allow_nan=False)+ f.write("\n")+ temp = f.name+ os.replace(temp, path)+++def command(argv, cwd=None, timeout=120, env=None):+ """No shell interpolation; keep complete logs as output, bound execution time."""+ result = subprocess.run([str(x) for x in argv], cwd=cwd, timeout=timeout,+ env=env, text=True, capture_output=True)+ if result.returncode:+ raise RuntimeError((result.stderr or result.stdout)[-1600:] or f"{argv[0]} exited {result.returncode}")+ return result.stdout+++def parameters(config, values):+ if not isinstance(values, dict) or set(values) - {c["id"] for c in config["controls"]}:+ raise ValueError("Invalid studio controls")+ result = {}+ for c in config["controls"]:+ value = values.get(c["id"], c["value"])+ if c["type"] == "number":+ if type(value) not in (int, float) or not math.isfinite(value) or not c["min"] <= value <= c["max"]:+ raise ValueError(f'{c["label"]} is outside its range')+ if c.get("integer") and value != int(value):+ raise ValueError(f'{c["label"]} must be a whole number')+ elif c["type"] == "select":+ if value not in [o["value"] for o in c["options"]]:+ raise ValueError(f'Unknown {c["label"]}')+ elif not isinstance(value, str) or len(value) > c.get("maxLength", 500):+ raise ValueError(f'Invalid {c["label"]}')+ result[c["id"]] = value+ return result+++def metric(label, value, unit=""):+ return {"label": label, "value": value, "unit": unit}+++def previous_runs():+ base = contained(workspace() / "out/runs")+ rows = []+ for p in sorted(base.glob("*/result.json"))[-100:]:+ try:+ rows.append(json.loads(contained(p).read_text()))+ except (ValueError, OSError):+ continue+ return rows+++def execute(actions):+ root = workspace()+ config = json.loads((package() / "studio.config.json").read_text())+ action = sys.argv[1] if len(sys.argv) > 1 else config["actions"][0]["id"]+ started = time.monotonic()+ verdict_path = root / ".harness/verdict.json"+ verdict = {"spec": 1, "ready": False, "summary": "Preparing the studio run", "findings": [],+ "phases": [{"id": "run", "name": "Make", "state": "active"},+ {"id": "inspect", "name": "Inspect", "state": "pending"}]}+ try:+ if action not in actions:+ raise ValueError(f"Unknown action: {action}")+ source = contained(root / "studio.json")+ if source.stat().st_size > 16384:+ raise ValueError("studio.json is too large")+ project = json.loads(source.read_text())+ p = parameters(config, project["parameters"])+ atomic_json(verdict_path, verdict)+ run_id = time.strftime("%Y%m%dT%H%M%S", time.gmtime()) + "-" + uuid.uuid4().hex[:8]+ output = contained(root / "out/runs" / run_id)+ output.mkdir(parents=True)+ print(f'{config["title"]}: {action}', flush=True)+ result = actions[action](p, output)+ artifacts = []+ for artifact in result.pop("files", []):+ file = contained(output / artifact["name"])+ file.relative_to(output)+ if not file.is_file() or not file.stat().st_size:+ raise ValueError(f'Missing output: {artifact["name"]}')+ artifacts.append({"label": artifact["label"], "path": str(file.relative_to(root))})+ result.update({"spec": 1, "id": run_id, "action": action, "parameters": p,+ "createdAt": time.strftime("%Y-%m-%dT%H:%M:%SZ", time.gmtime()),+ "durationSeconds": round(time.monotonic() - started, 3), "artifacts": artifacts,+ "upstream": json.loads((package() / "upstream.lock.json").read_text())})+ atomic_json(output / "result.json", result)+ atomic_json(root / "out/latest.json", result)+ verdict.update({"ready": True, "summary": f'{result["title"]} · {result["engine"]}',+ "artifact": str((output / "result.json").relative_to(root)),+ "phases": [{"id": "run", "name": "Make", "state": "done"},+ {"id": "inspect", "name": "Inspect", "state": "done"}],+ "updatedAt": result["createdAt"]})+ atomic_json(verdict_path, verdict)+ print(f'Ready: {result["title"]}', flush=True)+ except Exception as exc:+ verdict.update({"summary": str(exc)[:500], "findings": [{"severity": "error", "kind": "run-failed", "message": str(exc)[:1000]}],+ "phases": [{"id": "run", "name": "Make", "state": "failed"}]})+ try:+ atomic_json(verdict_path, verdict)+ except (ValueError, OSError):+ pass+ print(str(exc), file=sys.stderr)+ raise SystemExit(1) from excdiff --git a/store/agents/dimos/toolchain/workflow.py b/store/agents/dimos/toolchain/workflow.pynew file mode 100644index 000000000..c65e8893b--- /dev/null+++ b/store/agents/dimos/toolchain/workflow.py@@ -0,0 +1,76 @@+import heapq+import json+import math+import shutil+import xml.etree.ElementTree as ET+import mujoco+import numpy as np+from studio_runtime import execute, metric, command+++def obstacles(layout):+ return [[4,3,2,3],[7,5,2,1],[2.5,7,2,1]] if layout=='office' else [[3,3,1.4,1.4],[6,3,1.4,1.4],[4.5,6,1.4,1.4],[7.5,7.5,1.4,1.4]]+++def plan(goal, blocks):+ spacing=.25;start=(4,4);target=(round(goal[0]/spacing),round(goal[1]/spacing))+ def blocked(node):+ x,y=node[0]*spacing,node[1]*spacing+ return x<.5 or y<.5 or x>9.5 or y>9.5 or any(abs(x-cx)<w/2+.32 and abs(y-cy)<h/2+.32 for cx,cy,w,h in blocks)+ if blocked(target):raise ValueError('That destination is inside a wall or too close to it. Pick open floor.')+ queue=[(0,start)];cost={start:0};previous={}+ while queue:+ _,node=heapq.heappop(queue)+ if node==target:+ route=[node]+ while node!=start:node=previous[node];route.append(node)+ return [[x*spacing,y*spacing] for x,y in reversed(route)]+ for dx,dy in [(1,0),(-1,0),(0,1),(0,-1)]:+ nxt=(node[0]+dx,node[1]+dy)+ if blocked(nxt):continue+ new=cost[node]+1+ if new<cost.get(nxt,math.inf):+ cost[nxt]=new;previous[nxt]=node;heapq.heappush(queue,(new+abs(nxt[0]-target[0])+abs(nxt[1]-target[1]),nxt))+ raise ValueError('There is no clear route to that destination.')+++def simulate(p,out):+ blocks=obstacles(p['layout']);route=plan([p['goal_x'],p['goal_y']],blocks)+ root=ET.Element('mujoco',model='Harness office rover');ET.SubElement(root,'option',timestep='0.01',gravity='0 0 0')+ world=ET.SubElement(root,'worldbody');ET.SubElement(world,'geom',type='plane',size='10 10 .1',rgba='.2 .25 .2 1')+ for i,(x,y,w,h) in enumerate(blocks):ET.SubElement(world,'geom',name=f'wall{i}',type='box',pos=f'{x} {y} .5',size=f'{w/2} {h/2} .5')+ body=ET.SubElement(world,'body',name='rover',pos='0 0 .2')+ ET.SubElement(body,'joint',name='east',type='slide',axis='1 0 0',damping='3')+ ET.SubElement(body,'joint',name='north',type='slide',axis='0 1 0',damping='3')+ ET.SubElement(body,'geom',name='rover_body',type='cylinder',size='.2 .12',mass='1',rgba='.75 .9 .5 1')+ actuators=ET.SubElement(root,'actuator')+ for name in ['east','north']:ET.SubElement(actuators,'velocity',joint=name,kv='10',ctrlrange='-1.5 1.5')+ xml=ET.tostring(root,encoding='unicode');(out/'mission.xml').write_text(xml)+ model=mujoco.MjModel.from_xml_string(xml);data=mujoco.MjData(model);data.qpos[:2]=[1,1]+ mujoco.mj_forward(model,data);positions=[];waypoint=1;distance=0.;contacts=0;last=np.array([1.,1.]);success=False+ for step in range(30000):+ target=np.array(route[min(waypoint,len(route)-1)]);delta=target-data.qpos[:2]+ if np.linalg.norm(delta)<.12:+ if waypoint>=len(route)-1:success=True;break+ waypoint+=1;target=np.array(route[waypoint]);delta=target-data.qpos[:2]+ control=delta*4;length=np.linalg.norm(control)+ data.ctrl[:]=control*min(1,p['speed']/max(length,1e-9))+ mujoco.mj_step(model,data)+ distance+=float(np.linalg.norm(data.qpos[:2]-last));last=data.qpos[:2].copy();contacts+=data.ncon+ if step%10==0:positions.append([round(data.time,2),round(float(data.qpos[0]),4),round(float(data.qpos[1]),4)])+ if not success:raise RuntimeError('The rover did not reach its destination within the simulation budget.')+ positions.append([round(data.time,2),round(float(data.qpos[0]),4),round(float(data.qpos[1]),4)])+ telemetry={'route':route,'positions':positions,'obstacles':blocks,'goal':[p['goal_x'],p['goal_y']],'success':success,'contacts':contacts,'layout':p['layout']}+ (out/'mission.json').write_text(json.dumps(telemetry,indent=2))+ return {'title':f'Arrived · {distance:.1f} metre adventure','description':'A planned route executed in MuJoCo dynamics. Replay uses the recorded robot positions, with no physical robot involved.','engine':f'MuJoCo {mujoco.__version__} · simulated rover','metrics':[metric('Distance',round(distance,1),'m'),metric('Travel time',round(data.time,1),'s'),metric('Wall contacts',contacts)],'data':telemetry,'files':[{'label':'Mission telemetry','name':'mission.json'},{'label':'MuJoCo world','name':'mission.xml'}]}+++def dimos(p,out):+ executable=shutil.which('dimos')+ if not executable:raise RuntimeError('The DimOS daemon is not installed on this machine. Use the local MuJoCo mission, or follow upstream/docs/installation for DimOS.')+ log=command([executable,'status'],timeout=15)+ (out/'dimos-status.txt').write_text(log)+ return {'title':'DimOS status','description':'Read the local daemon state. No mission or hardware command was sent.','engine':'Native DimOS CLI','metrics':[],'data':{'status':log},'files':[{'label':'Daemon status','name':'dimos-status.txt'}]}+++if __name__=='__main__':execute({'simulate':simulate,'dimos':dimos})diff --git a/store/agents/dimos/upstream.lock.json b/store/agents/dimos/upstream.lock.jsonnew file mode 100644index 000000000..b850dafe8--- /dev/null+++ b/store/agents/dimos/upstream.lock.json@@ -0,0 +1,15 @@+[+ {+ "name": "DimOS",+ "url": "https://github.com/dimensionalOS/dimos.git",+ "commit": "7da08fb303d354e72cd09cd7e0236fa515675665",+ "directory": "upstream",+ "sparse": [+ "dimos",+ "docs",+ "scripts",+ ".agents",+ "native"+ ]+ }+]diff --git a/store/agents/dimos/view.mjs b/store/agents/dimos/view.mjsnew file mode 100644index 000000000..1cff4e119--- /dev/null+++ b/store/agents/dimos/view.mjs@@ -0,0 +1,25 @@+import {canvas,round,line,circle,words,toolbar,badge,label,el} from '/graphics.mjs';+const layouts={office:[[4,3,2,3],[7,5,2,1],[2.5,7,2,1]],gallery:[[3,3,1.4,1.4],[6,3,1.4,1.4],[4.5,6,1.4,1.4],[7.5,7.5,1.4,1.4]]};+export function mount(stage,api){+ let p=api.getParameters(),result,showPath=true,replay=true,index=0,now=0,start=0,last='',bounds;+ const info=label(stage,'Choose somewhere worth exploring.'),tag=badge(stage,'SIMULATION ONLY');+ const screen=canvas(stage,(ctx,w,h,t)=>{+ now=t;const size=Math.min(h-85,w-70),left=(w-size)/2,top=22,s=size/10;bounds={left,top,s};const map=(x,y)=>[left+x*s,top+(10-y)*s];+ round(ctx,left,top,size,size,12,'#24372b','#ffffff20');+ for(let i=1;i<10;i++){line(ctx,[[left+i*s,top],[left+i*s,top+size]],'#ffffff0b',1);line(ctx,[[left,top+i*s],[left+size,top+i*s]],'#ffffff0b',1);}+ const blocks=layouts[p.layout];for(const [x,y,bw,bh] of blocks){const [px,py]=map(x-bw/2,y+bh/2);round(ctx,px+4,py+5,bw*s,bh*s,5,'#0a1e1644');round(ctx,px,py,bw*s,bh*s,5,'#66795d','#8da17a');line(ctx,[[px+5,py+7],[px+bw*s-5,py+7]],'#b0c49b55',1);}+ const compatible=result?.data?.positions&&result.parameters.layout===p.layout;+ if(showPath&&compatible)line(ctx,result.data.route.map(pt=>map(...pt)),'#bcdf8d55',3);+ const goal=map(p.goal_x,p.goal_y);circle(ctx,...goal,12+Math.sin(t*2)*2,'#bcdf8d17');circle(ctx,...goal,6,'#c2e98b');words(ctx,'GOAL',goal[0]+11,goal[1]+4,'#d9edbb',9);+ let position=[1,1];+ if(compatible){if(replay)index=Math.min(result.data.positions.length-1,Math.floor(((t-start)*30)%result.data.positions.length));const frame=result.data.positions[index];position=[frame[1],frame[2]];scrub.value=index;}+ const robot=map(...position);circle(ctx,...robot,17,'#bae38912');circle(ctx,...robot,9,'#e5edcc');circle(ctx,robot[0]+3,robot[1]-3,2,'#364d35');+ if(w>550){words(ctx,'ROVER 01',24,70,'#a7c292',10);words(ctx,compatible?`${result.data.positions[index][0].toFixed(1)} s`:'READY',24,98,'#dceac7',20);words(ctx,compatible?'Recorded trajectory':'Choose a destination',24,121,'#8da684',9);}+ words(ctx,'1 METRE GRID',left,top+size+20,'#8da684',9);+ },api.signal);screen.element.setAttribute('aria-label','Office rover mission map; click to select a goal');screen.element.tabIndex=0;+ screen.element.addEventListener('click',e=>{const b=screen.element.getBoundingClientRect();const x=Math.max(1,Math.min(9,Math.round((e.clientX-b.left-bounds.left)/bounds.s*2)/2)),y=Math.max(1,Math.min(9,Math.round((10-(e.clientY-b.top-bounds.top)/bounds.s)*2)/2));api.setParameter('goal_x',x);api.setParameter('goal_y',y);api.announce(`Destination ${x} east, ${y} north`);});+ screen.element.addEventListener('keydown',e=>{const axes={ArrowLeft:['goal_x',-.5],ArrowRight:['goal_x',.5],ArrowUp:['goal_y',.5],ArrowDown:['goal_y',-.5]};if(axes[e.key]){const [key,delta]=axes[e.key];api.setParameter(key,Math.max(1,Math.min(9,p[key]+delta)));e.preventDefault();}});+ const bar=toolbar(stage,[['Replay mission',()=>{start=now;replay=true;}],['Hide route',b=>{showPath=!showPath;b.textContent=showPath?'Hide route':'Show route';b.setAttribute('aria-pressed',String(showPath));}]]);+ const scrub=el('input');scrub.type='range';scrub.min=0;scrub.max=1;scrub.value=0;scrub.setAttribute('aria-label','Mission replay position');scrub.style.width='100px';scrub.addEventListener('input',()=>{replay=false;index=Number(scrub.value);});bar.append(scrub);+ return {update(params,r,motion){p=params;result=r;screen.motion(motion);if(r?.data?.positions&&r.id!==last){last=r.id;start=now;index=0;scrub.max=r.data.positions.length-1;}const same=r?.data?.positions&&Object.keys(p).every(k=>p[k]===r.parameters[k]);tag.textContent=same?'RECORDED MISSION':'DESTINATION PREVIEW';info.textContent=same?'Replay the route your simulated rover actually travelled.':'Click open floor, then send the rover.';}};+}diff --git a/store/agents/foam-agent/.gitignore b/store/agents/foam-agent/.gitignorenew file mode 100644index 000000000..97ed7159a--- /dev/null+++ b/store/agents/foam-agent/.gitignore@@ -0,0 +1,8 @@+upstream/+juce/+.venv/+.build/+.sumo/+__pycache__/+*.pyc+coverage/diff --git a/store/agents/foam-agent/AGENTS.md b/store/agents/foam-agent/AGENTS.mdnew file mode 100644index 000000000..b559320ea--- /dev/null+++ b/store/agents/foam-agent/AGENTS.md@@ -0,0 +1,18 @@+# Foam-Agent workspace++This harness turns a request into a real, inspectable simulation artifact. Start with+the `foam-agent` skill. The editable project is `studio.json` plus files in this workspace.+The viewer follows `out/latest.json` and the run history; save small useful changes as you work.++Run `"$STUDIO_TOOLCHAIN/run.sh" simulate` after a change. The runner validates controls,+records provenance, writes artifacts, and updates `.harness/verdict.json`. Do not hand-edit the+verdict to claim a run succeeded. Inspect the produced artifact before describing the result.++The local workflow solves a two-dimensional D2Q9 lattice Boltzmann model on a coarse grid. It is an exploratory simulation, not a converged engineering drag analysis. The optional OpenFOAM action reproduces the supplied lid-driven cavity benchmark; Foam-Agent instructions and sources are pinned for richer cases.++The installed sources are at `$STUDIO_UPSTREAM`. Preserve upstream credit and use the pinned+instructions when extending the domain workflow. Local simulations are the default. Ask before+using a paid generation service or operating physical hardware unless the user already authorized it.++When developing this package itself, keep it independently installable from its folder; shared+runtime copies are synchronized by `store/tools/sync-studios.mjs` and `sync-runtimes.mjs`.diff --git a/store/agents/foam-agent/INTEGRATION.md b/store/agents/foam-agent/INTEGRATION.mdnew file mode 100644index 000000000..40c046e95--- /dev/null+++ b/store/agents/foam-agent/INTEGRATION.md@@ -0,0 +1,12 @@+# Local flow simulation and optional OpenFOAM benchmark++`simulate` executes an original D2Q9 lattice Boltzmann solver with a circle, square, or ellipse. It exports the velocity/pressure field and convergence samples. The animated replay samples those measured velocities; an unsaved control change switches to a labelled flow sketch. `openfoam` uses active `blockMesh` and `icoFoam` executables for the supplied cavity case. The upstream Foam-Agent skill is in `upstream/.claude/skills/foam.md`; its MCP/model calls need its separate native setup.++## Verification scope++Local solver variants, field export, tracer interaction, and failure recovery are in the local test scope. OpenFOAM itself is optional and was not installed on this Mac. The coarse local solver is not a validated engineering wind tunnel.++The browser acceptance suite lives in `store/viewers/studio-viewer/test/studios.e2e.mjs`.+`TESTING.md` beside that viewer records commands, outcomes, screenshots and coverage.+Upstream source revisions are in `upstream.lock.json`; install-time Python dependencies are+hash-locked in `requirements.lock`. No user application configuration is written by setup.diff --git a/store/agents/foam-agent/LICENSE b/store/agents/foam-agent/LICENSEnew file mode 100644index 000000000..a499cd17e--- /dev/null+++ b/store/agents/foam-agent/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Autonomous, Inc.++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/foam-agent/LICENSE-upstream b/store/agents/foam-agent/LICENSE-upstreamnew file mode 100644index 000000000..c89766daf--- /dev/null+++ b/store/agents/foam-agent/LICENSE-upstream@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2025 Ling Yue++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/foam-agent/README.md b/store/agents/foam-agent/README.mdnew file mode 100644index 000000000..7cdcfb97f--- /dev/null+++ b/store/agents/foam-agent/README.md@@ -0,0 +1,49 @@+# Foam-Agent · Wind tunnel++Give the wind something to move around. Explore shapes, trace the currents, and compare your experiments.++```sh+harness dsh install autonomous/foam-agent+```++Open a workspace in Harness. Setup fetches upstream sources at the commit in `upstream.lock.json`,+installs a package-local Python 3.11 environment, and verifies the local tools. The starter runs+without credentials or a cloud account. Studio Viewer provides controls, history, downloads,+live agent updates, and failure recovery. Setup never edits an application's preferences.++## What runs here++The local workflow solves a two-dimensional D2Q9 lattice Boltzmann model on a coarse grid. It is an exploratory simulation, not a converged engineering drag analysis. The optional OpenFOAM action reproduces the supplied lid-driven cavity benchmark; Foam-Agent instructions and sources are pinned for richer cases.++Edit `studio.json`, then run:++```sh+"$STUDIO_TOOLCHAIN/run.sh" simulate # Release the wind+"$STUDIO_TOOLCHAIN/run.sh" openfoam # Run OpenFOAM cavity+```++The native command is optional and fails with a useful message when its external runtime is+unavailable. It never silently substitutes sample output. Use the upstream README in `upstream/`+for full native application setup. See `INTEGRATION.md` for the exact bridge and local test scope.++Every successful run owns a new folder under `out/runs/`, a `result.json` with parameters, engine,+source commit, timestamps, measured values, and downloadable artifacts. `.harness/verdict.json`+means the named artifact was produced, not that an engineering or aesthetic claim was certified.+The starter can be regenerated with no network after install.++## Development and testing++Install the shared viewer and this package with `harness dsh install <path> --link`.+`toolchain/doctor.sh` checks the local runtime. The repository's Studio Viewer browser suite+materializes temporary workspaces and exercises each shipped local workflow. Run it from+`store/viewers/studio-viewer` with `npm run test:browser`; exact results live in its `TESTING.md`.++## Credit and stewardship++[Foam-Agent](https://github.com/csml-rpi/Foam-Agent) is maintained by Foam-Agent team. Its sources are+fetched unchanged at `9e3e253e76727036585ca6e88e6fc5a762cb62e0`. Upstream licensing: MIT; OpenFOAM: GPL-3.0.+The original license is preserved in `LICENSE-upstream`; dependency terms still apply.++OpenHarness contributors wrote the MIT wrapper, local starter, and viewer integration. This is+an independent integration, not an upstream endorsement. Upstream bugs belong with the upstream+project; wrapper bugs belong in OpenHarness. Maintainers are welcome to take over this package.diff --git a/store/agents/foam-agent/THIRD_PARTY_NOTICES.md b/store/agents/foam-agent/THIRD_PARTY_NOTICES.mdnew file mode 100644index 000000000..7c91080e9--- /dev/null+++ b/store/agents/foam-agent/THIRD_PARTY_NOTICES.md@@ -0,0 +1,9 @@+# Third-party notices++Foam-Agent — Foam-Agent team. https://github.com/csml-rpi/Foam-Agent++Pinned source: 9e3e253e76727036585ca6e88e6fc5a762cb62e0. Fetched at install into ignored `upstream/`, unmodified.+License: MIT; OpenFOAM: GPL-3.0. See `LICENSE-upstream` and the fetched source tree.++The original local starter and wrapper are MIT licensed. The native runtime and separately+installed applications retain their own licenses. No upstream endorsement is claimed.diff --git a/store/agents/foam-agent/VERSIONS b/store/agents/foam-agent/VERSIONSnew file mode 100644index 000000000..5406c1ac7--- /dev/null+++ b/store/agents/foam-agent/VERSIONS@@ -0,0 +1,2 @@+UPSTREAM_COMMIT=9e3e253e76727036585ca6e88e6fc5a762cb62e0+PYTHON=3.11diff --git a/store/agents/foam-agent/harness.json b/store/agents/foam-agent/harness.jsonnew file mode 100644index 000000000..08e1a2608--- /dev/null+++ b/store/agents/foam-agent/harness.json@@ -0,0 +1,33 @@+{+ "spec": 1,+ "id": "autonomous/foam-agent",+ "name": "Foam-Agent",+ "category": "Simulation",+ "author": "Foam-Agent team",+ "description": "Give the wind something to move around. Explore shapes, trace the currents, and compare your experiments.",+ "engine": "codex",+ "workspace": {+ "template": "template",+ "marker": "studio.json",+ "init": "toolchain/init-workspace.sh"+ },+ "agent": {+ "instructions": "AGENTS.md",+ "skills": [+ "skills"+ ],+ "env": {+ "STUDIO_TOOLCHAIN": "${dsh}/toolchain",+ "STUDIO_PYTHON": "${dsh}/.venv/bin/python",+ "STUDIO_UPSTREAM": "${dsh}/upstream"+ }+ },+ "toolchain": {+ "setup": "toolchain/setup.sh",+ "doctor": "toolchain/doctor.sh"+ },+ "viewer": {+ "use": "autonomous/studio-viewer"+ },+ "verdict": ".harness/verdict.json"+}diff --git a/store/agents/foam-agent/requirements.in b/store/agents/foam-agent/requirements.innew file mode 100644index 000000000..d59d856f1--- /dev/null+++ b/store/agents/foam-agent/requirements.in@@ -0,0 +1 @@+numpy==2.3.5diff --git a/store/agents/foam-agent/requirements.lock b/store/agents/foam-agent/requirements.locknew file mode 100644index 000000000..327a140ba--- /dev/null+++ b/store/agents/foam-agent/requirements.lock@@ -0,0 +1,78 @@+# This file was autogenerated by uv via the following command:+# uv pip compile requirements.in --python-version 3.11 --universal --generate-hashes -o requirements.lock+numpy==2.3.5 \+ --hash=sha256:00dc4e846108a382c5869e77c6ed514394bdeb3403461d25a829711041217d5b \+ --hash=sha256:0472f11f6ec23a74a906a00b48a4dcf3849209696dff7c189714511268d103ae \+ --hash=sha256:04822c00b5fd0323c8166d66c701dc31b7fbd252c100acd708c48f763968d6a3 \+ --hash=sha256:052e8c42e0c49d2575621c158934920524f6c5da05a1d3b9bab5d8e259e045f0 \+ --hash=sha256:09a1bea522b25109bf8e6f3027bd810f7c1085c64a0c7ce050c1676ad0ba010b \+ --hash=sha256:0cd00b7b36e35398fa2d16af7b907b65304ef8bb4817a550e06e5012929830fa \+ --hash=sha256:0d8163f43acde9a73c2a33605353a4f1bc4798745a8b1d73183b28e5b435ae28 \+ --hash=sha256:1062fde1dcf469571705945b0f221b73928f34a20c904ffb45db101907c3454e \+ --hash=sha256:11e06aa0af8c0f05104d56450d6093ee639e15f24ecf62d417329d06e522e017 \+ --hash=sha256:17531366a2e3a9e30762c000f2c43a9aaa05728712e25c11ce1dbe700c53ad41 \+ --hash=sha256:1978155dd49972084bd6ef388d66ab70f0c323ddee6f693d539376498720fb7e \+ --hash=sha256:1ed1ec893cff7040a02c8aa1c8611b94d395590d553f6b53629a4461dc7f7b63 \+ --hash=sha256:2dcd0808a421a482a080f89859a18beb0b3d1e905b81e617a188bd80422d62e9 \+ --hash=sha256:2e2eb32ddb9ccb817d620ac1d8dae7c3f641c1e5f55f531a33e8ab97960a75b8 \+ --hash=sha256:2feae0d2c91d46e59fcd62784a3a83b3fb677fead592ce51b5a6fbb4f95965ff \+ --hash=sha256:3095bdb8dd297e5920b010e96134ed91d852d81d490e787beca7e35ae1d89cf7 \+ --hash=sha256:30bc11310e8153ca664b14c5f1b73e94bd0503681fcf136a163de856f3a50139 \+ --hash=sha256:3101e5177d114a593d79dd79658650fe28b5a0d8abeb8ce6f437c0e6df5be1a4 \+ --hash=sha256:396084a36abdb603546b119d96528c2f6263921c50df3c8fd7cb28873a237748 \+ --hash=sha256:3997b5b3c9a771e157f9aae01dd579ee35ad7109be18db0e85dbdbe1de06e952 \+ --hash=sha256:414802f3b97f3c1eef41e530aaba3b3c1620649871d8cb38c6eaff034c2e16bd \+ --hash=sha256:51c1e14eb1e154ebd80e860722f9e6ed6ec89714ad2db2d3aa33c31d7c12179b \+ --hash=sha256:51c55fe3451421f3a6ef9a9c1439e82101c57a2c9eab9feb196a62b1a10b58ce \+ --hash=sha256:5ee6609ac3604fa7780e30a03e5e241a7956f8e2fcfe547d51e3afa5247ac47f \+ --hash=sha256:612a95a17655e213502f60cfb9bf9408efdc9eb1d5f50535cc6eb365d11b42b5 \+ --hash=sha256:6203fdf9f3dc5bdaed7319ad8698e685c7a3be10819f41d32a0723e611733b42 \+ --hash=sha256:63c0e9e7eea69588479ebf4a8a270d5ac22763cc5854e9a7eae952a3908103f7 \+ --hash=sha256:66f85ce62c70b843bab1fb14a05d5737741e74e28c7b8b5a064de10142fad248 \+ --hash=sha256:6cf9b429b21df6b99f4dee7a1218b8b7ffbbe7df8764dc0bd60ce8a0708fed1e \+ --hash=sha256:70b37199913c1bd300ff6e2693316c6f869c7ee16378faf10e4f5e3275b299c3 \+ --hash=sha256:727fd05b57df37dc0bcf1a27767a3d9a78cbbc92822445f32cc3436ba797337b \+ --hash=sha256:74ae7b798248fe62021dbf3c914245ad45d1a6b0cb4a29ecb4b31d0bfbc4cc3e \+ --hash=sha256:784db1dcdab56bf0517743e746dfb0f885fc68d948aba86eeec2cba234bdf1c0 \+ --hash=sha256:86945f2ee6d10cdfd67bcb4069c1662dd711f7e2a4343db5cecec06b87cf31aa \+ --hash=sha256:86d835afea1eaa143012a2d7a3f45a3adce2d7adc8b4961f0b362214d800846a \+ --hash=sha256:872a5cf366aec6bb1147336480fef14c9164b154aeb6542327de4970282cd2f5 \+ --hash=sha256:8b973c57ff8e184109db042c842423ff4f60446239bd585a5131cc47f06f789d \+ --hash=sha256:8cba086a43d54ca804ce711b2a940b16e452807acebe7852ff327f1ecd49b0d4 \+ --hash=sha256:8f7f0e05112916223d3f438f293abf0727e1181b5983f413dfa2fefc4098245c \+ --hash=sha256:900218e456384ea676e24ea6a0417f030a3b07306d29d7ad843957b40a9d8d52 \+ --hash=sha256:93eebbcf1aafdf7e2ddd44c2923e2672e1010bddc014138b229e49725b4d6be5 \+ --hash=sha256:9c75442b2209b8470d6d5d8b1c25714270686f14c749028d2199c54e29f20b4d \+ --hash=sha256:9ee2197ef8c4f0dfe405d835f3b6a14f5fee7782b5de51ba06fb65fc9b36e9f1 \+ --hash=sha256:a414504bef8945eae5f2d7cb7be2d4af77c5d1cb5e20b296c2c25b61dff2900c \+ --hash=sha256:a4b9159734b326535f4dd01d947f919c6eefd2d9827466a696c44ced82dfbc18 \+ --hash=sha256:a80afd79f45f3c4a7d341f13acbe058d1ca8ac017c165d3fa0d3de6bc1a079d7 \+ --hash=sha256:aa5bc7c5d59d831d9773d1170acac7893ce3a5e130540605770ade83280e7188 \+ --hash=sha256:acfd89508504a19ed06ef963ad544ec6664518c863436306153e13e94605c218 \+ --hash=sha256:aeffcab3d4b43712bb7a60b65f6044d444e75e563ff6180af8f98dd4b905dfd2 \+ --hash=sha256:afaffc4393205524af9dfa400fa250143a6c3bc646c08c9f5e25a9f4b4d6a903 \+ --hash=sha256:b0c7088a73aef3d687c4deef8452a3ac7c1be4e29ed8bf3b366c8111128ac60c \+ --hash=sha256:b46b4ec24f7293f23adcd2d146960559aaf8020213de8ad1909dba6c013bf89c \+ --hash=sha256:b501b5fa195cc9e24fe102f21ec0a44dffc231d2af79950b451e0d99cea02234 \+ --hash=sha256:bf06bc2af43fa8d32d30fae16ad965663e966b1a3202ed407b84c989c3221e82 \+ --hash=sha256:c804e3a5aba5460c73955c955bdbd5c08c354954e9270a2c1565f62e866bdc39 \+ --hash=sha256:c8a9958e88b65c3b27e22ca2a076311636850b612d6bbfb76e8d156aacde2aaf \+ --hash=sha256:cc0a57f895b96ec78969c34f682c602bf8da1a0270b09bc65673df2e7638ec20 \+ --hash=sha256:cc8920d2ec5fa99875b670bb86ddeb21e295cb07aa331810d9e486e0b969d946 \+ --hash=sha256:ccc933afd4d20aad3c00bcef049cb40049f7f196e0397f1109dba6fed63267b0 \+ --hash=sha256:ce581db493ea1a96c0556360ede6607496e8bf9b3a8efa66e06477267bc831e9 \+ --hash=sha256:d0f23b44f57077c1ede8c5f26b30f706498b4862d3ff0a7298b8411dd2f043ff \+ --hash=sha256:d21644de1b609825ede2f48be98dfde4656aefc713654eeee280e37cadc4e0ad \+ --hash=sha256:d6889ec4ec662a1a37eb4b4fb26b6100841804dac55bd9df579e326cdc146227 \+ --hash=sha256:de5672f4a7b200c15a4127042170a694d4df43c992948f5e1af57f0174beed10 \+ --hash=sha256:e6a0bc88393d65807d751a614207b7129a310ca4fe76a74e5c7da5fa5671417e \+ --hash=sha256:ed89927b86296067b4f81f108a2271d8926467a8868e554eaf370fc27fa3ccaf \+ --hash=sha256:ee3888d9ff7c14604052b2ca5535a30216aa0a58e948cdd3eeb8d3415f638769 \+ --hash=sha256:f0963b55cdd70fad460fa4c1341f12f976bb26cb66021a5580329bd498988310 \+ --hash=sha256:f16417ec91f12f814b10bafe79ef77e70113a2f5f7018640e7425ff979253425 \+ --hash=sha256:f28620fe26bee16243be2b7b874da327312240a7cdc38b769a697578d2100013 \+ --hash=sha256:f4255143f5160d0de972d28c8f9665d882b5f61309d8362fdd3e103cf7bf010c \+ --hash=sha256:ffac52f28a7849ad7576293c0cb7b9f08304e8f7d738a8cb8a90ec4c55a998eb \+ --hash=sha256:ffe22d2b05504f786c867c8395de703937f934272eb67586817b46188b4ded6d \+ --hash=sha256:fffe29a1ef00883599d1dc2c51aa2e5d80afe49523c261a74933df395c15c520+ # via -r requirements.indiff --git a/store/agents/foam-agent/skills/foam-agent/SKILL.md b/store/agents/foam-agent/skills/foam-agent/SKILL.mdnew file mode 100644index 000000000..d50071561--- /dev/null+++ b/store/agents/foam-agent/skills/foam-agent/SKILL.md@@ -0,0 +1,19 @@+---+name: foam-agent+description: Create and inspect simulation projects in the Foam-Agent Harness workspace, including its local starter and optional upstream integration.+---++# Wind tunnel++Read `studio.json` to understand the current controls; `"$STUDIO_TOOLCHAIN/../studio.config.json"`+describes their ranges. Run `"$STUDIO_TOOLCHAIN/run.sh" simulate` to make a new result.+Successful artifacts and their measurements are in `out/runs/<id>/`; `out/latest.json` names the+current result. A failed run preserves the last success and records the error in the verdict.++The local workflow solves a two-dimensional D2Q9 lattice Boltzmann model on a coarse grid. It is an exploratory simulation, not a converged engineering drag analysis. The optional OpenFOAM action reproduces the supplied lid-driven cavity benchmark; Foam-Agent instructions and sources are pinned for richer cases.++Use `"$STUDIO_TOOLCHAIN/../README.md"` for the integration contract and commands. Read the relevant+files under `$STUDIO_UPSTREAM` before using an upstream API. Keep controls within their documented+ranges, preserve the data needed to reproduce a comparison, and distinguish preview results from+native service or hardware output. The viewer supports history and artifact downloads; tell the+user which run contains the result, and what was actually measured.diff --git a/store/agents/foam-agent/store.json b/store/agents/foam-agent/store.jsonnew file mode 100644index 000000000..b8d0a30bd--- /dev/null+++ b/store/agents/foam-agent/store.json@@ -0,0 +1,6 @@+{+ "homepage": "https://github.com/csml-rpi/Foam-Agent",+ "upstream": "https://github.com/csml-rpi/Foam-Agent",+ "license": "MIT; OpenFOAM: GPL-3.0",+ "screenshots": []+}diff --git a/store/agents/foam-agent/studio.config.json b/store/agents/foam-agent/studio.config.jsonnew file mode 100644index 000000000..cc0dd325f--- /dev/null+++ b/store/agents/foam-agent/studio.config.json@@ -0,0 +1,99 @@+{+ "title": "Wind tunnel",+ "description": "Give the wind something to move around. Explore shapes, trace the currents, and compare your experiments.",+ "category": "Simulation",+ "scene": "A LITTLE ROOM FOR AIR",+ "hint": "Click the flow field to seed a tracer \u00b7 compare shapes",+ "tip": "A round nose and a narrow tail change the wake. Try a shape, then keep the same wind for the next run.",+ "previewLabel": "Flow illustration \u00b7 run to simulate",+ "controls": [+ {+ "id": "shape",+ "label": "Shape",+ "type": "select",+ "value": "circle",+ "options": [+ {+ "value": "circle",+ "label": "Pebble"+ },+ {+ "value": "ellipse",+ "label": "Airfoil study"+ },+ {+ "value": "square",+ "label": "Square block"+ }+ ]+ },+ {+ "id": "speed",+ "label": "Wind speed",+ "type": "number",+ "value": 4,+ "min": 2,+ "max": 8,+ "step": 1,+ "integer": true,+ "unit": "lattice units \u00d7 100",+ "hint": ""+ },+ {+ "id": "radius",+ "label": "Body size",+ "type": "number",+ "value": 7,+ "min": 4,+ "max": 10,+ "step": 1,+ "integer": true,+ "unit": "cells",+ "hint": ""+ },+ {+ "id": "viscosity",+ "label": "Viscosity",+ "type": "number",+ "value": 0.08,+ "min": 0.04,+ "max": 0.16,+ "step": 0.01,+ "integer": false,+ "unit": "",+ "hint": ""+ },+ {+ "id": "steps",+ "label": "Simulation steps",+ "type": "number",+ "value": 320,+ "min": 80,+ "max": 800,+ "step": 40,+ "integer": false,+ "unit": "",+ "hint": ""+ }+ ],+ "actions": [+ {+ "id": "simulate",+ "label": "Release the wind",+ "description": ""+ },+ {+ "id": "openfoam",+ "label": "Run OpenFOAM cavity",+ "description": "Run the supplied Foundation OpenFOAM v10 benchmark when installed"+ }+ ],+ "credit": "Foam-Agent \u00b7 Foam-Agent team",+ "empty": "Adjust the controls, then make your first exploration. Every successful run stays in the history.",+ "theme": {+ "accent": "#3d7289",+ "tint": "#e0e9ea",+ "stage": "#152830",+ "stage-accent": "#95d9dd"+ }+}diff --git a/store/agents/foam-agent/template/openfoam-cavity/0/U b/store/agents/foam-agent/template/openfoam-cavity/0/Unew file mode 100644index 000000000..e779f6837--- /dev/null+++ b/store/agents/foam-agent/template/openfoam-cavity/0/U@@ -0,0 +1,4 @@+FoamFile+{ version 2.0; format ascii; class volVectorField; object U; }+dimensions [0 1 -1 0 0 0 0]; internalField uniform (0 0 0);+boundaryField {movingWall {type fixedValue; value uniform (1 0 0);} fixedWalls {type noSlip;} frontAndBack {type empty;}}diff --git a/store/agents/foam-agent/template/openfoam-cavity/0/p b/store/agents/foam-agent/template/openfoam-cavity/0/pnew file mode 100644index 000000000..1613c04b7--- /dev/null+++ b/store/agents/foam-agent/template/openfoam-cavity/0/p@@ -0,0 +1,4 @@+FoamFile+{ version 2.0; format ascii; class volScalarField; object p; }+dimensions [0 2 -2 0 0 0 0]; internalField uniform 0;+boundaryField {movingWall {type zeroGradient;} fixedWalls {type zeroGradient;} frontAndBack {type empty;}}diff --git a/store/agents/foam-agent/template/openfoam-cavity/constant/transportProperties b/store/agents/foam-agent/template/openfoam-cavity/constant/transportPropertiesnew file mode 100644index 000000000..bb3326bcd--- /dev/null+++ b/store/agents/foam-agent/template/openfoam-cavity/constant/transportProperties@@ -0,0 +1,3 @@+FoamFile+{ version 2.0; format ascii; class dictionary; object transportProperties; }+nu [0 2 -1 0 0 0 0] 0.01;diff --git a/store/agents/foam-agent/template/openfoam-cavity/system/blockMeshDict b/store/agents/foam-agent/template/openfoam-cavity/system/blockMeshDictnew file mode 100644index 000000000..a5df332b4--- /dev/null+++ b/store/agents/foam-agent/template/openfoam-cavity/system/blockMeshDict@@ -0,0 +1,12 @@+FoamFile+{ version 2.0; format ascii; class dictionary; object blockMeshDict; }+convertToMeters 0.1;+vertices ((0 0 0) (1 0 0) (1 1 0) (0 1 0) (0 0 0.1) (1 0 0.1) (1 1 0.1) (0 1 0.1));+blocks (hex (0 1 2 3 4 5 6 7) (20 20 1) simpleGrading (1 1 1));+edges ();+boundary (+ movingWall {type wall; faces ((3 7 6 2));}+ fixedWalls {type wall; faces ((0 4 7 3) (2 6 5 1) (1 5 4 0));}+ frontAndBack {type empty; faces ((0 3 2 1) (4 5 6 7));}+);+mergePatchPairs ();diff --git a/store/agents/foam-agent/template/openfoam-cavity/system/controlDict b/store/agents/foam-agent/template/openfoam-cavity/system/controlDictnew file mode 100644index 000000000..d675da87c--- /dev/null+++ b/store/agents/foam-agent/template/openfoam-cavity/system/controlDict@@ -0,0 +1,5 @@+FoamFile+{ version 2.0; format ascii; class dictionary; object controlDict; }+application icoFoam; startFrom startTime; startTime 0; stopAt endTime; endTime 0.5; deltaT 0.005;+writeControl timeStep; writeInterval 20; purgeWrite 0; writeFormat ascii; writePrecision 6; writeCompression off;+timeFormat general; timePrecision 6; runTimeModifiable true;diff --git a/store/agents/foam-agent/template/openfoam-cavity/system/fvSchemes b/store/agents/foam-agent/template/openfoam-cavity/system/fvSchemesnew file mode 100644index 000000000..78d1f85db--- /dev/null+++ b/store/agents/foam-agent/template/openfoam-cavity/system/fvSchemes@@ -0,0 +1,8 @@+FoamFile+{ version 2.0; format ascii; class dictionary; object fvSchemes; }+ddtSchemes {default Euler;}+gradSchemes {default Gauss linear; grad(p) Gauss linear;}+divSchemes {default none; div(phi,U) Gauss linear;}+laplacianSchemes {default Gauss linear orthogonal;}+interpolationSchemes {default linear;}+snGradSchemes {default orthogonal;}diff --git a/store/agents/foam-agent/template/openfoam-cavity/system/fvSolution b/store/agents/foam-agent/template/openfoam-cavity/system/fvSolutionnew file mode 100644index 000000000..c440fa14f--- /dev/null+++ b/store/agents/foam-agent/template/openfoam-cavity/system/fvSolution@@ -0,0 +1,4 @@+FoamFile+{ version 2.0; format ascii; class dictionary; object fvSolution; }+solvers {p {solver PCG; preconditioner DIC; tolerance 1e-06; relTol 0.05;} pFinal {$p; relTol 0;} U {solver smoothSolver; smoother symGaussSeidel; tolerance 1e-05; relTol 0;}}+PISO {nCorrectors 2; nNonOrthogonalCorrectors 0; pRefCell 0; pRefValue 0;}diff --git a/store/agents/foam-agent/template/studio.json b/store/agents/foam-agent/template/studio.jsonnew file mode 100644index 000000000..6ea64af42--- /dev/null+++ b/store/agents/foam-agent/template/studio.json@@ -0,0 +1,11 @@+{+ "spec": 1,+ "title": "Wind tunnel",+ "parameters": {+ "shape": "circle",+ "speed": 4,+ "radius": 7,+ "viscosity": 0.08,+ "steps": 320+ }+}diff --git a/store/agents/foam-agent/toolchain/doctor.sh b/store/agents/foam-agent/toolchain/doctor.shnew file mode 100755index 000000000..f0130f59b--- /dev/null+++ b/store/agents/foam-agent/toolchain/doctor.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+test -x .venv/bin/python || { echo 'miss run toolchain/setup.sh to install the local runtime'; exit 1; }+.venv/bin/python -c 'import numpy; import json; json.load(open("studio.config.json")); print("ok Foam-Agent local workflow")'+test -f upstream/README.md || { echo "miss pinned upstream sources"; exit 1; }+echo "ok upstream 9e3e253e7672"diff --git a/store/agents/foam-agent/toolchain/init-workspace.sh b/store/agents/foam-agent/toolchain/init-workspace.shnew file mode 100755index 000000000..8749f6568--- /dev/null+++ b/store/agents/foam-agent/toolchain/init-workspace.sh@@ -0,0 +1,3 @@+#!/usr/bin/env bash+set -euo pipefail+exec "${HARNESS_DSH_DIR:?}/toolchain/run.sh" simulatediff --git a/store/agents/foam-agent/toolchain/run.sh b/store/agents/foam-agent/toolchain/run.shnew file mode 100755index 000000000..a9e5df771--- /dev/null+++ b/store/agents/foam-agent/toolchain/run.sh@@ -0,0 +1,6 @@+#!/usr/bin/env bash+set -euo pipefail+studio_package="$(cd "$(dirname "$0")/.." && pwd)"+export PATH="$studio_package/.venv/bin:$PATH"+export PYTHONUNBUFFERED=1+exec "$studio_package/.venv/bin/python" "$studio_package/toolchain/workflow.py" "$@"diff --git a/store/agents/foam-agent/toolchain/runtimes.sh b/store/agents/foam-agent/toolchain/runtimes.shnew file mode 100644index 000000000..7223c78dc--- /dev/null+++ b/store/agents/foam-agent/toolchain/runtimes.sh@@ -0,0 +1,192 @@+# shellcheck shell=bash+# runtimes.sh — the interpreters a store package runs on, found on this machine or fetched, never+# asked of the person who pressed Get.+#+# Sourced (not run) by a package's setup, doctor and viewer scripts. A new Mac has Apple's Python 3.9,+# no Homebrew and, for most people, no Node on PATH; a package that answers "brew install [email protected]"+# has failed its install. So:+#+# harness_node 18 node >= 18 on PATH, with npm: the machine's own, else the Node Harness+# itself runs on (~/.harness/runtime/current-node, laid down with the CLI)+# harness_uv uv on PATH: the machine's own, else a pinned, checksummed release+# fetched into ~/.harness/runtime+# harness_venv DIR 3.12 [MIN [BELOW]]+# DIR is a venv on CPython 3.12, which uv downloads when the machine+# has none. A venv already there on a Python in [MIN, BELOW) is kept.+# harness_pip DIR PKG… install into that venv, through uv+# harness_micromamba micromamba, pinned and checksummed, for native libraries PyPI has+# no wheel for (pycairo on macOS)+# harness_conda_env DIR SPEC… DIR is a conda-forge environment with those packages+#+# Every function prints `miss …` and returns 1 when it cannot deliver, so `harness_node 18 || exit 1`+# reads like the rest of a setup script. Nothing here touches the user's shell profile; what it+# installs lands in ~/.harness/runtime or the package's own directory (uv keeps its download cache+# where it always does, which a venv does not depend on).+#+# ONE copy is written by hand: store/tools/runtimes.sh in the OpenHarness repository. Each package+# carries an identical copy (a package installs alone, so it cannot reach this one);+# `node store/tools/sync-runtimes.mjs` rewrites them and the CLI's store spec fails when one drifts.++HARNESS_RUNTIME="${ADAPTER_RUNTIME_DIR:-${HOME:-}/.harness/runtime}"+# The Pythons uv downloads live with Harness's other runtimes, not in uv's own ~/.local/share/uv:+# a package's venv points at its interpreter, and `uv python uninstall` there must not break it.+UV_PYTHON_INSTALL_DIR="${UV_PYTHON_INSTALL_DIR:-$HARNESS_RUNTIME/python}"+export UV_PYTHON_INSTALL_DIR+HARNESS_UV_VERSION=0.12.15+HARNESS_MICROMAMBA_VERSION=2.9.0-0++_harness_platform() {+ case "$(uname -s)-$(uname -m)" in+ Darwin-arm64) echo darwin-arm64 ;;+ Darwin-x86_64) echo darwin-x64 ;;+ Linux-x86_64) echo linux-x64 ;;+ Linux-aarch64 | Linux-arm64) echo linux-arm64 ;;+ *) return 1 ;;+ esac+}++_harness_sha256() {+ if command -v shasum >/dev/null 2>&1; then shasum -a 256 "$1" | cut -d' ' -f1+ else sha256sum "$1" | cut -d' ' -f1; fi+}++# _harness_fetch URL DEST SHA256 — DEST exists only if what arrived matches the pinned checksum.+_harness_fetch() {+ local part="$2.part.$$"+ if ! curl -fsSL --retry 3 --connect-timeout 20 --max-time 900 -o "$part" "$1"; then+ rm -f "$part"; echo "miss could not download $1 — check this machine's internet connection"; return 1+ fi+ if [ "$(_harness_sha256 "$part")" != "$3" ]; then+ rm -f "$part"; echo "miss $1 did not match its pinned checksum; nothing was installed"; return 1+ fi+ mv -f "$part" "$2"+}++_harness_node_at_least() {+ command -v node >/dev/null 2>&1 || return 1+ node -e '+ const [a, b = 0] = process.argv[1].split(".").map(Number)+ const [x, y] = process.versions.node.split(".").map(Number)+ process.exit(x > a || (x === a && y >= b) ? 0 : 1)+ ' "$1" >/dev/null 2>&1+}++harness_node() {+ local min="${1:-18}" recorded saved="$PATH" own=0+ _harness_node_at_least "$min" && own=1+ # A node without npm beside it (a distro's nodejs package) cannot run a setup's `npm ci`.+ if [ "$own" = 1 ] && command -v npm >/dev/null 2>&1; then return 0; fi+ recorded="$(cat "$HARNESS_RUNTIME/current-node" 2>/dev/null || true)"+ # Already Harness's own (a second call, or a wrapper calling a script that asks again): nothing to add.+ if [ "$own" = 1 ] && [ -n "$recorded" ] && [ "$(command -v node)" = "${recorded%/*}/node" ]; then return 0; fi+ if [ -n "$recorded" ] && [ -x "${recorded%/*}/node" ]; then+ PATH="${recorded%/*}:$PATH"; export PATH; hash -r 2>/dev/null || true+ _harness_node_at_least "$min" && return 0+ PATH="$saved"; export PATH; hash -r 2>/dev/null || true+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min — this machine's newest is $("${recorded%/*}/node" -v), Harness's own; update Harness"+ return 1+ fi+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min, and Harness's own Node is not in $HARNESS_RUNTIME — run \`harness start\` once to lay it down"+ return 1+}++harness_uv() {+ local dir asset sum tmp+ command -v uv >/dev/null 2>&1 && return 0+ for dir in "${HOME:-}/.local/bin" "${HOME:-}/.cargo/bin"; do+ [ -n "${HOME:-}" ] || break+ if [ -x "$dir/uv" ]; then PATH="$dir:$PATH"; export PATH; return 0; fi+ done+ dir="$HARNESS_RUNTIME/uv-$HARNESS_UV_VERSION"+ if [ ! -x "$dir/uv" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=uv-aarch64-apple-darwin sum=dc304b9ed1b24174572290fba60ac3f6fe63c73a671f0439e62a91375841964d ;;+ darwin-x64) asset=uv-x86_64-apple-darwin sum=e9ca61775532368fe518ab03e7a354c7ecab8ccb3c7d941c775fcc4a362b801b ;;+ linux-x64) asset=uv-x86_64-unknown-linux-gnu sum=f97935763c04be3e692460a7aaeaaab8fc3b78fcf8b389da820b38ae7423a638 ;;+ linux-arm64) asset=uv-aarch64-unknown-linux-gnu sum=0e9a3499b0587d449c9ff684c0160da607826e4af1cee220bc87f378702d3e08 ;;+ *) echo "miss uv — there is no uv release for $(uname -s) $(uname -m); install it from https://docs.astral.sh/uv/"; return 1 ;;+ esac+ echo " fetching uv $HARNESS_UV_VERSION into $HARNESS_RUNTIME (it brings Python and the packages)"+ mkdir -p "$HARNESS_RUNTIME" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ tmp="$(mktemp -d "$HARNESS_RUNTIME/.uv.XXXXXX")" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ if ! _harness_fetch "https://github.com/astral-sh/uv/releases/download/$HARNESS_UV_VERSION/$asset.tar.gz" "$tmp/uv.tar.gz" "$sum"; then+ rm -rf "$tmp"; return 1+ fi+ tar -xzf "$tmp/uv.tar.gz" -C "$tmp" && chmod +x "$tmp/$asset/uv" "$tmp/$asset/uvx" \+ || { rm -rf "$tmp"; echo "miss the uv archive would not unpack"; return 1; }+ # Two installs at once both get here; whichever renames first wins and the other's copy goes.+ # (mv onto a directory that exists would nest the copy inside it, hence the test.)+ [ -e "$dir" ] || mv "$tmp/$asset" "$dir" 2>/dev/null || true+ rm -rf "$tmp"+ [ -x "$dir/uv" ] || { echo "miss uv did not land in $dir"; return 1; }+ fi+ PATH="$dir:$PATH"; export PATH+}++# harness_venv DIR VERSION [MIN [BELOW]] — MIN defaults to VERSION; BELOW is exclusive and optional.+harness_venv() {+ local dir="${1:?harness_venv needs a directory}" want="${2:?harness_venv needs a Python version}"+ local min="${3:-$2}" below="${4:-}"+ if [ -x "$dir/bin/python" ] && "$dir/bin/python" -c '+import sys+at = lambda s: tuple(int(p) for p in s.split("."))+v = sys.version_info[:2]+sys.exit(0 if v >= at(sys.argv[1]) and (not sys.argv[2] or v < at(sys.argv[2])) else 1)+' "$min" "$below" 2>/dev/null; then+ echo "ok $("$dir/bin/python" --version) in $dir"+ return 0+ fi+ harness_uv || return 1+ echo " python $want in $dir (uv downloads it when this machine has none)"+ rm -rf "$dir"+ # only-managed: the same python-build-standalone interpreter on every machine, so a package tested+ # once is tested everywhere — not whichever Homebrew or pyenv Python happened to be first on PATH.+ uv venv --quiet --seed --python "$want" --python-preference only-managed "$dir" \+ || { echo "miss could not make a Python $want environment in $dir"; return 1; }+ echo "ok $("$dir/bin/python" --version) in $dir"+}++harness_pip() {+ local dir="${1:?harness_pip needs a venv}"+ shift+ harness_uv || return 1+ # uv's own error comes first; the miss line is last, so it is the line the store shows.+ uv pip install --quiet --python "$dir/bin/python" "$@" \+ || { echo "miss could not install $* into $dir"; return 1; }+}++harness_micromamba() {+ local dir asset sum+ dir="$HARNESS_RUNTIME/micromamba-$HARNESS_MICROMAMBA_VERSION"+ if [ ! -x "$dir/micromamba" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=micromamba-osx-arm64 sum=ec2a072f028e1a7cf20f3e2e74d5a8127cf5a5f27636375b5359811565f4e5be ;;+ darwin-x64) asset=micromamba-osx-64 sum=1e71054bb3ac9a076e21f7ec48acfef536f9b3f1408f371a942784bf5ef83d8a ;;+ linux-x64) asset=micromamba-linux-64 sum=366cd9cd8be14df1ab8ed50352a82111082a36686b2d389fdb79a92c3fafb3e3 ;;+ linux-arm64) asset=micromamba-linux-aarch64 sum=9f93b974adcb4d166996af969b6cd371287d1a3e52733704727884d9b74cb7a7 ;;+ *) echo "miss micromamba — there is no release for $(uname -s) $(uname -m)"; return 1 ;;+ esac+ echo " fetching micromamba $HARNESS_MICROMAMBA_VERSION into $HARNESS_RUNTIME (native libraries PyPI has no wheel for)"+ mkdir -p "$dir" || { echo "miss cannot write $dir"; return 1; }+ _harness_fetch "https://github.com/mamba-org/micromamba-releases/releases/download/$HARNESS_MICROMAMBA_VERSION/$asset" "$dir/micromamba.$$" "$sum" || return 1+ chmod +x "$dir/micromamba.$$" && mv -f "$dir/micromamba.$$" "$dir/micromamba" \+ || { rm -f "$dir/micromamba.$$"; echo "miss micromamba would not install into $dir"; return 1; }+ fi+ HARNESS_MICROMAMBA="$dir/micromamba"+ export HARNESS_MICROMAMBA+}++# harness_conda_env DIR SPEC… — conda-forge only, packages cached under ~/.harness/runtime/mamba.+harness_conda_env() {+ local dir="${1:?harness_conda_env needs a directory}"+ shift+ # micromamba takes a relative --prefix as a name under its root prefix and "succeeds" there.+ case "$dir" in /*) ;; *) dir="$PWD/$dir" ;; esac+ harness_micromamba || return 1+ MAMBA_ROOT_PREFIX="$HARNESS_RUNTIME/mamba" "$HARNESS_MICROMAMBA" create --yes --quiet \+ --prefix "$dir" --override-channels --channel conda-forge "$@" >/dev/null \+ && [ -d "$dir/conda-meta" ] \+ || { echo "miss could not make the conda-forge environment in $dir ($*)"; return 1; }+}diff --git a/store/agents/foam-agent/toolchain/setup.sh b/store/agents/foam-agent/toolchain/setup.shnew file mode 100755index 000000000..efbece7e2--- /dev/null+++ b/store/agents/foam-agent/toolchain/setup.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+harness_venv .venv 3.11 3.11 3.12+.venv/bin/python toolchain/studio_fetch.py+if [ -s requirements.lock ]; then harness_pip .venv --require-hashes -r requirements.lock; fi+exec toolchain/doctor.shdiff --git a/store/agents/foam-agent/toolchain/studio_fetch.py b/store/agents/foam-agent/toolchain/studio_fetch.pynew file mode 100644index 000000000..88a670b25--- /dev/null+++ b/store/agents/foam-agent/toolchain/studio_fetch.py@@ -0,0 +1,34 @@+"""Fetch reviewed source pins without installing a service or changing user configuration."""+import json+import os+from pathlib import Path+import subprocess++root = Path(__file__).resolve().parent.parent+sources = json.loads((root / "upstream.lock.json").read_text())+for source in sources:+ target = root / source["directory"]+ def git(*args):+ return subprocess.check_output(["git", "-C", str(target), *args], text=True,+ env={**os.environ, "GIT_LFS_SKIP_SMUDGE": "1"}).strip()+ if not (target / ".git").exists():+ target.mkdir(parents=True, exist_ok=True)+ git("init", "-q")+ git("remote", "add", "origin", source["url"])+ if source.get("sparse"):+ git("sparse-checkout", "init", "--cone")+ git("sparse-checkout", "set", *source["sparse"])+ if git("remote", "get-url", "origin") != source["url"]:+ raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])+ try:+ current = git("rev-parse", "HEAD")+ except subprocess.CalledProcessError:+ current = ""+ if current != source["commit"]:+ if current and git("status", "--porcelain"):+ raise SystemExit(f"Save your edits in {target} before changing its source pin")+ git("fetch", "--depth", "1", "--filter=blob:none", "origin", source["commit"])+ git("checkout", "--detach", source["commit"])+ print(f'ok {source["name"]} at {source["commit"][:12]}', flush=True)diff --git a/store/agents/foam-agent/toolchain/studio_runtime.py b/store/agents/foam-agent/toolchain/studio_runtime.pynew file mode 100644index 000000000..8b8ea016c--- /dev/null+++ b/store/agents/foam-agent/toolchain/studio_runtime.py@@ -0,0 +1,132 @@+"""Portable runner copied into each independently installable studio package."""+import json+import math+import os+from pathlib import Path+import subprocess+import sys+import tempfile+import time+import uuid+++def workspace():+ return Path(os.environ.get("HARNESS_WORKSPACE", os.getcwd())).resolve()+++def package():+ return Path(__file__).resolve().parent.parent+++def contained(path):+ target = Path(path).resolve()+ target.relative_to(workspace())+ return target+++def atomic_json(path, data):+ path = contained(path)+ path.parent.mkdir(parents=True, exist_ok=True)+ with tempfile.NamedTemporaryFile(mode="w", dir=path.parent, prefix=".studio-", delete=False) as f:+ json.dump(data, f, indent=2, allow_nan=False)+ f.write("\n")+ temp = f.name+ os.replace(temp, path)+++def command(argv, cwd=None, timeout=120, env=None):+ """No shell interpolation; keep complete logs as output, bound execution time."""+ result = subprocess.run([str(x) for x in argv], cwd=cwd, timeout=timeout,+ env=env, text=True, capture_output=True)+ if result.returncode:+ raise RuntimeError((result.stderr or result.stdout)[-1600:] or f"{argv[0]} exited {result.returncode}")+ return result.stdout+++def parameters(config, values):+ if not isinstance(values, dict) or set(values) - {c["id"] for c in config["controls"]}:+ raise ValueError("Invalid studio controls")+ result = {}+ for c in config["controls"]:+ value = values.get(c["id"], c["value"])+ if c["type"] == "number":+ if type(value) not in (int, float) or not math.isfinite(value) or not c["min"] <= value <= c["max"]:+ raise ValueError(f'{c["label"]} is outside its range')+ if c.get("integer") and value != int(value):+ raise ValueError(f'{c["label"]} must be a whole number')+ elif c["type"] == "select":+ if value not in [o["value"] for o in c["options"]]:+ raise ValueError(f'Unknown {c["label"]}')+ elif not isinstance(value, str) or len(value) > c.get("maxLength", 500):+ raise ValueError(f'Invalid {c["label"]}')+ result[c["id"]] = value+ return result+++def metric(label, value, unit=""):+ return {"label": label, "value": value, "unit": unit}+++def previous_runs():+ base = contained(workspace() / "out/runs")+ rows = []+ for p in sorted(base.glob("*/result.json"))[-100:]:+ try:+ rows.append(json.loads(contained(p).read_text()))+ except (ValueError, OSError):+ continue+ return rows+++def execute(actions):+ root = workspace()+ config = json.loads((package() / "studio.config.json").read_text())+ action = sys.argv[1] if len(sys.argv) > 1 else config["actions"][0]["id"]+ started = time.monotonic()+ verdict_path = root / ".harness/verdict.json"+ verdict = {"spec": 1, "ready": False, "summary": "Preparing the studio run", "findings": [],+ "phases": [{"id": "run", "name": "Make", "state": "active"},+ {"id": "inspect", "name": "Inspect", "state": "pending"}]}+ try:+ if action not in actions:+ raise ValueError(f"Unknown action: {action}")+ source = contained(root / "studio.json")+ if source.stat().st_size > 16384:+ raise ValueError("studio.json is too large")+ project = json.loads(source.read_text())+ p = parameters(config, project["parameters"])+ atomic_json(verdict_path, verdict)+ run_id = time.strftime("%Y%m%dT%H%M%S", time.gmtime()) + "-" + uuid.uuid4().hex[:8]+ output = contained(root / "out/runs" / run_id)+ output.mkdir(parents=True)+ print(f'{config["title"]}: {action}', flush=True)+ result = actions[action](p, output)+ artifacts = []+ for artifact in result.pop("files", []):+ file = contained(output / artifact["name"])+ file.relative_to(output)+ if not file.is_file() or not file.stat().st_size:+ raise ValueError(f'Missing output: {artifact["name"]}')+ artifacts.append({"label": artifact["label"], "path": str(file.relative_to(root))})+ result.update({"spec": 1, "id": run_id, "action": action, "parameters": p,+ "createdAt": time.strftime("%Y-%m-%dT%H:%M:%SZ", time.gmtime()),+ "durationSeconds": round(time.monotonic() - started, 3), "artifacts": artifacts,+ "upstream": json.loads((package() / "upstream.lock.json").read_text())})+ atomic_json(output / "result.json", result)+ atomic_json(root / "out/latest.json", result)+ verdict.update({"ready": True, "summary": f'{result["title"]} · {result["engine"]}',+ "artifact": str((output / "result.json").relative_to(root)),+ "phases": [{"id": "run", "name": "Make", "state": "done"},+ {"id": "inspect", "name": "Inspect", "state": "done"}],+ "updatedAt": result["createdAt"]})+ atomic_json(verdict_path, verdict)+ print(f'Ready: {result["title"]}', flush=True)+ except Exception as exc:+ verdict.update({"summary": str(exc)[:500], "findings": [{"severity": "error", "kind": "run-failed", "message": str(exc)[:1000]}],+ "phases": [{"id": "run", "name": "Make", "state": "failed"}]})+ try:+ atomic_json(verdict_path, verdict)+ except (ValueError, OSError):+ pass+ print(str(exc), file=sys.stderr)+ raise SystemExit(1) from excdiff --git a/store/agents/foam-agent/toolchain/workflow.py b/store/agents/foam-agent/toolchain/workflow.pynew file mode 100644index 000000000..bee1a9fd6--- /dev/null+++ b/store/agents/foam-agent/toolchain/workflow.py@@ -0,0 +1,74 @@+import json+import shutil+import numpy as np+from studio_runtime import execute, metric, command, workspace, contained+++def simulate(p, out):+ width, height = 120, 56+ x, y = np.meshgrid(np.arange(width), np.arange(height))+ cx, cy, radius = 36, height // 2, p["radius"]+ if p["shape"] == "circle":+ body = (x-cx)**2 + (y-cy)**2 <= radius**2+ elif p["shape"] == "square":+ body = (abs(x-cx) <= radius) & (abs(y-cy) <= radius)+ else:+ body = ((x-cx)/(radius*1.8))**2 + ((y-cy)/(radius*.55))**2 <= 1+ solid = body.copy(); solid[0,:] = True; solid[-1,:] = True+ c = np.array([[0,0],[1,0],[0,1],[-1,0],[0,-1],[1,1],[-1,1],[-1,-1],[1,-1]])+ weights = np.array([4/9]+[1/9]*4+[1/36]*4)+ opposite = [0,3,4,1,2,7,8,5,6]+ speed = p["speed"] / 100+ rho = np.ones((height,width)); ux = np.full_like(rho,speed); uy = np.zeros_like(rho)+ def equilibrium():+ cu = c[:,0,None,None]*ux + c[:,1,None,None]*uy+ return weights[:,None,None]*rho*(1+3*cu+4.5*cu**2-1.5*(ux**2+uy**2))+ f = equilibrium(); inlet = f[:,:,0].copy(); changes=[]+ for step in range(p["steps"]):+ previous = ux.copy()+ rho = f.sum(axis=0)+ ux = np.sum(f*c[:,0,None,None],axis=0)/rho+ uy = np.sum(f*c[:,1,None,None],axis=0)/rho+ ux[solid]=0; uy[solid]=0+ f += (equilibrium()-f)/(3*p["viscosity"]+.5)+ for i,(dx,dy) in enumerate(c):+ f[i]=np.roll(np.roll(f[i],dx,axis=1),dy,axis=0)+ bounced=f[opposite][:,solid].copy();f[:,solid]=bounced+ f[:,:,0]=inlet;f[:,:,-1]=f[:,:,-2]+ if step%40==0:+ change=float(np.sqrt(np.mean((ux-previous)**2)));changes.append([step,round(change,8)])+ print(f'Simulating flow · {step}/{p["steps"]} steps',flush=True)+ if not np.all(np.isfinite(f)) or np.max(abs(ux))>.6:+ raise RuntimeError('The flow became unstable. Use a slower wind or higher viscosity.')+ velocity=np.sqrt(ux**2+uy**2);fluid=~solid+ field=np.stack([x,y,ux,uy,rho/3,solid.astype(float)],axis=-1).reshape(-1,6)+ np.savetxt(out/'flow.csv',field,delimiter=',',header='x,y,ux,uy,pressure,solid',comments='')+ stride=2+ data={"width":width,"height":height,"stride":stride,"shape":p["shape"],"radius":radius,+ "ux":np.round(ux[::stride,::stride],5).tolist(),"uy":np.round(uy[::stride,::stride],5).tolist(),+ "pressure":np.round(rho[::stride,::stride]/3,6).tolist(),+ "solid":solid[::stride,::stride].astype(int).tolist(),"convergence":changes}+ (out/'field.json').write_text(json.dumps(data))+ return {"title":f'{p["shape"].capitalize()} · wind {p["speed"]}',"description":"A real coarse-grid 2D flow simulation. Compare the velocity field under the same settings; this is not a validated drag estimate.",+ "engine":"Local D2Q9 lattice Boltzmann simulation","metrics":[metric("Reynolds number",round(speed*2*radius/p["viscosity"],1)),metric("Peak velocity",round(float(velocity[fluid].max()),3),"lattice"),metric("Solver steps",p["steps"])],"data":data,+ "files":[{"label":"Velocity field CSV","name":"flow.csv"},{"label":"Flow data","name":"field.json"}]}+++def openfoam(p,out):+ if not shutil.which('icoFoam') or not shutil.which('blockMesh'):+ raise RuntimeError('OpenFOAM Foundation v10 is not active. Source its etc/bashrc, then run again. The local flow simulation is available now.')+ source=contained(workspace()/'openfoam-cavity')+ if not source.is_dir():+ raise RuntimeError('The workspace needs the supplied openfoam-cavity benchmark.')+ target=out/'cavity';shutil.copytree(source,target)+ mesh=command(['blockMesh','-case',target],timeout=60)+ log=command(['icoFoam','-case',target],timeout=300)+ (out/'openfoam.log').write_text(mesh+'\n'+log)+ if not (target/'0.5/U').exists():+ raise RuntimeError('OpenFOAM did not produce the final velocity field.')+ shutil.make_archive(str(out/'cavity'),'zip',target)+ return {"title":"Lid-driven cavity · OpenFOAM","description":"The Foundation v10 reference case completed. Inspect its mesh, residuals and final fields before drawing conclusions.","engine":"Native OpenFOAM · icoFoam", "metrics":[metric("Final time",.5,"s"),metric("Mesh",400,"cells")],"data":{"log":log[-3000:]},"files":[{"label":"OpenFOAM case","name":"cavity.zip"},{"label":"Solver log","name":"openfoam.log"}]}+++if __name__=='__main__':+ execute({'simulate':simulate,'openfoam':openfoam})diff --git a/store/agents/foam-agent/upstream.lock.json b/store/agents/foam-agent/upstream.lock.jsonnew file mode 100644index 000000000..6dec904f7--- /dev/null+++ b/store/agents/foam-agent/upstream.lock.json@@ -0,0 +1,14 @@+[+ {+ "name": "Foam-Agent",+ "url": "https://github.com/csml-rpi/Foam-Agent.git",+ "commit": "9e3e253e76727036585ca6e88e6fc5a762cb62e0",+ "directory": "upstream",+ "sparse": [+ "src",+ ".claude",+ "scripts",+ "docker"+ ]+ }+]diff --git a/store/agents/foam-agent/view.mjs b/store/agents/foam-agent/view.mjsnew file mode 100644index 000000000..e76bf3312--- /dev/null+++ b/store/agents/foam-agent/view.mjs@@ -0,0 +1,38 @@+import {canvas,grid,line,words,circle,toolbar,badge,label} from '/graphics.mjs';+export function mount(stage,api){+ let p=api.getParameters(),field,pressure=false,arrows=false,tracers=[],lastT=0;+ const info=label(stage,'An invitation to follow the flow.'),tag=badge(stage,'FLOW SKETCH');+ const screen=canvas(stage,(ctx,w,h,t)=>{+ grid(ctx,w,h,32);const top=38,bottom=h-55,fh=bottom-top,scaleX=(w-48)/120,scaleY=fh/56;+ const speed=p.speed/100,cx=24+36*scaleX,cy=top+28*scaleY;+ if(field){+ for(let row=0;row<field.ux.length;row++)for(let col=0;col<field.ux[row].length;col++){+ if(field.solid[row][col])continue;+ const magnitude=Math.hypot(field.ux[row][col],field.uy[row][col]);+ const v=pressure?Math.max(0,Math.min(1,.5+(field.pressure[row][col]-1/3)*20)):Math.min(1,magnitude/.13);+ ctx.fillStyle=`hsla(${205-v*150},60%,${25+v*30}%,${.06+v*.3})`;ctx.fillRect(24+col*2*scaleX,top+row*2*scaleY,2*scaleX+1,2*scaleY+1);+ if(arrows&&col%4===0&&row%4===0){const x=24+col*2*scaleX,y=top+row*2*scaleY;line(ctx,[[x,y],[x+field.ux[row][col]*90,y+field.uy[row][col]*90]],'#d0eeec66',1);}+ }+ }+ for(let row=0;row<19;row++){+ const y0=top+row/18*fh,points=[];+ for(let x=24;x<w-24;x+=4){const near=Math.exp(-(((x-cx)/(30*scaleX))**2)),dy=(y0-cy),spread=Math.sign(dy)*p.radius*scaleY*Math.exp(-((dy/(p.radius*scaleY*2))**2))*near;points.push([x,y0+spread]);}+ line(ctx,points,field?'#b3e5e41b':'#b3e5e42f',.8);+ if(!field){const x=24+((t*p.speed*22+row*53)%(w-48)),near=Math.exp(-(((x-cx)/(30*scaleX))**2)),dy=y0-cy;circle(ctx,x,y0+Math.sign(dy)*p.radius*scaleY*Math.exp(-((dy/(p.radius*scaleY*2))**2))*near,1.4,'#a1dadba0');}+ }+ ctx.fillStyle='#cedad4';ctx.strokeStyle='#f0faf0';ctx.lineWidth=2;ctx.beginPath();+ if(p.shape==='square')ctx.rect(cx-p.radius*scaleX,cy-p.radius*scaleY,p.radius*2*scaleX,p.radius*2*scaleY);+ else ctx.ellipse(cx,cy,p.radius*scaleX*(p.shape==='ellipse'?1.8:1),p.radius*scaleY*(p.shape==='ellipse'?.55:1),0,0,Math.PI*2);+ ctx.fill();ctx.stroke();+ const dt=Math.min(.05,Math.max(0,t-lastT));lastT=t;+ if(field&&tracers.length<80&&dt>0)tracers.push({x:1,y:2+Math.random()*52});+ for(const dot of tracers){let ux=speed,uy=0;if(field){const row=Math.max(0,Math.min(field.ux.length-1,Math.floor(dot.y/2))),col=Math.max(0,Math.min(field.ux[0].length-1,Math.floor(dot.x/2)));ux=field.ux[row][col];uy=field.uy[row][col];}dot.x+=ux*dt*120;dot.y+=uy*dt*120;circle(ctx,24+dot.x*scaleX,top+dot.y*scaleY,1.8,'#c6fbf3');}+ tracers=tracers.filter(dot=>dot.x<120&&dot.y>0&&dot.y<56);+ words(ctx,pressure?'PRESSURE':'VELOCITY',24,h-23,'#99b9bf',9);words(ctx,field?'Measured field':'Illustrative field',w-132,h-23,'#99b9bf',9);+ },api.signal);+ screen.element.setAttribute('aria-label','Interactive flow field; click to release a tracer');screen.element.tabIndex=0;+ screen.element.addEventListener('click',e=>{const b=screen.element.getBoundingClientRect();tracers.push({x:(e.clientX-b.left-24)/(b.width-48)*120,y:(e.clientY-b.top-38)/(b.height-93)*56});api.announce('Tracer released.');});+ screen.element.addEventListener('keydown',e=>{if(e.key==='Enter'){tracers.push({x:1,y:20});api.announce('Tracer released.');}});+ toolbar(stage,[['Show pressure',b=>{pressure=!pressure;b.textContent=pressure?'Show velocity':'Show pressure';b.setAttribute('aria-pressed',String(pressure));}],['Show vectors',b=>{arrows=!arrows;b.textContent=arrows?'Hide vectors':'Show vectors';b.setAttribute('aria-pressed',String(arrows));}],['Release tracers',()=>{for(let i=0;i<15;i++)tracers.push({x:1,y:3+i*3.3});api.announce('Fifteen tracers released.');}]]);+ return {update(params,result,motion){p=params;field=result?.data?.ux&&Object.keys(p).every(k=>p[k]===result.parameters[k])?result.data:null;tag.textContent=field?'SIMULATION REPLAY':'FLOW SKETCH';info.textContent=field?'Particles follow your measured velocity field.':'Adjust the body, then run to calculate the flow.';screen.motion(motion);}};+}diff --git a/store/agents/juce-agent-toolkit/.gitignore b/store/agents/juce-agent-toolkit/.gitignorenew file mode 100644index 000000000..97ed7159a--- /dev/null+++ b/store/agents/juce-agent-toolkit/.gitignore@@ -0,0 +1,8 @@+upstream/+juce/+.venv/+.build/+.sumo/+__pycache__/+*.pyc+coverage/diff --git a/store/agents/juce-agent-toolkit/AGENTS.md b/store/agents/juce-agent-toolkit/AGENTS.mdnew file mode 100644index 000000000..325e277cd--- /dev/null+++ b/store/agents/juce-agent-toolkit/AGENTS.md@@ -0,0 +1,18 @@+# JUCE Agent Toolkit workspace++This harness turns a request into a real, inspectable audio artifact. Start with+the `juce-agent-toolkit` skill. The editable project is `studio.json` plus files in this workspace.+The viewer follows `out/latest.json` and the run history; save small useful changes as you work.++Run `"$STUDIO_TOOLCHAIN/run.sh" render` after a change. The runner validates controls,+records provenance, writes artifacts, and updates `.harness/verdict.json`. Do not hand-edit the+verdict to claim a run succeeded. Inspect the produced artifact before describing the result.++The browser audition and Python WAV renderer are local DSP previews. The JUCE action compiles a native offline renderer from the workspace CMake project. JUCE toolkit skills also cover creating full DAW plugins; the starter renderer is not a VST3 plugin.++The installed sources are at `$STUDIO_UPSTREAM`. Preserve upstream credit and use the pinned+instructions when extending the domain workflow. Local simulations are the default. Ask before+using a paid generation service or operating physical hardware unless the user already authorized it.++When developing this package itself, keep it independently installable from its folder; shared+runtime copies are synchronized by `store/tools/sync-studios.mjs` and `sync-runtimes.mjs`.diff --git a/store/agents/juce-agent-toolkit/INTEGRATION.md b/store/agents/juce-agent-toolkit/INTEGRATION.mdnew file mode 100644index 000000000..fca3e22f8--- /dev/null+++ b/store/agents/juce-agent-toolkit/INTEGRATION.md@@ -0,0 +1,12 @@+# Local DSP and native JUCE offline rendering++`render` writes a mono PCM WAV and measures its peak and RMS; `juce` compiles `CMakeLists.txt` and `Source/main.cpp` in the workspace against the pinned JUCE modules, then measures the recorded WAV. The native renderer needs a C++ compiler/SDK; no DAW is required. JUCE toolkit skills under `upstream/skills` cover full plugin projects beyond this starter.++## Verification scope++Play the on-screen keys, change waveform/brightness, record, download, and compare history. Native JUCE was compiled and rendered on the Intel Mac. The output is an offline instrument renderer, not a packaged VST3.++The browser acceptance suite lives in `store/viewers/studio-viewer/test/studios.e2e.mjs`.+`TESTING.md` beside that viewer records commands, outcomes, screenshots and coverage.+Upstream source revisions are in `upstream.lock.json`; install-time Python dependencies are+hash-locked in `requirements.lock`. No user application configuration is written by setup.diff --git a/store/agents/juce-agent-toolkit/LICENSE b/store/agents/juce-agent-toolkit/LICENSEnew file mode 100644index 000000000..a499cd17e--- /dev/null+++ b/store/agents/juce-agent-toolkit/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Autonomous, Inc.++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/juce-agent-toolkit/LICENSE-upstream b/store/agents/juce-agent-toolkit/LICENSE-upstreamnew file mode 100644index 000000000..56b65f54c--- /dev/null+++ b/store/agents/juce-agent-toolkit/LICENSE-upstream@@ -0,0 +1,22 @@+MIT License++Copyright (c) 2026 Dan Raffel++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.+diff --git a/store/agents/juce-agent-toolkit/README.md b/store/agents/juce-agent-toolkit/README.mdnew file mode 100644index 000000000..8eb4b7056--- /dev/null+++ b/store/agents/juce-agent-toolkit/README.md@@ -0,0 +1,49 @@+# JUCE Agent Toolkit · Instrument maker++Find a sound that feels like you. Shape a synth, play a little, and take the recording with you.++```sh+harness dsh install autonomous/juce-agent-toolkit+```++Open a workspace in Harness. Setup fetches upstream sources at the commit in `upstream.lock.json`,+installs a package-local Python 3.11 environment, and verifies the local tools. The starter runs+without credentials or a cloud account. Studio Viewer provides controls, history, downloads,+live agent updates, and failure recovery. Setup never edits an application's preferences.++## What runs here++The browser audition and Python WAV renderer are local DSP previews. The JUCE action compiles a native offline renderer from the workspace CMake project. JUCE toolkit skills also cover creating full DAW plugins; the starter renderer is not a VST3 plugin.++Edit `studio.json`, then run:++```sh+"$STUDIO_TOOLCHAIN/run.sh" render # Record a phrase+"$STUDIO_TOOLCHAIN/run.sh" juce # Build with JUCE+```++The native command is optional and fails with a useful message when its external runtime is+unavailable. It never silently substitutes sample output. Use the upstream README in `upstream/`+for full native application setup. See `INTEGRATION.md` for the exact bridge and local test scope.++Every successful run owns a new folder under `out/runs/`, a `result.json` with parameters, engine,+source commit, timestamps, measured values, and downloadable artifacts. `.harness/verdict.json`+means the named artifact was produced, not that an engineering or aesthetic claim was certified.+The starter can be regenerated with no network after install.++## Development and testing++Install the shared viewer and this package with `harness dsh install <path> --link`.+`toolchain/doctor.sh` checks the local runtime. The repository's Studio Viewer browser suite+materializes temporary workspaces and exercises each shipped local workflow. Run it from+`store/viewers/studio-viewer` with `npm run test:browser`; exact results live in its `TESTING.md`.++## Credit and stewardship++[JUCE Agent Toolkit](https://github.com/danielraffel/juce-agent-toolkit) is maintained by Daniel Raffel. Its sources are+fetched unchanged at `9089b719f7378eba28dd078cdfb8b6e1c062bf13`. Upstream licensing: MIT; JUCE: AGPL-3.0 or commercial.+The original license is preserved in `LICENSE-upstream`; dependency terms still apply.++OpenHarness contributors wrote the MIT wrapper, local starter, and viewer integration. This is+an independent integration, not an upstream endorsement. Upstream bugs belong with the upstream+project; wrapper bugs belong in OpenHarness. Maintainers are welcome to take over this package.diff --git a/store/agents/juce-agent-toolkit/THIRD_PARTY_NOTICES.md b/store/agents/juce-agent-toolkit/THIRD_PARTY_NOTICES.mdnew file mode 100644index 000000000..9b8edb9af--- /dev/null+++ b/store/agents/juce-agent-toolkit/THIRD_PARTY_NOTICES.md@@ -0,0 +1,9 @@+# Third-party notices++JUCE Agent Toolkit — Daniel Raffel. https://github.com/danielraffel/juce-agent-toolkit++Pinned source: 9089b719f7378eba28dd078cdfb8b6e1c062bf13. Fetched at install into ignored `upstream/`, unmodified.+License: MIT; JUCE: AGPL-3.0 or commercial. See `LICENSE-upstream` and the fetched source tree.++The original local starter and wrapper are MIT licensed. The native runtime and separately+installed applications retain their own licenses. No upstream endorsement is claimed.diff --git a/store/agents/juce-agent-toolkit/VERSIONS b/store/agents/juce-agent-toolkit/VERSIONSnew file mode 100644index 000000000..0a1fd69b1--- /dev/null+++ b/store/agents/juce-agent-toolkit/VERSIONS@@ -0,0 +1,2 @@+UPSTREAM_COMMIT=9089b719f7378eba28dd078cdfb8b6e1c062bf13+PYTHON=3.11diff --git a/store/agents/juce-agent-toolkit/harness.json b/store/agents/juce-agent-toolkit/harness.jsonnew file mode 100644index 000000000..d76071abc--- /dev/null+++ b/store/agents/juce-agent-toolkit/harness.json@@ -0,0 +1,33 @@+{+ "spec": 1,+ "id": "autonomous/juce-agent-toolkit",+ "name": "JUCE Agent Toolkit",+ "category": "Audio",+ "author": "Daniel Raffel",+ "description": "Find a sound that feels like you. Shape a synth, play a little, and take the recording with you.",+ "engine": "codex",+ "workspace": {+ "template": "template",+ "marker": "studio.json",+ "init": "toolchain/init-workspace.sh"+ },+ "agent": {+ "instructions": "AGENTS.md",+ "skills": [+ "skills"+ ],+ "env": {+ "STUDIO_TOOLCHAIN": "${dsh}/toolchain",+ "STUDIO_PYTHON": "${dsh}/.venv/bin/python",+ "STUDIO_UPSTREAM": "${dsh}/upstream"+ }+ },+ "toolchain": {+ "setup": "toolchain/setup.sh",+ "doctor": "toolchain/doctor.sh"+ },+ "viewer": {+ "use": "autonomous/studio-viewer"+ },+ "verdict": ".harness/verdict.json"+}diff --git a/store/agents/juce-agent-toolkit/requirements.in b/store/agents/juce-agent-toolkit/requirements.innew file mode 100644index 000000000..7ded088c9--- /dev/null+++ b/store/agents/juce-agent-toolkit/requirements.in@@ -0,0 +1 @@+cmake==4.4.3diff --git a/store/agents/juce-agent-toolkit/requirements.lock b/store/agents/juce-agent-toolkit/requirements.locknew file mode 100644index 000000000..f80c268dd--- /dev/null+++ b/store/agents/juce-agent-toolkit/requirements.lock@@ -0,0 +1,23 @@+# This file was autogenerated by uv via the following command:+# uv pip compile requirements.in --python-version 3.11 --universal --generate-hashes -o requirements.lock+cmake==4.4.3 \+ --hash=sha256:09edc3fe8cee225bb2e7f3386199be7832cf5b65ef454827e001c02ec928298e \+ --hash=sha256:25a61850847c46e3268bb54058daa8a9043c91167909203ed19f8fa28223cc31 \+ --hash=sha256:3c2a6c250c411c0529c997de5d3ce18c3d98635cc0725efafb083dc475f3572b \+ --hash=sha256:520ff2ba3afb7a1e34a0ab222c0f4e89ad334dc7462814886e099bdf6ba8cbb3 \+ --hash=sha256:6558aa24eadc83315b0a66ae7570cb24a95147f35a3fff19771e574cecbfe23c \+ --hash=sha256:6bff4e826b3a0e153cfbf53d496f457b9b7d2ad3f16b327686b752609f2a562f \+ --hash=sha256:6c95b37116bb5c714656e4f76931ebdcb739209a1aee91cf51408ccfe137694e \+ --hash=sha256:708ad6b662ee89d3eb2eac02a1afba20ca653139cbe769fed046124d0c6bc050 \+ --hash=sha256:7f1916f8064c9593abf7fd9de6a7be22d826dbef17925e50a161df5196aabd88 \+ --hash=sha256:92a93bc9941cd5f5c8cc9a7da5c40a53f7643fcd2ac75d6c850510cb44945271 \+ --hash=sha256:a21c9f60d530d678659f100445b9c0828467a67d4bb5e8eb76343aca91e80e90 \+ --hash=sha256:a4e0a067f12a8b7869daf7090086029356fc641a0702eddc185cd4477583730a \+ --hash=sha256:ad3b88073f215841ef3eb45e7c7bab4ee3e7f33b7001e1d1b5454ed3f4eb9c9c \+ --hash=sha256:b0c2703ec0a624649dd184c0ac5ee4c7f5fe5ef35eb82f9da44f5a0903adb2b6 \+ --hash=sha256:bae3c4954623ec4d62e62c70443f0da7988b733111c2871fcc6a31ead5137e20 \+ --hash=sha256:c0d2ccd8f83605fedfd688bb37b4cb4008a7ddf6c32321b9c804168031a3cc74 \+ --hash=sha256:cd58e9d3d6b4372d2456da43f2eb74e4ff5fe7d700bbcaede290a09db3790b1e \+ --hash=sha256:d36c9bb471a67970b031d45b29c3b852f14bc8b64ac46b39ccc046fdf652f36d \+ --hash=sha256:f5aead3c09bfa662da5d1d65f6c526a449966314913039ce6de3c0ff82ea9266+ # via -r requirements.indiff --git a/store/agents/juce-agent-toolkit/skills/juce-agent-toolkit/SKILL.md b/store/agents/juce-agent-toolkit/skills/juce-agent-toolkit/SKILL.mdnew file mode 100644index 000000000..f6c892a43--- /dev/null+++ b/store/agents/juce-agent-toolkit/skills/juce-agent-toolkit/SKILL.md@@ -0,0 +1,19 @@+---+name: juce-agent-toolkit+description: Create and inspect audio projects in the JUCE Agent Toolkit Harness workspace, including its local starter and optional upstream integration.+---++# Instrument maker++Read `studio.json` to understand the current controls; `"$STUDIO_TOOLCHAIN/../studio.config.json"`+describes their ranges. Run `"$STUDIO_TOOLCHAIN/run.sh" render` to make a new result.+Successful artifacts and their measurements are in `out/runs/<id>/`; `out/latest.json` names the+current result. A failed run preserves the last success and records the error in the verdict.++The browser audition and Python WAV renderer are local DSP previews. The JUCE action compiles a native offline renderer from the workspace CMake project. JUCE toolkit skills also cover creating full DAW plugins; the starter renderer is not a VST3 plugin.++Use `"$STUDIO_TOOLCHAIN/../README.md"` for the integration contract and commands. Read the relevant+files under `$STUDIO_UPSTREAM` before using an upstream API. Keep controls within their documented+ranges, preserve the data needed to reproduce a comparison, and distinguish preview results from+native service or hardware output. The viewer supports history and artifact downloads; tell the+user which run contains the result, and what was actually measured.diff --git a/store/agents/juce-agent-toolkit/store.json b/store/agents/juce-agent-toolkit/store.jsonnew file mode 100644index 000000000..49f8b2d19--- /dev/null+++ b/store/agents/juce-agent-toolkit/store.json@@ -0,0 +1,6 @@+{+ "homepage": "https://github.com/danielraffel/juce-agent-toolkit",+ "upstream": "https://github.com/danielraffel/juce-agent-toolkit",+ "license": "MIT; JUCE: AGPL-3.0 or commercial",+ "screenshots": []+}diff --git a/store/agents/juce-agent-toolkit/studio.config.json b/store/agents/juce-agent-toolkit/studio.config.jsonnew file mode 100644index 000000000..a96bf02c4--- /dev/null+++ b/store/agents/juce-agent-toolkit/studio.config.json@@ -0,0 +1,99 @@+{+ "title": "Instrument maker",+ "description": "Find a sound that feels like you. Shape a synth, play a little, and take the recording with you.",+ "category": "Audio",+ "scene": "THE SOUND GARDEN",+ "hint": "Play the keys \u00b7 A S D F G H J K on your keyboard",+ "tip": "Try a mellow triangle with a slow attack. Every recording is a new version.",+ "previewLabel": "Live oscillator preview",+ "controls": [+ {+ "id": "wave",+ "label": "Waveform",+ "type": "select",+ "value": "sine",+ "options": [+ {+ "value": "sine",+ "label": "Sine \u00b7 soft"+ },+ {+ "value": "triangle",+ "label": "Triangle \u00b7 warm"+ },+ {+ "value": "saw",+ "label": "Saw \u00b7 bright"+ }+ ]+ },+ {+ "id": "frequency",+ "label": "Root note",+ "type": "number",+ "value": 220,+ "min": 110,+ "max": 880,+ "step": 1,+ "integer": true,+ "unit": "Hz",+ "hint": ""+ },+ {+ "id": "attack",+ "label": "Fade in",+ "type": "number",+ "value": 0.08,+ "min": 0.01,+ "max": 0.8,+ "step": 0.01,+ "integer": false,+ "unit": "s",+ "hint": ""+ },+ {+ "id": "brightness",+ "label": "Brightness",+ "type": "number",+ "value": 0.65,+ "min": 0.1,+ "max": 1,+ "step": 0.05,+ "integer": false,+ "unit": "",+ "hint": ""+ },+ {+ "id": "duration",+ "label": "Phrase length",+ "type": "number",+ "value": 3,+ "min": 1,+ "max": 8,+ "step": 1,+ "integer": true,+ "unit": "s",+ "hint": ""+ }+ ],+ "actions": [+ {+ "id": "render",+ "label": "Record a phrase",+ "description": ""+ },+ {+ "id": "juce",+ "label": "Build with JUCE",+ "description": "Compile and render the same oscillator with native JUCE"+ }+ ],+ "credit": "JUCE Agent Toolkit \u00b7 Daniel Raffel",+ "empty": "Adjust the controls, then make your first exploration. Every successful run stays in the history.",+ "theme": {+ "accent": "#a75c39",+ "tint": "#efe4d6",+ "stage": "#28211e",+ "stage-accent": "#f2bc88"+ }+}diff --git a/store/agents/juce-agent-toolkit/template/CMakeLists.txt b/store/agents/juce-agent-toolkit/template/CMakeLists.txtnew file mode 100644index 000000000..61ab24ddc--- /dev/null+++ b/store/agents/juce-agent-toolkit/template/CMakeLists.txt@@ -0,0 +1,11 @@+cmake_minimum_required(VERSION 3.22)+project(HarnessInstrument VERSION 1.0.0 LANGUAGES C CXX)+set(CMAKE_CXX_STANDARD 17)+if(NOT JUCE_ROOT)+ message(FATAL_ERROR "Pass -DJUCE_ROOT=<installed harness>/juce")+endif()+add_subdirectory("${JUCE_ROOT}" juce EXCLUDE_FROM_ALL)+juce_add_console_app(HarnessTone PRODUCT_NAME "Harness Tone")+target_sources(HarnessTone PRIVATE Source/main.cpp)+target_compile_definitions(HarnessTone PRIVATE JUCE_WEB_BROWSER=0 JUCE_USE_CURL=0)+target_link_libraries(HarnessTone PRIVATE juce::juce_audio_basics juce::juce_recommended_config_flags)diff --git a/store/agents/juce-agent-toolkit/template/Source/main.cpp b/store/agents/juce-agent-toolkit/template/Source/main.cppnew file mode 100644index 000000000..eb1fbcd97--- /dev/null+++ b/store/agents/juce-agent-toolkit/template/Source/main.cpp@@ -0,0 +1,50 @@+// Original OpenHarness offline instrument. JUCE retains its own license.+#include <juce_audio_basics/juce_audio_basics.h>+#include <cmath>+#include <cstdint>+#include <fstream>+#include <string>++int main(int argc, char** argv) {+ if (argc != 7) return 2;+ const std::string shape = argv[2];+ const double frequency = std::stod(argv[3]), attack = std::stod(argv[4]);+ const double brightness = std::stod(argv[5]), duration = std::stod(argv[6]);+ constexpr int rate = 44100;+ const auto count = static_cast<int>(rate * duration);+ if (count <= 0 || count > rate * 8 || frequency < 110 || frequency > 880) return 3;+ juce::AudioBuffer<float> buffer(1, count);+ juce::ADSR envelope;+ envelope.setSampleRate(rate);+ envelope.setParameters({static_cast<float>(attack), 0.05f, 0.85f, 0.05f});+ double filtered = 0;+ int lastSegment = -1;+ const int notes[] = {0, 7, 12, 3};+ const double alpha = 1 - std::exp(-2 * juce::MathConstants<double>::pi * (250 + 5000 * brightness) / rate);+ for (int i = 0; i < count; ++i) {+ const double t = static_cast<double>(i) / rate;+ const int segment = std::min(3, static_cast<int>(4 * t / duration));+ if (segment != lastSegment) { envelope.reset(); envelope.noteOn(); lastSegment = segment; }+ const double local = t - segment * duration / 4;+ const double hz = frequency * std::pow(2., notes[segment] / 12.);+ const double phase = std::fmod(t * hz, 1.);+ double value = std::sin(phase * juce::MathConstants<double>::twoPi);+ if (shape == "triangle") value = 1 - 4 * std::abs(phase - .5);+ if (shape == "saw") {+ value = 0;+ for (int n = 1; n < std::min(24, static_cast<int>(rate / (2 * hz))); ++n)+ value += std::sin(juce::MathConstants<double>::twoPi * phase * n) / n;+ value *= .5;+ }+ if (duration / 4 - local < .05) envelope.noteOff();+ filtered += alpha * (value - filtered);+ buffer.setSample(0, i, static_cast<float>(filtered * envelope.getNextSample() * .3));+ }+ std::ofstream file(argv[1], std::ios::binary);+ auto u16 = [&file](uint16_t n) { file.put(n & 255); file.put((n >> 8) & 255); };+ auto u32 = [&file](uint32_t n) { for (int j=0;j<4;++j) file.put((n >> (j*8)) & 255); };+ file.write("RIFF",4); u32(36 + count*2); file.write("WAVEfmt ",8); u32(16); u16(1); u16(1);+ u32(rate); u32(rate*2); u16(2); u16(16); file.write("data",4); u32(count*2);+ for (int i=0;i<count;++i) u16(static_cast<uint16_t>(static_cast<int16_t>(buffer.getSample(0,i)*32767)));+ return file.good() ? 0 : 4;+}diff --git a/store/agents/juce-agent-toolkit/template/studio.json b/store/agents/juce-agent-toolkit/template/studio.jsonnew file mode 100644index 000000000..220ae454b--- /dev/null+++ b/store/agents/juce-agent-toolkit/template/studio.json@@ -0,0 +1,11 @@+{+ "spec": 1,+ "title": "Instrument maker",+ "parameters": {+ "wave": "sine",+ "frequency": 220,+ "attack": 0.08,+ "brightness": 0.65,+ "duration": 3+ }+}diff --git a/store/agents/juce-agent-toolkit/toolchain/doctor.sh b/store/agents/juce-agent-toolkit/toolchain/doctor.shnew file mode 100755index 000000000..1aa90abbf--- /dev/null+++ b/store/agents/juce-agent-toolkit/toolchain/doctor.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+test -x .venv/bin/python || { echo 'miss run toolchain/setup.sh to install the local runtime'; exit 1; }+.venv/bin/python -c 'import json; json.load(open("studio.config.json")); print("ok JUCE Agent Toolkit local workflow")'+test -f upstream/README.md || { echo "miss pinned upstream sources"; exit 1; }+echo "ok upstream 9089b719f737"diff --git a/store/agents/juce-agent-toolkit/toolchain/init-workspace.sh b/store/agents/juce-agent-toolkit/toolchain/init-workspace.shnew file mode 100755index 000000000..d68d2d3b3--- /dev/null+++ b/store/agents/juce-agent-toolkit/toolchain/init-workspace.sh@@ -0,0 +1,3 @@+#!/usr/bin/env bash+set -euo pipefail+exec "${HARNESS_DSH_DIR:?}/toolchain/run.sh" renderdiff --git a/store/agents/juce-agent-toolkit/toolchain/run.sh b/store/agents/juce-agent-toolkit/toolchain/run.shnew file mode 100755index 000000000..a9e5df771--- /dev/null+++ b/store/agents/juce-agent-toolkit/toolchain/run.sh@@ -0,0 +1,6 @@+#!/usr/bin/env bash+set -euo pipefail+studio_package="$(cd "$(dirname "$0")/.." && pwd)"+export PATH="$studio_package/.venv/bin:$PATH"+export PYTHONUNBUFFERED=1+exec "$studio_package/.venv/bin/python" "$studio_package/toolchain/workflow.py" "$@"diff --git a/store/agents/juce-agent-toolkit/toolchain/runtimes.sh b/store/agents/juce-agent-toolkit/toolchain/runtimes.shnew file mode 100644index 000000000..7223c78dc--- /dev/null+++ b/store/agents/juce-agent-toolkit/toolchain/runtimes.sh@@ -0,0 +1,192 @@+# shellcheck shell=bash+# runtimes.sh — the interpreters a store package runs on, found on this machine or fetched, never+# asked of the person who pressed Get.+#+# Sourced (not run) by a package's setup, doctor and viewer scripts. A new Mac has Apple's Python 3.9,+# no Homebrew and, for most people, no Node on PATH; a package that answers "brew install [email protected]"+# has failed its install. So:+#+# harness_node 18 node >= 18 on PATH, with npm: the machine's own, else the Node Harness+# itself runs on (~/.harness/runtime/current-node, laid down with the CLI)+# harness_uv uv on PATH: the machine's own, else a pinned, checksummed release+# fetched into ~/.harness/runtime+# harness_venv DIR 3.12 [MIN [BELOW]]+# DIR is a venv on CPython 3.12, which uv downloads when the machine+# has none. A venv already there on a Python in [MIN, BELOW) is kept.+# harness_pip DIR PKG… install into that venv, through uv+# harness_micromamba micromamba, pinned and checksummed, for native libraries PyPI has+# no wheel for (pycairo on macOS)+# harness_conda_env DIR SPEC… DIR is a conda-forge environment with those packages+#+# Every function prints `miss …` and returns 1 when it cannot deliver, so `harness_node 18 || exit 1`+# reads like the rest of a setup script. Nothing here touches the user's shell profile; what it+# installs lands in ~/.harness/runtime or the package's own directory (uv keeps its download cache+# where it always does, which a venv does not depend on).+#+# ONE copy is written by hand: store/tools/runtimes.sh in the OpenHarness repository. Each package+# carries an identical copy (a package installs alone, so it cannot reach this one);+# `node store/tools/sync-runtimes.mjs` rewrites them and the CLI's store spec fails when one drifts.++HARNESS_RUNTIME="${ADAPTER_RUNTIME_DIR:-${HOME:-}/.harness/runtime}"+# The Pythons uv downloads live with Harness's other runtimes, not in uv's own ~/.local/share/uv:+# a package's venv points at its interpreter, and `uv python uninstall` there must not break it.+UV_PYTHON_INSTALL_DIR="${UV_PYTHON_INSTALL_DIR:-$HARNESS_RUNTIME/python}"+export UV_PYTHON_INSTALL_DIR+HARNESS_UV_VERSION=0.12.15+HARNESS_MICROMAMBA_VERSION=2.9.0-0++_harness_platform() {+ case "$(uname -s)-$(uname -m)" in+ Darwin-arm64) echo darwin-arm64 ;;+ Darwin-x86_64) echo darwin-x64 ;;+ Linux-x86_64) echo linux-x64 ;;+ Linux-aarch64 | Linux-arm64) echo linux-arm64 ;;+ *) return 1 ;;+ esac+}++_harness_sha256() {+ if command -v shasum >/dev/null 2>&1; then shasum -a 256 "$1" | cut -d' ' -f1+ else sha256sum "$1" | cut -d' ' -f1; fi+}++# _harness_fetch URL DEST SHA256 — DEST exists only if what arrived matches the pinned checksum.+_harness_fetch() {+ local part="$2.part.$$"+ if ! curl -fsSL --retry 3 --connect-timeout 20 --max-time 900 -o "$part" "$1"; then+ rm -f "$part"; echo "miss could not download $1 — check this machine's internet connection"; return 1+ fi+ if [ "$(_harness_sha256 "$part")" != "$3" ]; then+ rm -f "$part"; echo "miss $1 did not match its pinned checksum; nothing was installed"; return 1+ fi+ mv -f "$part" "$2"+}++_harness_node_at_least() {+ command -v node >/dev/null 2>&1 || return 1+ node -e '+ const [a, b = 0] = process.argv[1].split(".").map(Number)+ const [x, y] = process.versions.node.split(".").map(Number)+ process.exit(x > a || (x === a && y >= b) ? 0 : 1)+ ' "$1" >/dev/null 2>&1+}++harness_node() {+ local min="${1:-18}" recorded saved="$PATH" own=0+ _harness_node_at_least "$min" && own=1+ # A node without npm beside it (a distro's nodejs package) cannot run a setup's `npm ci`.+ if [ "$own" = 1 ] && command -v npm >/dev/null 2>&1; then return 0; fi+ recorded="$(cat "$HARNESS_RUNTIME/current-node" 2>/dev/null || true)"+ # Already Harness's own (a second call, or a wrapper calling a script that asks again): nothing to add.+ if [ "$own" = 1 ] && [ -n "$recorded" ] && [ "$(command -v node)" = "${recorded%/*}/node" ]; then return 0; fi+ if [ -n "$recorded" ] && [ -x "${recorded%/*}/node" ]; then+ PATH="${recorded%/*}:$PATH"; export PATH; hash -r 2>/dev/null || true+ _harness_node_at_least "$min" && return 0+ PATH="$saved"; export PATH; hash -r 2>/dev/null || true+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min — this machine's newest is $("${recorded%/*}/node" -v), Harness's own; update Harness"+ return 1+ fi+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min, and Harness's own Node is not in $HARNESS_RUNTIME — run \`harness start\` once to lay it down"+ return 1+}++harness_uv() {+ local dir asset sum tmp+ command -v uv >/dev/null 2>&1 && return 0+ for dir in "${HOME:-}/.local/bin" "${HOME:-}/.cargo/bin"; do+ [ -n "${HOME:-}" ] || break+ if [ -x "$dir/uv" ]; then PATH="$dir:$PATH"; export PATH; return 0; fi+ done+ dir="$HARNESS_RUNTIME/uv-$HARNESS_UV_VERSION"+ if [ ! -x "$dir/uv" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=uv-aarch64-apple-darwin sum=dc304b9ed1b24174572290fba60ac3f6fe63c73a671f0439e62a91375841964d ;;+ darwin-x64) asset=uv-x86_64-apple-darwin sum=e9ca61775532368fe518ab03e7a354c7ecab8ccb3c7d941c775fcc4a362b801b ;;+ linux-x64) asset=uv-x86_64-unknown-linux-gnu sum=f97935763c04be3e692460a7aaeaaab8fc3b78fcf8b389da820b38ae7423a638 ;;+ linux-arm64) asset=uv-aarch64-unknown-linux-gnu sum=0e9a3499b0587d449c9ff684c0160da607826e4af1cee220bc87f378702d3e08 ;;+ *) echo "miss uv — there is no uv release for $(uname -s) $(uname -m); install it from https://docs.astral.sh/uv/"; return 1 ;;+ esac+ echo " fetching uv $HARNESS_UV_VERSION into $HARNESS_RUNTIME (it brings Python and the packages)"+ mkdir -p "$HARNESS_RUNTIME" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ tmp="$(mktemp -d "$HARNESS_RUNTIME/.uv.XXXXXX")" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ if ! _harness_fetch "https://github.com/astral-sh/uv/releases/download/$HARNESS_UV_VERSION/$asset.tar.gz" "$tmp/uv.tar.gz" "$sum"; then+ rm -rf "$tmp"; return 1+ fi+ tar -xzf "$tmp/uv.tar.gz" -C "$tmp" && chmod +x "$tmp/$asset/uv" "$tmp/$asset/uvx" \+ || { rm -rf "$tmp"; echo "miss the uv archive would not unpack"; return 1; }+ # Two installs at once both get here; whichever renames first wins and the other's copy goes.+ # (mv onto a directory that exists would nest the copy inside it, hence the test.)+ [ -e "$dir" ] || mv "$tmp/$asset" "$dir" 2>/dev/null || true+ rm -rf "$tmp"+ [ -x "$dir/uv" ] || { echo "miss uv did not land in $dir"; return 1; }+ fi+ PATH="$dir:$PATH"; export PATH+}++# harness_venv DIR VERSION [MIN [BELOW]] — MIN defaults to VERSION; BELOW is exclusive and optional.+harness_venv() {+ local dir="${1:?harness_venv needs a directory}" want="${2:?harness_venv needs a Python version}"+ local min="${3:-$2}" below="${4:-}"+ if [ -x "$dir/bin/python" ] && "$dir/bin/python" -c '+import sys+at = lambda s: tuple(int(p) for p in s.split("."))+v = sys.version_info[:2]+sys.exit(0 if v >= at(sys.argv[1]) and (not sys.argv[2] or v < at(sys.argv[2])) else 1)+' "$min" "$below" 2>/dev/null; then+ echo "ok $("$dir/bin/python" --version) in $dir"+ return 0+ fi+ harness_uv || return 1+ echo " python $want in $dir (uv downloads it when this machine has none)"+ rm -rf "$dir"+ # only-managed: the same python-build-standalone interpreter on every machine, so a package tested+ # once is tested everywhere — not whichever Homebrew or pyenv Python happened to be first on PATH.+ uv venv --quiet --seed --python "$want" --python-preference only-managed "$dir" \+ || { echo "miss could not make a Python $want environment in $dir"; return 1; }+ echo "ok $("$dir/bin/python" --version) in $dir"+}++harness_pip() {+ local dir="${1:?harness_pip needs a venv}"+ shift+ harness_uv || return 1+ # uv's own error comes first; the miss line is last, so it is the line the store shows.+ uv pip install --quiet --python "$dir/bin/python" "$@" \+ || { echo "miss could not install $* into $dir"; return 1; }+}++harness_micromamba() {+ local dir asset sum+ dir="$HARNESS_RUNTIME/micromamba-$HARNESS_MICROMAMBA_VERSION"+ if [ ! -x "$dir/micromamba" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=micromamba-osx-arm64 sum=ec2a072f028e1a7cf20f3e2e74d5a8127cf5a5f27636375b5359811565f4e5be ;;+ darwin-x64) asset=micromamba-osx-64 sum=1e71054bb3ac9a076e21f7ec48acfef536f9b3f1408f371a942784bf5ef83d8a ;;+ linux-x64) asset=micromamba-linux-64 sum=366cd9cd8be14df1ab8ed50352a82111082a36686b2d389fdb79a92c3fafb3e3 ;;+ linux-arm64) asset=micromamba-linux-aarch64 sum=9f93b974adcb4d166996af969b6cd371287d1a3e52733704727884d9b74cb7a7 ;;+ *) echo "miss micromamba — there is no release for $(uname -s) $(uname -m)"; return 1 ;;+ esac+ echo " fetching micromamba $HARNESS_MICROMAMBA_VERSION into $HARNESS_RUNTIME (native libraries PyPI has no wheel for)"+ mkdir -p "$dir" || { echo "miss cannot write $dir"; return 1; }+ _harness_fetch "https://github.com/mamba-org/micromamba-releases/releases/download/$HARNESS_MICROMAMBA_VERSION/$asset" "$dir/micromamba.$$" "$sum" || return 1+ chmod +x "$dir/micromamba.$$" && mv -f "$dir/micromamba.$$" "$dir/micromamba" \+ || { rm -f "$dir/micromamba.$$"; echo "miss micromamba would not install into $dir"; return 1; }+ fi+ HARNESS_MICROMAMBA="$dir/micromamba"+ export HARNESS_MICROMAMBA+}++# harness_conda_env DIR SPEC… — conda-forge only, packages cached under ~/.harness/runtime/mamba.+harness_conda_env() {+ local dir="${1:?harness_conda_env needs a directory}"+ shift+ # micromamba takes a relative --prefix as a name under its root prefix and "succeeds" there.+ case "$dir" in /*) ;; *) dir="$PWD/$dir" ;; esac+ harness_micromamba || return 1+ MAMBA_ROOT_PREFIX="$HARNESS_RUNTIME/mamba" "$HARNESS_MICROMAMBA" create --yes --quiet \+ --prefix "$dir" --override-channels --channel conda-forge "$@" >/dev/null \+ && [ -d "$dir/conda-meta" ] \+ || { echo "miss could not make the conda-forge environment in $dir ($*)"; return 1; }+}diff --git a/store/agents/juce-agent-toolkit/toolchain/setup.sh b/store/agents/juce-agent-toolkit/toolchain/setup.shnew file mode 100755index 000000000..efbece7e2--- /dev/null+++ b/store/agents/juce-agent-toolkit/toolchain/setup.sh@@ -0,0 +1,9 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+harness_venv .venv 3.11 3.11 3.12+.venv/bin/python toolchain/studio_fetch.py+if [ -s requirements.lock ]; then harness_pip .venv --require-hashes -r requirements.lock; fi+exec toolchain/doctor.shdiff --git a/store/agents/juce-agent-toolkit/toolchain/studio_fetch.py b/store/agents/juce-agent-toolkit/toolchain/studio_fetch.pynew file mode 100644index 000000000..88a670b25--- /dev/null+++ b/store/agents/juce-agent-toolkit/toolchain/studio_fetch.py@@ -0,0 +1,34 @@+"""Fetch reviewed source pins without installing a service or changing user configuration."""+import json+import os+from pathlib import Path+import subprocess++root = Path(__file__).resolve().parent.parent+sources = json.loads((root / "upstream.lock.json").read_text())+for source in sources:+ target = root / source["directory"]+ def git(*args):+ return subprocess.check_output(["git", "-C", str(target), *args], text=True,+ env={**os.environ, "GIT_LFS_SKIP_SMUDGE": "1"}).strip()+ if not (target / ".git").exists():+ target.mkdir(parents=True, exist_ok=True)+ git("init", "-q")+ git("remote", "add", "origin", source["url"])+ if source.get("sparse"):+ git("sparse-checkout", "init", "--cone")+ git("sparse-checkout", "set", *source["sparse"])+ if git("remote", "get-url", "origin") != source["url"]:+ raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])+ try:+ current = git("rev-parse", "HEAD")+ except subprocess.CalledProcessError:+ current = ""+ if current != source["commit"]:+ if current and git("status", "--porcelain"):+ raise SystemExit(f"Save your edits in {target} before changing its source pin")+ git("fetch", "--depth", "1", "--filter=blob:none", "origin", source["commit"])+ git("checkout", "--detach", source["commit"])+ print(f'ok {source["name"]} at {source["commit"][:12]}', flush=True)diff --git a/store/agents/juce-agent-toolkit/toolchain/studio_runtime.py b/store/agents/juce-agent-toolkit/toolchain/studio_runtime.pynew file mode 100644index 000000000..8b8ea016c--- /dev/null+++ b/store/agents/juce-agent-toolkit/toolchain/studio_runtime.py@@ -0,0 +1,132 @@+"""Portable runner copied into each independently installable studio package."""+import json+import math+import os+from pathlib import Path+import subprocess+import sys+import tempfile+import time+import uuid+++def workspace():+ return Path(os.environ.get("HARNESS_WORKSPACE", os.getcwd())).resolve()+++def package():+ return Path(__file__).resolve().parent.parent+++def contained(path):+ target = Path(path).resolve()+ target.relative_to(workspace())+ return target+++def atomic_json(path, data):+ path = contained(path)+ path.parent.mkdir(parents=True, exist_ok=True)+ with tempfile.NamedTemporaryFile(mode="w", dir=path.parent, prefix=".studio-", delete=False) as f:+ json.dump(data, f, indent=2, allow_nan=False)+ f.write("\n")+ temp = f.name+ os.replace(temp, path)+++def command(argv, cwd=None, timeout=120, env=None):+ """No shell interpolation; keep complete logs as output, bound execution time."""+ result = subprocess.run([str(x) for x in argv], cwd=cwd, timeout=timeout,+ env=env, text=True, capture_output=True)+ if result.returncode:+ raise RuntimeError((result.stderr or result.stdout)[-1600:] or f"{argv[0]} exited {result.returncode}")+ return result.stdout+++def parameters(config, values):+ if not isinstance(values, dict) or set(values) - {c["id"] for c in config["controls"]}:+ raise ValueError("Invalid studio controls")+ result = {}+ for c in config["controls"]:+ value = values.get(c["id"], c["value"])+ if c["type"] == "number":+ if type(value) not in (int, float) or not math.isfinite(value) or not c["min"] <= value <= c["max"]:+ raise ValueError(f'{c["label"]} is outside its range')+ if c.get("integer") and value != int(value):+ raise ValueError(f'{c["label"]} must be a whole number')+ elif c["type"] == "select":+ if value not in [o["value"] for o in c["options"]]:+ raise ValueError(f'Unknown {c["label"]}')+ elif not isinstance(value, str) or len(value) > c.get("maxLength", 500):+ raise ValueError(f'Invalid {c["label"]}')+ result[c["id"]] = value+ return result+++def metric(label, value, unit=""):+ return {"label": label, "value": value, "unit": unit}+++def previous_runs():+ base = contained(workspace() / "out/runs")+ rows = []+ for p in sorted(base.glob("*/result.json"))[-100:]:+ try:+ rows.append(json.loads(contained(p).read_text()))+ except (ValueError, OSError):+ continue+ return rows+++def execute(actions):+ root = workspace()+ config = json.loads((package() / "studio.config.json").read_text())+ action = sys.argv[1] if len(sys.argv) > 1 else config["actions"][0]["id"]+ started = time.monotonic()+ verdict_path = root / ".harness/verdict.json"+ verdict = {"spec": 1, "ready": False, "summary": "Preparing the studio run", "findings": [],+ "phases": [{"id": "run", "name": "Make", "state": "active"},+ {"id": "inspect", "name": "Inspect", "state": "pending"}]}+ try:+ if action not in actions:+ raise ValueError(f"Unknown action: {action}")+ source = contained(root / "studio.json")+ if source.stat().st_size > 16384:+ raise ValueError("studio.json is too large")+ project = json.loads(source.read_text())+ p = parameters(config, project["parameters"])+ atomic_json(verdict_path, verdict)+ run_id = time.strftime("%Y%m%dT%H%M%S", time.gmtime()) + "-" + uuid.uuid4().hex[:8]+ output = contained(root / "out/runs" / run_id)+ output.mkdir(parents=True)+ print(f'{config["title"]}: {action}', flush=True)+ result = actions[action](p, output)+ artifacts = []+ for artifact in result.pop("files", []):+ file = contained(output / artifact["name"])+ file.relative_to(output)+ if not file.is_file() or not file.stat().st_size:+ raise ValueError(f'Missing output: {artifact["name"]}')+ artifacts.append({"label": artifact["label"], "path": str(file.relative_to(root))})+ result.update({"spec": 1, "id": run_id, "action": action, "parameters": p,+ "createdAt": time.strftime("%Y-%m-%dT%H:%M:%SZ", time.gmtime()),+ "durationSeconds": round(time.monotonic() - started, 3), "artifacts": artifacts,+ "upstream": json.loads((package() / "upstream.lock.json").read_text())})+ atomic_json(output / "result.json", result)+ atomic_json(root / "out/latest.json", result)+ verdict.update({"ready": True, "summary": f'{result["title"]} · {result["engine"]}',+ "artifact": str((output / "result.json").relative_to(root)),+ "phases": [{"id": "run", "name": "Make", "state": "done"},+ {"id": "inspect", "name": "Inspect", "state": "done"}],+ "updatedAt": result["createdAt"]})+ atomic_json(verdict_path, verdict)+ print(f'Ready: {result["title"]}', flush=True)+ except Exception as exc:+ verdict.update({"summary": str(exc)[:500], "findings": [{"severity": "error", "kind": "run-failed", "message": str(exc)[:1000]}],+ "phases": [{"id": "run", "name": "Make", "state": "failed"}]})+ try:+ atomic_json(verdict_path, verdict)+ except (ValueError, OSError):+ pass+ print(str(exc), file=sys.stderr)+ raise SystemExit(1) from excdiff --git a/store/agents/juce-agent-toolkit/toolchain/workflow.py b/store/agents/juce-agent-toolkit/toolchain/workflow.pynew file mode 100644index 000000000..14ad76592--- /dev/null+++ b/store/agents/juce-agent-toolkit/toolchain/workflow.py@@ -0,0 +1,78 @@+import array+import math+import platform+import os+from pathlib import Path+import wave+from studio_runtime import execute, metric, command, package, workspace, contained+++def summarize(p, out, engine):+ with wave.open(str(out / "phrase.wav"), "rb") as f:+ if f.getsampwidth() != 2 or f.getnchannels() != 1:+ raise ValueError("Expected a 16-bit mono recording")+ samples = array.array("h", f.readframes(f.getnframes()))+ rate = f.getframerate()+ peak = max(abs(x) for x in samples) / 32768+ if peak >= .999 or not samples:+ raise ValueError("The recording clipped or was empty")+ rms = math.sqrt(sum((x / 32768) ** 2 for x in samples) / len(samples))+ return {"title": f'{p["wave"].capitalize()} · {p["frequency"]} Hz',+ "description": "A four-note phrase rendered locally. Play it, inspect the waveform, or download the WAV.",+ "engine": engine, "metrics": [metric("Peak level", round(20 * math.log10(max(peak, 1e-8)), 1), "dBFS"),+ metric("RMS level", round(20 * math.log10(max(rms, 1e-8)), 1), "dBFS"),+ metric("Recording", round(len(samples) / rate, 2), "s")],+ "data": {"waveform": [round(x / 32768, 4) for x in samples[::max(1, len(samples) // 600)]], "sampleRate": rate},+ "files": [{"label": "WAV recording", "name": "phrase.wav"}]}+++def render(p, out):+ rate = 44100+ samples = array.array("h")+ count = int(p["duration"] * rate)+ filtered = 0.+ alpha = 1 - math.exp(-2 * math.pi * (250 + 5000 * p["brightness"]) / rate)+ for i in range(count):+ t = i / rate+ segment = min(3, int(4 * t / p["duration"]))+ local = t - segment * p["duration"] / 4+ frequency = p["frequency"] * 2 ** ([0, 7, 12, 3][segment] / 12)+ phase = (t * frequency) % 1+ value = math.sin(phase * 2 * math.pi)+ if p["wave"] == "triangle":+ value = 1 - 4 * abs(phase - .5)+ elif p["wave"] == "saw":+ # Finite harmonics avoid the unbounded discontinuity of a naive saw.+ value = sum(math.sin(2 * math.pi * phase * n) / n for n in range(1, min(24, int(rate / (2 * frequency))))) * .5+ envelope = min(1, local / p["attack"], max(0, (p["duration"] / 4 - local) / .08))+ filtered += alpha * (value - filtered)+ samples.append(round(filtered * envelope * .3 * 32767))+ with wave.open(str(out / "phrase.wav"), "wb") as f:+ f.setnchannels(1); f.setsampwidth(2); f.setframerate(rate); f.writeframes(samples.tobytes())+ return summarize(p, out, "Local DSP · Python renderer")+++def juce(p, out):+ source = contained(workspace() / "CMakeLists.txt")+ if not source.exists():+ raise RuntimeError("The workspace needs its CMakeLists.txt and Source/main.cpp starter.")+ build = contained(workspace() / ".harness/juce-build")+ cmake = package() / ".venv/bin/cmake"+ print("Compiling the native JUCE instrument…", flush=True)+ flags=[];env=dict(os.environ)+ if platform.system()=='Darwin':+ sdk=command(['xcrun','--show-sdk-path']).strip();flags.append('-DCMAKE_OSX_SYSROOT='+sdk)+ env['SDKROOT']=sdk+ # Recent Apple SDKs carry libc++ headers inside the SDK, including for juceaide's nested build.+ headers=Path(sdk)/'usr/include/c++/v1'+ if headers.is_dir():env['CPLUS_INCLUDE_PATH']=str(headers)+(os.pathsep+env['CPLUS_INCLUDE_PATH'] if env.get('CPLUS_INCLUDE_PATH') else '')+ command([cmake, "-S", workspace(), "-B", build, f'-DJUCE_ROOT={package() / "juce"}', "-DCMAKE_BUILD_TYPE=Release",*flags], timeout=600,env=env)+ command([cmake, "--build", build, "--target", "HarnessTone", "-j", "2"], timeout=600,env=env)+ binary = build / "HarnessTone_artefacts/Release/HarnessTone"+ command([binary, out / "phrase.wav", p["wave"], str(p["frequency"]), str(p["attack"]), str(p["brightness"]), str(p["duration"])])+ result = summarize(p, out, "Native JUCE · offline instrument")+ return result+++if __name__ == "__main__":+ execute({"render": render, "juce": juce})diff --git a/store/agents/juce-agent-toolkit/upstream.lock.json b/store/agents/juce-agent-toolkit/upstream.lock.jsonnew file mode 100644index 000000000..4bd406747--- /dev/null+++ b/store/agents/juce-agent-toolkit/upstream.lock.json@@ -0,0 +1,23 @@+[+ {+ "name": "JUCE Agent Toolkit",+ "url": "https://github.com/danielraffel/juce-agent-toolkit.git",+ "commit": "9089b719f7378eba28dd078cdfb8b6e1c062bf13",+ "directory": "upstream",+ "sparse": [+ "skills",+ "shared"+ ]+ },+ {+ "name": "JUCE",+ "url": "https://github.com/juce-framework/JUCE.git",+ "commit": "72782788ce18c2d4d760b28e0921d6ffc6431102",+ "directory": "juce",+ "sparse": [+ "modules",+ "extras/Build",+ "examples/CMake"+ ]+ }+]diff --git a/store/agents/juce-agent-toolkit/view.mjs b/store/agents/juce-agent-toolkit/view.mjsnew file mode 100644index 000000000..f7689a21f--- /dev/null+++ b/store/agents/juce-agent-toolkit/view.mjs@@ -0,0 +1,21 @@+import {canvas,grid,line,words,circle,toolbar,badge,label,el,tone} from '/graphics.mjs';+export function mount(stage,api){+ let p=api.getParameters(),result,playing=false,recording=new Audio(),keyIndex=-1;+ label(stage,'A small instrument, waiting for your hands.');const tag=badge(stage,'LIVE AUDITION');+ const screen=canvas(stage,(ctx,w,h,t)=>{+ grid(ctx,w,h,36);const center=h*.33,amplitude=h*.15;+ const points=[];for(let x=20;x<w-20;x+=2){const a=x/w*7*Math.PI*2-t*2;let v=Math.sin(a);if(p.wave==='triangle')v=Math.asin(Math.sin(a))*2/Math.PI;if(p.wave==='saw')v=2*((a/(2*Math.PI))%1)-1;points.push([x,center+v*amplitude*p.brightness]);}+ ctx.shadowBlur=20;ctx.shadowColor='#e6ac7550';line(ctx,points,'#f2bc88',2);ctx.shadowBlur=0;+ line(ctx,[[20,center],[w-20,center]],'#ffffff0a',1);words(ctx,`${p.frequency} Hz`,25,center+amplitude+24,'#ac998c',10);+ if(keyIndex>=0)circle(ctx,w-35,center+amplitude+20,4,'#f2bc88');+ if(result?.data?.waveform){const wave=result.data.waveform;line(ctx,wave.map((v,i)=>[24+i/(wave.length-1)*(w-48),h-20-v*12]),'#bf9875',1);}+ },api.signal);screen.element.setAttribute('aria-label','Oscillator waveform preview');+ const keyboard=el('div','','keyboard'),keys=['C','D','E','F','G','A','B','C'],offset=[0,2,4,5,7,9,11,12];+ async function play(i){keyIndex=i;try{await tone(p.frequency*2**(offset[i]/12),.45,p.wave==='saw'?'sawtooth':p.wave,.12);api.announce(`Playing ${keys[i]}`);}catch{api.announce('Audio is unavailable in this browser. Download the recording to listen.');}setTimeout(()=>{keyIndex=-1;},450);}+ keys.forEach((name,i)=>{const b=el('button',`${name} · ${'ASDFGHJK'[i]}`,'key');b.type='button';b.setAttribute('aria-label',`Play ${name}${i===7?' high':''}`);b.addEventListener('click',()=>play(i));keyboard.append(b);});stage.append(keyboard);+ window.addEventListener('keydown',e=>{if(e.repeat||/INPUT|TEXTAREA|SELECT/.test(e.target.tagName))return;const i='asdfghjk'.indexOf(e.key.toLowerCase());if(i>=0&&e.key.length===1){e.preventDefault();play(i);}},{signal:api.signal});+ const bar=toolbar(stage,[['Play recording',async b=>{const artifact=result?.artifacts?.find(a=>a.path.endsWith('.wav'));if(!artifact){api.announce('Record a phrase first.');return;}if(playing){recording.pause();recording.currentTime=0;playing=false;b.textContent='Play recording';}else{recording.src=api.artifactURL(artifact.path);try{await recording.play();playing=true;b.textContent='Stop recording';}catch{api.announce('Audio could not play. Download the WAV to listen.');}}}],['Surprise me',()=>{api.setParameter('frequency',[165,220,277,330,440][Math.floor(Math.random()*5)]);api.setParameter('wave',['sine','triangle','saw'][Math.floor(Math.random()*3)]);}]]);+ recording.addEventListener('ended',()=>{playing=false;bar.firstChild.textContent='Play recording';});+ api.signal.addEventListener('abort',()=>recording.pause());+ return {update(params,r,motion){p=params;result=r;screen.motion(motion);tag.textContent=r?.engine?.startsWith('Native')?'JUCE RECORDING':'LIVE AUDITION';}};+}diff --git a/store/agents/simskill/.gitignore b/store/agents/simskill/.gitignorenew file mode 100644index 000000000..877cbe18a--- /dev/null+++ b/store/agents/simskill/.gitignore@@ -0,0 +1,9 @@+upstream/+juce/+.venv/+.build/+.sumo/+__pycache__/+*.pyc+coverage/+sumo-src/diff --git a/store/agents/simskill/AGENTS.md b/store/agents/simskill/AGENTS.mdnew file mode 100644index 000000000..a56051430--- /dev/null+++ b/store/agents/simskill/AGENTS.md@@ -0,0 +1,18 @@+# SimSkill workspace++This harness turns a request into a real, inspectable simulation artifact. Start with+the `simskill` skill. The editable project is `studio.json` plus files in this workspace.+The viewer follows `out/latest.json` and the run history; save small useful changes as you work.++Run `"$STUDIO_TOOLCHAIN/run.sh" simulate` after a change. The runner validates controls,+records provenance, writes artifacts, and updates `.harness/verdict.json`. Do not hand-edit the+verdict to claim a run succeeded. Inspect the produced artifact before describing the result.++The local workflow generates an original four-way intersection with SUMO netconvert and simulates actual traffic with SUMO. Playback uses its floating-car output. A comparison is a simulation experiment, not a calibrated forecast for a real city. Intel Macs build pinned SUMO 1.27.1 headlessly with package-local Xerces.++The installed sources are at `$STUDIO_UPSTREAM`. Preserve upstream credit and use the pinned+instructions when extending the domain workflow. Local simulations are the default. Ask before+using a paid generation service or operating physical hardware unless the user already authorized it.++When developing this package itself, keep it independently installable from its folder; shared+runtime copies are synchronized by `store/tools/sync-studios.mjs` and `sync-runtimes.mjs`.diff --git a/store/agents/simskill/INTEGRATION.md b/store/agents/simskill/INTEGRATION.mdnew file mode 100644index 000000000..f44c4fcf7--- /dev/null+++ b/store/agents/simskill/INTEGRATION.md@@ -0,0 +1,12 @@+# Actual headless Eclipse SUMO traffic simulation++`simulate` builds an original intersection with `netconvert`, identifies the east/west phase from generated connection link indices, runs `sumo`, and parses floating-car and trip records. Delay statistics identify their completed-trip denominator and report unfinished trips. Intel macOS compiles pinned SUMO 1.27.1 with GUI and optional geo libraries disabled, using package-local Xerces 3.3.0. Other supported platforms use the pinned SUMO wheel.++## Verification scope++All animation positions come from SUMO vehicle traces. The local experiment is not a calibrated real-city forecast. The package includes the relevant upstream SimSkill procedures for building intersections and analyzing outputs.++The browser acceptance suite lives in `store/viewers/studio-viewer/test/studios.e2e.mjs`.+`TESTING.md` beside that viewer records commands, outcomes, screenshots and coverage.+Upstream source revisions are in `upstream.lock.json`; install-time Python dependencies are+hash-locked in `requirements.lock`. No user application configuration is written by setup.diff --git a/store/agents/simskill/LICENSE b/store/agents/simskill/LICENSEnew file mode 100644index 000000000..a499cd17e--- /dev/null+++ b/store/agents/simskill/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Autonomous, Inc.++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/store/agents/simskill/LICENSE-upstream b/store/agents/simskill/LICENSE-upstreamnew file mode 100644index 000000000..261eeb9e9--- /dev/null+++ b/store/agents/simskill/LICENSE-upstream@@ -0,0 +1,201 @@+ Apache License+ Version 2.0, January 2004+ http://www.apache.org/licenses/++ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION++ 1. Definitions.++ "License" shall mean the terms and conditions for use, reproduction,+ and distribution as defined by Sections 1 through 9 of this document.++ "Licensor" shall mean the copyright owner or entity authorized by+ the copyright owner that is granting the License.++ "Legal Entity" shall mean the union of the acting entity and all+ other entities that control, are controlled by, or are under common+ control with that entity. For the purposes of this definition,+ "control" means (i) the power, direct or indirect, to cause the+ direction or management of such entity, whether by contract or+ otherwise, or (ii) ownership of fifty percent (50%) or more of the+ outstanding shares, or (iii) beneficial ownership of such entity.++ "You" (or "Your") shall mean an individual or Legal Entity+ exercising permissions granted by this License.++ "Source" form shall mean the preferred form for making modifications,+ including but not limited to software source code, documentation+ source, and configuration files.++ "Object" form shall mean any form resulting from mechanical+ transformation or translation of a Source form, including but+ not limited to compiled object code, generated documentation,+ and conversions to other media types.++ "Work" shall mean the work of authorship, whether in Source or+ Object form, made available under the License, as indicated by a+ copyright notice that is included in or attached to the work+ (an example is provided in the Appendix below).++ "Derivative Works" shall mean any work, whether in Source or Object+ form, that is based on (or derived from) the Work and for which the+ editorial revisions, annotations, elaborations, or other modifications+ represent, as a whole, an original work of authorship. For the purposes+ of this License, Derivative Works shall not include works that remain+ separable from, or merely link (or bind by name) to the interfaces of,+ the Work and Derivative Works thereof.++ "Contribution" shall mean any work of authorship, including+ the original version of the Work and any modifications or additions+ to that Work or Derivative Works thereof, that is intentionally+ submitted to Licensor for inclusion in the Work by the copyright owner+ or by an individual or Legal Entity authorized to submit on behalf of+ the copyright owner. For the purposes of this definition, "submitted"+ means any form of electronic, verbal, or written communication sent+ to the Licensor or its representatives, including but not limited to+ communication on electronic mailing lists, source code control systems,+ and issue tracking systems that are managed by, or on behalf of, the+ Licensor for the purpose of discussing and improving the Work, but+ excluding communication that is conspicuously marked or otherwise+ designated in writing by the copyright owner as "Not a Contribution."++ "Contributor" shall mean Licensor and any individual or Legal Entity+ on behalf of whom a Contribution has been received by Licensor and+ subsequently incorporated within the Work.++ 2. Grant of Copyright License. Subject to the terms and conditions of+ this License, each Contributor hereby grants to You a perpetual,+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable+ copyright license to reproduce, prepare Derivative Works of,+ publicly display, publicly perform, sublicense, and distribute the+ Work and such Derivative Works in Source or Object form.++ 3. Grant of Patent License. Subject to the terms and conditions of+ this License, each Contributor hereby grants to You a perpetual,+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable+ (except as stated in this section) patent license to make, have made,+ use, offer to sell, sell, import, and otherwise transfer the Work,+ where such license applies only to those patent claims licensable+ by such Contributor that are necessarily infringed by their+ Contribution(s) alone or by combination of their Contribution(s)+ with the Work to which such Contribution(s) was submitted. If You+ institute patent litigation against any entity (including a+ cross-claim or counterclaim in a lawsuit) alleging that the Work+ or a Contribution incorporated within the Work constitutes direct+ or contributory patent infringement, then any patent licenses+ granted to You under this License for that Work shall terminate+ as of the date such litigation is filed.++ 4. Redistribution. You may reproduce and distribute copies of the+ Work or Derivative Works thereof in any medium, with or without+ modifications, and in Source or Object form, provided that You+ meet the following conditions:++ (a) You must give any other recipients of the Work or+ Derivative Works a copy of this License; and++ (b) You must cause any modified files to carry prominent notices+ stating that You changed the files; and++ (c) You must retain, in the Source form of any Derivative Works+ that You distribute, all copyright, patent, trademark, and+ attribution notices from the Source form of the Work,+ excluding those notices that do not pertain to any part of+ the Derivative Works; and++ (d) If the Work includes a "NOTICE" text file as part of its+ distribution, then any Derivative Works that You distribute must+ include a readable copy of the attribution notices contained+ within such NOTICE file, excluding those notices that do not+ pertain to any part of the Derivative Works, in at least one+ of the following places: within a NOTICE text file distributed+ as part of the Derivative Works; within the Source form or+ documentation, if provided along with the Derivative Works; or,+ within a display generated by the Derivative Works, if and+ wherever such third-party notices normally appear. The contents+ of the NOTICE file are for informational purposes only and+ do not modify the License. You may add Your own attribution+ notices within Derivative Works that You distribute, alongside+ or as an addendum to the NOTICE text from the Work, provided+ that such additional attribution notices cannot be construed+ as modifying the License.++ You may add Your own copyright statement to Your modifications and+ may provide additional or different license terms and conditions+ for use, reproduction, or distribution of Your modifications, or+ for any such Derivative Works as a whole, provided Your use,+ reproduction, and distribution of the Work otherwise complies with+ the conditions stated in this License.++ 5. Submission of Contributions. Unless You explicitly state otherwise,+ any Contribution intentionally submitted for inclusion in the Work+ by You to the Licensor shall be under the terms and conditions of+ this License, without any additional terms or conditions.+ Notwithstanding the above, nothing herein shall supersede or modify+ the terms of any separate license agreement you may have executed+ with Licensor regarding such Contributions.++ 6. Trademarks. This License does not grant permission to use the trade+ names, trademarks, service marks, or product names of the Licensor,+ except as required for reasonable and customary use in describing the+ origin of the Work and reproducing the content of the NOTICE file.++ 7. Disclaimer of Warranty. Unless required by applicable law or+ agreed to in writing, Licensor provides the Work (and each+ Contributor provides its Contributions) on an "AS IS" BASIS,+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or+ implied, including, without limitation, any warranties or conditions+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A+ PARTICULAR PURPOSE. You are solely responsible for determining the+ appropriateness of using or redistributing the Work and assume any+ risks associated with Your exercise of permissions under this License.++ 8. Limitation of Liability. In no event and under no legal theory,+ whether in tort (including negligence), contract, or otherwise,+ unless required by applicable law (such as deliberate and grossly+ negligent acts) or agreed to in writing, shall any Contributor be+ liable to You for damages, including any direct, indirect, special,+ incidental, or consequential damages of any character arising as a+ result of this License or out of the use or inability to use the+ Work (including but not limited to damages for loss of goodwill,+ work stoppage, computer failure or malfunction, or any and all+ other commercial damages or losses), even if such Contributor+ has been advised of the possibility of such damages.++ 9. Accepting Warranty or Additional Liability. While redistributing+ the Work or Derivative Works thereof, You may choose to offer,+ and charge a fee for, acceptance of support, warranty, indemnity,+ or other liability obligations and/or rights consistent with this+ License. However, in accepting such obligations, You may act only+ on Your own behalf and on Your sole responsibility, not on behalf+ of any other Contributor, and only if You agree to indemnify,+ defend, and hold each Contributor harmless for any liability+ incurred by, or claims asserted against, such Contributor by reason+ of your accepting any such warranty or additional liability.++ END OF TERMS AND CONDITIONS++ APPENDIX: How to apply the Apache License to your work.++ To apply the Apache License to your work, attach the following+ boilerplate notice, with the fields enclosed by brackets "[]"+ replaced with your own identifying information. (Don't include+ the brackets!) The text should be enclosed in the appropriate+ comment syntax for the file format. We also recommend that a+ file or class name and description of purpose be included on the+ same "printed page" as the copyright notice for easier+ identification within third-party archives.++ Copyright [yyyy] [name of copyright owner]++ Licensed under the Apache License, Version 2.0 (the "License");+ you may not use this file except in compliance with the License.+ You may obtain a copy of the License at++ http://www.apache.org/licenses/LICENSE-2.0++ Unless required by applicable law or agreed to in writing, software+ distributed under the License is distributed on an "AS IS" BASIS,+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+ See the License for the specific language governing permissions and+ limitations under the License.diff --git a/store/agents/simskill/README.md b/store/agents/simskill/README.mdnew file mode 100644index 000000000..8a0f704d5--- /dev/null+++ b/store/agents/simskill/README.md@@ -0,0 +1,48 @@+# SimSkill · City lab++Make a little city flow better. Change the lights, watch the streets, and measure what happens.++```sh+harness dsh install autonomous/simskill+```++Open a workspace in Harness. Setup fetches upstream sources at the commit in `upstream.lock.json`,+installs a package-local Python 3.11 environment, and verifies the local tools. The starter runs+without credentials or a cloud account. Studio Viewer provides controls, history, downloads,+live agent updates, and failure recovery. Setup never edits an application's preferences.++## What runs here++The local workflow generates an original four-way intersection with SUMO netconvert and simulates actual traffic with SUMO. Playback uses its floating-car output. A comparison is a simulation experiment, not a calibrated forecast for a real city. Intel Macs build pinned SUMO 1.27.1 headlessly with package-local Xerces; no Homebrew libraries are required.++Edit `studio.json`, then run:++```sh+"$STUDIO_TOOLCHAIN/run.sh" simulate # Wake up the city+```++The native command is optional and fails with a useful message when its external runtime is+unavailable. It never silently substitutes sample output. Use the upstream README in `upstream/`+for full native application setup. See `INTEGRATION.md` for the exact bridge and local test scope.++Every successful run owns a new folder under `out/runs/`, a `result.json` with parameters, engine,+source commit, timestamps, measured values, and downloadable artifacts. `.harness/verdict.json`+means the named artifact was produced, not that an engineering or aesthetic claim was certified.+The starter can be regenerated with no network after install.++## Development and testing++Install the shared viewer and this package with `harness dsh install <path> --link`.+`toolchain/doctor.sh` checks the local runtime. The repository's Studio Viewer browser suite+materializes temporary workspaces and exercises each shipped local workflow. Run it from+`store/viewers/studio-viewer` with `npm run test:browser`; exact results live in its `TESTING.md`.++## Credit and stewardship++[SimSkill](https://github.com/qiliuchn/SimSkill-V1) is maintained by Qiliu Chen and contributors. Its sources are+fetched unchanged at `10113c1e6ba28b57b48a38a7c25ee113b49ab4e6`. Upstream licensing: Apache-2.0; SUMO EPL-2.0 / GPL-2.0.+The original license is preserved in `LICENSE-upstream`; dependency terms still apply.++OpenHarness contributors wrote the MIT wrapper, local starter, and viewer integration. This is+an independent integration, not an upstream endorsement. Upstream bugs belong with the upstream+project; wrapper bugs belong in OpenHarness. Maintainers are welcome to take over this package.diff --git a/store/agents/simskill/THIRD_PARTY_NOTICES.md b/store/agents/simskill/THIRD_PARTY_NOTICES.mdnew file mode 100644index 000000000..d5a9631e5--- /dev/null+++ b/store/agents/simskill/THIRD_PARTY_NOTICES.md@@ -0,0 +1,9 @@+# Third-party notices++SimSkill — Qiliu Chen and contributors. https://github.com/qiliuchn/SimSkill-V1++Pinned source: 10113c1e6ba28b57b48a38a7c25ee113b49ab4e6. Fetched at install into ignored `upstream/`, unmodified.+License: Apache-2.0; SUMO EPL-2.0 / GPL-2.0. See `LICENSE-upstream` and the fetched source tree.++The original local starter and wrapper are MIT licensed. The native runtime and separately+installed applications retain their own licenses. No upstream endorsement is claimed.diff --git a/store/agents/simskill/VERSIONS b/store/agents/simskill/VERSIONSnew file mode 100644index 000000000..bc86afaad--- /dev/null+++ b/store/agents/simskill/VERSIONS@@ -0,0 +1,2 @@+UPSTREAM_COMMIT=10113c1e6ba28b57b48a38a7c25ee113b49ab4e6+PYTHON=3.11diff --git a/store/agents/simskill/harness.json b/store/agents/simskill/harness.jsonnew file mode 100644index 000000000..b00179914--- /dev/null+++ b/store/agents/simskill/harness.json@@ -0,0 +1,33 @@+{+ "spec": 1,+ "id": "autonomous/simskill",+ "name": "SimSkill",+ "category": "Simulation",+ "author": "Qiliu Chen and contributors",+ "description": "Make a little city flow better. Change the lights, watch the streets, and measure what happens.",+ "engine": "codex",+ "workspace": {+ "template": "template",+ "marker": "studio.json",+ "init": "toolchain/init-workspace.sh"+ },+ "agent": {+ "instructions": "AGENTS.md",+ "skills": [+ "skills"+ ],+ "env": {+ "STUDIO_TOOLCHAIN": "${dsh}/toolchain",+ "STUDIO_PYTHON": "${dsh}/.venv/bin/python",+ "STUDIO_UPSTREAM": "${dsh}/upstream"+ }+ },+ "toolchain": {+ "setup": "toolchain/setup.sh",+ "doctor": "toolchain/doctor.sh"+ },+ "viewer": {+ "use": "autonomous/studio-viewer"+ },+ "verdict": ".harness/verdict.json"+}diff --git a/store/agents/simskill/requirements.in b/store/agents/simskill/requirements.innew file mode 100644index 000000000..0f94df551--- /dev/null+++ b/store/agents/simskill/requirements.in@@ -0,0 +1,2 @@+cmake==4.4.3+eclipse-sumo==1.27.1; sys_platform != "darwin" or platform_machine != "x86_64"diff --git a/store/agents/simskill/requirements.lock b/store/agents/simskill/requirements.locknew file mode 100644index 000000000..3f030c5a2--- /dev/null+++ b/store/agents/simskill/requirements.lock@@ -0,0 +1,36 @@+# This file was autogenerated by uv via the following command:+# uv pip compile requirements.in --python-version 3.11 --universal --generate-hashes -o requirements.lock+cmake==4.4.3 \+ --hash=sha256:09edc3fe8cee225bb2e7f3386199be7832cf5b65ef454827e001c02ec928298e \+ --hash=sha256:25a61850847c46e3268bb54058daa8a9043c91167909203ed19f8fa28223cc31 \+ --hash=sha256:3c2a6c250c411c0529c997de5d3ce18c3d98635cc0725efafb083dc475f3572b \+ --hash=sha256:520ff2ba3afb7a1e34a0ab222c0f4e89ad334dc7462814886e099bdf6ba8cbb3 \+ --hash=sha256:6558aa24eadc83315b0a66ae7570cb24a95147f35a3fff19771e574cecbfe23c \+ --hash=sha256:6bff4e826b3a0e153cfbf53d496f457b9b7d2ad3f16b327686b752609f2a562f \+ --hash=sha256:6c95b37116bb5c714656e4f76931ebdcb739209a1aee91cf51408ccfe137694e \+ --hash=sha256:708ad6b662ee89d3eb2eac02a1afba20ca653139cbe769fed046124d0c6bc050 \+ --hash=sha256:7f1916f8064c9593abf7fd9de6a7be22d826dbef17925e50a161df5196aabd88 \+ --hash=sha256:92a93bc9941cd5f5c8cc9a7da5c40a53f7643fcd2ac75d6c850510cb44945271 \+ --hash=sha256:a21c9f60d530d678659f100445b9c0828467a67d4bb5e8eb76343aca91e80e90 \+ --hash=sha256:a4e0a067f12a8b7869daf7090086029356fc641a0702eddc185cd4477583730a \+ --hash=sha256:ad3b88073f215841ef3eb45e7c7bab4ee3e7f33b7001e1d1b5454ed3f4eb9c9c \+ --hash=sha256:b0c2703ec0a624649dd184c0ac5ee4c7f5fe5ef35eb82f9da44f5a0903adb2b6 \+ --hash=sha256:bae3c4954623ec4d62e62c70443f0da7988b733111c2871fcc6a31ead5137e20 \+ --hash=sha256:c0d2ccd8f83605fedfd688bb37b4cb4008a7ddf6c32321b9c804168031a3cc74 \+ --hash=sha256:cd58e9d3d6b4372d2456da43f2eb74e4ff5fe7d700bbcaede290a09db3790b1e \+ --hash=sha256:d36c9bb471a67970b031d45b29c3b852f14bc8b64ac46b39ccc046fdf652f36d \+ --hash=sha256:f5aead3c09bfa662da5d1d65f6c526a449966314913039ce6de3c0ff82ea9266+ # via -r requirements.in+eclipse-sumo==1.27.1 ; platform_machine != 'x86_64' or sys_platform != 'darwin' \+ --hash=sha256:2255536237d81383efe5e53862b030e2dee6e18025210ff6ba4819f11edbb0d4 \+ --hash=sha256:4b56e8bb331bee39d5a102feda7b3441fdfca4704a9ba4f7ed2cdf99ac19d915 \+ --hash=sha256:80f68e916d10696a677a60db81f13d5340efae9451eaa8f3088e67e89870d6aa \+ --hash=sha256:97abddcb7395c25538f22a272ef67ca77c8a625d3eec6010eed5b62dfac011f3 \+ --hash=sha256:e557879511b66511943f0fa1b0f95d2c135d26e2b681665546deb8001133edd5 \+ --hash=sha256:fd96ace26bccb78312c8c04464c0894a5432db8e2c072388b73e8ae3a6a43586+ # via -r requirements.in+sumo-data==1.27.1 ; platform_machine != 'x86_64' or sys_platform != 'darwin' \+ --hash=sha256:2e547fd20558e07d6004d576eeaf85f4aa061efb4a9bab7675233726364fba61 \+ --hash=sha256:cc3f71bbeac8dc45a67ef90b023fa8d7ee4bd25c7f62f8006c5c036d545a9527 \+ --hash=sha256:fa53a3cd34c2f9fd7137d055451b19c44b8972b65dcc15328d2f469647d6d38d+ # via eclipse-sumodiff --git a/store/agents/simskill/skills/simskill/SKILL.md b/store/agents/simskill/skills/simskill/SKILL.mdnew file mode 100644index 000000000..dc1e817c7--- /dev/null+++ b/store/agents/simskill/skills/simskill/SKILL.md@@ -0,0 +1,19 @@+---+name: simskill+description: Create and inspect simulation projects in the SimSkill Harness workspace, including its local starter and optional upstream integration.+---++# City lab++Read `studio.json` to understand the current controls; `"$STUDIO_TOOLCHAIN/../studio.config.json"`+describes their ranges. Run `"$STUDIO_TOOLCHAIN/run.sh" simulate` to make a new result.+Successful artifacts and their measurements are in `out/runs/<id>/`; `out/latest.json` names the+current result. A failed run preserves the last success and records the error in the verdict.++The local workflow generates an original four-way intersection with SUMO netconvert and simulates actual traffic with SUMO. Playback uses its floating-car output. A comparison is a simulation experiment, not a calibrated forecast for a real city. Intel Macs build pinned SUMO 1.27.1 headlessly with package-local Xerces.++Use `"$STUDIO_TOOLCHAIN/../README.md"` for the integration contract and commands. Read the relevant+files under `$STUDIO_UPSTREAM` before using an upstream API. Keep controls within their documented+ranges, preserve the data needed to reproduce a comparison, and distinguish preview results from+native service or hardware output. The viewer supports history and artifact downloads; tell the+user which run contains the result, and what was actually measured.diff --git a/store/agents/simskill/store.json b/store/agents/simskill/store.jsonnew file mode 100644index 000000000..499c63440--- /dev/null+++ b/store/agents/simskill/store.json@@ -0,0 +1,6 @@+{+ "homepage": "https://github.com/qiliuchn/SimSkill-V1",+ "upstream": "https://github.com/qiliuchn/SimSkill-V1",+ "license": "Apache-2.0; SUMO EPL-2.0 / GPL-2.0",+ "screenshots": []+}diff --git a/store/agents/simskill/studio.config.json b/store/agents/simskill/studio.config.jsonnew file mode 100644index 000000000..2a0596054--- /dev/null+++ b/store/agents/simskill/studio.config.json@@ -0,0 +1,68 @@+{+ "title": "City lab",+ "description": "Make a little city flow better. Change the lights, watch the streets, and measure what happens.",+ "category": "Simulation",+ "scene": "THE NEIGHBOURHOOD EXPERIMENT",+ "hint": "Follow a car \u00b7 switch the signal plan \u00b7 replay the rush",+ "tip": "Compare two light timings with the same demand and seed. A quieter animation is not proof of a faster trip.",+ "previewLabel": "Street illustration \u00b7 run SUMO to measure",+ "controls": [+ {+ "id": "demand",+ "label": "Traffic demand",+ "type": "number",+ "value": 360,+ "min": 120,+ "max": 900,+ "step": 60,+ "integer": false,+ "unit": "vehicles/hour/approach",+ "hint": ""+ },+ {+ "id": "green",+ "label": "East\u2013west green",+ "type": "number",+ "value": 30,+ "min": 10,+ "max": 70,+ "step": 5,+ "integer": false,+ "unit": "s",+ "hint": ""+ },+ {+ "id": "duration",+ "label": "Rush-hour sample",+ "type": "number",+ "value": 240,+ "min": 120,+ "max": 480,+ "step": 60,+ "integer": false,+ "unit": "s",+ "hint": ""+ },+ {+ "id": "seed",+ "label": "Traffic seed",+ "type": "number",+ "value": 11,+ "min": 1,+ "max": 99,+ "step": 1,+ "integer": true,+ "unit": "",+ "hint": ""+ }+ ],+ "actions": [+ {+ "id": "simulate",+ "label": "Wake up the city",+ "description": ""+ }+ ],+ "credit": "SimSkill \u00b7 Qiliu Chen and contributors",+ "empty": "Adjust the controls, then make your first exploration. Every successful run stays in the history."+}diff --git a/store/agents/simskill/template/studio.json b/store/agents/simskill/template/studio.jsonnew file mode 100644index 000000000..03448414b--- /dev/null+++ b/store/agents/simskill/template/studio.json@@ -0,0 +1,10 @@+{+ "spec": 1,+ "title": "City lab",+ "parameters": {+ "demand": 360,+ "green": 30,+ "duration": 240,+ "seed": 11+ }+}diff --git a/store/agents/simskill/toolchain/build-sumo.sh b/store/agents/simskill/toolchain/build-sumo.shnew file mode 100755index 000000000..5b6ce2858--- /dev/null+++ b/store/agents/simskill/toolchain/build-sumo.sh@@ -0,0 +1,26 @@+#!/usr/bin/env bash+# Intel macOS's published SUMO wheel requires global Homebrew libraries. Build just the two+# headless tools instead, with a package-local Xerces library and the pinned upstream source.+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+if [ -x .sumo/bin/sumo ] && [ -x .sumo/bin/netconvert ]; then exit 0; fi+harness_conda_env .sumo 'xerces-c=3.3.0'+if [ "$(uname -s)" = Darwin ]; then+ export SDKROOT="$(xcrun --show-sdk-path)"+ if [ -d "$SDKROOT/usr/include/c++/v1" ]; then+ export CPLUS_INCLUDE_PATH="$SDKROOT/usr/include/c++/v1${CPLUS_INCLUDE_PATH:+:$CPLUS_INCLUDE_PATH}"+ fi+fi+studio_cmake="$PWD/.venv/bin/cmake"+"$studio_cmake" -S sumo-src -B .build/sumo -DCMAKE_BUILD_TYPE=Release \+ -DCMAKE_PREFIX_PATH="$PWD/.sumo" -DCMAKE_INSTALL_PREFIX="$PWD/.sumo" \+ -DCHECK_OPTIONAL_LIBS=OFF -DENABLE_FOX=OFF -DENABLE_PROJ=OFF -DENABLE_GDAL=OFF \+ -DENABLE_FMI=OFF -DENABLE_NETEDIT=OFF -DENABLE_PYTHON_BINDINGS=OFF \+ -DENABLE_JAVA_BINDINGS=OFF -DENABLE_CS_BINDINGS=OFF -DENABLE_EIGEN=OFF \+ -DENABLE_FMT=OFF -DENABLE_GTEST=OFF -DENABLE_PARQUET=OFF -DENABLE_TCMALLOC=OFF \+ -DISOLATED_BUILD=ON+"$studio_cmake" --build .build/sumo --target sumo netconvert -j 2+mkdir -p .sumo/bin+cp .build/sumo/bin/sumo .build/sumo/bin/netconvert .sumo/bin/+.sumo/bin/sumo --versiondiff --git a/store/agents/simskill/toolchain/doctor.sh b/store/agents/simskill/toolchain/doctor.shnew file mode 100755index 000000000..a1b15856c--- /dev/null+++ b/store/agents/simskill/toolchain/doctor.sh@@ -0,0 +1,10 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+test -x .venv/bin/python || { echo 'miss run toolchain/setup.sh to install the local runtime'; exit 1; }+if [ -x .sumo/bin/sumo ]; then .sumo/bin/sumo --version; .sumo/bin/netconvert --version;+else .venv/bin/sumo --version; .venv/bin/netconvert --version; fi+test -f upstream/README.md || { echo "miss pinned upstream sources"; exit 1; }+echo "ok upstream 10113c1e6ba2"diff --git a/store/agents/simskill/toolchain/init-workspace.sh b/store/agents/simskill/toolchain/init-workspace.shnew file mode 100755index 000000000..8749f6568--- /dev/null+++ b/store/agents/simskill/toolchain/init-workspace.sh@@ -0,0 +1,3 @@+#!/usr/bin/env bash+set -euo pipefail+exec "${HARNESS_DSH_DIR:?}/toolchain/run.sh" simulatediff --git a/store/agents/simskill/toolchain/run.sh b/store/agents/simskill/toolchain/run.shnew file mode 100755index 000000000..a9e5df771--- /dev/null+++ b/store/agents/simskill/toolchain/run.sh@@ -0,0 +1,6 @@+#!/usr/bin/env bash+set -euo pipefail+studio_package="$(cd "$(dirname "$0")/.." && pwd)"+export PATH="$studio_package/.venv/bin:$PATH"+export PYTHONUNBUFFERED=1+exec "$studio_package/.venv/bin/python" "$studio_package/toolchain/workflow.py" "$@"diff --git a/store/agents/simskill/toolchain/runtimes.sh b/store/agents/simskill/toolchain/runtimes.shnew file mode 100644index 000000000..7223c78dc--- /dev/null+++ b/store/agents/simskill/toolchain/runtimes.sh@@ -0,0 +1,192 @@+# shellcheck shell=bash+# runtimes.sh — the interpreters a store package runs on, found on this machine or fetched, never+# asked of the person who pressed Get.+#+# Sourced (not run) by a package's setup, doctor and viewer scripts. A new Mac has Apple's Python 3.9,+# no Homebrew and, for most people, no Node on PATH; a package that answers "brew install [email protected]"+# has failed its install. So:+#+# harness_node 18 node >= 18 on PATH, with npm: the machine's own, else the Node Harness+# itself runs on (~/.harness/runtime/current-node, laid down with the CLI)+# harness_uv uv on PATH: the machine's own, else a pinned, checksummed release+# fetched into ~/.harness/runtime+# harness_venv DIR 3.12 [MIN [BELOW]]+# DIR is a venv on CPython 3.12, which uv downloads when the machine+# has none. A venv already there on a Python in [MIN, BELOW) is kept.+# harness_pip DIR PKG… install into that venv, through uv+# harness_micromamba micromamba, pinned and checksummed, for native libraries PyPI has+# no wheel for (pycairo on macOS)+# harness_conda_env DIR SPEC… DIR is a conda-forge environment with those packages+#+# Every function prints `miss …` and returns 1 when it cannot deliver, so `harness_node 18 || exit 1`+# reads like the rest of a setup script. Nothing here touches the user's shell profile; what it+# installs lands in ~/.harness/runtime or the package's own directory (uv keeps its download cache+# where it always does, which a venv does not depend on).+#+# ONE copy is written by hand: store/tools/runtimes.sh in the OpenHarness repository. Each package+# carries an identical copy (a package installs alone, so it cannot reach this one);+# `node store/tools/sync-runtimes.mjs` rewrites them and the CLI's store spec fails when one drifts.++HARNESS_RUNTIME="${ADAPTER_RUNTIME_DIR:-${HOME:-}/.harness/runtime}"+# The Pythons uv downloads live with Harness's other runtimes, not in uv's own ~/.local/share/uv:+# a package's venv points at its interpreter, and `uv python uninstall` there must not break it.+UV_PYTHON_INSTALL_DIR="${UV_PYTHON_INSTALL_DIR:-$HARNESS_RUNTIME/python}"+export UV_PYTHON_INSTALL_DIR+HARNESS_UV_VERSION=0.12.15+HARNESS_MICROMAMBA_VERSION=2.9.0-0++_harness_platform() {+ case "$(uname -s)-$(uname -m)" in+ Darwin-arm64) echo darwin-arm64 ;;+ Darwin-x86_64) echo darwin-x64 ;;+ Linux-x86_64) echo linux-x64 ;;+ Linux-aarch64 | Linux-arm64) echo linux-arm64 ;;+ *) return 1 ;;+ esac+}++_harness_sha256() {+ if command -v shasum >/dev/null 2>&1; then shasum -a 256 "$1" | cut -d' ' -f1+ else sha256sum "$1" | cut -d' ' -f1; fi+}++# _harness_fetch URL DEST SHA256 — DEST exists only if what arrived matches the pinned checksum.+_harness_fetch() {+ local part="$2.part.$$"+ if ! curl -fsSL --retry 3 --connect-timeout 20 --max-time 900 -o "$part" "$1"; then+ rm -f "$part"; echo "miss could not download $1 — check this machine's internet connection"; return 1+ fi+ if [ "$(_harness_sha256 "$part")" != "$3" ]; then+ rm -f "$part"; echo "miss $1 did not match its pinned checksum; nothing was installed"; return 1+ fi+ mv -f "$part" "$2"+}++_harness_node_at_least() {+ command -v node >/dev/null 2>&1 || return 1+ node -e '+ const [a, b = 0] = process.argv[1].split(".").map(Number)+ const [x, y] = process.versions.node.split(".").map(Number)+ process.exit(x > a || (x === a && y >= b) ? 0 : 1)+ ' "$1" >/dev/null 2>&1+}++harness_node() {+ local min="${1:-18}" recorded saved="$PATH" own=0+ _harness_node_at_least "$min" && own=1+ # A node without npm beside it (a distro's nodejs package) cannot run a setup's `npm ci`.+ if [ "$own" = 1 ] && command -v npm >/dev/null 2>&1; then return 0; fi+ recorded="$(cat "$HARNESS_RUNTIME/current-node" 2>/dev/null || true)"+ # Already Harness's own (a second call, or a wrapper calling a script that asks again): nothing to add.+ if [ "$own" = 1 ] && [ -n "$recorded" ] && [ "$(command -v node)" = "${recorded%/*}/node" ]; then return 0; fi+ if [ -n "$recorded" ] && [ -x "${recorded%/*}/node" ]; then+ PATH="${recorded%/*}:$PATH"; export PATH; hash -r 2>/dev/null || true+ _harness_node_at_least "$min" && return 0+ PATH="$saved"; export PATH; hash -r 2>/dev/null || true+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min — this machine's newest is $("${recorded%/*}/node" -v), Harness's own; update Harness"+ return 1+ fi+ [ "$own" = 1 ] && return 0+ echo "miss node >= $min, and Harness's own Node is not in $HARNESS_RUNTIME — run \`harness start\` once to lay it down"+ return 1+}++harness_uv() {+ local dir asset sum tmp+ command -v uv >/dev/null 2>&1 && return 0+ for dir in "${HOME:-}/.local/bin" "${HOME:-}/.cargo/bin"; do+ [ -n "${HOME:-}" ] || break+ if [ -x "$dir/uv" ]; then PATH="$dir:$PATH"; export PATH; return 0; fi+ done+ dir="$HARNESS_RUNTIME/uv-$HARNESS_UV_VERSION"+ if [ ! -x "$dir/uv" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=uv-aarch64-apple-darwin sum=dc304b9ed1b24174572290fba60ac3f6fe63c73a671f0439e62a91375841964d ;;+ darwin-x64) asset=uv-x86_64-apple-darwin sum=e9ca61775532368fe518ab03e7a354c7ecab8ccb3c7d941c775fcc4a362b801b ;;+ linux-x64) asset=uv-x86_64-unknown-linux-gnu sum=f97935763c04be3e692460a7aaeaaab8fc3b78fcf8b389da820b38ae7423a638 ;;+ linux-arm64) asset=uv-aarch64-unknown-linux-gnu sum=0e9a3499b0587d449c9ff684c0160da607826e4af1cee220bc87f378702d3e08 ;;+ *) echo "miss uv — there is no uv release for $(uname -s) $(uname -m); install it from https://docs.astral.sh/uv/"; return 1 ;;+ esac+ echo " fetching uv $HARNESS_UV_VERSION into $HARNESS_RUNTIME (it brings Python and the packages)"+ mkdir -p "$HARNESS_RUNTIME" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ tmp="$(mktemp -d "$HARNESS_RUNTIME/.uv.XXXXXX")" || { echo "miss cannot write $HARNESS_RUNTIME"; return 1; }+ if ! _harness_fetch "https://github.com/astral-sh/uv/releases/download/$HARNESS_UV_VERSION/$asset.tar.gz" "$tmp/uv.tar.gz" "$sum"; then+ rm -rf "$tmp"; return 1+ fi+ tar -xzf "$tmp/uv.tar.gz" -C "$tmp" && chmod +x "$tmp/$asset/uv" "$tmp/$asset/uvx" \+ || { rm -rf "$tmp"; echo "miss the uv archive would not unpack"; return 1; }+ # Two installs at once both get here; whichever renames first wins and the other's copy goes.+ # (mv onto a directory that exists would nest the copy inside it, hence the test.)+ [ -e "$dir" ] || mv "$tmp/$asset" "$dir" 2>/dev/null || true+ rm -rf "$tmp"+ [ -x "$dir/uv" ] || { echo "miss uv did not land in $dir"; return 1; }+ fi+ PATH="$dir:$PATH"; export PATH+}++# harness_venv DIR VERSION [MIN [BELOW]] — MIN defaults to VERSION; BELOW is exclusive and optional.+harness_venv() {+ local dir="${1:?harness_venv needs a directory}" want="${2:?harness_venv needs a Python version}"+ local min="${3:-$2}" below="${4:-}"+ if [ -x "$dir/bin/python" ] && "$dir/bin/python" -c '+import sys+at = lambda s: tuple(int(p) for p in s.split("."))+v = sys.version_info[:2]+sys.exit(0 if v >= at(sys.argv[1]) and (not sys.argv[2] or v < at(sys.argv[2])) else 1)+' "$min" "$below" 2>/dev/null; then+ echo "ok $("$dir/bin/python" --version) in $dir"+ return 0+ fi+ harness_uv || return 1+ echo " python $want in $dir (uv downloads it when this machine has none)"+ rm -rf "$dir"+ # only-managed: the same python-build-standalone interpreter on every machine, so a package tested+ # once is tested everywhere — not whichever Homebrew or pyenv Python happened to be first on PATH.+ uv venv --quiet --seed --python "$want" --python-preference only-managed "$dir" \+ || { echo "miss could not make a Python $want environment in $dir"; return 1; }+ echo "ok $("$dir/bin/python" --version) in $dir"+}++harness_pip() {+ local dir="${1:?harness_pip needs a venv}"+ shift+ harness_uv || return 1+ # uv's own error comes first; the miss line is last, so it is the line the store shows.+ uv pip install --quiet --python "$dir/bin/python" "$@" \+ || { echo "miss could not install $* into $dir"; return 1; }+}++harness_micromamba() {+ local dir asset sum+ dir="$HARNESS_RUNTIME/micromamba-$HARNESS_MICROMAMBA_VERSION"+ if [ ! -x "$dir/micromamba" ]; then+ case "$(_harness_platform)" in+ darwin-arm64) asset=micromamba-osx-arm64 sum=ec2a072f028e1a7cf20f3e2e74d5a8127cf5a5f27636375b5359811565f4e5be ;;+ darwin-x64) asset=micromamba-osx-64 sum=1e71054bb3ac9a076e21f7ec48acfef536f9b3f1408f371a942784bf5ef83d8a ;;+ linux-x64) asset=micromamba-linux-64 sum=366cd9cd8be14df1ab8ed50352a82111082a36686b2d389fdb79a92c3fafb3e3 ;;+ linux-arm64) asset=micromamba-linux-aarch64 sum=9f93b974adcb4d166996af969b6cd371287d1a3e52733704727884d9b74cb7a7 ;;+ *) echo "miss micromamba — there is no release for $(uname -s) $(uname -m)"; return 1 ;;+ esac+ echo " fetching micromamba $HARNESS_MICROMAMBA_VERSION into $HARNESS_RUNTIME (native libraries PyPI has no wheel for)"+ mkdir -p "$dir" || { echo "miss cannot write $dir"; return 1; }+ _harness_fetch "https://github.com/mamba-org/micromamba-releases/releases/download/$HARNESS_MICROMAMBA_VERSION/$asset" "$dir/micromamba.$$" "$sum" || return 1+ chmod +x "$dir/micromamba.$$" && mv -f "$dir/micromamba.$$" "$dir/micromamba" \+ || { rm -f "$dir/micromamba.$$"; echo "miss micromamba would not install into $dir"; return 1; }+ fi+ HARNESS_MICROMAMBA="$dir/micromamba"+ export HARNESS_MICROMAMBA+}++# harness_conda_env DIR SPEC… — conda-forge only, packages cached under ~/.harness/runtime/mamba.+harness_conda_env() {+ local dir="${1:?harness_conda_env needs a directory}"+ shift+ # micromamba takes a relative --prefix as a name under its root prefix and "succeeds" there.+ case "$dir" in /*) ;; *) dir="$PWD/$dir" ;; esac+ harness_micromamba || return 1+ MAMBA_ROOT_PREFIX="$HARNESS_RUNTIME/mamba" "$HARNESS_MICROMAMBA" create --yes --quiet \+ --prefix "$dir" --override-channels --channel conda-forge "$@" >/dev/null \+ && [ -d "$dir/conda-meta" ] \+ || { echo "miss could not make the conda-forge environment in $dir ($*)"; return 1; }+}diff --git a/store/agents/simskill/toolchain/setup.sh b/store/agents/simskill/toolchain/setup.shnew file mode 100755index 000000000..3cf31d4d2--- /dev/null+++ b/store/agents/simskill/toolchain/setup.sh@@ -0,0 +1,10 @@+#!/usr/bin/env bash+set -euo pipefail+cd "$(dirname "$0")/.."+. toolchain/runtimes.sh+harness_node 22+harness_venv .venv 3.11 3.11 3.12+.venv/bin/python toolchain/studio_fetch.py+if [ -s requirements.lock ]; then harness_pip .venv --require-hashes -r requirements.lock; fi+if [ "$(uname -s)-$(uname -m)" = Darwin-x86_64 ]; then toolchain/build-sumo.sh; fi+exec toolchain/doctor.shdiff --git a/store/agents/simskill/toolchain/studio_fetch.py b/store/agents/simskill/toolchain/studio_fetch.pynew file mode 100644index 000000000..88a670b25--- /dev/null+++ b/store/agents/simskill/toolchain/studio_fetch.py@@ -0,0 +1,34 @@+"""Fetch reviewed source pins without installing a service or changing user configuration."""+import json+import os+from pathlib import Path+import subprocess++root = Path(__file__).resolve().parent.parent+sources = json.loads((root / "upstream.lock.json").read_text())+for source in sources:+ target = root / source["directory"]+ def git(*args):+ return subprocess.check_output(["git", "-C", str(target), *args], text=True,+ env={**os.environ, "GIT_LFS_SKIP_SMUDGE": "1"}).strip()+ if not (target / ".git").exists():+ target.mkdir(parents=True, exist_ok=True)+ git("init", "-q")+ git("remote", "add", "origin", source["url"])+ if source.get("sparse"):+ git("sparse-checkout", "init", "--cone")+ git("sparse-checkout", "set", *source["sparse"])+ if git("remote", "get-url", "origin") != source["url"]:+ raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])+ try:+ current = git("rev-parse", "HEAD")+ except subprocess.CalledProcessError:+ current = ""+ if current != source["commit"]:+ if current and git("status", "--porcelain"):+ raise SystemExit(f"Save your edits in {target} before changing its source pin")+ git("fetch", "--depth", "1", "--filter=blob:none", "origin", source["commit"])+ git("checkout", "--detach", source["commit"])+ print(f'ok {source["name"]} at {source["commit"][:12]}', flush=True)diff --git a/store/agents/simskill/toolchain/studio_runtime.py b/store/agents/simskill/toolchain/studio_runtime.pynew file mode 100644index 000000000..8b8ea016c--- /dev/null+++ b/store/agents/simskill/toolchain/studio_runtime.py@@ -0,0 +1,132 @@+"""Portable runner copied into each independently installable studio package."""+import json+import math+import os+from pathlib import Path+import subprocess+import sys+import tempfile+import time+import uuid+++def workspace():+ return Path(os.environ.get("HARNESS_WORKSPACE", os.getcwd())).resolve()+++def package():+ return Path(__file__).resolve().parent.parent+++def contained(path):+ target = Path(path).resolve()+ target.relative_to(workspace())+ return target+++def atomic_json(path, data):+ path = contained(path)+ path.parent.mkdir(parents=True, exist_ok=True)+ with tempfile.NamedTemporaryFile(mode="w", dir=path.parent, prefix=".studio-", delete=False) as f:+ json.dump(data, f, indent=2, allow_nan=False)+ f.write("\n")+ temp = f.name+ os.replace(temp, path)+++def command(argv, cwd=None, timeout=120, env=None):+ """No shell interpolation; keep complete logs as output, bound execution time."""+ result = subprocess.run([str(x) for x in argv], cwd=cwd, timeout=timeout,+ env=env, text=True, capture_output=True)+ if result.returncode:+ raise RuntimeError((result.stderr or result.stdout)[-1600:] or f"{argv[0]} exited {result.returncode}")+ return result.stdout+++def parameters(config, values):+ if not isinstance(values, dict) or set(values) - {c["id"] for c in config["controls"]}:+ raise ValueError("Invalid studio controls")+ result = {}+ for c in config["controls"]:+ value = values.get(c["id"], c["value"])+ if c["type"] == "number":+ if type(value) not in (int, float) or not math.isfinite(value) or not c["min"] <= value <= c["max"]:+ raise ValueError(f'{c["label"]} is outside its range')+ if c.get("integer") and value != int(value):+ raise ValueError(f'{c["label"]} must be a whole number')+ elif c["type"] == "select":+ if value not in [o["value"] for o in c["options"]]:+ raise ValueError(f'Unknown {c["label"]}')+ elif not isinstance(value, str) or len(value) > c.get("maxLength", 500):+ raise ValueError(f'Invalid {c["label"]}')+ result[c["id"]] = value+ return result+++def metric(label, value, unit=""):+ return {"label": label, "value": value, "unit": unit}+++def previous_runs():+ base = contained(workspace() / "out/runs")+ rows = []+ for p in sorted(base.glob("*/result.json"))[-100:]:+ try:+ rows.append(json.loads(contained(p).read_text()))+ except (ValueError, OSError):+ continue+ return rows+++def execute(actions):+ root = workspace()+ config = json.loads((package() / "studio.config.json").read_text())+ action = sys.argv[1] if len(sys.argv) > 1 else config["actions"][0]["id"]+ started = time.monotonic()+ verdict_path = root / ".harness/verdict.json"+ verdict = {"spec": 1, "ready": False, "summary": "Preparing the studio run", "findings": [],+ "phases": [{"id": "run", "name": "Make", "state": "active"},+ {"id": "inspect", "name": "Inspect", "state": "pending"}]}+ try:+ if action not in actions:+ raise ValueError(f"Unknown action: {action}")+ source = contained(root / "studio.json")+ if source.stat().st_size > 16384:+ raise ValueError("studio.json is too large")+ project = json.loads(source.read_text())+ p = parameters(config, project["parameters"])+ atomic_json(verdict_path, verdict)+ run_id = time.strftime("%Y%m%dT%H%M%S", time.gmtime()) + "-" + uuid.uuid4().hex[:8]+ output = contained(root / "out/runs" / run_id)+ output.mkdir(parents=True)+ print(f'{config["title"]}: {action}', flush=True)+ result = actions[action](p, output)+ artifacts = []+ for artifact in result.pop("files", []):+ file = contained(output / artifact["name"])+ file.relative_to(output)+ if not file.is_file() or not file.stat().st_size:+ raise ValueError(f'Missing output: {artifact["name"]}')+ artifacts.append({"label": artifact["label"], "path": str(file.relative_to(root))})+ result.update({"spec": 1, "id": run_id, "action": action, "parameters": p,+ "createdAt": time.strftime("%Y-%m-%dT%H:%M:%SZ", time.gmtime()),+ "durationSeconds": round(time.monotonic() - started, 3), "artifacts": artifacts,+ "upstream": json.loads((package() / "upstream.lock.json").read_text())})+ atomic_json(output / "result.json", result)+ atomic_json(root / "out/latest.json", result)+ verdict.update({"ready": True, "summary": f'{result["title"]} · {result["engine"]}',+ "artifact": str((output / "result.json").relative_to(root)),+ "phases": [{"id": "run", "name": "Make", "state": "done"},+ {"id": "inspect", "name": "Inspect", "state": "done"}],+ "updatedAt": result["createdAt"]})+ atomic_json(verdict_path, verdict)+ print(f'Ready: {result["title"]}', flush=True)+ except Exception as exc:+ verdict.update({"summary": str(exc)[:500], "findings": [{"severity": "error", "kind": "run-failed", "message": str(exc)[:1000]}],+ "phases": [{"id": "run", "name": "Make", "state": "failed"}]})+ try:+ atomic_json(verdict_path, verdict)+ except (ValueError, OSError):+ pass+ print(str(exc), file=sys.stderr)+ raise SystemExit(1) from excdiff --git a/store/agents/simskill/toolchain/workflow.py b/store/agents/simskill/toolchain/workflow.pynew file mode 100644index 000000000..7efbaf79d--- /dev/null+++ b/store/agents/simskill/toolchain/workflow.py@@ -0,0 +1,59 @@+import json+from pathlib import Path+import statistics+import xml.etree.ElementTree as ET+from studio_runtime import execute, metric, command, package+++def binary(name):+ conda=package()/'.sumo/bin'/name+ return conda if conda.exists() else package()/'.venv/bin'/name+++def simulate(p,out):+ points={'W':(0,200),'E':(400,200),'N':(200,400),'S':(200,0),'C':(200,200)}+ nodes=ET.Element('nodes')+ for id,(x,y) in points.items():ET.SubElement(nodes,'node',id=id,x=str(x),y=str(y),type='traffic_light' if id=='C' else 'priority')+ edges=ET.Element('edges')+ for id in ['W','E','N','S']:+ ET.SubElement(edges,'edge',id=id+'C',**{'from':id,'to':'C','numLanes':'1','speed':'13.9'})+ ET.SubElement(edges,'edge',id='C'+id,**{'from':'C','to':id,'numLanes':'1','speed':'13.9'})+ ET.ElementTree(nodes).write(out/'nodes.xml');ET.ElementTree(edges).write(out/'edges.xml')+ print('Building the intersection…',flush=True)+ command([binary('netconvert'),'--node-files',out/'nodes.xml','--edge-files',out/'edges.xml','--output-file',out/'city.net.xml','--no-turnarounds','true'],timeout=60)+ network=ET.parse(out/'city.net.xml');logic=network.find('.//tlLogic')+ if logic is None:raise RuntimeError('SUMO did not generate the traffic light.')+ phases=logic.findall('phase')+ # Detect which generated phase serves west/east straight connections instead of relying on link indices.+ eastwest=[int(c.attrib['linkIndex']) for c in network.findall('connection') if c.get('tl')=='C' and c.get('from') in ['WC','EC'] and c.get('dir')=='s']+ for phase in phases:+ s=phase.get('state','')+ if 'y' in s.lower():phase.set('duration','3')+ elif any(i<len(s) and s[i] in 'Gg' for i in eastwest):phase.set('duration',str(p['green']))+ else:phase.set('duration',str(80-p['green']))+ network.write(out/'city.net.xml')+ routes=ET.Element('routes');ET.SubElement(routes,'vType',id='car',accel='2.6',decel='4.5',sigma='.3',length='4.5',minGap='2.5',maxSpeed='13.9')+ for direction,opposite in [('W','E'),('E','W'),('N','S'),('S','N')]:+ ET.SubElement(routes,'route',id=direction,edges=f'{direction}C C{opposite}')+ ET.SubElement(routes,'flow',id=direction,type='car',route=direction,begin='0',end=str(p['duration']-30),vehsPerHour=str(p['demand']),departLane='best',departSpeed='max')+ ET.ElementTree(routes).write(out/'routes.xml')+ print('Simulating the rush…',flush=True)+ log=command([binary('sumo'),'-n',out/'city.net.xml','-r',out/'routes.xml','--begin','0','--end',str(p['duration']),'--seed',str(p['seed']),'--step-length','.5','--fcd-output',out/'traffic.xml','--tripinfo-output',out/'trips.xml','--tripinfo-output.write-unfinished','true','--no-step-log','true','--duration-log.disable','true'],timeout=90)+ (out/'sumo.log').write_text(log or 'SUMO completed successfully.\n')+ trips=ET.parse(out/'trips.xml').getroot().findall('tripinfo')+ completed=[v for v in trips if float(v.get('arrival','-1'))>=0]+ if not completed:raise RuntimeError('No trips finished. Increase the sample duration or reduce traffic demand.')+ frames=[];max_queue=0+ for t in ET.parse(out/'traffic.xml').getroot().findall('timestep'):+ cars=[{'id':v.get('id'),'x':round(float(v.get('x')),2),'y':round(float(v.get('y')),2),'speed':round(float(v.get('speed')),2),'angle':float(v.get('angle'))} for v in t]+ max_queue=max(max_queue,sum(v['speed']<.1 for v in cars))+ if round(float(t.get('time'))*2)%4==0:frames.append({'time':float(t.get('time')),'cars':cars})+ summary={'frames':frames,'extent':400,'phases':[dict(x.attrib) for x in phases],'finished':len(completed),'unfinished':len(trips)-len(completed),'maxQueue':max_queue}+ (out/'playback.json').write_text(json.dumps(summary))+ avg=statistics.mean(float(t.get('timeLoss')) for t in completed)+ (out/'trips.csv').write_text('id,duration,time_loss,waiting_time,finished\n'+'\n'.join(f'{t.get("id")},{t.get("duration")},{t.get("timeLoss")},{t.get("waitingTime")},{float(t.get("arrival","-1"))>=0}' for t in trips)+'\n')+ version=command([binary('sumo'),'--version'],timeout=15).splitlines()[0]+ return {'title':f'Rush hour · {len(completed)} trips completed','description':f'{len(trips)-len(completed)} vehicles were still travelling at the end. Trip delay is measured for completed trips; compare identical demand, duration and seed.','engine':version,'metrics':[metric('Mean trip delay',round(avg,1),'s'),metric('Finished trips',len(completed)),metric('Largest stopped queue',max_queue,'cars')],'data':summary,'files':[{'label':'Trip measurements','name':'trips.csv'},{'label':'SUMO network','name':'city.net.xml'},{'label':'Playback data','name':'playback.json'},{'label':'Raw vehicle traces','name':'traffic.xml'}]}+++if __name__=='__main__':execute({'simulate':simulate})diff --git a/store/agents/simskill/upstream.lock.json b/store/agents/simskill/upstream.lock.jsonnew file mode 100644index 000000000..973239f45--- /dev/null+++ b/store/agents/simskill/upstream.lock.json@@ -0,0 +1,27 @@+[+ {+ "name": "SimSkill",+ "url": "https://github.com/qiliuchn/SimSkill-V1.git",+ "commit": "10113c1e6ba28b57b48a38a7c25ee113b49ab4e6",+ "directory": "upstream",+ "sparse": [+ ".claude/skills/procedural-memory/create-single-intersection",+ ".claude/skills/procedural-memory/run-simulation",+ ".claude/skills/procedural-memory/analyze-simulation-outputs",+ "semantic-memory"+ ]+ },+ {+ "name": "Eclipse SUMO",+ "url": "https://github.com/eclipse-sumo/sumo.git",+ "commit": "7717f2379d9e314a0c81c5cec748444de06a2a91",+ "directory": "sumo-src",+ "sparse": [+ "src",+ "build_config",+ "data/xsd",+ "tools/build_config",+ "tools/sumolib"+ ]+ }+]diff --git a/store/agents/simskill/view.mjs b/store/agents/simskill/view.mjsnew file mode 100644index 000000000..b75b2fbdf--- /dev/null+++ b/store/agents/simskill/view.mjs@@ -0,0 +1,23 @@+import {canvas,round,line,circle,words,toolbar,badge,label,el} from '/graphics.mjs';+export function mount(stage,api){+ let p=api.getParameters(),result,index=0,playing=true,rate=8,now=0,start=0,last='',follow=false,bounds;+ label(stage,'Every little journey has somewhere to be.');const tag=badge(stage,'TRAFFIC REPLAY');+ const screen=canvas(stage,(ctx,w,h,t)=>{+ now=t;const size=Math.min(w-50,h-70),left=(w-size)/2,top=18,s=size/400;bounds={left,top,s};const map=(x,y)=>[left+x*s,top+(400-y)*s];+ round(ctx,left,top,size,size,14,'#2e4230');+ const mid=left+size/2,cy=top+size/2,road=28;+ ctx.fillStyle='#b9bfaa';ctx.fillRect(left,cy-road/2-4,size,road+8);ctx.fillRect(mid-road/2-4,top,road+8,size);+ ctx.fillStyle='#39433c';ctx.fillRect(left,cy-road/2,size,road);ctx.fillRect(mid-road/2,top,road,size);+ for(let i=0;i<4;i++){const x=left+(i%2?size*.67:size*.13),y=top+(i>1?size*.67:size*.13);round(ctx,x+3,y+5,size*.19,size*.16,4,'#11271955');round(ctx,x,y,size*.19,size*.16,4,['#acb68d','#7d9475','#889780','#b4ae8c'][i]);line(ctx,[[x+5,y+6],[x+size*.19-5,y+6]],'#e5e6c333',1);circle(ctx,x+size*.1,y+size*.23,9,'#698952');circle(ctx,x+size*.16,y+size*.23,7,'#76975b');}+ ctx.setLineDash([6,8]);line(ctx,[[left,cy],[mid-22,cy]],'#b6c3a04d',1);line(ctx,[[mid+22,cy],[left+size,cy]],'#b6c3a04d',1);line(ctx,[[mid,top],[mid,cy-22]],'#b6c3a04d',1);line(ctx,[[mid,cy+22],[mid,top+size]],'#b6c3a04d',1);ctx.setLineDash([]);+ const frames=result?.data?.frames;+ if(frames?.length){if(playing)index=Math.floor(((t-start)*rate/2)%frames.length);const frame=frames[index];scrub.value=index;tag.textContent=`SUMO · ${frame.time.toFixed(0)} S`;+ frame.cars.forEach((car,i)=>{const [x,y]=map(car.x,car.y);ctx.save();ctx.translate(x,y);ctx.rotate(car.angle*Math.PI/180);round(ctx,-2.5,-4.5,5,9,1.5,car.speed<.1?'#e79c75':'#d5e9a2');ctx.restore();if(follow&&i===0){circle(ctx,x,y,10,'#e5f8bd25');words(ctx,car.id,x+11,y-7,'#e5f8bd',9);}});+ if(w>570){words(ctx,'CITY CLOCK',24,69,'#a7c292',9);words(ctx,`${frame.time.toFixed(0)} s`,24,98,'#e1edc5',23);words(ctx,`${frame.cars.length} moving stories`,24,122,'#9cb78b',10);}+ }else words(ctx,'Run the city to record its traffic.',left,top+size/2,'#d5e9a2',11);+ words(ctx,`${p.green}s EAST–WEST GREEN`,left,top+size+20,'#9cb78b',9);+ },api.signal);screen.element.setAttribute('aria-label','SUMO traffic replay on a four-way city intersection');+ const bar=toolbar(stage,[['Pause traffic',b=>{playing=!playing;if(playing)start=now-index*2/rate;b.textContent=playing?'Pause traffic':'Play traffic';b.setAttribute('aria-pressed',String(playing));}],['8× speed',b=>{rate=rate===8?16:rate===16?1:8;start=now-index*2/rate;b.textContent=`${rate}× speed`;}],['Follow a car',b=>{follow=!follow;b.textContent=follow?'See the city':'Follow a car';b.setAttribute('aria-pressed',String(follow));}]]);+ const scrub=el('input');scrub.type='range';scrub.min=0;scrub.max=1;scrub.value=0;scrub.style.width='95px';scrub.setAttribute('aria-label','Traffic replay position');scrub.addEventListener('input',()=>{playing=false;index=Number(scrub.value);bar.firstChild.textContent='Play traffic';});bar.append(scrub);+ return {update(params,r,motion){p=params;result=r;screen.motion(motion);if(r?.data?.frames&&r.id!==last){last=r.id;start=now;index=0;scrub.max=r.data.frames.length-1;}}};+}diff --git a/store/tools/studio_fetch.py b/store/tools/studio_fetch.pyindex 0b41a17c6..88a670b25 100644--- a/store/tools/studio_fetch.py+++ b/store/tools/studio_fetch.py@@ -20,6 +20,8 @@ for source in sources:git("sparse-checkout", "set", *source["sparse"])if git("remote", "get-url", "origin") != source["url"]:raise SystemExit(f"Unexpected upstream remote in {target}")+ if source.get("sparse"):+ git("sparse-checkout", "set", *source["sparse"])try:current = git("rev-parse", "HEAD")except subprocess.CalledProcessError:diff --git a/store/viewers/studio-viewer/test/studios.e2e.mjs b/store/viewers/studio-viewer/test/studios.e2e.mjsnew file mode 100644index 000000000..15707dd5f--- /dev/null+++ b/store/viewers/studio-viewer/test/studios.e2e.mjs@@ -0,0 +1,82 @@+import assert from 'node:assert/strict';+import {mkdtemp,mkdir,cp,readFile,writeFile,stat,rm} from 'node:fs/promises';+import {tmpdir} from 'node:os';+import {join} from 'node:path';+import {fileURLToPath} from 'node:url';+import {spawn} from 'node:child_process';+import {chromium} from 'playwright';+import {createStudio} from '../server.mjs';++const viewer=fileURLToPath(new URL('../',import.meta.url));+const agents=fileURLToPath(new URL('../../../agents/',import.meta.url));+const names=(process.env.STUDIO_TEST_PACKAGES??'juce-agent-toolkit,foam-agent,autoresearch-mlx,ableton-ai,dimos,simskill,bonsai-mcp,comfy-mcp').split(',');+const output=join(viewer,'test-results');await mkdir(output,{recursive:true});+const root=await mkdtemp(join(tmpdir(),'harness-studio-browser-'));+const browser=await chromium.launch({channel:process.env.STUDIO_BROWSER_CHANNEL??'chrome',headless:true});+const report=[];+const exec=(command,args,cwd,env={})=>new Promise((ok,fail)=>{const p=spawn(command,args,{cwd,env:{...process.env,...env},stdio:['ignore','pipe','pipe']});let log='';p.stdout.on('data',b=>{log+=b;});p.stderr.on('data',b=>{log+=b;});p.on('error',fail);p.on('close',code=>code===0?ok(log):fail(Error(log)));});+const domains={+ 'juce-agent-toolkit':async page=>{await page.getByRole('button',{name:'Play C',exact:true}).click();await page.keyboard.press('a');await page.getByRole('button',{name:'Play recording',exact:true}).click();await page.getByRole('button',{name:'Stop recording',exact:true}).click();await page.getByRole('button',{name:'Surprise me',exact:true}).click();},+ 'foam-agent':async page=>{await page.getByRole('button',{name:'Show pressure',exact:true}).click();await page.getByRole('button',{name:'Show velocity',exact:true}).click();await page.getByRole('button',{name:'Show vectors',exact:true}).click();await page.getByRole('button',{name:'Hide vectors',exact:true}).click();await page.getByRole('button',{name:'Release tracers',exact:true}).click();await page.locator('canvas').click({position:{x:40,y:100}});},+ 'autoresearch-mlx':async page=>{await page.getByRole('button',{name:'Hide held-out score',exact:true}).click();await page.getByRole('button',{name:'Show held-out score',exact:true}).click();await page.locator('canvas').focus();await page.keyboard.press('ArrowRight');await page.keyboard.press('ArrowLeft');await page.getByRole('button',{name:'Try another seed',exact:true}).click();},+ 'ableton-ai':async page=>{await page.getByRole('button',{name:'Play loop',exact:true}).click();await page.getByRole('button',{name:'Pause loop',exact:true}).click();await page.getByRole('button',{name:'New variation',exact:true}).click();await page.locator('canvas').focus();await page.keyboard.press('ArrowRight');await page.keyboard.press('Enter');await page.getByRole('button',{name:'Play WAV',exact:true}).click();},+ 'dimos':async page=>{await page.getByRole('button',{name:'Hide route',exact:true}).click();await page.getByRole('button',{name:'Show route',exact:true}).click();await page.getByRole('button',{name:'Replay mission',exact:true}).click();await page.getByRole('slider',{name:'Mission replay position'}).focus();await page.keyboard.press('ArrowRight');await page.locator('canvas').focus();await page.keyboard.press('ArrowLeft');},+ 'simskill':async page=>{await page.getByRole('button',{name:'Pause traffic',exact:true}).click();await page.getByRole('button',{name:'Play traffic',exact:true}).click();await page.getByRole('button',{name:'8× speed',exact:true}).click();await page.getByRole('button',{name:'16× speed',exact:true}).click();await page.getByRole('button',{name:'1× speed',exact:true}).click();await page.getByRole('button',{name:'Follow a car',exact:true}).click();await page.getByRole('button',{name:'See the city',exact:true}).click();await page.getByRole('slider',{name:'Traffic replay position'}).focus();await page.keyboard.press('ArrowRight');},+ 'bonsai-mcp':async page=>{await page.getByRole('button',{name:'Floor plan',exact:true}).click();await page.getByRole('button',{name:'Next room',exact:true}).click();await page.getByRole('button',{name:'Orbit view',exact:true}).click();await page.getByRole('button',{name:'Separate floors',exact:true}).click();await page.getByRole('button',{name:'Bring together',exact:true}).click();const box=await page.locator('canvas').boundingBox();await page.mouse.move(box.x+box.width/2,box.y+100);await page.mouse.down();await page.mouse.move(box.x+box.width/2+70,box.y+100,{steps:5});await page.mouse.up();await page.locator('canvas').focus();await page.keyboard.press('ArrowRight');},+ 'comfy-mcp':async page=>{await page.locator('.gallery button').first().click();await page.getByRole('button',{name:'Close',exact:true}).click();await page.getByRole('button',{name:'Inspect favourite',exact:true}).click();await page.keyboard.press('Escape');await page.getByRole('button',{name:'Another family',exact:true}).click();},+};+try{+ for(const name of names){+ const packageDir=join(agents,name),workspace=join(root,name);await cp(join(packageDir,'template'),workspace,{recursive:true});+ const manifest=JSON.parse(await readFile(join(packageDir,'harness.json'),'utf8'));+ const config=JSON.parse(await readFile(join(packageDir,'studio.config.json'),'utf8'));+ const doctor=await exec(join(packageDir,'toolchain/doctor.sh'),[],packageDir);+ const init=await exec(join(packageDir,manifest.workspace.init),[],workspace,{HARNESS_DSH_DIR:packageDir,HARNESS_WORKSPACE:workspace});+ let verdict=JSON.parse(await readFile(join(workspace,'.harness/verdict.json'),'utf8'));assert.equal(verdict.ready,true);assert.ok((await stat(join(workspace,verdict.artifact))).size>0);+ const studio=await createStudio({workspace,packageDir});+ const context=await browser.newContext({viewport:{width:1280,height:1000},acceptDownloads:true});+ const page=await context.newPage();const errors=[];+ page.on('pageerror',e=>errors.push(e.message));+ const requests=[];page.on('requestfailed',r=>requests.push(`${r.method()} ${r.url()}: ${r.failure()?.errorText}`));+ await page.coverage.startJSCoverage({resetOnNavigation:false});+ try{+ await page.goto(studio.url);await page.waitForFunction(()=>document.getElementById('connection').textContent==='Workspace connected');+ assert.equal(await page.locator('h1').textContent(),config.title);+ await page.locator('#run').waitFor({state:'visible'});+ await page.waitForFunction(()=>document.querySelector('#stage canvas')||document.querySelector('.gallery img')?.complete);+ await page.screenshot({path:join(output,`${name}-wide.png`),fullPage:true});+ await domains[name](page);+ const first=await (await fetch(studio.url+'/api/state')).json();+ for(const c of config.controls.filter(c=>!c.hidden)){+ const input=page.locator(`[name="${c.id}"]`);+ if(c.type==='number'){await input.focus();await page.keyboard.press('ArrowRight');await page.keyboard.press('ArrowLeft');}+ else if(c.type==='select'){await input.selectOption(c.options.at(-1).value);await input.selectOption(c.value);}+ else await input.fill(c.value);+ }+ // Keep the default valid robot goal after exercising map movement.+ await page.getByRole('button',{name:'Reset controls',exact:true}).click();+ await page.getByRole('button',{name:config.actions[0].label,exact:true}).click();+ await page.waitForFunction(async old=>{const s=await(await fetch('/api/state')).json();if(s.job?.status==='failed')throw Error(s.job.message);return s.job?.status==='done'&&s.result.id!==old;},first.result.id,{timeout:120000});+ await page.waitForFunction(()=>document.querySelectorAll('#history button').length>=2);+ const current=await (await fetch(studio.url+'/api/state')).json();assert.notEqual(current.result.id,first.result.id);+ for(const a of current.result.artifacts){const r=await fetch(studio.url+'/artifacts/'+a.path);assert.equal(r.status,200);assert.ok((await r.arrayBuffer()).byteLength>0);}+ const downloading=page.waitForEvent('download');await page.locator('.artifact').first().click();const download=await downloading;await download.saveAs(join(output,`${name}-download-${download.suggestedFilename()}`));assert.equal(await download.failure(),null);+ await page.locator('#history button').last().click();await page.getByRole('button',{name:'Back to latest'}).waitFor();await page.getByRole('button',{name:'Back to latest'}).click();+ await page.getByRole('button',{name:'Pause motion',exact:true}).click();assert.equal(await page.locator('#motion').getAttribute('aria-pressed'),'false');await page.getByRole('button',{name:'Resume motion',exact:true}).click();+ // A concurrent agent edit must not be overwritten by an older UI draft.+ const c=config.controls.find(c=>c.type==='number');await page.locator(`[name="${c.id}"]`).focus();await page.keyboard.press('ArrowRight');+ const project=JSON.parse(await readFile(join(workspace,'studio.json'),'utf8'));project.title+=' · edited by agent';await writeFile(join(workspace,'studio.json'),JSON.stringify(project));+ await page.locator('#remote').waitFor({state:'visible'});await page.getByRole('button',{name:'Load update',exact:true}).click();+ await page.reload();await page.waitForFunction(()=>document.getElementById('connection').textContent==='Workspace connected');assert.equal((await(await fetch(studio.url+'/api/state')).json()).history.length,2);+ await page.setViewportSize({width:390,height:844});await page.screenshot({path:join(output,`${name}-narrow.png`),fullPage:true});+ assert.ok(await page.evaluate(()=>document.documentElement.scrollWidth<=innerWidth+1),'narrow layout must not scroll horizontally');+ await page.emulateMedia({reducedMotion:'reduce'});await page.reload();await page.waitForFunction(()=>document.getElementById('connection').textContent==='Workspace connected');assert.equal(await page.locator('#motion').getAttribute('aria-pressed'),'false');+ // Malformed agent output surfaces an error and recovers without losing artifacts.+ const source=await readFile(join(workspace,'studio.json'),'utf8');await writeFile(join(workspace,'studio.json'),'unfinished');await page.waitForFunction(()=>document.getElementById('connection').textContent==='Reconnecting');await writeFile(join(workspace,'studio.json'),source);await page.waitForFunction(()=>document.getElementById('connection').textContent==='Workspace connected');+ assert.deepEqual(errors,[],`${name}: browser errors`);assert.deepEqual(requests,[],`${name}: failed resource requests`);+ const coverage=await page.coverage.stopJSCoverage();await writeFile(join(output,`${name}-browser-coverage.json`),JSON.stringify(coverage));+ report.push({name,status:'passed',artifactCount:current.result.artifacts.length,engine:current.result.engine,workflows:['doctor','initialization','viewer','all controls','domain interactions','run','artifacts','download','history','pause','agent edit','reload','narrow layout','reduced motion','malformed project recovery']});+ console.log(`PASS ${name}: ${report.at(-1).workflows.length} workflow checks, ${current.result.artifacts.length} artifacts`);+ }finally{await context.close();await studio.close();}+ }+}finally{await browser.close();await writeFile(join(output,'browser-report.json'),JSON.stringify(report,null,2));if(process.env.KEEP_STUDIO_TEST_WORKSPACES)console.log(`Workspaces: ${root}`);else await rm(root,{recursive:true,force:true});}diff --git a/store/viewers/studio-viewer/web/studio.mjs b/store/viewers/studio-viewer/web/studio.mjsindex aa1b91ba4..749448ae7 100644--- a/store/viewers/studio-viewer/web/studio.mjs+++ b/store/viewers/studio-viewer/web/studio.mjs@@ -1,12 +1,13 @@const $ = id => document.getElementById(id);const text = (tag, value, className) => {const e=document.createElement(tag);e.textContent=value;if(className)e.className=className;return e;};-let state, parameters, domain, dirty=false, selected=null, motion=!matchMedia('(prefers-reduced-motion: reduce)').matches, lastResult='', pending=false;+let state, parameters, domain, draftRevision, dirty=false, selected=null, motion=!matchMedia('(prefers-reduced-motion: reduce)').matches, lastResult='', pending=false;const abort = new AbortController();const artifactURL = path => '/artifacts/'+path.split('/').map(encodeURIComponent).join('/');const announce = message => {$('announcement').textContent=message;};function notice(message, error=false) {$('notice').textContent=message;$('notice').hidden=!message;$('notice').classList.toggle('error',error);}async function api(path, body) {const r=await fetch(path,body ? {method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify(body)}:{});const v=await r.json();if(!r.ok)throw Error(v.error);return v;}function setParameter(id,value) {+ if(!dirty)draftRevision=state.revision;parameters[id]=value;dirty=true;$('dirty').textContent='UNSAVED';const input=document.querySelector(`[name="${CSS.escape(id)}"]`);if(input){input.value=value;input.dispatchEvent(new Event('studio-value'));}domain?.update(parameters,selected??state.result,motion);@@ -14,6 +15,7 @@ function setParameter(id,value) {function controls(config) {$('controls').replaceChildren();for(const c of config.controls){+ if(c.hidden)continue;const label=text('label','', 'control'), head=text('span','', 'control-head'), caption=text('span',c.label), output=text('output','');let input;if(c.type==='select'){input=document.createElement('select');for(const o of c.options){const opt=text('option',o.label);opt.value=o.value;input.append(opt);}}@@ -41,7 +43,7 @@ function renderHistory(){async function run(action){if(pending)return;pending=true;notice('');$('run').disabled=true;- try{await api('/api/run',{action,parameters,revision:state.revision});dirty=false;selected=null;await refresh();announce('Run started.');}catch(e){notice(e.message,true);}finally{pending=false;$('run').disabled=state?.job?.status==='running';}+ try{await api('/api/run',{action,parameters,revision:draftRevision??state.revision});dirty=false;selected=null;await refresh();announce('Run started.');}catch(e){notice(e.message,true);}finally{pending=false;$('run').disabled=state?.job?.status==='running';}}async function refresh(){try{@@ -49,7 +51,7 @@ async function refresh(){const changed=state&&next.revision!==state.revision;if(!state){state=next;parameters={...state.project.parameters};const c=state.config;document.title=c.title+' · Harness';$('title').textContent=c.title;$('description').textContent=c.description;$('category').textContent=c.category.toUpperCase();$('scene-label').textContent=c.scene.toUpperCase();$('hint').textContent=c.hint;$('tip').textContent=c.tip;$('credit').textContent=c.credit;$('run').textContent=c.actions[0].label;for(const [key,value] of Object.entries(c.theme??{}))document.documentElement.style.setProperty('--'+key,value);controls(c);for(const a of c.actions.slice(1)){const b=text('button',a.label);b.type='button';b.title=a.description??a.label;b.addEventListener('click',()=>run(a.id));$('extra-actions').append(b);}const module=await import('/domain.mjs');domain=module.mount($('stage'),{getParameters:()=>parameters,setParameter,announce,artifactURL,signal:abort.signal,run:()=>run(c.actions[0].id)});}state=next;- if(changed&&dirty){$('remote').hidden=false;}else if(changed){parameters={...state.project.parameters};controls(state.config);$('remote').hidden=true;}+ if(changed&&dirty){$('remote').hidden=false;}else if(changed){parameters={...state.project.parameters};draftRevision=state.revision;controls(state.config);$('remote').hidden=true;}$('connection').textContent='Workspace connected';$('app').setAttribute('aria-busy','false');$('dirty').textContent=dirty?'UNSAVED':'SAVED';const running=state.job?.status==='running';$('run').disabled=running||pending;@@ -60,12 +62,12 @@ async function refresh(){else if(state.job?.status==='done')notice('');const stamp=state.result?.id??'';if(stamp!==lastResult||changed||!lastResult){lastResult=stamp;renderResult(selected??state.result);renderHistory();}- }catch(e){$('connection').textContent='Reconnecting';notice(e.message,true);}+ }catch(e){if(!domain){state=null;$('extra-actions').replaceChildren();}$('connection').textContent='Reconnecting';notice(e.message,true);}}$('run').addEventListener('click',()=>run(state.config.actions[0].id));$('controls').addEventListener('submit',e=>e.preventDefault());$('reset').addEventListener('click',()=>{for(const c of state.config.controls)setParameter(c.id,c.value);notice('Controls reset. Run to save a new exploration.');});-$('refresh').addEventListener('click',()=>{parameters={...state.project.parameters};dirty=false;controls(state.config);$('remote').hidden=true;$('dirty').textContent='SAVED';domain.update(parameters,selected??state.result,motion);});+$('refresh').addEventListener('click',()=>{parameters={...state.project.parameters};draftRevision=state.revision;dirty=false;controls(state.config);$('remote').hidden=true;$('dirty').textContent='SAVED';domain.update(parameters,selected??state.result,motion);});$('latest').addEventListener('click',()=>{selected=null;$('latest').hidden=true;renderResult(state.result);renderHistory();});$('motion').addEventListener('click',()=>{motion=!motion;setMotion();});function setMotion(){$('motion').setAttribute('aria-pressed',String(motion));$('motion').textContent=motion?'Pause motion':'Resume motion';domain?.update(parameters,selected??state?.result,motion);}