MCPcopy Create free account

hub / github.com/BerriAI/litellm / functions

Functions202,479 in github.com/BerriAI/litellm

↓ 165 callersFunctionpin
(tenant: &str, session_id: &str)
litellm-rust/crates/redis-store/src/sensitive_route_pins/keys.rs:1
↓ 163 callersMethodstring
`scanstring` with `strict=True`: control characters must be escaped.
litellm-rust/crates/python-compat/src/json.rs:187
↓ 163 callersMethodsub
(self, repl: str, string: str, count: int = 0)
tests/unit/test_logging.py:1073
↓ 163 callersMethodtoUpperCase
()
litellm/proxy/_experimental/out/_next/static/chunks/2j7hjtph8n74b.js:1
↓ 163 callersMethodupdate_environment_variables
( self, litellm_params: dict, optional_params: dict, model: str | None = None,
litellm/litellm_core_utils/litellm_logging.py:1233
↓ 162 callersMethodmodel_dump
(self, *, exclude_none: bool = ...)
tests/integration/providers/_mantle_gpt_prompt_cache_support.py:778
↓ 161 callersMethodescape
(&mut self)
litellm-rust/crates/python-compat/src/json.rs:213
↓ 161 callersMethodrespond_with
(self, response: object)
tests/unit/proxy/video_endpoints/test_endpoints.py:135
↓ 160 callersMethodparam
(self)
tests/integration/observability/test_otel_excluded_services_matrix.py:43
↓ 160 callersMethodsort
(self, *args: object, **kwargs: object)
litellm/router_rust/surface/indexes.py:120
↓ 159 callersMethoddirname
()
litellm/proxy/_experimental/out/_next/static/chunks/14v3irtjifjt2.js:1
↓ 159 callersFunctioneY
(...e)
litellm/proxy/_experimental/out/_next/static/chunks/085r5ieqhajig.js:1
↓ 159 callersMethodtimestamp
(self)
tests/unit/integrations/newrelic/test_newrelic.py:519
↓ 158 callersFunctionget_httpx_client
Retrieves the HTTP client from the cache If not present, creates a new client Caches the new client and returns it.
litellm/llms/custom_httpx/http_handler.py:1989
↓ 158 callersMethodresolve
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/085r5ieqhajig.js:1
↓ 156 callersMethodget_supported_openai_params
(self, model)
tests/unit/llms/custom_httpx/test_llm_http_handler.py:4682
↓ 156 callersMethodsleep
(self, seconds: float)
litellm/router_python_host.py:116
↓ 153 callersMethodapply
(self, changes: ChangeSet)
tests/unit/proxy/management_endpoints/test_model_management_endpoints.py:3911
↓ 153 callersFunctioncompletion_cost
Return the USD cost of a LiteLLM call. Pass `completion_response` to price a response LiteLLM returned. Without one, pass `model` plus `
litellm/cost_calculator.py:1783
↓ 152 callersMethodwarn
(self, session: ClientSession)
litellm/llms/custom_httpx/aiohttp_pool_diagnostics.py:59
↓ 151 callersMethodselect
( model: str, request_kwargs: Mapping[str, object], *, kind: L
tests/unit/router_strategy/test_complexity_router.py:6848
↓ 150 callersFunctionid
({draft:e})
litellm/proxy/_experimental/out/_next/static/chunks/1f2vcab0yti03.js:53
↓ 150 callersMethodjson
(self)
litellm/llms/sap/credentials.py:392
↓ 150 callersMethodreload
(self)
litellm/proxy/db/pgbouncer.py:629
↓ 150 callersMethodupdate
(self, where: Dict[str, Any], data: Dict[str, Any])
tests/unit/repositories/test_repositories.py:98
↓ 149 callersMethodfocus
()
litellm/proxy/_experimental/out/_next/static/chunks/085r5ieqhajig.js:1
↓ 149 callersMethodtoString
()
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 148 callersMethodsetdefault
(self, key: object, default: object = None)
litellm/router_rust/surface/indexes.py:182
↓ 147 callersFunctionact
(page: Page)
tests/e2e/perf/setup/ui_journeys.py:342
↓ 146 callersFunctionget_logging_payload
( kwargs: dict | None, response_obj: object, start_time: datetime, end_time: datetime, llm
litellm/proxy/spend_tracking/spend_tracking_utils.py:612
↓ 145 callersMethodtime
(self)
tests/unit/llms/custom_httpx/test_http_handler.py:2458
↓ 144 callersFunctioncompletion
()
tests/unit/litellm_core_utils/prompt_templates/test_litellm_core_utils_prompt_templates_factory.py:6276
↓ 144 callersMethodgroup
(self, name: str)
tests/integration/spend/test_router_cooldown_failure_row.py:62
↓ 144 callersMethodsettings
(self)
tests/unit/router_utils/test_fallback_event_handlers.py:63
↓ 143 callersMethodstart
(self, ctx: SessionContext)
tests/unit/harness/core_fakes.py:179
↓ 142 callersFunctionattempt
The response, or the error the core raised. A request the Rust core does not serve yet propagates, so the test is skipped rather than failed.
tests/unit/test_router/core/retries_health_helpers.py:81
↓ 142 callersMethodreset
Empty the host's success and failure callback lists (every entry, not only this core's), drop the retry policy and flush the caches.
litellm/router_rust/core.py:2341
↓ 142 callersMethodrespond
(self, request: httpx.Request)
tests/unit/proxy/guardrails/guardrail_hooks/test_wingback.py:197
↓ 140 callersFunction_invalidate_model_cost_lowercase_map
Invalidate the case-insensitive lookup map for model_cost. Call this whenever litellm.model_cost is modified to ensure the map is rebuilt. Al
litellm/utils.py:6810
↓ 140 callersMethodbind
(self, call_id: str)
litellm/proxy/telemetry/request_context.py:29
↓ 140 callersMethodendsWith
(e,t)
litellm/proxy/_experimental/out/_next/static/chunks/2j7hjtph8n74b.js:1
↓ 140 callersMethodmodel_dump
(self)
litellm/proxy/mcp_server/utils.py:707
↓ 140 callersMethodtype
()
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 139 callersMethod_handle_error
( self, e: Exception, provider_config: Union[ BaseConfig, Base
litellm/llms/custom_httpx/llm_http_handler.py:6693
↓ 139 callersFunctiongenerate_mock_user_api_key_auth
Generate a mock UserAPIKeyAuth object
tests/unit/proxy/management_endpoints/test_mcp_management_endpoints.py:107
↓ 138 callersMethodflush
(self)
tests/unit/telemetry/test_consent.py:50
↓ 137 callersFunctionField
({ className, orientation = "vertical", ...props }: React.ComponentProps<"div"> & VariantProps<typeof fi
ui/litellm-dashboard/src/components/ui/field.tsx:66
↓ 137 callersFunctionis_request_body_safe
Check if the request body is safe. A malicious user can set the api_base to their own domain and invoke POST /chat/completions to intercept
litellm/proxy/auth/auth_utils.py:775
↓ 137 callersFunctionreplace
(gateway: Gateway, name: str, body: Mapping[str, JsonValue], *, key: str | None = None)
tests/integration/management/test_claude_code_plugin_installation_preference.py:68
↓ 136 callersMethoddict
(self, *, exclude_none: bool)
tests/unit/proxy/mcp_server/test_semantic_tool_filter.py:2265
↓ 136 callersFunctionexception_type
Maps an LLM Provider Exception to OpenAI Exception Format
litellm/litellm_core_utils/exception_mapping_utils.py:2539
↓ 136 callersMethodgroup
( self, name: str, *, field: Literal["info", "cached_info"] = "info",
litellm/router_api.py:922
↓ 136 callersFunctionunquote
(raw: string)
ui/litellm-dashboard/src/components/shared/search/language.ts:59
↓ 135 callersMethodadd
(e)
litellm/proxy/_experimental/out/_next/static/chunks/0tx19jeq-wskb.js:2
↓ 135 callersMethodreset
()
litellm/proxy/_experimental/out/_next/static/chunks/0tx19jeq-wskb.js:2
↓ 132 callersMethodisNaN
()
litellm/proxy/_experimental/out/_next/static/chunks/2aatum0yo4cv8.js:1
↓ 131 callersMethodpost_call
( self, *, original_response: object, input: Sequence[AllMessageValues],
litellm/llms/microsoft_365_copilot/chat/handler.py:67
↓ 131 callersFunctionregister_scenario
(scenario_id: str, response: StoredResponse, *, control_url: str = CONTROL_URL)
tests/integration/_support/upstream.py:874
↓ 129 callersMethodasync_post_call_success_hook
(self, data: dict, user_api_key_dict: UserAPIKeyAuth, response: Any)
tests/unit/proxy/guardrails/test_deferred_guardrail_logging.py:113
↓ 129 callersFunctionget_optional_params
( # use the openai defaults # https://platform.openai.com/docs/api-reference/chat/create model: st
litellm/utils.py:5553
↓ 129 callersMethodis_empty
(&self)
litellm-rust/crates/config/src/value.rs:21
↓ 129 callersMethodreplacing_worker
(self, pid: int)
tests/integration/_support/process.py:330
↓ 128 callersMethodfilter
(self, record: logging.LogRecord)
tests/rust-python-harness/shared/reporting/ui.py:20
↓ 127 callersMethodat
(self, now: datetime)
litellm/types/proxy/skill_scanning.py:75
↓ 127 callersMethodmodel
(self)
tests/integration/authorization/test_team_admin_gate.py:96
↓ 127 callersMethodtoken_counter
(self, key: str, body: TokenCounterBody)
tests/e2e/proxy_client.py:1095
↓ 126 callersMethodasync_pre_routing_hook
Pre-routing hook called before the routing decision. When `session_affinity` is enabled and a session_id is resolvable on the reques
litellm/router_strategy/complexity_router/complexity_router.py:4497
↓ 126 callersMethoddone
()
tests/unit/test_router/core/scripted_host.py:329
↓ 126 callersMethodencode
( self, text: str, *, allowed_special: AllowedSpecial = frozenset(), d
litellm/litellm_core_utils/tokenizer.py:85
↓ 125 callersMethodasync_set_cache
Inside a request the Redis SET rides the request's pipeline (memory is written at once); anywhere else, or with options the pipeline does not
litellm/proxy/common_utils/user_api_key_cache.py:312
↓ 125 callersMethodconcat
(...e)
litellm/proxy/_experimental/out/_next/static/chunks/2aatum0yo4cv8.js:1
↓ 125 callersMethodnow
(cls, tz=None)
tests/unit/integrations/azure_storage/test_azure_storage.py:583
↓ 124 callersMethodsleep
(self, seconds: float)
tests/unit/proxy/management_endpoints/test_access_group_management.py:698
↓ 124 callersMethodstream
()
tests/integration/_support/upstream.py:599
↓ 123 callersFunctionbuild
(make_core: MakeCore, **arguments: object)
tests/unit/test_router/core/fallbacks_helpers.py:23
↓ 122 callersMethodcreate
(self, template: Database | None = None, schema: str = "public")
tests/e2e/migrations/database.py:140
↓ 122 callersMethodexit
(self)
tests/unit/test_router/test_router.py:12598
↓ 121 callersMethodaclassify
Classify a prompt by complexity, using the LLM classifier when configured. Falls back to the local heuristic scorer if classifier_ty
litellm/router_strategy/complexity_router/complexity_router.py:2068
↓ 121 callersFunctionfield
(description: str, **extra: JsonValue)
tests/integration/_support/claude_code.py:55
↓ 121 callersMethodmin
Python's `min` over numbers: the first of the smallest, keeping its type.
litellm-rust/crates/redis-store/src/number.rs:59
↓ 120 callersMethodadd_span_processor
(self, span_processor)
tests/unit/integrations/otel/test_otel_v2_destinations.py:2168
↓ 120 callersFunctionnormalize
Replace volatile field values with "<VOLATILE>" so dict equality works. Recursive over dicts and lists. Pass an explicit ``volatile`` set to
tests/unit/proxy/proxy_server/conftest.py:54
↓ 120 callersMethodread
(self)
tests/integration/compatibility/test_status_code_followups.py:85
↓ 120 callersMethodreset
Called first thing in every test's setup phase, so each test starts empty.
tests/e2e/e2e_metadata.py:250
↓ 119 callersFunctionconvert_to_model_response_object
( response_object: dict | None = None, model_response_object: ModelResponse | EmbeddingResponse
litellm/litellm_core_utils/llm_response_utils/convert_dict_to_response.py:733
↓ 119 callersMethodprocess_mcp_request
Process and validate MCP request headers from the ASGI scope. This includes: 1. Extracting and validating authentication head
litellm/proxy/mcp_server/auth/user_api_key_auth_mcp.py:689
↓ 119 callersMethodtimestamp
(self)
litellm/integrations/newrelic/newrelic.py:71
↓ 118 callersFunctionMakeRequest
MakeRequest is a helper function to make HTTP requests
terraform/provider/litellm/utils.go:93
↓ 118 callersFunctionencrypt_value_helper
(value: str, new_encryption_key: str | None = None)
litellm/proxy/common_utils/encrypt_decrypt_utils.py:204
↓ 118 callersMethodload_servers_from_config
Load the MCP Servers from the config Args: mcp_servers_config: Dictionary of MCP server configurations mcp_a
litellm/proxy/mcp_server/mcp_server_manager.py:2560
↓ 118 callersMethodstream
(self, model: str, marker: str)
tests/integration/providers/test_vertex_passthrough_stream_wire.py:52
↓ 118 callersMethodwalk
(s)
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 116 callersMethoddate
(e)
litellm/proxy/_experimental/out/_next/static/chunks/2j7hjtph8n74b.js:1
↓ 116 callersMethodlen
(&self)
litellm-rust/crates/config/src/value.rs:25
↓ 116 callersMethodwait
(self)
tests/unit/llms/pi/harness/test_transformation.py:121
↓ 115 callersFunctiongeneric_cost_per_token
Calculates the cost per token for a given model, prompt tokens, and completion tokens. Handles context caching as well. Input:
litellm/litellm_core_utils/llm_cost_calc/utils.py:1566
↓ 115 callersFunctionget_secret
( secret_name: str, default_value: str | bool | None = None, )
litellm/secret_managers/main.py:359
↓ 114 callersMethod__new__
(cls, reference: str, origins: frozenset[str])
litellm/types/utils.py:4509
↓ 114 callersMethodexec
(s)
litellm/proxy/swagger/swagger-ui-bundle.js:2
↓ 114 callersFunctionn
(n)
litellm/proxy/_experimental/out/_next/static/chunks/0r8bcbns1_gw5.js:1
← previousnext →301–400 of 202,479, ranked by callers