Skip to content

Improvements to manually running evals - #1260

Closed
aantn wants to merge 5 commits into
masterfrom
claude/fix-eval-regression-marker-XeZ7i
Closed

aantn wants to merge 5 commits into
masterfrom
claude/fix-eval-regression-marker-XeZ7i

Conversation

@aantn

@aantn aantn commented Dec 29, 2025 •

Copy link
Copy Markdown
Collaborator

Summary by CodeRabbit

  • New Features

    • Evaluation runs now show a detailed test preview and count before execution.
    • PR comments updated with rich run summaries (trigger source, model, markers/filter, iterations, run link).
    • Manual runs post completion now include a completion notification naming who triggered them.
  • Changes

    • Markers input now defaults to empty; manual runs no longer auto-apply a regression marker.
    • Outputs expanded to include who triggered a run and a derived marker expression when appropriate.
    • Help text clarified with additional marker and test-name guidance.

✏️ Tip: You can customize this high-level summary in your review settings.

- Remove 'regression' as default marker for /eval comments and
  workflow_dispatch triggers - they now run all LLM tests by default
- Keep 'regression' as default only for automatic triggers (PR/push)
- Add details section with list of valid markers and example test names
- Update marker_expr to handle empty markers (just 'llm' instead of
  'llm and ()')

Signed-off-by: Claude <noreply@anthropic.com>
- Add test preview step that runs pytest --collect-only to show which
  tests will run before actually running them
- Update initial comment with test count and expandable test list
- Add warning that manual re-runs have no default markers and will run
  all LLM tests (~100+) which can take 1+ hours
- Update example /eval command to include markers: regression
- Update markers description to emphasize no default

Signed-off-by: Claude <noreply@anthropic.com>
@github-actions

github-actions Bot commented Dec 29, 2025 •

Copy link
Copy Markdown
Contributor

✅ Docker image ready for 5bba825 (built in 40s)

⚠️ Warning: does not support ARM (ARM images are built on release only - not on every PR)

Use this tag to pull the image for testing.

📋 Copy commands

⚠️ Temporary images are deleted after 30 days. Copy to a permanent registry before using them:

gcloud auth configure-docker us-central1-docker.pkg.dev
docker pull us-central1-docker.pkg.dev/robusta-development/temporary-builds/holmes:5bba825
docker tag us-central1-docker.pkg.dev/robusta-development/temporary-builds/holmes:5bba825 me-west1-docker.pkg.dev/robusta-development/development/holmes-dev:5bba825
docker push me-west1-docker.pkg.dev/robusta-development/development/holmes-dev:5bba825

Patch Helm values in one line (choose the chart you use):

HolmesGPT chart:

helm upgrade --install holmesgpt ./helm/holmes \
  --set registry=me-west1-docker.pkg.dev/robusta-development/development \
  --set image=holmes-dev:5bba825

Robusta wrapper chart:

helm upgrade --install robusta robusta/robusta \
  --reuse-values \
  --set holmes.registry=me-west1-docker.pkg.dev/robusta-development/development \
  --set holmes.image=holmes-dev:5bba825

@coderabbitai

coderabbitai Bot commented Dec 29, 2025 •

Copy link
Copy Markdown
Contributor

Walkthrough

This change updates the eval-regression GitHub Actions workflow to track who triggered runs, change marker defaulting behavior based on trigger type, add pre-collection of evals (test_count/test_preview), and surface richer PR comments and outputs (including triggered_by and marker_expr).

Changes

Cohort / File(s) Summary
Workflow inputs/outputs & param parsing
.github/workflows/eval-regression.yaml
markers input description adjusted and default set to empty; parsing now records triggered_by; marker_expr output derives from markers or falls back to llm; default 'regression' only applied for automatic triggers.
Eval collection & feedback steps
.github/workflows/eval-regression.yaml
Added "Collect evals to run" step producing test_count and test_preview; added "Update comment with evals list" step to post detailed markdown summary; added "Notify user of completion" step to post completion comment for manual runs.
UI/help text within workflow
.github/workflows/eval-regression.yaml
Expanded comment and input help text to explain leaving markers empty, list marker examples, and de-emphasize automatic marker defaults for manual runs.

Sequence Diagram

