litellm/tests/batches_tests
mateo-berri 0b09588685 refactor(batches): aggregate batch output cost, usage, and models in a single pass
Completed-batch cost tracking parsed the whole output file into a list of
dicts, pretty-printed it into debug strings even with debug logging off, and
walked the list three times (cost, usage, models), so a large batch output
could pin a worker's memory. The output is now folded line by line into small
per-line stats records via _aggregate_batch_cost_usage_models, the eager
json.dumps debug calls are gone, and the raw-vertex path computes cost and
usage in one call instead of two. _get_batch_output_file_content_as_dictionary
becomes _fetch_batch_output_file_content (returns bytes); the superseded
three-pass helpers are deleted and their tests migrated
2026-07-29 22:00:01 -07:00
..
batch_job_results_furniture.jsonl (feat) Add cost tracking for /batches requests OpenAI (#7384) 2024-12-23 17:47:26 -08:00
bedrock_batch_completions.jsonl test fix us.anthropic.claude-haiku-4-5-20251001-v1:0 (#24931) 2026-04-01 11:01:03 -07:00
conftest.py test: stabilize batch VCR coverage and stop live upload/network leaks (#29477) 2026-06-02 16:11:52 -07:00
openai_batch_completions.jsonl (feat) Add cost tracking for /batches requests OpenAI (#7384) 2024-12-23 17:47:26 -08:00
pathrise-convert-1606954137718.json use pathrise-convert-1606954137718 2025-01-05 14:14:43 -08:00
test_batch_custom_pricing.py refactor(batches): aggregate batch output cost, usage, and models in a single pass 2026-07-29 22:00:01 -07:00
test_batch_rate_limits.py refactor(batches): aggregate batch output cost, usage, and models in a single pass 2026-07-29 22:00:01 -07:00
test_batches_logging_unit_tests.py refactor(batches): aggregate batch output cost, usage, and models in a single pass 2026-07-29 22:00:01 -07:00
test_bedrock_files_and_batches.py test: stabilize batch VCR coverage and stop live upload/network leaks (#29477) 2026-06-02 16:11:52 -07:00
test_fine_tuning_api.py test: remove live OpenAI fine-tuning job-creation test blocked by platform wind-down (#32933) 2026-07-11 12:57:37 -07:00
test_hosted_vllm_batches_and_files.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_manus_files_all_methods.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_openai_batches_and_files.py fix(vertex_ai/files): single media upload for batch files to fix 499s on large uploads (#31653) 2026-06-29 17:31:32 -07:00
vertex_batch_completions.jsonl (feat) Add cost tracking for /batches requests OpenAI (#7384) 2024-12-23 17:47:26 -08:00