MCPcopy Create free account

hub / github.com/BerriAI/litellm / functions

Functions202,479 in github.com/BerriAI/litellm

↓ 6 callersMethodadd
(self, spend_key: str, budget_duration: str, started_at: float, spend: float)
litellm/proxy/hooks/model_budget_shared_windows.py:45
↓ 6 callersMethodadd
(self, input_tokens: int = 0, output_tokens: int = 0, cost: float = 0.0)
litellm/harness/endpoint.py:160
↓ 6 callersMethodaddListener
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/085r5ieqhajig.js:10
↓ 6 callersMethodadd_custom_callback_generic_api_str
litellm_settings: success_callback: ["custom_callback_name"] callback_settings: custom_callback_name:
litellm/litellm_core_utils/logging_callback_manager.py:184
↓ 6 callersFunctionadd_guardrails_from_auth_metadata
Resolve key, team, and project guardrails, direct and via policies, onto the request metadata.
litellm/proxy/litellm_pre_call_utils.py:4120
↓ 6 callersMethodadd_job
(self, *args, **kwargs)
tests/unit/proxy/proxy_server/test_proxy_config.py:4797
↓ 6 callersMethodadd_litellm_async_failure_callback
Add a failure callback to litellm._async_failure_callback
litellm/litellm_core_utils/logging_callback_manager.py:113
↓ 6 callersFunctionadd_model_file_id_mappings
Create a mapping of model id to file id { "model_id": "file_id", "model_id": "file_id", } `healthy_deployments` may
litellm/litellm_core_utils/routing_common_utils.py:305
↓ 6 callersFunctionadd_model_to_db
( model_params: Deployment, user_api_key_dict: UserAPIKeyAuth, prisma_client: PrismaClient, ne
litellm/proxy/management_endpoints/model_management_endpoints.py:2128
↓ 6 callersFunctionadd_openai_metadata
Add metadata to openai optional parameters, excluding hidden params. OpenAI 'metadata' only supports string values. Args: param
litellm/utils.py:11948
↓ 6 callersMethodadd_optional_pre_call_checks
(self, optional_pre_call_checks: "Sequence[object] | None")
litellm/router_rust/steps/callbacks.py:654
↓ 6 callersMethodadd_request
(self, request: FlowItem)
tests/unit/test_scheduler.py:320
↓ 6 callersMethodadd_schema_to_components
Add a schema definition to the OpenAPI components/schemas section. Args: openapi_schema: The OpenAPI schema dict to modi
litellm/proxy/common_utils/custom_openapi_spec.py:69
↓ 6 callersFunctionadd_system_prompt_to_messages
Add a system prompt to the messages list. Args: messages: List of chat completion messages system_prompt: The system prompt
litellm/litellm_core_utils/prompt_templates/common_utils.py:1266
↓ 6 callersMethodadd_update
Count one more invocation of item's tool_name, keeping the first sighting's origin and caller fields.
litellm/proxy/db/db_transaction_queue/tool_discovery_queue.py:41
↓ 6 callersFunctionadjust_dates_for_timezone
( start_date: str, end_date: str, timezone_offset_minutes: int | None, include_current_utc_day
litellm/repositories/daily_activity_sql.py:50
↓ 6 callersFunctionadopt_model_cost_map
( new_model_cost_map: dict, # mutable-ok: public API preserves the mutable cost-map contract )
litellm/litellm_core_utils/get_model_cost_map.py:678
↓ 6 callersFunctionadvance
(position: _UpstreamPosition)
litellm/proxy/mcp_server/catalog.py:639
↓ 6 callersMethodadvance
(&mut self)
litellm-rust/crates/host-native/src/driver.rs:44
↓ 6 callersFunctionaembedding
Asynchronously calls the `embedding` function with the given arguments and keyword arguments. Parameters: - `args` (tuple): Positional a
litellm/main.py:6779
↓ 6 callersMethodaembedding
(self, *args: object, **kwargs: object)
litellm/router_rust/core.py:2580
↓ 6 callersFunctionagenerate_content
Async: Generate content using Google GenAI
litellm/google_genai/main.py:240
↓ 6 callersFunctionagenerate_content_stream
Async: Generate content using Google GenAI with streaming response
litellm/google_genai/main.py:400
↓ 6 callersFunctionagent_caller_from_headers
The caller an agent key is acting for, or ``None`` when the key is not an agent's or no id was echoed.
litellm/proxy/agent_endpoints/auth/agent_caller.py:28
↓ 6 callersFunctionagent_model_sync_env
Extra env or args an agent needs to see the proxy's model list. binary is the resolved path the launch will run (`codex.cmd` on a Windows npm
litellm/proxy/client/cli/commands/agents.py:931
↓ 6 callersFunctionaggregate_authorize
The aggregate authorize verb: validate the client, require S256 PKCE, interpose LiteLLM sign-in, and hand the browser to the connect page with the
litellm/proxy/mcp_server/gateway_dcr_flow.py:693
↓ 6 callersFunctionaj
(e,t,n)
litellm/proxy/_experimental/out/_next/static/chunks/0_6jqgnorqxl2.js:1
↓ 6 callersMethodalerting_handler
Alerting based on thresholds: - https://github.com/BerriAI/litellm/issues/1298 - Responses taking too long - Requests are ha
litellm/proxy/utils.py:3973
↓ 6 callersFunctionalias_and_metadata
(candidate: Gateway, team: str)
tests/integration/management/test_scim_group_pathless_patch.py:58
↓ 6 callersFunctionalias_map
(aliases: object)
litellm/proxy/common_utils/model_listing_utils.py:221
↓ 6 callersMethodalist_fine_tuning_jobs
( self, openai_client: AsyncOpenAI | AsyncAzureOpenAI, after: str | None = None,
litellm/llms/openai/fine_tuning/handler.py:200
↓ 6 callersMethodalist_kwargs
(self)
tests/unit/proxy/batches_endpoints/test_endpoints.py:2043
↓ 6 callersMethodalloc
(&self, layout: Layout)
litellm-rust/crates/token-counter/benches/allocations.rs:13
↓ 6 callersMethodallow
(self)
litellm/harness/types.py:111
↓ 6 callersFunctionan
litellm/proxy/_experimental/out/_next/static/chunks/138wymdv6q3wy.js:1
↓ 6 callersFunctionanswered
Park the host call `call` in the bound exchange and wait for its response. `response`, or the failure a step answered with instead ([`HostCallResponse
litellm-rust/crates/python-bridge/src/router/host.rs:513
↓ 6 callersFunctionanthropic_deployment
(name: str, identity: str, api_base: str, **fields: JsonValue)
tests/integration/routing/_prompt_cache_pin_support.py:205
↓ 6 callersFunctionanthropic_proxy_route
[Docs](https://docs.litellm.ai/docs/pass_through/anthropic_completion)
litellm/proxy/pass_through_endpoints/llm_passthrough_endpoints.py:1086
↓ 6 callersFunctionanthropic_sse_error_frames
Anthropic error event, for a failure discovered after the response headers were flushed. Once a keepalive ping has been sent a raise cannot reach
litellm/proxy/guardrails/anthropic_sse.py:53
↓ 6 callersFunctionanthropic_stream_events
(*, model: str = "claude-sonnet-5")
tests/rust-python-harness/strategies/trace_parity/fixtures.py:100
↓ 6 callersFunctionanthropic_text
(received: Received)
tests/integration/observability/test_presidio_streaming_output.py:196
↓ 6 callersFunctionany_assistant_message_has_thinking_blocks
Returns true if ANY assistant message has thinking_blocks. This is used to prevent dropping the thinking param when some messages in the
litellm/utils.py:9515
↓ 6 callersMethodapply
(self, changes: "ChangeSet")
litellm/router_core.py:42
↓ 6 callersMethodapply_guardrail
(self, inputs, request_data, input_type, logging_obj=None)
tests/unit/proxy/policy_engine/test_pipeline_executor.py:1576
↓ 6 callersFunctionapply_server_side_tool_usage_details_to_usage
Attach server_side_tool_usage_details and mirror web_search_calls onto prompt_tokens_details.web_search_requests for built-in tool cost gatin
litellm/llms/xai/cost_calculator.py:22
↓ 6 callersFunctionapply_turn
Detect signals on this turn, mutate state, return the delta. O(1) per turn (no full-history rescan). Only inspects last_*, recent tool histo
litellm/router_strategy/adaptive_router/signals.py:310
↓ 6 callersFunctionapply_upstream_reported_usage
Record the upstream's reported totals on the request's logging object. Only the values the upstream actually reported are written, so a target
litellm/proxy/pass_through_endpoints/upstream_usage_headers.py:121
↓ 6 callersFunctionapprove_guardrail_submission
Approve a pending guardrail submission: set status to active and initialize in memory (admin only).
litellm/proxy/guardrails/guardrail_endpoints.py:1064
↓ 6 callersFunctionar
(t,e)
litellm/proxy/_experimental/out/_next/static/chunks/0cz1d0mv5g_q7.js:1
↓ 6 callersMethodaresponses
(self, *args: object, **kwargs: object)
litellm/router_rust/core.py:2583
↓ 6 callersMethodarm_cooldowns
The cooldown read routing takes later, declared on the request's native pre-call batch now.
litellm/router_utils/routing_read_batch.py:42
↓ 6 callersFunctionarm_pre_call
Apply an auto router's compression policy, if any, before guardrails run. Suppresses every other compression guardrail and re-enables the model-s
litellm/proxy/guardrails/auto_router_compression.py:141
↓ 6 callersFunctionas_json_object
(value: object)
litellm/llms/vertex_ai/batches/transformation.py:41
↓ 6 callersMethodas_role
(self, role: LitellmUserRoles, user_id: str | None = "admin-user")
tests/unit/proxy/health_endpoints/test_deployment_warning_endpoints.py:84
↓ 6 callersFunctionas_tuple
(reply: Reply[Iterable[_T]])
litellm/redis/stores/_route.py:68
↓ 6 callersFunctionassemble_complete_response_from_streaming_chunks
Assemble a complete response from a streaming chunks - assemble a complete streaming response if result.choices[0].finish_reason is not None
litellm/litellm_core_utils/logging_utils.py:258
↓ 6 callersFunctionassert_canonical_tool_event
Assert tool_event has canonical PANW schema (no legacy keys).
tests/unit/proxy/guardrails/guardrail_hooks/test_panw_prisma_airs.py:133
↓ 6 callersFunctionassert_completed
(database: Database, migration: Migration = COMPLETE)
tests/e2e/migrations/checks.py:35
↓ 6 callersFunctionassert_control_answers
(gateway: Gateway, scenario: Scenario)
tests/integration/providers/_api_base_trailing_slash_support.py:312
↓ 6 callersFunctionassert_fresh_tokens_billed_at
Strip the cache components out of the gross input cost and what is left must be the freshly-read tokens at the deployment's input rate.
tests/e2e/quota_management/spend_tracking/cost_rows.py:125
↓ 6 callersFunctionassert_kept_out_of_the_deployment_metrics
(rig: Rig, cell: str)
tests/integration/observability/test_prometheus_provider_auth_failure.py:475
↓ 6 callersFunctionassert_reached_upstream_once
(received: tuple[Request, ...], route: Route, marker: str)
tests/integration/providers/_assistants_route_errors_support.py:279
↓ 6 callersFunctionassert_refusal_row
(gateway: Gateway, call_id: str, deployments: Mapping[str, str])
tests/integration/spend/test_router_cooldown_failure_row.py:206
↓ 6 callersFunctionassert_search_tool_on_the_wire
( provider: Provider, stream: bool, request: Request, body: Mapping[str, JsonValue], tools_before: int = 0
tests/integration/providers/test_chat_completions_tool_search_wire.py:430
↓ 6 callersFunctionassert_tool_search_replay_shape
Return None on success, else describe the first violation. Acceptance criteria: 1. The first turn succeeded, on the same terms as `assert_
tests/e2e/claude_code/http_probe.py:321
↓ 6 callersFunctionassert_tool_search_shape
Return None on success, else describe the first violation. Acceptance criteria: 1. The call succeeded (HTTP 200, no 400 from the upstream
tests/e2e/claude_code/http_probe.py:298
↓ 6 callersFunctionassert_upgraded
(before: frozenset[str], after: frozenset[str])
tests/e2e/migrations/upgrade.py:124
↓ 6 callersFunctionassistant_text_from_response
The assistant's natural-language text from a model response, across chat, Anthropic, and Responses shapes. Preserved when the turn is rebuilt for
litellm/proxy/guardrails/guardrail_hooks/content_text.py:61
↓ 6 callersMethodassume_role_with_web_identity
( self, *, RoleArn: str, RoleSessionName: str, WebIdentityToken: str, **_: int )
tests/unit/proxy/auth/test_rds_iam_token.py:83
↓ 6 callersMethodastype
(self, dtype: object)
litellm/llms/nvidia_riva/audio_transcription/audio_utils.py:44
↓ 6 callersMethodasync_anthropic_sse_wrapper
SSE-encoded bytes for each Anthropic event chunk.
litellm/llms/anthropic/messages/responses_adapters/streaming_iterator.py:548
↓ 6 callersMethodasync_audio_transcriptions
( self, model: str, audio_file: FileTypes, optional_params: dict, lite
litellm/llms/custom_httpx/llm_http_handler.py:2181
↓ 6 callersMethodasync_build_agentic_loop_plan
( self, tools: dict, model: str, messages: list[dict], response: objec
litellm/integrations/websearch_interception/handler.py:963
↓ 6 callersFunctionasync_gen
()
tests/unit/llms/base_llm/test_base_model_iterator.py:220
↓ 6 callersMethodasync_get_available_deployments
( self, model_group: str, healthy_deployments: list, messages:
tests/unit/router_strategy/test_lowest_tpm_rpm.py:118
↓ 6 callersMethodasync_get_cache
(self, *, key: str)
litellm/proxy/management_endpoints/mcp_management_endpoints.py:112
↓ 6 callersMethodasync_get_cache
(self, key: str)
tests/unit/integrations/focus/test_focus_logger.py:22
↓ 6 callersMethodasync_get_cache
(self, **kwargs)
tests/unit/caching/test_caching_handler.py:2671
↓ 6 callersMethodasync_increment
( self, key, value: float, ttl: int | None = None, parent_otel_span: S
litellm/caching/redis_cache.py:1402
↓ 6 callersMethodasync_increment_cache_post_call
Memory is incremented now; the Redis increment rides the request's post-call pipeline when one is open, and runs on its own as ``async_increme
litellm/caching/dual_cache.py:585
↓ 6 callersMethodasync_increment_reservation_aware_tokens
( self, pipeline_operations: Sequence[ReservationOperation], parent_otel_span: Span |
litellm/proxy/hooks/parallel_request_limiter_v3.py:4276
↓ 6 callersMethodasync_log_failure_event
(self, kwargs, response_obj, start_time, end_time)
litellm/router_utils/pre_call_checks/model_rate_limit_check.py:526
↓ 6 callersMethodasync_log_success_event
( self, kwargs: Mapping[str, object], response_obj: object, start_time: object, end_time: object )
tests/unit/extraction/test_main.py:349
↓ 6 callersMethodasync_lookup
( &self, request: &ResponseCacheRequest<B::Context>, now: Duration, )
litellm-rust/crates/cache-response/src/response.rs:123
↓ 6 callersMethodasync_lookup_pods
(self, deployment: object)
litellm/router_utils/kubernetes_pod_discovery.py:199
↓ 6 callersMethodasync_lpop
( self, key: str, count: int | None = None, parent_otel_span: Span | None = No
litellm/caching/redis_cache.py:2266
↓ 6 callersMethodasync_moderation_hook
(self, data, user_api_key_dict, call_type)
tests/unit/proxy/test_proxy_utils.py:2909
↓ 6 callersMethodasync_post_call_failure_hook
Track client side failures Proxy level tracking - failed client side requests See :attr:`PrometheusMetricLabels.litellm_pro
litellm/integrations/prometheus.py:3038
↓ 6 callersMethodasync_post_call_streaming_iterator_hook
(self, user_api_key_dict, response, request_data)
tests/unit/proxy/test_model_level_guardrails.py:467
↓ 6 callersMethodasync_pre_call_check
(self, deployment: dict, parent_otel_span: object)
tests/unit/test_router/core/test_legacy_members.py:71
↓ 6 callersMethodasync_pre_call_hook
( self, user_api_key_dict: UserAPIKeyAuth, cache: DualCache, data: dict[str, o
litellm/proxy/guardrails/guardrail_hooks/bedrock_guardrails.py:2678
↓ 6 callersMethodasync_read_secret
( self, secret_name: str, optional_params: dict[str, object] | None = None, ti
tests/unit/rust_bridge/host/test_settings.py:97
↓ 6 callersMethodasync_realtime
( self, model: str, websocket: _RealtimeClientWebSocket, logging_obj: LiteLLML
litellm/llms/custom_httpx/llm_http_handler.py:6851
↓ 6 callersMethodasync_replicate_secret
Replicate a secret to additional AWS regions using ReplicateSecretToRegions. Called after a successful CreateSecret when replica_reg
litellm/secret_managers/aws_secret_manager_v2.py:447
↓ 6 callersMethodasync_send_batch
Sends runs from self.log_queue. Raises S3BatchUploadError when any upload failed; CustomBatchLogger.flush_queue keeps the su
litellm/integrations/s3_v2.py:675
↓ 6 callersMethodasync_service_success_hook
- For counting if the redis, postgres call is successful
litellm/_service_logger.py:219
↓ 6 callersMethodasync_set_cache
(self, *, key: str, value: str, ttl: int)
litellm/proxy/management_endpoints/mcp_management_endpoints.py:108
↓ 6 callersMethodasync_set_cache
(self, key, value, **kwargs)
tests/unit/proxy/hooks/test_unit_test_max_model_budget_limiter.py:1582
↓ 6 callersMethodasync_set_cache
( &self, key: &str, value: Self::Value, context: Self::Context, )
litellm-rust/crates/cache-qdrant-semantic/src/cache.rs:216
↓ 6 callersMethodasync_set_cache_sadd
Add value to a set Key - the key in cache Value - str - the value you want to add to the set Returns - None
litellm/caching/dual_cache.py:651
← previousnext →12,601–12,700 of 202,479, ranked by callers