Redact eval artifact secrets and clarify quickstart polling snippets#977
Merged
Conversation
Address Copilot review on #976: redact known secrets when writing transcripts and judge failures, and scan results/runs before CI upload. Co-Authored-By: Claude <noreply@anthropic.com> Co-authored-by: Cursor <cursoragent@cursor.com>
Cover pattern and literal env redaction, JSON artifact output, and wire npm run test:redact-secrets into npm run test. Co-Authored-By: Claude <noreply@anthropic.com> Co-authored-by: Cursor <cursoragent@cursor.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR tightens handling of sensitive data in agent-evaluation artifacts (transcripts/judge outputs/CI uploads) and clarifies quickstart “poll events API” snippets so readers understand they depend on variables defined earlier in the walkthrough.
Changes:
- Introduces shared best-effort redaction utilities and applies them when writing eval artifacts (
transcript.json,llm-score.json,llm-judge-failure.json, eval failure sidecars). - Adds a CI redaction pass over
docs/agent-evaluation/results/runsbefore uploading artifacts. - Updates TypeScript/Python/curl quickstarts to clarify the optional polling snippets continue variables from the main script.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| docs/content/quickstarts/hookdeck-outpost-typescript.mdoc | Clarifies the optional polling snippet depends on published from the main script. |
| docs/content/quickstarts/hookdeck-outpost-python.mdoc | Clarifies the optional polling snippet continues the earlier variables (published, client, tenant_id, topic). |
| docs/content/quickstarts/hookdeck-outpost-curl.mdoc | Clarifies the optional polling snippet reuses env vars from the publish section. |
| docs/agent-evaluation/src/transcript-trajectory.ts | Reuses shared redaction helper for trajectory previews. |
| docs/agent-evaluation/src/run-agent-eval.ts | Applies JSON redaction when writing key eval artifacts and failure sidecars. |
| docs/agent-evaluation/src/redact-secrets.ts | Adds centralized redaction helpers for patterns + env-literal replacement. |
| docs/agent-evaluation/src/llm-judge.ts | Redacts raw judge attempt text before writing llm-judge-failure.json. |
| docs/agent-evaluation/scripts/redact-eval-artifacts.ts | Adds a CI-friendly in-place redaction walker for results/runs/**.json. |
| docs/agent-evaluation/README.md | Documents new redaction behavior and CI pre-upload scan. |
| .github/workflows/docs-agent-eval-ci.yml | Runs the new redaction script before artifact upload. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+86
to
+88
| - name: Redact secrets in eval artifacts (best effort) | ||
| if: always() | ||
| run: node --import tsx scripts/redact-eval-artifacts.ts |
Add EVAL_TEST_DESTINATION_URL and OUTPOST_TEST_WEBHOOK_URL to literal redaction; pass secrets into the CI redact step so re-scan can replace plain JSON echoes (Copilot review on #977). Co-Authored-By: Claude <noreply@anthropic.com> Co-authored-by: Cursor <cursoragent@cursor.com>
alexluong
approved these changes
Jun 24, 2026
Deep-walk artifact objects and redact string leaves before serialization so transcript.json stays parseable for heuristic scoring. Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Follow-up to #976 addressing Copilot review comments:
transcript.json,llm-score.json,llm-judge-failure.json, and eval failure sidecarsscripts/redact-eval-artifacts.tsin CI before uploadingresults/runsartifactsTest plan
npm run typecheckindocs/agent-evaluation/Made with Cursor