galaxyproject / galaxyproject/loom

Orbit: provide an async invocation-wait primitive + idle re-nudge (agent blocks on bash `sleep` loops and stalls 30 min–2 h)

Open
#215 1 comment 0 reactions 0 assignees View on GitHub
bug
Dominant language
TypeScript
Stars
14
Forks
12
Avg merge
6d 5h
Merged PRs (30d)
17

Description

_Context: from a controlled experiment in which eight frontier models (opus, sonnet, gpt, gpt2, gemini-2.5-pro, gemini-3.5-flash, deepseek, haiku) each drove an Orbit session to reanalyze the same RNA-seq dataset (Santana 2023 *C. auris*) on 2026-06-02–04. Evidence quotes are from the per-run `activity.jsonl` logs._

## Problem

The brain's only way to wait for a Galaxy invocation is a **blocking bash `sleep` loop**. These either time out, crash on a parse error mid-loop, or the agent simply abandons the wait and then sits idle with no harness re-nudge. Across the 8-model experiment this was the single biggest wall-clock sink.

## Evidence

- **opus**: a poll loop ran 16:35:28 → 17:05:01 (29.6 min) and died on a `json.JSONDecodeError`, never exiting.
- **gemini-3.5-flash**: ~2 h unexplained gap (15:11:59 → 17:09:10) — agent issued a text summary and made no further tool calls; harness logged no error. Broken only when the human typed "count table is ready."
- **gemini-2.5-pro**: stalled ~1 h 14 m after a `urllib` Traceback at 21:05, requiring three re-prompts across two restarts.
- **deepseek**: 9 m 44 s with no tool call after a dead end; user had to say "try again."

## Impact

High. Every long-running workflow (the IWC `rnaseq-pe` run is ~27 steps) risks a multi-hour silent stall that only a human can break — defeating autonomy.

## Proposed direction

- A first-class `galaxy_invocation_wait` (or brain-level await) that polls with backoff and returns on terminal state, instead of the agent hand-rolling bash `sleep`.
- An idle watchdog: if the agent emits no tool call for N minutes while an invocation is non-terminal, auto-poll and re-nudge rather than waiting for the user.

## Related

Adjacent to #210 (job errors not proactive), #70 (process monitor empties on detached work), #72 (resume-hardening after idle) — but none provides the missing async-wait primitive + self-resume.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.