Commit graph

10 commits

Author SHA1 Message Date
Krish Dholakia
1e7e538261
LiteLLM Minor fixes + improvements (08/04/2024) (#5505)
* Minor IAM AWS OIDC Improvements (#5246)

* AWS IAM: Temporary tokens are valid across all regions after being issued, so it is wasteful to request one for each region.

* AWS IAM: Include an inline policy, to help reduce misuse of overly permissive IAM roles.

* (test_bedrock_completion.py): Ensure we are testing cross AWS region OIDC flow.

* fix(router.py): log rejected requests

Fixes https://github.com/BerriAI/litellm/issues/5498

* refactor: don't use verbose_logger.exception, if exception is raised

User might already have handling for this. But alerting systems in prod will raise this as an unhandled error.

* fix(datadog.py): support setting datadog source as an env var

Fixes https://github.com/BerriAI/litellm/issues/5508

* docs(logging.md): add dd_source to datadog docs

* fix(proxy_server.py): expose `/customer/list` endpoint for showing all customers

* (bedrock): Fix usage with Cloudflare AI Gateway, and proxies in general. (#5509)

* feat(anthropic.py): support 'cache_control' param for content when it is a string

* Revert "(bedrock): Fix usage with Cloudflare AI Gateway, and proxies in gener…" (#5519)

This reverts commit 3fac0349c2.

* refactor: ci/cd run again

---------

Co-authored-by: David Manouchehri <david.manouchehri@ai.moda>
2024-09-04 22:16:55 -07:00
Idris Mokhtarzada
c2c5877afa
Fix Datadog JSON serialization
Nested dicts were not being serialized properly
2024-07-27 02:16:36 -04:00
Idris Mokhtarzada
e8d4234dbd
Better JSON serialization for Datadog logs
Dicts are now properly serialized to JSON so that Datadog can parse the child attributes.  Also, numbers and nulls are sent as numbers and nulls instead of strings.
2024-07-26 17:02:05 -04:00
Idris Mokhtarzada
a7e877d15f
Use milliseconds for response_time in Datadog logs
milliseconds is more commonly used and more standard than seconds
2024-07-26 16:43:21 -04:00
Idris Mokhtarzada
9b89280a90
Use underscores
Datadog does not play nice with special characters (as in "(seconds)").  Also just makes sense to standardize on either underscores or camelCase, but not mix-and-match.
2024-07-26 16:38:54 -04:00
Krrish Dholakia
6cca5612d2 refactor: replace 'traceback.print_exc()' with logging library
allows error logs to be in json format for otel logging
2024-06-06 13:47:43 -07:00
Krrish Dholakia
4a3b084961 feat(bedrock_httpx.py): moves to using httpx client for bedrock cohere calls 2024-05-11 13:43:08 -07:00
Krrish Dholakia
6575143460 feat(proxy_server.py): return litellm version in response headers 2024-05-08 16:00:08 -07:00
Ishaan Jaff
fedb4e5703 (fix) clean dd imports 2024-03-18 16:40:58 -07:00
Ishaan Jaff
2afddf4536 (feat) init datadog logger 2024-03-18 16:27:01 -07:00