Skip to content

Commit 8c53c6d

Browse files
umaannamalaimergify[bot]hmstepanek
authored
Add Gemini instrumentation (#1379)
* Add Gemini test infrastructure. (#1343) * Add Gemini test infra. * Pull tox.ini changes. * [MegaLinter] Apply linters fixes * Remove mock package dependency. * [MegaLinter] Apply linters fixes --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> * Add Gemini embeddings. * [MegaLinter] Apply linters fixes * Address review comments. * Key into kwargs dict. * Update embedding error logic. * Fix embeddings error tests for py39. * [MegaLinter] Apply linters fixes * Add Gemini test infrastructure. (#1343) * Add Gemini test infra. * Pull tox.ini changes. * [MegaLinter] Apply linters fixes * Remove mock package dependency. * [MegaLinter] Apply linters fixes --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> * Add Gemini embeddings. * [MegaLinter] Apply linters fixes * Address review comments. * Key into kwargs dict. * Update embedding error logic. * Fix embeddings error tests for py39. * [MegaLinter] Apply linters fixes * Add Gemini text generations. * Bump tests. * [MegaLinter] Apply linters fixes * Fix py39 errors test failure. * [MegaLinter] Apply linters fixes * Add comments. * Update request message logic. * [MegaLinter] Apply linters fixes * Add string-based tests. * Add Gemini test infrastructure. (#1343) * Add Gemini test infra. * Pull tox.ini changes. * [MegaLinter] Apply linters fixes * Remove mock package dependency. * [MegaLinter] Apply linters fixes --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> * Add Gemini embeddings. * [MegaLinter] Apply linters fixes * Address review comments. * Key into kwargs dict. * Update embedding error logic. * Fix embeddings error tests for py39. * [MegaLinter] Apply linters fixes * Add Gemini text generations. * Bump tests. * Fix py39 errors test failure. * [MegaLinter] Apply linters fixes * Add comments. * [MegaLinter] Apply linters fixes * Add Gemini embeddings. * Address review comments. * Key into kwargs dict. * Fix embeddings error tests for py39. * [MegaLinter] Apply linters fixes * Update request message logic. * Add string-based tests. * [MegaLinter] Apply linters fixes * Address review. * Temporarily pin redis tests. * Temporarily pin redis tests to below v5.3.0. --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> Co-authored-by: Hannah Stepanek <[email protected]>
1 parent c346346 commit 8c53c6d

File tree

9 files changed

+3156
-2
lines changed

9 files changed

+3156
-2
lines changed

newrelic/config.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2009,6 +2009,8 @@ def _process_module_builtin_defaults():
20092009
)
20102010
_process_module_definition("openai._base_client", "newrelic.hooks.mlmodel_openai", "instrument_openai_base_client")
20112011

2012+
_process_module_definition("google.genai.models", "newrelic.hooks.mlmodel_gemini", "instrument_genai_models")
2013+
20122014
_process_module_definition(
20132015
"asyncio.base_events", "newrelic.hooks.coroutines_asyncio", "instrument_asyncio_base_events"
20142016
)

0 commit comments

Comments
 (0)