---
title: "LiteLLM Core"
url: "/docs/litellm_core"
canonical_url: "https://docs.litellm.ai/docs/litellm_core"
type: "docs"
last_updated: "2026-10-08"
summary: "Install the LiteLLM SDK with fewer default dependencies and add AWS and Python tokenizer packages when needed"
related:
  - "/docs/learn/sdk_quickstart"
  - "/docs/completion/input"
---
# LiteLLM Core

> Index of all LiteLLM docs: https://docs.litellm.ai/llms.txt


`litellm-core` packages the LiteLLM Python SDK with fewer mandatory dependencies and without the bundled dashboard or gateway CLI entry points. It uses the same SDK sources and the same `litellm` Python namespace as the `litellm` distribution

## Choose a package

| Package | When to use it |
| --- | --- |
| `litellm-core` | Your application calls the SDK directly and you want to install AWS and Python Hugging Face tokenizer dependencies only when needed |
| `litellm` | You want the existing distribution, its dependency defaults, and its supported installation extras |

For a gateway deployment, follow the [Gateway Quickstart](https://docs.litellm.ai/docs/proxy/docker_quick_start). Core does not provide the `litellm` command or bundled Admin UI

## Install

Install core in a fresh virtual environment:

```bash
python -m venv .venv
source .venv/bin/activate
python -m pip install litellm-core
```

On Windows, activate the environment with `.venv\Scripts\activate` instead

Your Python imports still use `litellm`, including imports such as `from litellm import completion` or `from litellm import Router`. The distribution name is `litellm-core`; there is no change to the public import namespace

:::warning Install one distribution per environment

`litellm` and `litellm-core` install overlapping files. Installing both in the same environment causes `import litellm` to fail, even when their versions match

When moving an application to core, replace `litellm` in its dependency declaration and regenerate its lockfile in a fresh environment. If another dependency requires `litellm`, resolve that requirement before switching

:::

## SDK functionality

Core retains provider request and response translation, synchronous and asynchronous completions, streaming, embeddings, token counting, model metadata, and cost calculations. The shared SDK also includes the Router, retries, fallbacks, and provider error mapping

The package split preserves the broader SDK API surface, including Responses, image, audio, and batch operations. Model and provider support still varies by endpoint, and individual integrations can require additional packages. See [Supported Endpoints](https://docs.litellm.ai/docs/supported_endpoints) and the relevant [provider guide](https://docs.litellm.ai/docs/providers)

## Optional dependencies

Core removes `boto3`, `tokenizers`, and `huggingface-hub` from its mandatory dependencies. It declares `python-dateutil` directly and continues to require packages such as `jsonschema` and `tiktoken`

Install optional packages directly. Core does not currently declare installation extras such as `litellm-core[aws]` or `litellm-core[tokenizers]`

### AWS operations

Install `boto3` for AWS credential resolution, SigV4 signing, and AWS event-stream decoding:

```bash
python -m pip install boto3
```

This also installs `botocore`. AWS-dependent features include signed Bedrock requests, SageMaker, Polly, and AWS integrations such as Secrets Manager and S3 logging

Bedrock bearer-token request preparation can work without `botocore`. Streaming paths that decode AWS event streams still require it, so bearer authentication alone does not make every Bedrock operation independent of the AWS packages

### Python Hugging Face tokenizers

Install the Python tokenizer packages when your application uses those paths:

```bash
python -m pip install tokenizers huggingface-hub
```

Core retains its native tokenizer implementation and `tiktoken` dependency. Token counting does not universally require the optional Python Hugging Face packages. Where token counting falls back to an approximation, LiteLLM emits a warning; treat that result as an estimate

Missing optional dependencies are reported when the operation requiring them runs, with installation guidance

## Installation footprint

In matching source-build comparisons, `litellm-core` reduced installed size by **32.2%**, saving approximately **65.6 MB** including runtime dependencies

Both builds used version `1.106.0`, matching shared dependency versions, and the same Linux machine and Python interpreter. Measurements cover default installations without optional extras, excluding generated bytecode and common tooling. The source builds were baseline [`5d207d85`](https://github.com/BerriAI/litellm/commit/5d207d85ee547bc323d704bc6aaab901aa0be8b6) and core [`029a626c`](https://github.com/BerriAI/litellm/commit/029a626c99ec8c6012512b18ecea075a90db9dcd)

## Relationship to litellm

Currently, `litellm-core` and `litellm` are independently packaged distributions built from shared sources. Installing or upgrading `litellm` continues to use its existing dependency set

The planned architecture makes `litellm-core` the shared SDK dependency, with `litellm` wrapping it. That relationship is not implemented yet: `litellm` does not currently depend on `litellm-core`. Continue to choose one distribution per environment and use the `litellm` Python import namespace with either package

## Related pages

- [SDK Quickstart](https://docs.litellm.ai/docs/learn/sdk_quickstart.md)
- [completion()](https://docs.litellm.ai/docs/completion/input.md)
