Skip to content

✨ Add per-prompt Rudder test reports - #94

Merged
Vivekyy merged 3 commits into
mainfrom
Vivekyy/prompt-test-report
Jul 30, 2026
Merged

✨ Add per-prompt Rudder test reports#94
Vivekyy merged 3 commits into
mainfrom
Vivekyy/prompt-test-report

Conversation

@Vivekyy

@Vivekyy Vivekyy commented Jul 30, 2026

Copy link
Copy Markdown
Collaborator

Adds a temporary Markdown report at the end of each Rudder test-generation run, grouping human-readable test links by their captured prompts. Prompt groups include exact prompt text and a concise representation of prior agent context from the database. The context helper now exposes previous agent output, with runtime coverage for that behavioral field. Validation passed with npm run typecheck, npm test, and npm run build.


Open in Stage

Greptile Summary

Adds a per-prompt Markdown report to Rudder test-generation runs.

  • Exposes captured previous agent output in context helper prompt records.
  • Groups final tagged tests by their exact captured prompts and prior context.
  • Adds runtime coverage for retrieving previousAgentOutput from a captured transcript.

Confidence Score: 4/5

The PR should not merge until legacy database reads, early-run report finalization, and completion telemetry ordering are corrected.

The helper can terminate on pre-migration state, early workflow exits omit a report required for every run, and telemetry can mark a run complete before required report generation succeeds.

Files Needing Attention: skills/rudder/scripts/context.mjs and skills/rudder/SKILL.md

Important Files Changed

Filename Overview
skills/rudder/SKILL.md Adds the prompt-report workflow, but early exits bypass it and completion telemetry precedes the report it claims was reached.
skills/rudder/scripts/context.mjs Exposes previousAgentOutput but can fail against an existing database that has not received the column migration.
test/skill-runtime.test.ts Correctly validates retrieval of previousAgentOutput from a fresh, fully migrated transcript-backed state database.

Sequence Diagram

sequenceDiagram
    participant R as Rudder workflow
    participant C as context.mjs
    participant D as Prompt database
    participant T as Telemetry
    participant F as Temporary report
    R->>C: Refresh run context
    C->>D: Read promptText and previousAgentOutput
    D-->>C: Captured prompt records
    C-->>R: Context JSON
    R->>R: Match final tagged tests to prompts
    R->>T: Record completion
    R->>F: Create Markdown report
    F-->>R: Temporary report path
    R-->>R: Present report first in final response
Loading

Fix All in Cursor Fix All in Conductor

Reviews (1): Last reviewed commit: "✨ Add per-prompt Rudder test reports" | Re-trigger Greptile

Greptile also left 3 inline comments on this PR.

Co-authored-by: Codex Agent <codex@openai.com>
@github-actions

Copy link
Copy Markdown

📦 No plugin release on merge

The plugin package, tag, and GitHub Release already exist for 0.1.3.
Bump package.json to release a new plugin version.

@ghost

ghost commented Jul 30, 2026

Copy link
Copy Markdown

Ready to review this PR? Stage has broken it down into 4 individual chapters for you:

Title
1 Expose previous agent output in context helper
2 Verify agent output retrieval in runtime tests
3 Define prompt report generation requirements
4 Integrate reporting into the Rudder workflow
Open in Stage

Chapters generated by Stage for commit c011c1a on Jul 30, 2026 5:57pm UTC.

session_id AS sessionId,
prompt_id AS promptId,
prompt_text AS promptText,
previous_agent_output AS previousAgentOutput,

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Legacy database query failure

When an existing Rudder database predates the previous_agent_output migration and has not subsequently been migrated, the read-only context helper unconditionally selects that column, causing SQLite to terminate the helper without emitting the context JSON required to generate the report.

Fix in Cursor Fix in Conductor

Comment thread skills/rudder/SKILL.md Outdated
Use `completed` when the workflow reaches its normal report, `stopped` when it ends by user choice or missing intent, and `blocked` only for an external blocker.
Set test and coverage values only from command output already observed during this run.
Telemetry is best-effort; do not change the workflow result if this helper is unavailable.
13. After the generation loop ends, create and present the prompt report.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Early exits bypass reporting

When a run stops before the generation loop because intent is missing, declined, or not captured, execution never reaches this sole report step, so the run ends without the report and temporary path required by the new every-run contract.

Fix in Cursor Fix in Conductor

Comment thread skills/rudder/SKILL.md Outdated
Comment on lines +280 to +283
Use `completed` when the workflow reaches its normal report, `stopped` when it ends by user choice or missing intent, and `blocked` only for an external blocker.
Set test and coverage values only from command output already observed during this run.
Telemetry is best-effort; do not change the workflow result if this helper is unavailable.
13. After the generation loop ends, create and present the prompt report.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Completion recorded before reporting

When final tests succeed but temporary report creation or presentation subsequently fails, step 12 has already recorded the run as completed even though that status is defined as reaching the normal report, leaving telemetry inconsistent with the actual outcome.

Fix in Cursor Fix in Conductor

Vivekyy and others added 2 commits July 30, 2026 13:50
Co-authored-by: Codex Agent <codex@openai.com>
Co-authored-by: Codex Agent <codex@openai.com>
@Vivekyy
Vivekyy merged commit 6c13e74 into main Jul 30, 2026
3 checks passed
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.

1 participant