diff --git a/scripts/small_repos/run_claude.sh b/scripts/small_repos/run_claude.sh index 9f1a1c1e7..fe3651310 100644 --- a/scripts/small_repos/run_claude.sh +++ b/scripts/small_repos/run_claude.sh @@ -9,7 +9,7 @@ if [ $# -ne 1 ]; then fi directory="$1" -MODEL="codex-mini-latest" +ANTHROPIC_MODEL="claude-3-7-sonnet-20250219" if [ ! -d "$directory" ]; then echo "Error: Directory '$directory' does not exist" @@ -39,8 +39,9 @@ echo "Following the instructions in $base_dir/REFACTOR_INSTRUCTIONS.md..." echo "Running claude planner" # Claude plan -claude --dangerously-skip-permissions -p \ - "Follow the instructions in ../../../prompts/REFACTOR_INSTRUCTIONS.md. Only write PLAN.md. Give the file structure. Do not implement any code. Do not give example usage code." +claude --dangerously-skip-permissions -p </dev/null # Now that it's been refactored, remove all original persona subdirs @@ -70,8 +72,9 @@ pytest tests/ --json-report --json-report-file=report.json --continue-on-collect echo "Running final-check claude impl" # claude implement -claude --dangerously-skip-permissions -p \ - "Read the pytest results in test_output.txt. If they indicate pytest failures, fix them. Stick to the implementation plan and file structure proposed in PLAN.md. IMPORTANT: Create and modify files ONLY in this current working subdirectory ($new_directory/unified) and nowhere else. Implement ALL code and update ALL test file imports until this whole subfolder is a functional standalone repository. Do not stop to ask for confirmation; keep going until the final implementation passes all tests using pytest tests/. If there are no errors, exit." +claude --dangerously-skip-permissions -p < test_output.txt 2>&1 deactivate diff --git a/scripts/small_repos/run_codex.sh b/scripts/small_repos/run_codex.sh index 139133a1d..4f3f9fda4 100644 --- a/scripts/small_repos/run_codex.sh +++ b/scripts/small_repos/run_codex.sh @@ -41,8 +41,7 @@ echo "Following the instructions in $base_dir/prompts/REFACTOR_INSTRUCTIONS.md.. echo "Running codex planner" # Codex plan -codex --approval-mode full-auto -q \ - "Follow the instructions in ../../../prompts/REFACTOR_INSTRUCTIONS.md. Only write PLAN.md. Give the file structure. Do not implement any code. Do not give example usage code." +codex --approval-mode full-auto -q "Follow the instructions in ../../../prompts/REFACTOR_INSTRUCTIONS.md. Only write PLAN.md. Give the file structure. Do not implement any code. Do not give example usage code." # Setup testing environment uv venv @@ -51,8 +50,7 @@ uv pip install -e . echo "Running codex impl" # Codex implement -codex --approval-mode full-auto -q \ - "Read the instructions in ../../../prompts/REFACTOR_INSTRUCTIONS.md. Follow the implementation plan and file structure proposed in PLAN.md. IMPORTANT: Create, modify, and reference files ONLY in this current working subdirectory ($new_directory/unified) and nowhere else. Do NOT import from any other subdirectories in $new_directory except for what is here in unified/. Implement ALL code and update ALL test file imports until this whole subfolder is a functional standalone repository. Do not stop to ask for confirmation; keep going until the final implementation passes all tests using pytest tests/." +codex --approval-mode full-auto -q "Read the instructions in ../../../prompts/REFACTOR_INSTRUCTIONS.md. Follow the implementation plan and file structure proposed in PLAN.md. IMPORTANT: Create, modify, and reference files ONLY in this current working subdirectory ($new_directory/unified) and nowhere else. Do NOT import from any other subdirectories in $new_directory except for what is here in unified/. Implement ALL code and update ALL test file imports until this whole subfolder is a functional standalone repository. Do not stop to ask for confirmation; keep going until the final implementation passes all tests using pytest tests/." popd >/dev/null # Now that it's been refactored, remove all original persona subdirs @@ -71,8 +69,7 @@ pytest tests/ --json-report --json-report-file=report.json --continue-on-collect echo "Running final-check codex impl" # Codex implement -codex --approval-mode full-auto -q \ - "Read the pytest results in test_output.txt. If they indicate pytest failures, fix them. Stick to the implementation plan and file structure proposed in PLAN.md. IMPORTANT: Create and modify files ONLY in this current working subdirectory ($new_directory/unified) and nowhere else. Implement ALL code and update ALL test file imports until this whole subfolder is a functional standalone repository. Do not stop to ask for confirmation; keep going until the final implementation passes all tests using pytest tests/. If there are no errors, exit." +codex --approval-mode full-auto -q "Read the pytest results in test_output.txt. If they indicate pytest failures, fix them. Stick to the implementation plan and file structure proposed in PLAN.md. IMPORTANT: Create and modify files ONLY in this current working subdirectory ($new_directory/unified) and nowhere else. Implement ALL code and update ALL test file imports until this whole subfolder is a functional standalone repository. Do not stop to ask for confirmation; keep going until the final implementation passes all tests using pytest tests/. If there are no errors, exit." pytest tests/ --json-report --json-report-file=report.json --continue-on-collection-errors > test_output.txt 2>&1 deactivate