LiteAI-SDK
LiteAI-SDK is a wrapper of LiteLLM which provides a more intuitive API and AI SDK like DX.
Installation
pip install liteai-sdk
Develop with coding agent
You can access the complete usage guidance with llms.txt, just give it to your coding agent to tell it how to use LiteAI-SDK.
Examples
Below is a simple example of just a API call:
import os
from dotenv import load_dotenv
from liteai_sdk import LLM, LlmProviders, LlmRequestParams, UserMessage
load_dotenv()
llm = LLM(provider=LlmProviders.OPENAI,
api_key=os.getenv("API_KEY", ""),
base_url=os.getenv("BASE_URL", ""))
response = llm.generate_text_sync( # sync API of generate_text
LlmRequestParams(
model="deepseek-v3.1",
messages=[UserMessage(content="Hello.")]))
print(response)
Below is an example that shows the automatically tool call:
import os
from dotenv import load_dotenv
from liteai_sdk import LLM, LlmProviders, LlmRequestParams, UserMessage
load_dotenv()
def example_tool():
"""
This is a test tool that is used to test the tool calling functionality.
"""
print("The example tool is called.")
return "Hello World"
llm = LLM(provider=LlmProviders.OPENAI,
api_key=os.getenv("API_KEY", ""),
base_url=os.getenv("BASE_URL", ""))
params = LlmRequestParams(
model="deepseek-v3.1",
tools=[example_tool],
execute_tools=True,
messages=[UserMessage(content="Please call the tool example_tool.")])
print("User: ", "Please call the tool example_tool.")
messages = llm.generate_text_sync(params)
for message in messages:
match message.role:
case "assistant":
print("Assistant: ", message.content)
case "tool":
print("Tool: ", message.result)
Metadata
Release files for liteai-sdk 0.6.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| liteai_sdk-0.6.0.tar.gz | 18.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| liteai_sdk-0.6.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 43.3 kB
Release files / liteai_sdk-0.6.0.tar.gz
| Download URL | liteai_sdk-0.6.0.tar.gz |
|---|---|
| Size | 18.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a6ae452b1b7c0bcb1763b835d847a0748bc49b82eac0a1957dd84e578eeeb226
|
|
BLAKE2b-256 checksum How to use checksums |
2b7d8414ebb7dab5e5775211294e2b11e3ce7fbc0321c05107d5310504067fa7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 29, 2026.
Transparency logRelease files / liteai_sdk-0.6.0-py3-none-any.whl
| Download URL | liteai_sdk-0.6.0-py3-none-any.whl |
|---|---|
| Size | 24.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e36caf3fc177844cc16f4068da15df0b8652088166b4d58476cb71b91e199380
|
|
BLAKE2b-256 checksum How to use checksums |
6b3685cf128a281e95fab2434e2d55a525746b0ee565bfbe1a46a704e93455a8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 29, 2026.
Transparency log