claude-evolve 1.11.17 → 1.11.18
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.
- package/README.md +0 -0
- package/bin/claude-evolve-check +1 -1
- package/lib/__pycache__/ai_cli.cpython-311.pyc +0 -0
- package/lib/__pycache__/ai_cli.cpython-314.pyc +0 -0
- package/lib/__pycache__/embedding.cpython-314.pyc +0 -0
- package/lib/__pycache__/evolution_csv.cpython-311.pyc +0 -0
- package/lib/__pycache__/evolution_csv.cpython-313.pyc +0 -0
- package/lib/__pycache__/evolution_csv.cpython-314.pyc +0 -0
- package/lib/__pycache__/evolve_ideate.cpython-314.pyc +0 -0
- package/lib/__pycache__/evolve_run.cpython-311.pyc +0 -0
- package/lib/__pycache__/evolve_run.cpython-314.pyc +0 -0
- package/lib/__pycache__/evolve_worker.cpython-314.pyc +0 -0
- package/lib/__pycache__/llm_bandit.cpython-314.pyc +0 -0
- package/lib/__pycache__/log.cpython-311.pyc +0 -0
- package/lib/__pycache__/log.cpython-314.pyc +0 -0
- package/lib/__pycache__/meta_learning.cpython-314.pyc +0 -0
- package/lib/__pycache__/sandbox_wrapper.cpython-314.pyc +0 -0
- package/lib/ai-cli.sh +3 -3
- package/lib/ai_cli.py +0 -0
- package/lib/config.py +0 -0
- package/lib/config.sh +1 -1
- package/lib/csv-lock.sh +0 -0
- package/lib/editor.sh +0 -0
- package/lib/evolution_csv.py +0 -0
- package/lib/evolution_processor.py +0 -0
- package/lib/evolve_ideate.py +0 -0
- package/lib/evolve_run.py +5 -1
- package/lib/evolve_worker.py +7 -1
- package/lib/llm_bandit.py +21 -5
- package/lib/log.py +0 -0
- package/lib/meta_learning.py +0 -0
- package/lib/sandbox.sb +0 -0
- package/lib/sandbox_wrapper.py +0 -0
- package/package.json +1 -1
- package/templates/BRIEF.md +0 -0
- package/templates/algorithm.py +0 -0
- package/templates/config.yaml +0 -0
- package/templates/evaluator.py +0 -0
- package/lib/__pycache__/ai_cli.cpython-310.pyc +0 -0
- package/lib/__pycache__/embedding.cpython-310.pyc +0 -0
- package/lib/__pycache__/evolution_csv.cpython-310.pyc +0 -0
- package/lib/__pycache__/evolve_ideate.cpython-310.pyc +0 -0
- package/lib/__pycache__/log.cpython-310.pyc +0 -0
package/README.md
CHANGED
|
File without changes
|
package/bin/claude-evolve-check
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/lib/ai-cli.sh
CHANGED
|
@@ -252,7 +252,7 @@ $prompt"
|
|
|
252
252
|
ai_output=$(opencode -m openrouter/moonshotai/kimi-k2.5 run "$prompt" 2>&1)
|
|
253
253
|
local ai_exit_code=$?
|
|
254
254
|
;;
|
|
255
|
-
qwen)
|
|
255
|
+
qwen-openrouter)
|
|
256
256
|
local ai_output
|
|
257
257
|
# Qwen latest - Alibaba's flagship model (currently qwen3.5-plus)
|
|
258
258
|
# Linear attention + sparse MoE, strong multimodal capabilities
|
|
@@ -288,8 +288,8 @@ $prompt"
|
|
|
288
288
|
echo "[AI] Raw output from $model_name:" >&2
|
|
289
289
|
echo "----------------------------------------" >&2
|
|
290
290
|
if [[ ${#ai_output} -gt 2000 ]]; then
|
|
291
|
-
echo "$ai_output
|
|
292
|
-
echo "
|
|
291
|
+
echo "... (truncated from ${#ai_output} characters to last 50 lines) ..." >&2
|
|
292
|
+
echo "$ai_output" | tail -50 >&2
|
|
293
293
|
else
|
|
294
294
|
echo "$ai_output" >&2
|
|
295
295
|
fi
|
package/lib/ai_cli.py
CHANGED
|
File without changes
|
package/lib/config.py
CHANGED
|
File without changes
|
package/lib/config.sh
CHANGED
|
@@ -68,7 +68,7 @@ DEFAULT_LLM_RUN_FALLBACK="haiku glm-5-zai gemini-5-flash gpt-5.3-codex-spark"
|
|
|
68
68
|
#
|
|
69
69
|
# Ideate: Agentic models that can edit files for ideation
|
|
70
70
|
# All CLI tools (opencode, claude, gemini, kimi) are agentic and can edit files
|
|
71
|
-
DEFAULT_LLM_IDEATE="opus-think glm-5-zai gemini-pro kimi-coder gpt-5.2 gpt-5.3-codex"
|
|
71
|
+
DEFAULT_LLM_IDEATE="opus-think glm-5-zai gemini-pro kimi-coder gpt-5.2 gpt-5.3-codex qwen-openrouter"
|
|
72
72
|
DEFAULT_LLM_IDEATE_FALLBACK="haiku glm-5-zai gemini-5-flash gpt-5.3-codex-spark"
|
|
73
73
|
|
|
74
74
|
# Load configuration from a YAML file and update variables
|
package/lib/csv-lock.sh
CHANGED
|
File without changes
|
package/lib/editor.sh
CHANGED
|
File without changes
|
package/lib/evolution_csv.py
CHANGED
|
File without changes
|
|
File without changes
|
package/lib/evolve_ideate.py
CHANGED
|
File without changes
|
package/lib/evolve_run.py
CHANGED
|
@@ -71,7 +71,11 @@ class WorkerPool:
|
|
|
71
71
|
try:
|
|
72
72
|
# Don't capture output - let it stream directly to terminal
|
|
73
73
|
# This provides real-time visibility into which models are being used
|
|
74
|
-
|
|
74
|
+
# AIDEV-NOTE: Explicitly pass stdin=DEVNULL so workers don't inherit
|
|
75
|
+
# a closed/bad stdin FD from parent (e.g. when run via nohup or after
|
|
76
|
+
# terminal disconnect). Without this, Python workers crash at startup
|
|
77
|
+
# with "OSError: [Errno 9] Bad file descriptor" on sys stream init.
|
|
78
|
+
proc = subprocess.Popen(cmd, stdin=subprocess.DEVNULL)
|
|
75
79
|
self.workers[proc.pid] = proc
|
|
76
80
|
log(f"Spawned worker {proc.pid}")
|
|
77
81
|
return proc.pid
|
package/lib/evolve_worker.py
CHANGED
|
@@ -205,9 +205,15 @@ CRITICAL: If you do not know how to implement what was asked for, or if the requ
|
|
|
205
205
|
preview = output[-300:] if output else "(empty)"
|
|
206
206
|
log(f"Bandit model {selected_model} completed but didn't modify file ({len(output)} chars), trying fallback...")
|
|
207
207
|
log(f"AI output preview: {preview}")
|
|
208
|
+
# AIDEV-NOTE: Report no-modification as failure to bandit
|
|
209
|
+
self.bandit.update(selected_model, child_score=None, parent_score=self._parent_score)
|
|
210
|
+
log(f"Bandit update: {selected_model} no file modification")
|
|
208
211
|
|
|
209
212
|
except AIError as e:
|
|
210
213
|
log(f"Bandit model {selected_model} failed: {e}, trying fallback...")
|
|
214
|
+
# AIDEV-NOTE: Report AI-level failure to bandit so it learns to avoid broken models
|
|
215
|
+
self.bandit.update(selected_model, child_score=None, parent_score=self._parent_score)
|
|
216
|
+
log(f"Bandit update: {selected_model} AI call failed")
|
|
211
217
|
|
|
212
218
|
# Fallback to round-based retry with all models
|
|
213
219
|
try:
|
|
@@ -229,7 +235,7 @@ CRITICAL: If you do not know how to implement what was asked for, or if the requ
|
|
|
229
235
|
return True, model
|
|
230
236
|
else:
|
|
231
237
|
# AIDEV-NOTE: Log output so we can diagnose why file wasn't modified
|
|
232
|
-
preview = output[:
|
|
238
|
+
preview = output[-300:] if output else "(empty)"
|
|
233
239
|
log(f"AI completed but did not modify file ({len(output)} chars)")
|
|
234
240
|
log(f"AI output preview: {preview}")
|
|
235
241
|
return False, model
|
package/lib/llm_bandit.py
CHANGED
|
@@ -86,6 +86,12 @@ class LLMBandit:
|
|
|
86
86
|
# Baseline score for normalizing improvements
|
|
87
87
|
self._baseline_score: float = 0.0
|
|
88
88
|
|
|
89
|
+
# AIDEV-NOTE: Decay counter - only apply decay every N updates to prevent
|
|
90
|
+
# aggressive memory loss. With decay_factor=0.95 applied every update,
|
|
91
|
+
# n_completed floors at 1 after ~50 updates and the bandit can't learn.
|
|
92
|
+
self._updates_since_decay: int = 0
|
|
93
|
+
self._decay_interval: int = 50 # Apply decay every 50 updates
|
|
94
|
+
|
|
89
95
|
# Load existing state if available
|
|
90
96
|
if state_file and Path(state_file).exists():
|
|
91
97
|
self.load()
|
|
@@ -215,13 +221,23 @@ class LLMBandit:
|
|
|
215
221
|
return improvement
|
|
216
222
|
|
|
217
223
|
def _apply_decay(self) -> None:
|
|
218
|
-
"""Apply decay to reduce influence of old observations.
|
|
224
|
+
"""Apply decay to reduce influence of old observations.
|
|
225
|
+
|
|
226
|
+
AIDEV-NOTE: Only applies every _decay_interval updates to prevent
|
|
227
|
+
aggressive memory loss. The int() truncation on n_completed was
|
|
228
|
+
destroying the bandit's ability to learn from failures.
|
|
229
|
+
"""
|
|
230
|
+
self._updates_since_decay += 1
|
|
231
|
+
if self._updates_since_decay < self._decay_interval:
|
|
232
|
+
return
|
|
233
|
+
|
|
234
|
+
self._updates_since_decay = 0
|
|
219
235
|
for stats in self.models.values():
|
|
220
|
-
# Decay
|
|
236
|
+
# Decay totals to reduce influence of old observations
|
|
221
237
|
stats.total_improvement *= self.decay_factor
|
|
222
|
-
#
|
|
223
|
-
if stats.n_completed >
|
|
224
|
-
stats.n_completed = max(
|
|
238
|
+
# Decay counts but preserve enough memory to differentiate models
|
|
239
|
+
if stats.n_completed > 2:
|
|
240
|
+
stats.n_completed = max(2, int(stats.n_completed * self.decay_factor))
|
|
225
241
|
|
|
226
242
|
def save(self) -> None:
|
|
227
243
|
"""Persist state to file."""
|
package/lib/log.py
CHANGED
|
File without changes
|
package/lib/meta_learning.py
CHANGED
|
File without changes
|
package/lib/sandbox.sb
CHANGED
|
File without changes
|
package/lib/sandbox_wrapper.py
CHANGED
|
File without changes
|
package/package.json
CHANGED
package/templates/BRIEF.md
CHANGED
|
File without changes
|
package/templates/algorithm.py
CHANGED
|
File without changes
|
package/templates/config.yaml
CHANGED
|
File without changes
|
package/templates/evaluator.py
CHANGED
|
File without changes
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|