From fdaaea9b0d81db43fa51df63acd26e01fe2989ad Mon Sep 17 00:00:00 2001 From: Ishaan Jaff Date: Fri, 30 Aug 2024 07:30:16 -0700 Subject: [PATCH] add tests to check ai21 models cost is calculated correct --- litellm/tests/test_amazing_vertex_completion.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/litellm/tests/test_amazing_vertex_completion.py b/litellm/tests/test_amazing_vertex_completion.py index a4238995dcb..ec76d2cb093 100644 --- a/litellm/tests/test_amazing_vertex_completion.py +++ b/litellm/tests/test_amazing_vertex_completion.py @@ -2555,3 +2555,7 @@ async def test_partner_models_httpx_ai21(): assert response.usage.total_tokens == 194 print(f"response: {response}") + + print("hidden params from response=", response._hidden_params) + + assert response._hidden_params["response_cost"] > 0