@nbardy/oompa 0.4.2 → 0.4.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -136,23 +136,31 @@
136
136
  (declare cmd-swarm parse-model-string)
137
137
 
138
138
  (defn- probe-model
139
- "Send 'say ok' to a model via its harness CLI. Returns true if model responds."
139
+ "Send 'say ok' to a model via its harness CLI. Returns true if model responds.
140
+ Claude hangs without /dev/null stdin when spawned from bb."
140
141
  [harness model]
141
142
  (try
142
143
  (let [cmd (case harness
143
- :claude ["claude" "--model" model "-p" "say ok"]
144
+ :claude ["claude" "--model" model "-p" "say ok" "--max-turns" "1"]
144
145
  :codex ["codex" "exec" "--dangerously-bypass-approvals-and-sandbox" "--skip-git-repo-check" "--model" model "--" "say ok"])
145
- result (process/sh cmd {:out :string :err :string :timeout 30000})]
146
- (zero? (:exit result)))
146
+ null-in (io/input-stream (io/file "/dev/null"))
147
+ proc (process/process cmd {:out :string :err :string :in null-in})
148
+ result (deref proc 30000 :timeout)]
149
+ (if (= result :timeout)
150
+ (do (.destroyForcibly (:proc proc)) false)
151
+ (zero? (:exit result))))
147
152
  (catch Exception _ false)))
148
153
 
149
154
  (defn- validate-models!
150
155
  "Probe each unique harness:model pair. Prints results and exits if any fail."
151
156
  [worker-configs review-model]
152
- (let [models (cond-> (set (map (fn [wc]
153
- (parse-model-string (:model wc)))
154
- worker-configs))
155
- review-model (conj review-model))
157
+ (let [;; Deduplicate by harness:model only (ignore reasoning level)
158
+ models (cond-> (->> worker-configs
159
+ (map (fn [wc]
160
+ (let [{:keys [harness model]} (parse-model-string (:model wc))]
161
+ {:harness harness :model model})))
162
+ set)
163
+ review-model (conj (select-keys review-model [:harness :model])))
156
164
  _ (println "Validating models...")
157
165
  results (pmap (fn [{:keys [harness model]}]
158
166
  (let [ok (probe-model harness model)]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nbardy/oompa",
3
- "version": "0.4.2",
3
+ "version": "0.4.4",
4
4
  "description": "Git-worktree multi-agent swarm orchestrator for Codex and Claude",
5
5
  "license": "MIT",
6
6
  "type": "commonjs",