sequenceDiagram
    participant Trigger as Trigger (comment / dispatch)
    participant WF as Workflow
    participant Parser as eval-params step
    participant Collector as Collect evals step
    participant Commenter as Update PR Comment
    participant Executor as Run tests step
    participant Notifier as Notify user step

    Trigger->>WF: start (manual or automatic)
    WF->>Parser: parse inputs
    Parser->>Parser: set triggered_by
    Parser->>Parser: apply conditional marker default (auto only)
    Parser->>Parser: derive marker_expr

    rect rgb(220,240,255)
    Parser->>Collector: request tests (marker_expr, filter)
    Collector->>Collector: collect tests
    Collector->>Commenter: return test_count & test_preview
    end

    Commenter->>Trigger: post detailed PR comment (trigger, model, markers, filter, iterations, test_count, preview, run URL)

    Parser->>Executor: pass eval params
    Executor->>Executor: run tests

    rect rgb(240,220,255)
    Executor->>Notifier: send results
    Notifier->>Trigger: post completion comment (manual runs include triggered_by)
    end
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested reviewers

  • Sheeproid
  • moshemorad

Pre-merge checks

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Improvements to manually running evals' accurately reflects the main focus of the changeset, which centers on enhancing manual evaluation workflow execution with new features like better tracking, notifications, and test previews.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

📜 Recent review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7b43d8a and 682a686.

📒 Files selected for processing (1)
  • .github/workflows/eval-regression.yaml
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: llm_evals
  • GitHub Check: build (3.11)
  • GitHub Check: build (3.12)
  • GitHub Check: build (3.10)
🔇 Additional comments (11)
.github/workflows/eval-regression.yaml (11)

19-21: LGTM! Behavioral change is well-documented.

The removal of the default regression marker from the input definition is appropriate. The conditional defaulting logic later (lines 161-162) ensures automatic triggers still get the regression default while manual triggers must explicitly specify markers. The updated description clearly warns users about this behavior.


111-111: LGTM!

Consistent with the input definition change. The empty default for markers in parseComment correctly reflects that manual /eval triggers should not have implicit defaults.


123-123: LGTM! Excellent addition for user accountability.

The triggeredBy tracking correctly captures the user for manual triggers (issue_comment and workflow_dispatch) and remains empty for automatic triggers. This is properly utilized in the completion notification (line 428) to mention the user.

Also applies to: 136-136, 147-147, 156-156, 172-172


161-162: LGTM! Critical behavioral change is intentional and well-communicated.

The conditional defaulting logic correctly applies the regression marker only to automatic triggers while leaving manual triggers with no default. This ensures users explicitly choose what to run for manual evaluations. The comprehensive warnings added in the documentation (lines 384-392) effectively communicate this behavior change.


173-173: LGTM! Marker expression logic is correct.

The conditional marker expression correctly constructs the pytest filter:

  • Non-empty markers: llm and (${markers}) - filters to LLM tests matching the specified markers
  • Empty markers: llm - runs all tests marked with 'llm'

This is consistently used in both test collection (line 244) and execution (line 326).


239-259: LGTM! Test collection implementation is secure and robust.

The test collection step correctly:

  • Uses environment variables with proper quoting to prevent injection
  • Handles empty results with fallbacks (|| echo "" and || echo "0")
  • Generates a secure EOF delimiter using /dev/urandom for multiline output
  • Suppresses stderr with 2>/dev/null for clean output
  • Uses the same marker expression and filter as the actual test execution (line 331-332) for consistency

This provides valuable preview functionality for users to see what tests will run.


261-303: LGTM! Excellent UX enhancement with test preview.

The comment update step provides valuable user feedback:

  • Displays test count before execution starts (line 287, 291)
  • Shows collapsible test preview for transparency (lines 294-296)
  • User-friendly display text: 'all LLM tests' when markers is empty (line 270)
  • Appropriate formatting differences for manual vs automatic triggers

This helps users verify their marker/filter selection before waiting for execution to complete.


413-420: LGTM! Comment logic correctly handles different trigger scenarios.

The conditional comment posting logic is correct:

  • Updates existing comment if commentId exists (line 409)
  • Creates new comment for automatic triggers without initial comment, e.g., fork PRs without secrets (lines 413-419)
  • For manual triggers, commentId should always exist since the initial comment is created early (lines 188-223)

The edge case where workflow_dispatch without pr_number won't post results is intentional—there's no PR to comment on in that scenario.


422-442: LGTM! Great UX addition for manual eval notifications.

