Skip to content

Add RFC-0012: Trace-Aware Webhook Events - #41

Open
Nehanth wants to merge 2 commits into
mlflow:mainfrom
Nehanth:add-trace-webhook-events-rfc
Open

Nehanth wants to merge 2 commits into
mlflow:mainfrom
Nehanth:add-trace-webhook-events-rfc

Conversation

@Nehanth

@Nehanth Nehanth commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Splitting #38 into two standalone RFCs per the review feedback. This is the first: webhook events for the observability side — evaluation scores crossing a threshold, issue detection creating or updating an issue, and traces completing with errors — reusing the webhook delivery system MLflow already ships. Useful on its own.

Follows the template with the journeys-first model: Detailed design, Drawbacks, Alternatives, and Adoption strategy are TBD until the journeys are settled. Review feedback from #38 is incorporated.

Webhook events for the observability side: evaluation threshold
breaches, issue detection findings, and trace errors, reusing the
existing webhook delivery system.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

@B-Step62 B-Step62 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.

I know this is probably still WIP but just wanted to comment on one internal context that can affect the design.

"feedback_name": "correctness",
"threshold": 0.7,
"direction": "below",
"window_size": 10,

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.

I think trace signal should be aggregated into metrics with fixed unit (e.g. 1 minute average) before being emitted as webhook events. Using the raw event count for aggregation is not practical - target duration becomes highly dynamic depends on the trace traffic. At the same time, implementing it as a part of webhook API complicates the interface (e.g. no other events require that level of complexity).

We have some WIP design for this aggregation for alerting purpose, so probably combine it with this RFC.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, agreed — fixed time units make a lot more sense. Since you already have a WIP design for the aggregation side, what would be the best way to combine the two? Happy to keep this PR open and update it to line up with your design once it's shareable — is there a rough timeline for when that might be?


| Event | Fires from |
|---|---|
| `trace_feedback.threshold_breached` | The online scoring job (automatic evaluations), immediately after it writes a judge score — server-internal, not a public API endpoint. Scores logged manually through the feedback API do not trigger it. |

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.

I might miss some context about the full agent improvement proposal, but this doesn't seem to be necessary for building that flow in MLflow? Scheduled issue detection job can be the trigger for the whole workflow.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes — it could run detection itself and read the results directly. It could also build on these events, so runs started from the UI or API feed it the same way. In my opinion the webhooks are worth having either way, since customers can build their own tooling on top of them (Slack, CI, their own pipelines) even without the improvement workflow — but what do you think?

Per review feedback: count-based windows behave differently for busy
and quiet agents; fixed time units are predictable. Also notes the
in-progress aggregation-for-alerting design as the likely home for
the rule layer.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@Nehanth

Nehanth commented Aug 26, 2026

Copy link
Copy Markdown
Contributor Author

Hey @mprahl @HumairAK @B-Step62 @jwm4 — this RFC is intentionally user-journey first; I can make it a bit more detailed after we all agree on them. Would appreciate a review of the user journeys in this RFC and the companion one (#42) when you get a chance!

@Nehanth
Nehanth requested a review from B-Step62 August 31, 2026 15:44
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