diff --git a/.github/workflows/agentics/shared/job-summary.md b/.github/workflows/agentics/shared/job-summary.md index d21ab74eb6..2de6f85e79 100644 --- a/.github/workflows/agentics/shared/job-summary.md +++ b/.github/workflows/agentics/shared/job-summary.md @@ -11,7 +11,7 @@ tools: ### Output Report implemented via GitHub Action Job Summary -You will use the Job Summary for GitHub Actions run ${{ github.run_id }} in ${{ github.repository }} to report progess. This means writing to the special file $GITHUB_STEP_SUMMARY. You can write the file using "echo" or the "Write" tool. GITHUB_STEP_SUMMARY is an environment variable set by GitHub Actions which you can use to write the report. You can read this environment variable using the bash command "echo $GITHUB_STEP_SUMMARY". +You will use the Job Summary for GitHub Actions run ${{ github.run_id }} in ${{ github.repository }} to report progess. This means writing to the special file that is stored in the environment variable GITHUB_STEP_SUMMARY. You can write the file using "echo" or the "Write" tool. GITHUB_STEP_SUMMARY is an environment variable set by GitHub Actions which you can use to write the report. You can read this environment variable using the bash command "echo $GITHUB_STEP_SUMMARY". At the end of the workflow, finalize the job summry with a very, very succinct summary in note form of - the steps you took diff --git a/.github/workflows/test-codex.lock.yml b/.github/workflows/test-codex.lock.yml index 093a0681b4..096a240ded 100644 --- a/.github/workflows/test-codex.lock.yml +++ b/.github/workflows/test-codex.lock.yml @@ -173,7 +173,7 @@ jobs: ### Output Report implemented via GitHub Action Job Summary - You will use the Job Summary for GitHub Actions run ${{ github.run_id }} in ${{ github.repository }} to report progess. This means writing to the special file $GITHUB_STEP_SUMMARY. You can write the file using "echo" or the "Write" tool. GITHUB_STEP_SUMMARY is an environment variable set by GitHub Actions which you can use to write the report. You can read this environment variable using the bash command "echo $GITHUB_STEP_SUMMARY". + You will use the Job Summary for GitHub Actions run ${{ github.run_id }} in ${{ github.repository }} to report progess. This means writing to the special file that is stored in the environment variable GITHUB_STEP_SUMMARY. You can write the file using "echo" or the "Write" tool. GITHUB_STEP_SUMMARY is an environment variable set by GitHub Actions which you can use to write the report. You can read this environment variable using the bash command "echo $GITHUB_STEP_SUMMARY". At the end of the workflow, finalize the job summry with a very, very succinct summary in note form of - the steps you took @@ -240,9 +240,10 @@ jobs: # Run codex with log capture codex exec \ -c model=o4-mini \ - --full-auto "$INSTRUCTION" 2>&1 | tee /tmp/aw-logs//tmp/test-codex.log.log + --full-auto "$INSTRUCTION" 2>&1 | tee /tmp/test-codex.log env: OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + GITHUB_STEP_SUMMARY: ${{ env.GITHUB_STEP_SUMMARY }} - name: Check if workflow-complete.txt exists, if so upload it id: check_file run: | diff --git a/.github/workflows/weekly-research.lock.yml b/.github/workflows/weekly-research.lock.yml index 02a9aeb93f..9ef1c892ae 100644 --- a/.github/workflows/weekly-research.lock.yml +++ b/.github/workflows/weekly-research.lock.yml @@ -129,7 +129,7 @@ jobs: ### Output Report implemented via GitHub Action Job Summary - You will use the Job Summary for GitHub Actions run ${{ github.run_id }} in ${{ github.repository }} to report progess. This means writing to the special file $GITHUB_STEP_SUMMARY. You can write the file using "echo" or the "Write" tool. GITHUB_STEP_SUMMARY is an environment variable set by GitHub Actions which you can use to write the report. You can read this environment variable using the bash command "echo $GITHUB_STEP_SUMMARY". + You will use the Job Summary for GitHub Actions run ${{ github.run_id }} in ${{ github.repository }} to report progess. This means writing to the special file that is stored in the environment variable GITHUB_STEP_SUMMARY. You can write the file using "echo" or the "Write" tool. GITHUB_STEP_SUMMARY is an environment variable set by GitHub Actions which you can use to write the report. You can read this environment variable using the bash command "echo $GITHUB_STEP_SUMMARY". At the end of the workflow, finalize the job summry with a very, very succinct summary in note form of - the steps you took diff --git a/pkg/workflow/codex_engine.go b/pkg/workflow/codex_engine.go index 8651665548..a639f35248 100644 --- a/pkg/workflow/codex_engine.go +++ b/pkg/workflow/codex_engine.go @@ -44,8 +44,8 @@ func (e *CodexEngine) GetInstallationSteps(engineConfig *EngineConfig) []GitHubA } func (e *CodexEngine) GetExecutionConfig(workflowName string, logFile string, engineConfig *EngineConfig) ExecutionConfig { - // Use model from engineConfig if available, otherwise default to gpt-4o - model := "gpt-4o" + // Use model from engineConfig if available, otherwise default to o4-mini + model := "o4-mini" if engineConfig != nil && engineConfig.Model != "" { model = engineConfig.Model } @@ -59,13 +59,14 @@ mkdir -p /tmp/aw-logs # Run codex with log capture codex exec \ -c model=%s \ - --full-auto "$INSTRUCTION" 2>&1 | tee /tmp/aw-logs/%s.log`, model, logFile) + --full-auto "$INSTRUCTION" 2>&1 | tee %s`, model, logFile) return ExecutionConfig{ StepName: "Run Codex", Command: command, Environment: map[string]string{ - "OPENAI_API_KEY": "${{ secrets.OPENAI_API_KEY }}", + "OPENAI_API_KEY": "${{ secrets.OPENAI_API_KEY }}", + "GITHUB_STEP_SUMMARY": "${{ env.GITHUB_STEP_SUMMARY }}", }, } } diff --git a/pkg/workflow/codex_engine_test.go b/pkg/workflow/codex_engine_test.go index bbd3fdb60b..709ae9a92c 100644 --- a/pkg/workflow/codex_engine_test.go +++ b/pkg/workflow/codex_engine_test.go @@ -60,7 +60,7 @@ func TestCodexEngine(t *testing.T) { t.Errorf("Expected command to contain 'codex exec', got '%s'", config.Command) } - if !strings.Contains(config.Command, "test-log.log") { + if !strings.Contains(config.Command, "test-log") { t.Errorf("Expected command to contain log file name, got '%s'", config.Command) } diff --git a/pkg/workflow/codex_test.go b/pkg/workflow/codex_test.go index c1e5f94c10..3129bb7666 100644 --- a/pkg/workflow/codex_test.go +++ b/pkg/workflow/codex_test.go @@ -122,8 +122,8 @@ This is a test workflow. t.Errorf("Expected lock file to contain 'codex exec' command but it didn't.\nContent:\n%s", lockContent) } // Check for correct model based on AI setting - if !strings.Contains(lockContent, "model=gpt-4o") { - t.Errorf("Expected lock file to contain 'model=gpt-4o' for codex but it didn't.\nContent:\n%s", lockContent) + if !strings.Contains(lockContent, "model=o4-mini") { + t.Errorf("Expected lock file to contain 'model=o4-mini' for codex but it didn't.\nContent:\n%s", lockContent) } if !strings.Contains(lockContent, "OPENAI_API_KEY") { t.Errorf("Expected lock file to contain 'OPENAI_API_KEY' for codex but it didn't.\nContent:\n%s", lockContent)