The completion notification provides excellent user experience:

  • Mentions the triggering user with @${triggeredBy} (line 441)
  • Clear status indication: success vs regressions (lines 433-435)
  • Directs user to detailed results above
  • Only runs for manual triggers with valid PR context (line 423)

This ensures users are promptly notified when their manually triggered evaluations complete.


384-405: LGTM! Comprehensive documentation prevents user confusion.

The documentation improvements effectively communicate the behavioral change:

  • Strong warning about no default markers in manual runs (lines 384-385)
  • Updated examples showing explicit markers: regression usage (lines 387-389)
  • Emphasized table row highlighting no default behavior (line 392)
  • New reference section listing valid markers and example test names (lines 396-405)

This thorough documentation helps prevent users from accidentally triggering expensive full test runs.


215-215: LGTM! Initial comment simplified appropriately.

The initial automatic trigger comment is now simpler, with detailed information (test count, preview) added later in the "Update comment with evals list" step (lines 290-296). This provides a quick initial response while gathering test information.


Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions

github-actions Bot commented Dec 29, 2025 •

Copy link
Copy Markdown
Contributor

Results of HolmesGPT evals

Duration: 4m 6s | View workflow logs

Results of HolmesGPT evals

  • ask_holmes: 9/9 test cases were successful, 0 regressions
Test suite Test case Status
ask 09_crashpod ✅
ask 101_loki_historical_logs_pod_deleted ✅
ask 111_pod_names_contain_service ✅
ask 12_job_crashing ✅
ask 162_get_runbooks ✅
ask 176_network_policy_blocking_traffic_no_runbooks ✅
ask 24_misconfigured_pvc ✅
ask 43_current_datetime_from_prompt ✅
ask 61_exact_match_counting ✅

Legend

  • ✅ the test was successful
  • :minus: the test was skipped
  • ⚠️ the test failed but is known to be flaky or known to fail
  • 🚧 the test had a setup failure (not a code regression)
  • 🔧 the test failed due to mock data issues (not a code regression)
  • 🚫 the test was throttled by API rate limits/overload
  • ❌ the test failed and should be fixed before merging the PR

🔄 Re-run evals manually

⚠️ Warning: Manual re-runs have NO default markers and will run ALL LLM tests (~100+), which can take 1+ hours. Use markers: regression or filter: test_name to limit scope.

Option 1: Comment on this PR with /eval:

/eval
markers: regression

Or with more options (one per line):

/eval
model: gpt-4o
markers: regression
filter: 09_crashpod
iterations: 5
Option Description
model Model(s) to test (default: same as automatic runs)
markers Pytest markers (no default - runs all tests!)
filter Pytest -k filter
iterations Number of runs, max 10

Option 2: Trigger via GitHub Actions UI → "Run workflow"

📋 Valid eval names and markers

Valid markers:
regression, easy, medium, hard, logs, metrics, kubernetes, prometheus, loki, grafana-dashboard, traces, datadog, newrelic, coralogix, runbooks, transparency, question-answer, counting, database, storage, kafka, chain-of-causation, compaction, network, port-forward

Example test names (use with filter):
09_crashpod, 17_oom_kill, 10_image_pull_backoff, 22_high_latency_dbi_down, 35_tempo, 100a_loki_historical_logs, 114_checkout_latency_tracing_rebuild, 177_grafana_home_dashboard

Full list: Run ls tests/llm/fixtures/test_ask_holmes/ or ls tests/llm/fixtures/test_investigate/

When a user triggers evals manually via /eval comment or workflow_dispatch,
they now receive a notification when the run completes. The notification:
- @mentions the user who triggered the eval
- Shows success or regression count status
- Points to the updated results comment above

This ensures users get a GitHub notification instead of having to poll
the PR for the updated comment.

Signed-off-by: Claude <noreply@anthropic.com>
@github-actions

github-actions Bot commented Dec 29, 2025 •

Copy link
Copy Markdown
Contributor

Results of HolmesGPT evals

Duration: 4m 27s | View workflow logs

Results of HolmesGPT evals

  • ask_holmes: 9/9 test cases were successful, 0 regressions
Test suite Test case Status
ask 09_crashpod ✅
ask 101_loki_historical_logs_pod_deleted ✅
ask 111_pod_names_contain_service ✅
ask 12_job_crashing ✅
ask 162_get_runbooks ✅
ask 176_network_policy_blocking_traffic_no_runbooks ✅
ask 24_misconfigured_pvc ✅
ask 43_current_datetime_from_prompt ✅
ask 61_exact_match_counting ✅

