LLMLight - Lightweight and Flexible Agentic Framework
Key Features
| Feature | Description |
|---|---|
| Local LLM Support | Run LLMs locally with minimal dependencies. |
| Full Prompt Control | Fine-grained control over prompts including Query, Instructions, System, Context, Response Format, Automatic formatting, Temperature, and Top P. |
| Single Endpoint for All Local Models | One unified endpoint to connect different local models. |
| Flexible Embedding Methods | Multiple embedding strategies: TF-IDF for structured documents, Bag of Words (BOW), BERT for free text, BGE-Small. |
| Advanced Retrieval Methods | Supports Naive RAG with fixed chunking and RSE (Relevant Segment Extraction). |
| Context Strategies | Advanced reasoning for complex queries using Global-reasoning and Chunk-wise approaches. |
| Local Memory | Video memory storage for efficient local use. |
| PDF Processing | Native support for reading and processing PDF documents. |
Documentation & Resources
Installation
# Install from PyPI
pip install LLMlight
Quick Start
1. Check Available Models at Endpoint
from LLMlight import LLMlight
# Initialize client
from LLMlight import LLMlight
# Initialize with LM Studio endpoint
client = LLMlight(model='mistralai/mistral-small-3.2',
endpoint="http://localhost:1234/v1/chat/completions")
modelnames = client.get_available_models(validate=False)
print(modelnames)
2. Basic Usage with Endpoint
from LLMlight import LLMlight
# Initialize with default settings
client = LLMlight(model='openai/gpt-oss-20b', endpoint='http://localhost:1234/v1/chat/completions')
# Run a simple query
response = client.prompt('What is the capital of France?',
context='The capital of France is Amsterdam.',
instructions='Do not argue with the information in the context. Only return the information from the context.')
print(response)
# According to the provided context, the capital of France is Amsterdam.
3. Using with LM Studio
https://erdogant.github.io/LLMlight/pages/html/Algorithm.html#get-available-llm-models
3. Query against PDF files
https://erdogant.github.io/LLMlight/pages/html/Examples.html#working-with-files-pdfs
4. Creating Local Memory Database
https://erdogant.github.io/LLMlight/pages/html/Saving%20and%20Loading.html#memory-management
Maintainer
Metadata
Release files for LLMlight 1.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| llmlight-1.2.1.tar.gz | 69.4 kB | Without provenance | Details for llmlight-1.2.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| llmlight-1.2.1-py3-none-any.whl | Python 3 | none | any | Details for llmlight-1.2.1-py3-none-any.whl |
Total release size: 142.8 kB
Release files / llmlight-1.2.1.tar.gz
| Download URL | llmlight-1.2.1.tar.gz |
|---|---|
| Size | 69.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
47eb6ab992b0b14901d5168ebb0de64c92da8fc4cf99e3851529a2df6778d856
|
|
BLAKE2b-256 checksum How to use checksums |
25672b95259d971b740c0f9dcff1d684f9d4825a48e820cbc709f8cbded58e4a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.14
|
Release files / llmlight-1.2.1-py3-none-any.whl
| Download URL | llmlight-1.2.1-py3-none-any.whl |
|---|---|
| Size | 73.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
65ae33791131cbe3464d9e615fc94a7448c8cf9d4f7ec1aab03c78348e0847be
|
|
BLAKE2b-256 checksum How to use checksums |
ea6e20f25e1c463a59c5d51652e81e37b28c6e4206278d3e07d6b155638d398a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.14
|
Security for LLMlight 1.2.1
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.