Skip to content

[feat] optional trace hook on TestContext for runtime instrumentation#16

Merged
Thibaut-Fatus merged 1 commit into
mainfrom
feat/trace-hook
May 12, 2026
Merged

[feat] optional trace hook on TestContext for runtime instrumentation#16
Thibaut-Fatus merged 1 commit into
mainfrom
feat/trace-hook

Conversation

@Thibaut-Fatus
Copy link
Copy Markdown
Collaborator

Adds an optional trace?: (event: TraceEvent) => void field to TestContext so consumers can attach observability without taking a dependency on a specific logger. kora.runTest emits user_message and assistant_response events per turn, and runJudges emits per-judge and overall judges events. Existing consumers passing no trace are unaffected — the hook is fully optional and the package remains logger-free.

Adds an optional `trace?: (event: TraceEvent) => void` field to `TestContext` so consumers can attach observability without taking a dependency on a specific logger. `kora.runTest` emits `user_message` and `assistant_response` events per turn, and `runJudges` emits per-`judge` and overall `judges` events. Existing consumers passing no `trace` are unaffected — the hook is fully optional and the package remains logger-free.
@Thibaut-Fatus Thibaut-Fatus merged commit 587c92d into main May 12, 2026
4 checks passed
@Thibaut-Fatus Thibaut-Fatus deleted the feat/trace-hook branch May 12, 2026 11:17
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