You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(rfspec): persist results and support fire-and-forget polling
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
Where `<slug>` is a short kebab-case name derived from the topic.
45
88
89
+
## Resuming from slash command
90
+
91
+
If you are loading this skill after `/rfspec` already ran (the slash command told
92
+
you to invoke `Skill: rfspec`), you already have the run directory. Pick up from
93
+
Step 3:
94
+
95
+
1. Read `<run_dir>/results.md` to get the model outputs.
96
+
2. Follow Step 4 (evaluate and present) and Step 5 (finalize) below.
97
+
98
+
The `results.md` file includes embedded agent instructions as a fallback, but
99
+
prefer the full workflow in this document -- it covers the evaluation guide,
100
+
saving rules, and rejection handling that the embedded version omits.
101
+
46
102
## Pitfalls
47
103
48
104
- Don't summarize each option individually -- compare them against each other.
@@ -63,29 +119,31 @@ Example 1: User wants competing specs
63
119
User says: "Get me specs from multiple models for adding a dark mode toggle"
64
120
Actions:
65
121
66
-
1. Run `/rfspec add a dark mode toggle to the settings page with persistent user preference`
67
-
2. Read Options A, B, C
68
-
3. Compare: "Option A uses CSS variables with a React context, Option B uses Tailwind's dark class with localStorage, Option C uses a theme provider with system preference detection."
69
-
4. Present choice via AskUser
70
-
Result: User picks Option B, saved to `specs/active/2026-03-06-dark-mode-toggle.md`
122
+
1. Execute `/rfspec add a dark mode toggle ...` with `fireAndForget=true`
123
+
2. Read the background log to get `RFSPEC_RUN_DIR`
124
+
3. Tell user: "Models are running, I'll check back shortly."
125
+
4. Poll `<run_dir>/done` until `STATUS=complete`
126
+
5. Read `<run_dir>/results.md`, compare Options A, B, C
127
+
6. Present choice via AskUser
128
+
Result: User picks Option B, saved to `specs/active/2026-03-06-dark-mode-toggle.md`
71
129
72
130
Example 2: User wants synthesis
73
131
User says: "rfspec this: refactor the auth module to use JWT"
74
132
Actions:
75
133
76
-
1.Run `/rfspec refactor the auth module to use JWT`
77
-
2.Compare results, noting Option A has better token rotation but Option C has cleaner middleware
134
+
1.Launch background, poll for completion
135
+
2.Read results, compare -- Option A has better token rotation, Option C has cleaner middleware
0 commit comments