mirror of
https://github.com/tiennm99/litellm.git
synced 2026-08-02 06:22:48 +00:00
* fix(unified_guardrails.py): send all chunks on completion of final stream * feat(generic_guardrail_api.py): handle tool call response on streaming LLM responses * fix(anthropic/chat/guardrail_translation): initial commit adding anthropic tool response streaming guardrails enables guardrail checks on tool response from llm's to work via `/v1/messages` * feat(anthropic/): working guardrail checks on tool response from LLMs ensures guardrail checks on anthropic /v1/messages works as expected * feat(responses/guardrail_translation): support tool call response guardrails on streaming for /v1/responses ensures complete coverage of tool call responses * refactor(openai.py): refactor to use consistent pydantic model for responses api tool response on streaming enables non-openai model tool call response to work correctly with guardrail checks on /v1/responses * test: update tests * fix: fix linting error * fix: fix failing tests * fix: fix import errors * fix(openai/chat/guardrail_transformation): fix final chunk returned on streaming
Testing for litellm/
This directory 1:1 maps the the litellm/ directory, and can only contain mocked tests.
The point of this is to:
- Increase test coverage of
litellm/ - Make it easy for contributors to add tests for the
litellm/package and easily run tests without needing LLM API keys.
File name conventions
litellm/proxy/test_caching_routes.pymaps tolitellm/proxy/caching_routes.pytest_<filename>.pymaps tolitellm/<filename>.py