Legend

  • ✅ the test was successful
  • :minus: the test was skipped
  • ⚠️ the test failed but is known to be flaky or known to fail
  • 🚧 the test had a setup failure (not a code regression)
  • 🔧 the test failed due to mock data issues (not a code regression)
  • 🚫 the test was throttled by API rate limits/overload
  • ❌ the test failed and should be fixed before merging the PR

🔄 Re-run evals manually

⚠️ Warning: Manual re-runs have NO default markers and will run ALL LLM tests (~100+), which can take 1+ hours. Use markers: regression or filter: test_name to limit scope.

Option 1: Comment on this PR with /eval:

/eval
markers: regression

Or with more options (one per line):

/eval
model: gpt-4o
markers: regression
filter: 09_crashpod
iterations: 5
Option Description
model Model(s) to test (default: same as automatic runs)
markers Pytest markers (no default - runs all tests!)
filter Pytest -k filter
iterations Number of runs, max 10

Option 2: Trigger via GitHub Actions UI → "Run workflow"

📋 Valid eval names and markers

Valid markers:
regression, easy, medium, hard, logs, metrics, kubernetes, prometheus, loki, grafana-dashboard, traces, datadog, newrelic, coralogix, runbooks, transparency, question-answer, counting, database, storage, kafka, chain-of-causation, compaction, network, port-forward

Example test names (use with filter):
09_crashpod, 17_oom_kill, 10_image_pull_backoff, 22_high_latency_dbi_down, 35_tempo, 100a_loki_historical_logs, 114_checkout_latency_tracing_rebuild, 177_grafana_home_dashboard

Full list: Run ls tests/llm/fixtures/test_ask_holmes/ or ls tests/llm/fixtures/test_investigate/

- Rename step names and summary text from "Test preview" to "Evals to run"
- Remove the 20 test limit to show all evals that will run

Signed-off-by: Claude <noreply@anthropic.com>
@github-actions

github-actions Bot commented Dec 29, 2025 •

Copy link
Copy Markdown
Contributor

Results of HolmesGPT evals

Duration: N/A | View workflow logs

⚠️ No eval report was generated.


🔄 Re-run evals manually

⚠️ Warning: Manual re-runs have NO default markers and will run ALL LLM tests (~100+), which can take 1+ hours. Use markers: regression or filter: test_name to limit scope.

Option 1: Comment on this PR with /eval:

/eval
markers: regression

Or with more options (one per line):

/eval
model: gpt-4o
markers: regression
filter: 09_crashpod
iterations: 5
Option Description
model Model(s) to test (default: same as automatic runs)
markers Pytest markers (no default - runs all tests!)
filter Pytest -k filter
iterations Number of runs, max 10

Option 2: Trigger via GitHub Actions UI → "Run workflow"

📋 Valid eval names and markers

Valid markers:
regression, easy, medium, hard, logs, metrics, kubernetes, prometheus, loki, grafana-dashboard, traces, datadog, newrelic, coralogix, runbooks, transparency, question-answer, counting, database, storage, kafka, chain-of-causation, compaction, network, port-forward

Example test names (use with filter):
09_crashpod, 17_oom_kill, 10_image_pull_backoff, 22_high_latency_dbi_down, 35_tempo, 100a_loki_historical_logs, 114_checkout_latency_tracing_rebuild, 177_grafana_home_dashboard

Full list: Run ls tests/llm/fixtures/test_ask_holmes/ or ls tests/llm/fixtures/test_investigate/

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
.github/workflows/eval-regression.yaml (1)

239-259: Consider handling pytest collection failures gracefully.

If pytest --collect-only fails (e.g., due to a syntax error in a test file), the step will fail and block the workflow. The actual test run step (line 333) uses || true to continue on failure.

Consider adding similar error handling:

🔎 Suggested improvement
           # Collect test names
-          TEST_LIST=$(poetry run pytest "${PYTEST_ARGS[@]}" 2>/dev/null | grep -E "^tests/llm/" || echo "")
+          TEST_LIST=$(poetry run pytest "${PYTEST_ARGS[@]}" 2>/dev/null | grep -E "^tests/llm/" || true)
           TEST_COUNT=$(echo "$TEST_LIST" | grep -c "^tests/llm/" || echo "0")
📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between e6ae36b and 7b43d8a.

📒 Files selected for processing (1)
  • .github/workflows/eval-regression.yaml
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: build
  • GitHub Check: build (3.11)
  • GitHub Check: build (3.10)
  • GitHub Check: build (3.12)
🔇 Additional comments (6)
.github/workflows/eval-regression.yaml (6)

18-21: LGTM!

The input description and default changes correctly reflect the new behavior where manual triggers (workflow_dispatch, /eval) will run all LLM tests unless markers are explicitly specified. The warning in the PR comment (lines 384-385) appropriately alerts users about this behavior.


123-157: LGTM!

The triggeredBy tracking is correctly implemented for each trigger type. Using context.payload.comment.user.login for issue comments and context.actor for workflow_dispatch ensures the right user is notified upon completion.


159-173: LGTM!

The marker defaulting logic correctly differentiates between automatic and manual triggers. The marker_expr output properly handles both cases: using llm and (markers) when markers are specified, or just llm to run all LLM tests when empty.


261-303: LGTM!

The comment update step is well-structured with proper fallbacks for missing outputs. The collapsible details section for test preview is a nice UX improvement. The step conditions correctly ensure it only runs when all prerequisites are met.


384-405: LGTM!

The updated help text provides clear guidance about the behavior change. The warning about manual re-runs having no default markers is prominent, and the expanded marker/test name examples help users construct appropriate /eval commands.


420-440: LGTM!

The notification step appropriately pings the user who triggered the manual eval, with a clear status message and pointer to the results. The conditions correctly ensure this only runs for manual triggers where the user is known.

- Remove "Results will appear here when complete." text from both
  initial and running status comments since it's confusing
- For manual triggers, don't create a new comment if comment_id is
  missing - the initial comment should always exist for manual runs

Signed-off-by: Claude <noreply@anthropic.com>
@github-actions

github-actions Bot commented Dec 29, 2025 •

Copy link
Copy Markdown
Contributor

Results of HolmesGPT evals

Duration: 3m 55s | View workflow logs

Results of HolmesGPT evals

  • ask_holmes: 9/9 test cases were successful, 0 regressions
Test suite Test case Status
ask 09_crashpod ✅
ask 101_loki_historical_logs_pod_deleted ✅
ask 111_pod_names_contain_service ✅
ask 12_job_crashing ✅
ask 162_get_runbooks ✅
ask 176_network_policy_blocking_traffic_no_runbooks ✅
ask 24_misconfigured_pvc ✅
ask 43_current_datetime_from_prompt ✅
ask 61_exact_match_counting ✅

Legend

  • ✅ the test was successful
  • :minus: the test was skipped
  • ⚠️ the test failed but is known to be flaky or known to fail
  • 🚧 the test had a setup failure (not a code regression)
  • 🔧 the test failed due to mock data issues (not a code regression)
  • 🚫 the test was throttled by API rate limits/overload
  • ❌ the test failed and should be fixed before merging the PR

🔄 Re-run evals manually

⚠️ Warning: Manual re-runs have NO default markers and will run ALL LLM tests (~100+), which can take 1+ hours. Use markers: regression or filter: test_name to limit scope.

Option 1: Comment on this PR with /eval:

/eval
markers: regression

Or with more options (one per line):

/eval
model: gpt-4o
markers: regression
filter: 09_crashpod
iterations: 5
Option Description
model Model(s) to test (default: same as automatic runs)
markers Pytest markers (no default - runs all tests!)
filter Pytest -k filter
iterations Number of runs, max 10

Option 2: Trigger via GitHub Actions UI → "Run workflow"

📋 Valid eval names and markers

Valid markers:
regression, easy, medium, hard, logs, metrics, kubernetes, prometheus, loki, grafana-dashboard, traces, datadog, newrelic, coralogix, runbooks, transparency, question-answer, counting, database, storage, kafka, chain-of-causation, compaction, network, port-forward

Example test names (use with filter):
09_crashpod, 17_oom_kill, 10_image_pull_backoff, 22_high_latency_dbi_down, 35_tempo, 100a_loki_historical_logs, 114_checkout_latency_tracing_rebuild, 177_grafana_home_dashboard

Full list: Run ls tests/llm/fixtures/test_ask_holmes/ or ls tests/llm/fixtures/test_investigate/

@aantn aantn closed this Dec 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants