[MLOS-459] Support enriched evalmetric event submission#7503
[MLOS-459] Support enriched evalmetric event submission#7503
Conversation
This comment has been minimized.
This comment has been minimized.
Overall package sizeSelf size: 4.61 MB Dependency sizes| name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 2.0.6 | 81.92 kB | 813.08 kB | | dc-polyfill | 0.1.10 | 26.73 kB | 26.73 kB |🤖 This report was automatically generated by heaviest-objects-in-the-universe |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #7503 +/- ##
==========================================
+ Coverage 80.13% 80.18% +0.04%
==========================================
Files 730 731 +1
Lines 31104 31212 +108
==========================================
+ Hits 24926 25026 +100
- Misses 6178 6186 +8
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
BenchmarksBenchmark execution time: 2026-02-13 15:48:25 Comparing candidate commit 27c9b5a in PR branch Found 0 performance improvements and 0 performance regressions! Performance is the same for 231 metrics, 29 unstable metrics. |
sabrenner
left a comment
There was a problem hiding this comment.
noting for transparency on the pr that we talked briefly offline that we might also have to include an update to use the v2 endpoint of the evaluation metrics api. this should not have an impact on the existing api here
…svigruha/eval-data-model-new-fields
sabrenner
left a comment
There was a problem hiding this comment.
just a couple more js-specific comments! thanks for attaching manual tests in the pr description 🙇
packages/dd-trace/src/llmobs/sdk.js
Outdated
| if (reasoning !== undefined) { | ||
| payload.reasoning = reasoning | ||
| } | ||
| if (metadata !== undefined) { | ||
| payload.metadata = metadata | ||
| } | ||
| if (assessment !== undefined) { | ||
| payload.assessment = assessment | ||
| } |
There was a problem hiding this comment.
these will allow null values through (in js, null !== undefined). we can do this instead
| if (reasoning !== undefined) { | |
| payload.reasoning = reasoning | |
| } | |
| if (metadata !== undefined) { | |
| payload.metadata = metadata | |
| } | |
| if (assessment !== undefined) { | |
| payload.assessment = assessment | |
| } | |
| if (reasoning != null) { | |
| payload.reasoning = reasoning | |
| } | |
| if (metadata != null) { | |
| payload.metadata = metadata | |
| } | |
| if (assessment != null) { | |
| payload.assessment = assessment | |
| } |
as null == undefined
There was a problem hiding this comment.
thanks! i can never wrap my head around TS null vs undefined and == vs ===
sabrenner
left a comment
There was a problem hiding this comment.
looks great! unless the diff is bugged on my end it looks like we still have
assessment?: stringinstead of 'pass' | 'fail' in the index.d.ts but not a blocker
|
I added |
* Add reasoning, assessment and metadata * more guards * nit * fix syntax * some unit tests * more tests * fix lint * undefined * address comments * partial revert * revert metadata * pass / fail * fix test * fix test * json * token * doh * fix message * fix doc * fixes * fix
* Add reasoning, assessment and metadata * more guards * nit * fix syntax * some unit tests * more tests * fix lint * undefined * address comments * partial revert * revert metadata * pass / fail * fix test * fix test * json * token * doh * fix message * fix doc * fixes * fix
What does this PR do?
Adds reasoning, metadata and assessment to the submitEvaluation endpoint.
Add support for JSON value type.
Motivation
Close feature gaps between the Python SDK.
Customer FR: https://datadoghq.atlassian.net/browse/MLOS-459
Test