claude-evolve 1.6.24 → 1.6.26
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/lib/config.py +3 -2
- package/lib/config.sh +14 -12
- package/package.json +1 -1
package/lib/config.py
CHANGED
|
@@ -43,6 +43,9 @@ class Config:
|
|
|
43
43
|
|
|
44
44
|
def load(self, config_path=None, working_dir=None):
|
|
45
45
|
"""Load configuration from YAML file."""
|
|
46
|
+
# Initialize working_dir with a default
|
|
47
|
+
self.working_dir = Path('evolution')
|
|
48
|
+
|
|
46
49
|
# Determine self.working_dir (EVOLUTION_DIR equivalent) based on specified logic
|
|
47
50
|
if working_dir:
|
|
48
51
|
self.working_dir = Path(working_dir)
|
|
@@ -50,8 +53,6 @@ class Config:
|
|
|
50
53
|
self.working_dir = Path('evolution')
|
|
51
54
|
elif Path('./evolution.csv').exists():
|
|
52
55
|
self.working_dir = Path('.')
|
|
53
|
-
else:
|
|
54
|
-
self.working_dir = Path('evolution') # Default
|
|
55
56
|
|
|
56
57
|
# Determine local config file path relative to self.working_dir
|
|
57
58
|
local_config_path = None
|
package/lib/config.sh
CHANGED
|
@@ -172,19 +172,8 @@ _load_yaml_config() {
|
|
|
172
172
|
|
|
173
173
|
# Load configuration from config file
|
|
174
174
|
load_config() {
|
|
175
|
-
# Determine EVOLUTION_DIR based on specified logic
|
|
176
|
-
local user_working_dir="$1"
|
|
177
|
-
if [[ -n "$user_working_dir" ]]; then
|
|
178
|
-
EVOLUTION_DIR="$user_working_dir"
|
|
179
|
-
elif [[ -f "evolution/evolution.csv" ]]; then
|
|
180
|
-
EVOLUTION_DIR="evolution"
|
|
181
|
-
elif [[ -f "./evolution.csv" ]]; then
|
|
182
|
-
EVOLUTION_DIR="."
|
|
183
|
-
else
|
|
184
|
-
EVOLUTION_DIR="$DEFAULT_EVOLUTION_DIR"
|
|
185
|
-
fi
|
|
186
|
-
|
|
187
175
|
# Set defaults first
|
|
176
|
+
EVOLUTION_DIR="$DEFAULT_EVOLUTION_DIR" # Initialize with default
|
|
188
177
|
ALGORITHM_FILE="$DEFAULT_ALGORITHM_FILE"
|
|
189
178
|
EVALUATOR_FILE="$DEFAULT_EVALUATOR_FILE"
|
|
190
179
|
BRIEF_FILE="$DEFAULT_BRIEF_FILE"
|
|
@@ -192,6 +181,16 @@ load_config() {
|
|
|
192
181
|
OUTPUT_DIR="$DEFAULT_OUTPUT_DIR"
|
|
193
182
|
PARENT_SELECTION="$DEFAULT_PARENT_SELECTION"
|
|
194
183
|
PYTHON_CMD="$DEFAULT_PYTHON_CMD"
|
|
184
|
+
|
|
185
|
+
# Determine EVOLUTION_DIR based on specified logic, overriding default if found
|
|
186
|
+
local user_working_dir="$1"
|
|
187
|
+
if [[ -n "$user_working_dir" ]]; then
|
|
188
|
+
EVOLUTION_DIR="$user_working_dir"
|
|
189
|
+
elif [[ -f "evolution/evolution.csv" ]]; then
|
|
190
|
+
EVOLUTION_DIR="evolution"
|
|
191
|
+
elif [[ -f "./evolution.csv" ]]; then
|
|
192
|
+
EVOLUTION_DIR="."
|
|
193
|
+
fi
|
|
195
194
|
|
|
196
195
|
TOTAL_IDEAS="$DEFAULT_TOTAL_IDEAS"
|
|
197
196
|
NOVEL_EXPLORATION="$DEFAULT_NOVEL_EXPLORATION"
|
|
@@ -234,6 +233,8 @@ load_config() {
|
|
|
234
233
|
# Load global config (overrides local config)
|
|
235
234
|
local global_config_file="$HOME/.config/claude-evolve/config.yaml"
|
|
236
235
|
_load_yaml_config "$global_config_file"
|
|
236
|
+
|
|
237
|
+
echo "[DEBUG] EVOLUTION_DIR before FULL_EVOLUTION_DIR calculation: $EVOLUTION_DIR" >&2
|
|
237
238
|
|
|
238
239
|
# Create full paths - ALL paths are relative to EVOLUTION_DIR
|
|
239
240
|
# Make EVOLUTION_DIR absolute if it's relative
|
|
@@ -253,6 +254,7 @@ load_config() {
|
|
|
253
254
|
else
|
|
254
255
|
FULL_OUTPUT_DIR="$FULL_EVOLUTION_DIR"
|
|
255
256
|
fi
|
|
257
|
+
echo "[DEBUG] FULL_EVOLUTION_DIR at end of load_config: $FULL_EVOLUTION_DIR" >&2
|
|
256
258
|
}
|
|
257
259
|
|
|
258
260
|
# Validate configuration
|