From 59eb0f8843d9b813b766fbb0e72b63b1e410bac8 Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 12:39:47 -0500 Subject: [PATCH 1/9] don't spam us --- AGENTS.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/AGENTS.md b/AGENTS.md index fe6acacc4..f3d2b0deb 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -317,6 +317,23 @@ Language Server Protocol support in `codeflash/lsp/` enables IDE integration dur - Use benchmarks to validate improvements - Generate detailed performance reports +### PR Review Comments +When reviewing pull requests: +- Make a **single comment** per PR review, consolidating all feedback into one comment +- If an existing review comment from you already exists on the PR, **update that comment** instead of creating a new one +- Never spam PRs with multiple separate comments + +### Comments and Documentation +- Keep comments and docstrings to a minimum +- Only add comments where the logic is not self-evident +- Do not add docstrings to functions unless explicitly requested +- Code should be self-documenting through clear naming and structure + +### Naming Conventions +- Prefer public function names over private (no leading underscore) +- Python doesn't have true private functions, so avoid `_function_name` patterns unless there's a strong reason +- Use clear, descriptive names that make the code self-documenting + # Agent Rules @.tessl/RULES.md follow the [instructions](.tessl/RULES.md) From 00710687204a8142c128afe92507b2545afd9f3e Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 12:46:18 -0500 Subject: [PATCH 2/9] consolidate sections --- AGENTS.md | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index f3d2b0deb..6b8e3c9d8 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -219,6 +219,10 @@ uv run codeflash --replay-test tests/specific_test.py - Pre-commit hooks enforce code quality - Line length: 120 characters - Python 3.10+ syntax +- Keep comments and docstrings to a minimum +- **Inline comments**: Only add where the logic is not self-evident (explain "why", not "what") +- **Docstrings**: Do not add to functions unless explicitly requested - function names should be self-explanatory +- Code should be self-documenting through clear naming and structure ### Testing Strategy - Primary test framework: pytest @@ -319,16 +323,11 @@ Language Server Protocol support in `codeflash/lsp/` enables IDE integration dur ### PR Review Comments When reviewing pull requests: +- **Limit your review to the changes in the PR** - only review the code that was actually modified in the commits, not other parts of the codebase - Make a **single comment** per PR review, consolidating all feedback into one comment -- If an existing review comment from you already exists on the PR, **update that comment** instead of creating a new one +- If an existing review comment from you already exists on the PR, **edit that existing comment** instead of creating a new one - Never spam PRs with multiple separate comments -### Comments and Documentation -- Keep comments and docstrings to a minimum -- Only add comments where the logic is not self-evident -- Do not add docstrings to functions unless explicitly requested -- Code should be self-documenting through clear naming and structure - ### Naming Conventions - Prefer public function names over private (no leading underscore) - Python doesn't have true private functions, so avoid `_function_name` patterns unless there's a strong reason From 9845a9d95aa88788f7c8223c5b23d65d0341669a Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 12:53:40 -0500 Subject: [PATCH 3/9] cleanup agents.md --- AGENTS.md | 349 +++++++----------------------------------------------- 1 file changed, 43 insertions(+), 306 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 6b8e3c9d8..005f66962 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,113 +1,46 @@ # CodeFlash AI Agent Instructions -This file provides comprehensive guidance to any coding agent (Warp, GitHub Copilot, Claude, Gemini, etc.) when working with the CodeFlash repository. - ## Project Overview -CodeFlash is an AI-powered Python code optimizer that automatically improves code performance while maintaining correctness. It uses LLMs to analyze code, generate optimization ideas, validate correctness through comprehensive testing, benchmark performance improvements, and create merge-ready pull requests. - -**Key Capabilities:** -- Optimize entire codebases with `codeflash --all` -- Optimize specific files or functions with targeted commands -- End-to-end workflow optimization with `codeflash optimize script.py` -- Automated GitHub Actions integration for CI/CD pipelines -- Comprehensive benchmarking and performance analysis -- Git worktree isolation for safe optimization - -## Core Architecture - -### Data Flow Pipeline -Discovery → Context → Optimization → Verification → Benchmarking → PR - -1. **Discovery** (`codeflash/discovery/`) - Find optimizable functions via static analysis or execution tracing -2. **Context Extraction** (`codeflash/context/`) - Extract dependencies, imports, and related code -3. **Optimization** (`codeflash/optimization/`) - Generate optimized code via AI service calls -4. **Verification** (`codeflash/verification/`) - Run deterministic tests with custom pytest plugin -5. **Benchmarking** (`codeflash/benchmarking/`) - Performance measurement and comparison -6. **GitHub Integration** (`codeflash/github/`) - Automated PR creation with detailed analysis - -### Key Components - -**Main Entry Points:** -- `codeflash/main.py` - CLI entry point and main orchestration -- `codeflash/cli_cmds/cli.py` - Command-line argument parsing and validation - -**Core Optimization Pipeline:** -- `codeflash/optimization/optimizer.py` - Main optimization orchestrator -- `codeflash/optimization/function_optimizer.py` - Individual function optimization -- `codeflash/tracing/` - Function call tracing and profiling - -**Code Analysis & Manipulation:** -- `codeflash/code_utils/` - Code parsing, AST manipulation, static analysis -- `codeflash/context/` - Code context extraction and analysis -- `codeflash/verification/` - Code correctness verification through testing - -**External Integrations:** -- `codeflash/api/aiservice.py` - LLM communication with rate limiting and retries -- `codeflash/github/` - GitHub integration for PR creation -- `codeflash/benchmarking/` - Performance benchmarking and measurement +CodeFlash is an AI-powered Python code optimizer that automatically improves code performance while maintaining correctness. -**Supporting Systems:** -- `codeflash/models/models.py` - Pydantic models and type definitions -- `codeflash/telemetry/` - Usage analytics (PostHog) and error reporting (Sentry) -- `codeflash/ui/` - User interface components (Rich console output) -- `codeflash/lsp/` - Language Server Protocol support for IDE integration +## Architecture -### Key Optimization Workflows - -**1. Full Codebase Optimization (`--all`)** -- Discovers all optimizable functions in the project -- Runs benchmarks if configured -- Optimizes functions in parallel -- Creates PRs for successful optimizations - -**2. Targeted Optimization (`--file`, `--function`)** -- Focuses on specific files or functions -- Performs detailed analysis and context extraction -- Applies targeted optimizations - -**3. Workflow Tracing (`optimize`)** -- Traces Python script execution -- Identifies performance bottlenecks -- Generates optimizations for traced functions -- Uses checkpoint system to resume interrupted runs +``` +codeflash/ +├── main.py # CLI entry point +├── cli_cmds/ # Command handling, console output (Rich) +├── discovery/ # Find optimizable functions +├── context/ # Extract code dependencies and imports +├── optimization/ # Generate optimized code via AI +├── verification/ # Run deterministic tests (pytest plugin) +├── benchmarking/ # Performance measurement +├── github/ # PR creation +├── api/ # AI service communication +├── code_utils/ # Code parsing, git utilities +├── models/ # Pydantic models and types +├── tracing/ # Function call tracing +├── lsp/ # IDE integration +├── telemetry/ # Sentry, PostHog +└── either.py # Functional error handling +``` ## Critical Development Patterns -### Package Management with uv (NOT pip) +### Use uv, not pip ```bash -# Always use uv, never pip uv sync # Install dependencies -uv sync --group dev # Install dev dependencies +uv sync --group dev # Dev dependencies uv run pytest # Run commands -uv add package # Add new packages -uv build # Build package +uv add package # Add packages ``` -### Code Manipulation with LibCST (NOT ast) -Always use `libcst` for code parsing/modification to preserve formatting: -```python -from libcst import parse_module, PartialPythonCodeGen -# Never use ast module for code transformations -``` - -### Testing with Deterministic Execution -Custom pytest plugin (`codeflash/verification/pytest_plugin.py`) ensures reproducible tests: -- Patches time, random, uuid for deterministic behavior -- Environment variables: `CODEFLASH_TEST_MODULE`, `CODEFLASH_TEST_CLASS`, `CODEFLASH_TEST_FUNCTION` -- Always use `uv run pytest`, never `python -m pytest` - -### Git Worktree Isolation -Optimizations run in isolated git worktrees to avoid affecting main repo: -```python -from codeflash.code_utils.git_utils import create_detached_worktree, remove_worktree -# Pattern: create_detached_worktree() → optimize → create_diff_patch_from_worktree() -``` +### Use libcst, not ast +Always use `libcst` for code parsing/modification to preserve formatting. -### Error Handling with Either Pattern -Use functional error handling instead of exceptions: +### Use Either pattern for errors ```python -from codeflash.either import is_successful, Either +from codeflash.either import is_successful result = aiservice_client.call_llm(...) if is_successful(result): optimized_code = result.value @@ -115,223 +48,27 @@ else: error = result.error ``` -## Configuration - -All configuration in `pyproject.toml` under `[tool.codeflash]`: -```toml -[tool.codeflash] -module-root = "codeflash" # Source code location -tests-root = "tests" # Test directory -benchmarks-root = "tests/benchmarks" # Benchmark tests -test-framework = "pytest" # Always pytest -formatter-cmds = [ # Auto-formatting commands - "uvx ruff check --exit-zero --fix $file", - "uvx ruff format $file", -] -``` - -## Development Commands - -### Environment Setup -```bash -# Install dependencies (always use uv) -uv sync - -# Install development dependencies -uv sync --group dev - -# Install pre-commit hooks -uv run pre-commit install -``` - -### Code Quality & Linting -```bash -# Run linting and formatting with ruff (primary tool) -uv run ruff check --fix . -uv run ruff format . - -# Type checking with mypy (strict mode) -uv run mypy . - -# Clean Python cache files -uvx pyclean . -``` - -### Testing -```bash -# Run all tests -uv run pytest - -# Run tests with coverage -uv run coverage run -m pytest tests/ - -# Run specific test file -uv run pytest tests/test_code_utils.py - -# Run tests with verbose output -uv run pytest -v - -# Run benchmarks -uv run pytest tests/benchmarks/ - -# Run end-to-end tests -uv run pytest tests/scripts/ - -# Run with specific markers -uv run pytest -m "not ci_skip" -``` - -### Running CodeFlash -```bash -# Initialize CodeFlash in a project -uv run codeflash init - -# Optimize entire codebase -uv run codeflash --all - -# Optimize specific file -uv run codeflash --file path/to/file.py - -# Optimize specific function -uv run codeflash --file path/to/file.py --function function_name - -# Trace and optimize a workflow -uv run codeflash optimize script.py - -# Verify setup with test optimization -uv run codeflash --verify-setup - -# Run with verbose logging -uv run codeflash --verbose --all - -# Run with benchmarking enabled -uv run codeflash --benchmark --file target_file.py - -# Use replay tests for debugging -uv run codeflash --replay-test tests/specific_test.py -``` - -## Development Guidelines - -### Code Style -- Uses Ruff for linting and formatting (configured in pyproject.toml) -- Strict mypy type checking enabled -- Pre-commit hooks enforce code quality -- Line length: 120 characters -- Python 3.10+ syntax -- Keep comments and docstrings to a minimum -- **Inline comments**: Only add where the logic is not self-evident (explain "why", not "what") -- **Docstrings**: Do not add to functions unless explicitly requested - function names should be self-explanatory -- Code should be self-documenting through clear naming and structure - -### Testing Strategy -- Primary test framework: pytest -- Tests located in `tests/` directory -- End-to-end tests in `tests/scripts/` -- Benchmarks in `tests/benchmarks/` -- Extensive use of `@pytest.mark.parametrize` -- Shared fixtures in conftest.py -- Test isolation via custom pytest plugin - -### Key Dependencies -- **Core**: `libcst`, `jedi`, `gitpython`, `pydantic` -- **Testing**: `pytest`, `coverage`, `crosshair-tool` -- **Performance**: `line_profiler`, `timeout-decorator` -- **UI**: `rich`, `inquirer`, `click` -- **AI**: Custom API client for LLM interactions - -### Data Models & Types -- `codeflash/models/models.py` - Pydantic models for all data structures -- Extensive use of `@dataclass(frozen=True)` for immutable data -- Core types: `FunctionToOptimize`, `ValidCode`, `BenchmarkKey` - -## AI Service Integration - -### Rate Limiting & Retries -- Built-in rate limiting and exponential backoff -- Handle `Either` return types for error handling -- AI service endpoint: `codeflash/api/aiservice.py` - -### Telemetry & Monitoring -- **Sentry**: Error tracking with `codeflash.telemetry.sentry` -- **PostHog**: Usage analytics with `codeflash.telemetry.posthog_cf` -- **Environment Variables**: `CODEFLASH_EXPERIMENT_ID` for testing modes - -## Performance & Benchmarking - -### Line Profiler Integration -- Uses `line_profiler` for detailed performance analysis -- Instruments functions with `@profile` decorator -- Generates before/after profiling reports -- Calculates precise speedup measurements - -### Benchmark Test Framework -- Custom benchmarking in `tests/benchmarks/` -- Generates replay tests from execution traces -- Validates performance improvements statistically - -## Debugging & Development - -### Verbose Logging -```bash -uv run codeflash --verbose --file target_file.py +### Git worktree isolation +Optimizations run in isolated worktrees: +```python +from codeflash.code_utils.git_worktree_utils import create_detached_worktree, remove_worktree ``` -### Important Environment Variables -- `CODEFLASH_TEST_MODULE` - Current test module during verification -- `CODEFLASH_TEST_CLASS` - Current test class during verification -- `CODEFLASH_TEST_FUNCTION` - Current test function during verification -- `CODEFLASH_LOOP_INDEX` - Current iteration in pytest loops -- `CODEFLASH_EXPERIMENT_ID` - Enables local AI service for testing - -### LSP Integration -Language Server Protocol support in `codeflash/lsp/` enables IDE integration during optimization. - -### Common Debugging Patterns -1. Use verbose logging to trace optimization flow -2. Check git worktree operations for isolation issues -3. Verify deterministic test execution with environment variables -4. Use replay tests to debug specific optimization scenarios -5. Monitor AI service calls with rate limiting logs - -## Best Practices - -### Path Handling -- Always use absolute paths -- Handle encoding explicitly (UTF-8) -- Extensive path validation and cleanup utilities in `codeflash/code_utils/` - -### Git Operations -- All optimizations run in isolated worktrees -- Never modify the main repository directly -- Use git utilities in `codeflash/code_utils/git_utils.py` - -### Code Transformations -- Always use libcst, never ast module -- Preserve code formatting and comments -- Validate transformations with deterministic tests - -### Error Handling -- Use Either pattern for functional error handling -- Log errors to Sentry for monitoring -- Provide clear user feedback via Rich console +## Code Style & Conventions -### Performance Optimization -- Profile before and after changes -- Use benchmarks to validate improvements -- Generate detailed performance reports +- **Tooling**: Ruff for linting/formatting, mypy strict mode, pre-commit hooks +- **Line length**: 120 characters +- **Python**: 3.9+ syntax +- **Comments**: Minimal - only explain "why", not "what" +- **Docstrings**: Do not add unless explicitly requested +- **Naming**: Prefer public functions (no leading underscore) - Python doesn't have true private functions +- **Paths**: Always use absolute paths, handle encoding explicitly (UTF-8) -### PR Review Comments -When reviewing pull requests: -- **Limit your review to the changes in the PR** - only review the code that was actually modified in the commits, not other parts of the codebase -- Make a **single comment** per PR review, consolidating all feedback into one comment -- If an existing review comment from you already exists on the PR, **edit that existing comment** instead of creating a new one -- Never spam PRs with multiple separate comments +## PR Review Guidelines -### Naming Conventions -- Prefer public function names over private (no leading underscore) -- Python doesn't have true private functions, so avoid `_function_name` patterns unless there's a strong reason -- Use clear, descriptive names that make the code self-documenting +- **Limit review scope** - only review code actually modified in the PR, not other parts of the codebase +- **Single comment** - consolidate all feedback into one comment per review +- **Edit existing comments** - if you already commented on the PR, edit that comment instead of creating a new one # Agent Rules From f00bc9b6fb7e95ea9fc71e644d1f6be0effb595b Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 12:58:09 -0500 Subject: [PATCH 4/9] use uv --- AGENTS.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 005f66962..ef132bbee 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -27,12 +27,13 @@ codeflash/ ## Critical Development Patterns -### Use uv, not pip +### Use uv, NEVER pip +**NEVER use `pip install` or `pip` commands.** This project uses `uv` exclusively for package management. ```bash -uv sync # Install dependencies -uv sync --group dev # Dev dependencies -uv run pytest # Run commands -uv add package # Add packages +uv sync # Install dependencies (NOT pip install -r requirements.txt) +uv sync --group dev # Dev dependencies (NOT pip install -e .) +uv run pytest # Run commands (NOT python -m pytest) +uv add package # Add packages (NOT pip install package) ``` ### Use libcst, not ast From 09c6ec7cf09220c797b86c3184bb6c6dba1cef35 Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 13:03:29 -0500 Subject: [PATCH 5/9] sticky comments --- .github/workflows/claude-code-review.yml | 7 +++---- AGENTS.md | 6 ------ 2 files changed, 3 insertions(+), 10 deletions(-) diff --git a/.github/workflows/claude-code-review.yml b/.github/workflows/claude-code-review.yml index a4c8f6a89..08a8ea705 100644 --- a/.github/workflows/claude-code-review.yml +++ b/.github/workflows/claude-code-review.yml @@ -21,7 +21,7 @@ jobs: runs-on: ubuntu-latest permissions: contents: read - pull-requests: read + pull-requests: write issues: read id-token: write @@ -36,6 +36,7 @@ jobs: uses: anthropics/claude-code-action@v1 with: anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }} + use_sticky_comment: true prompt: | REPO: ${{ github.repository }} PR NUMBER: ${{ github.event.pull_request.number }} @@ -49,9 +50,7 @@ jobs: Use the repository's CLAUDE.md for guidance on style and conventions. Be constructive and helpful in your feedback. - Use `gh pr comment` with your Bash tool to leave your review as a comment on the PR. - # See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md # or https://code.claude.com/docs/en/cli-reference for available options - claude_args: '--allowed-tools "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"' + claude_args: '--allowed-tools "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"' diff --git a/AGENTS.md b/AGENTS.md index ef132bbee..5acea2bdb 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -65,12 +65,6 @@ from codeflash.code_utils.git_worktree_utils import create_detached_worktree, re - **Naming**: Prefer public functions (no leading underscore) - Python doesn't have true private functions - **Paths**: Always use absolute paths, handle encoding explicitly (UTF-8) -## PR Review Guidelines - -- **Limit review scope** - only review code actually modified in the PR, not other parts of the codebase -- **Single comment** - consolidate all feedback into one comment per review -- **Edit existing comments** - if you already commented on the PR, edit that comment instead of creating a new one - # Agent Rules @.tessl/RULES.md follow the [instructions](.tessl/RULES.md) From 1cc97b751771e8396bc14dbea5d7fc99e6d1c023 Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 13:22:52 -0500 Subject: [PATCH 6/9] Remove qodo-ai pr-agent workflow (replaced by Claude) --- .github/workflows/pr_agent.yml | 20 -------------------- 1 file changed, 20 deletions(-) delete mode 100644 .github/workflows/pr_agent.yml diff --git a/.github/workflows/pr_agent.yml b/.github/workflows/pr_agent.yml deleted file mode 100644 index 4f6d48de6..000000000 --- a/.github/workflows/pr_agent.yml +++ /dev/null @@ -1,20 +0,0 @@ -on: - pull_request: - types: [opened, reopened, ready_for_review] - issue_comment: -jobs: - pr_agent_job: - if: ${{ github.event.sender.type != 'Bot' }} - runs-on: ubuntu-latest - permissions: - issues: write - pull-requests: write - contents: write - name: Run pr agent on every pull request, respond to user comments - steps: - - name: PR Agent action step - id: pragent - uses: qodo-ai/pr-agent@main - env: - OPENAI_KEY: ${{ secrets.OPENAI_KEY }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From e1b7425d54ec68e1b5a942122a66d14aa3f097e8 Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 13:35:56 -0500 Subject: [PATCH 7/9] Switch Claude workflows to Azure Foundry --- .github/workflows/claude-code-review.yml | 5 ++++- .github/workflows/claude.yml | 15 ++++----------- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/.github/workflows/claude-code-review.yml b/.github/workflows/claude-code-review.yml index 08a8ea705..86abd4c9a 100644 --- a/.github/workflows/claude-code-review.yml +++ b/.github/workflows/claude-code-review.yml @@ -35,7 +35,7 @@ jobs: id: claude-review uses: anthropics/claude-code-action@v1 with: - anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }} + use_foundry: "true" use_sticky_comment: true prompt: | REPO: ${{ github.repository }} @@ -53,4 +53,7 @@ jobs: # See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md # or https://code.claude.com/docs/en/cli-reference for available options claude_args: '--allowed-tools "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"' + env: + ANTHROPIC_FOUNDRY_API_KEY: ${{ secrets.ANTHROPIC_FOUNDRY_API_KEY }} + ANTHROPIC_FOUNDRY_BASE_URL: ${{ secrets.ANTHROPIC_FOUNDRY_BASE_URL }} diff --git a/.github/workflows/claude.yml b/.github/workflows/claude.yml index 79fe05647..2b6eb15e9 100644 --- a/.github/workflows/claude.yml +++ b/.github/workflows/claude.yml @@ -34,17 +34,10 @@ jobs: id: claude uses: anthropics/claude-code-action@v1 with: - anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }} - - # This is an optional setting that allows Claude to read CI results on PRs + use_foundry: "true" additional_permissions: | actions: read - - # Optional: Give a custom prompt to Claude. If this is not specified, Claude will perform the instructions specified in the comment that tagged it. - # prompt: 'Update the pull request description to include a summary of changes.' - - # Optional: Add claude_args to customize behavior and configuration - # See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md - # or https://code.claude.com/docs/en/cli-reference for available options - # claude_args: '--allowed-tools Bash(gh pr:*)' + env: + ANTHROPIC_FOUNDRY_API_KEY: ${{ secrets.ANTHROPIC_FOUNDRY_API_KEY }} + ANTHROPIC_FOUNDRY_BASE_URL: ${{ secrets.ANTHROPIC_FOUNDRY_BASE_URL }} From 2a5d303e6f94492bc3e379fb4677321e84f4dd95 Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 13:37:02 -0500 Subject: [PATCH 8/9] Rename secret to AZURE_ANTHROPIC_ENDPOINT --- .github/workflows/claude-code-review.yml | 2 +- .github/workflows/claude.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/claude-code-review.yml b/.github/workflows/claude-code-review.yml index 86abd4c9a..821e150ef 100644 --- a/.github/workflows/claude-code-review.yml +++ b/.github/workflows/claude-code-review.yml @@ -55,5 +55,5 @@ jobs: claude_args: '--allowed-tools "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"' env: ANTHROPIC_FOUNDRY_API_KEY: ${{ secrets.ANTHROPIC_FOUNDRY_API_KEY }} - ANTHROPIC_FOUNDRY_BASE_URL: ${{ secrets.ANTHROPIC_FOUNDRY_BASE_URL }} + ANTHROPIC_FOUNDRY_BASE_URL: ${{ secrets.AZURE_ANTHROPIC_ENDPOINT }} diff --git a/.github/workflows/claude.yml b/.github/workflows/claude.yml index 2b6eb15e9..3f8437567 100644 --- a/.github/workflows/claude.yml +++ b/.github/workflows/claude.yml @@ -39,5 +39,5 @@ jobs: actions: read env: ANTHROPIC_FOUNDRY_API_KEY: ${{ secrets.ANTHROPIC_FOUNDRY_API_KEY }} - ANTHROPIC_FOUNDRY_BASE_URL: ${{ secrets.ANTHROPIC_FOUNDRY_BASE_URL }} + ANTHROPIC_FOUNDRY_BASE_URL: ${{ secrets.AZURE_ANTHROPIC_ENDPOINT }} From 9fcbd2bb8f3bc2c1f6768c0abb6f5514bbc46997 Mon Sep 17 00:00:00 2001 From: Kevin Turcios Date: Fri, 26 Dec 2025 13:39:12 -0500 Subject: [PATCH 9/9] Rename secret to AZURE_ANTHROPIC_API_KEY --- .github/workflows/claude-code-review.yml | 2 +- .github/workflows/claude.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/claude-code-review.yml b/.github/workflows/claude-code-review.yml index 821e150ef..d932516f7 100644 --- a/.github/workflows/claude-code-review.yml +++ b/.github/workflows/claude-code-review.yml @@ -54,6 +54,6 @@ jobs: # or https://code.claude.com/docs/en/cli-reference for available options claude_args: '--allowed-tools "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"' env: - ANTHROPIC_FOUNDRY_API_KEY: ${{ secrets.ANTHROPIC_FOUNDRY_API_KEY }} + ANTHROPIC_FOUNDRY_API_KEY: ${{ secrets.AZURE_ANTHROPIC_API_KEY }} ANTHROPIC_FOUNDRY_BASE_URL: ${{ secrets.AZURE_ANTHROPIC_ENDPOINT }} diff --git a/.github/workflows/claude.yml b/.github/workflows/claude.yml index 3f8437567..24acf1ffd 100644 --- a/.github/workflows/claude.yml +++ b/.github/workflows/claude.yml @@ -38,6 +38,6 @@ jobs: additional_permissions: | actions: read env: - ANTHROPIC_FOUNDRY_API_KEY: ${{ secrets.ANTHROPIC_FOUNDRY_API_KEY }} + ANTHROPIC_FOUNDRY_API_KEY: ${{ secrets.AZURE_ANTHROPIC_API_KEY }} ANTHROPIC_FOUNDRY_BASE_URL: ${{ secrets.AZURE_ANTHROPIC_ENDPOINT }}