Allow token usage statistics to be unavailable - #279
Conversation
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## trunk #279 +/- ##
============================================
+ Coverage 86.49% 86.51% +0.02%
- Complexity 1327 1331 +4
============================================
Files 68 68
Lines 4295 4302 +7
============================================
+ Hits 3715 3722 +7
Misses 580 580
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Closes #158
Allows providers to omit token usage statistics without manufacturing zero values. TokenUsage fields and accessors now accept null, GenerativeAiResult can carry a null usage object, array and JSON schema transformations preserve the absence, and unit coverage documents the behavior.