litellm/tests/unit/router_utils/pre_call_checks
Nate Armstrong c60a320b05
perf(token_counter): memoize token counts of long texts per tokenizer (#51904)
* perf(token_counter): memoize token counts of long texts per tokenizer

* test(prompt_caching): count a prompt no other test has counted in the loop lag checks

* fix(token_counter): key the count memo on the string hash instead of blake2b

* test(router): embed distinct texts so the batches are counted in full

* test: time token counts over text no earlier count has memoized
2026-11-16 19:21:55 +00:00
..
__init__.py test: add __init__.py to new tests/unit packages 2026-09-20 12:36:13 +00:00
test_continuation_prefill_check.py fix(router): continue Responses mid-stream fallbacks on models without assistant prefill (#47672) 2026-10-28 04:34:40 -07:00
test_deployment_affinity_check.py feat(redis): serve the router's session pins from a native store (#50870) 2026-11-13 03:22:28 +00:00
test_encrypted_content_affinity_check.py feat(redis): serve the router's session pins from a native store (#50870) 2026-11-13 03:22:28 +00:00
test_prompt_caching_deployment_check.py perf(token_counter): memoize token counts of long texts per tokenizer (#51904) 2026-11-16 19:21:55 +00:00
test_responses_api_deployment_check.py refactor: expose core private helpers under public names (#44871) 2026-10-07 00:05:27 +00:00
test_session_id_affinity.py feat(redis): serve the router's session pins from a native store (#50870) 2026-11-13 03:22:28 +00:00