fix(rfspec): persist results and support fire-and-forget polling#9
Closed
TheFactoriousDROID wants to merge 3 commits intoFactory-AI:masterfrom
Closed
fix(rfspec): persist results and support fire-and-forget polling#9TheFactoriousDROID wants to merge 3 commits intoFactory-AI:masterfrom
TheFactoriousDROID wants to merge 3 commits intoFactory-AI:masterfrom
Conversation
Sends user prompt directly to Opus 4.6 (max), GPT-5.4 (xhigh), and Gemini 3.1 Pro (high) in parallel -- each at its maximum reasoning tier. Presents competing responses and lets the user pick or synthesize. Includes a skill that teaches the agent the full workflow: when to invoke rfspec, how to evaluate and compare results, how to synthesize, and where to save the final spec.
…saving Background droid exec calls failed for Opus because no --auto flag was set, causing permission denial in non-interactive subprocesses. Also, the agent instructions allowed saving specs directly without user review -- now requires ExitSpecMode approval before writing to specs/active/.
The run.sh script spawns three droid exec calls that take several minutes, but the Execute tool times out at 60s. When that happens the temp dir self-destructs and results are lost. Changes: - Write model outputs to persistent ~/.factory/rfspec/runs/<id>/ instead of a temp dir - Print RFSPEC_RUN_DIR path immediately so the agent captures it before timeout - Write a done sentinel (STATUS=complete|failed) for polling - Update SKILL.md (v1.3.0) with fire-and-forget + poll workflow instructions
a7e2bf0 to
9213b79
Compare
Author
|
Merged into #8 (add-rfspec-plugin branch). All timeout/persistence fixes are now included there. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The rfspec
run.shscript spawns threedroid execcalls in parallel (Opus, GPT-5.4, Gemini). These take several minutes to complete, but the Execute tool has a default 60-second timeout. When the timeout hits:trapwhen the script finishesFix
run.sh
~/.factory/rfspec/runs/<timestamp-pid>/instead of a self-destructing temp dirRFSPEC_RUN_DIR=<path>immediately on launch so the agent captures it even if Execute times outdonesentinel file (STATUS=completeorSTATUS=failed) so the parent session can poll for completionSKILL.md (v1.2.0 -> v1.3.0)
fireAndForget=trueon the Execute call<run_dir>/doneevery 30-60s<run_dir>/results.mdwith the Read tool