Skip to content

OpenAI Token Counting#1751

Draft
TimPansino wants to merge 4 commits into
mainfrom
feat-openai-token-counting
Draft

OpenAI Token Counting#1751
TimPansino wants to merge 4 commits into
mainfrom
feat-openai-token-counting

Conversation

@TimPansino
Copy link
Copy Markdown
Contributor

Overview

  • Add token counting to OpenAI SDK for all LLM invocations.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 2, 2026

MegaLinter analysis: Success

Descriptor Linter Files Fixed Errors Warnings Elapsed time
✅ ACTION actionlint 8 0 0 1.26s
✅ MARKDOWN markdownlint 7 0 0 0 1.64s
✅ PYTHON ruff 1038 0 0 0 1.35s
✅ PYTHON ruff-format 1038 0 0 0 0.5s
✅ YAML prettier 20 0 0 0 1.95s
✅ YAML v8r 20 0 0 5.86s
✅ YAML yamllint 20 0 0 0.79s

Notices

📣 MegaLinter 9.5.0 is out! Discover the new features and security recommendations in the release announcement. (Skip this info by defining SECURITY_SUGGESTIONS: false)

See detailed reports in MegaLinter artifacts

MegaLinter is graciously provided by OX Security
Show us your support by starring ⭐ the repository

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Jun 2, 2026

Codecov Report

❌ Patch coverage is 93.33333% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.02%. Comparing base (c972036) to head (458c39e).

Files with missing lines Patch % Lines
newrelic/hooks/mlmodel_openai.py 93.33% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1751      +/-   ##
==========================================
- Coverage   82.08%   82.02%   -0.07%     
==========================================
  Files         215      215              
  Lines       26324    26352      +28     
  Branches     4153     4160       +7     
==========================================
+ Hits        21609    21614       +5     
- Misses       3300     3317      +17     
- Partials     1415     1421       +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mergify mergify Bot added the tests-failing Tests failing in CI. label Jun 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tests-failing Tests failing in CI.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants