LLM utilities with agents, file parsing, and preprocessing built in.
Project description
tokens-lab
LLM utilities with agents, file parsing, and preprocessing built in.
Features
- Agent Framework: LangGraph-based agents with OpenAI integration
- File Text I/O: Parse PDFs, DOCX, PPTX, and images with ease
- Preprocessing: Text normalization and cleaning utilities
- Azure Integration: Azure Storage and service utilities
- ML Tools: String similarity and text analysis
- Utilities: Date, Excel, JSON, and Pandas helpers
- Logging: Structured logging support
- Exception Handling: Custom exception hierarchy
Installation
pip install tokens-lab
Quick Start
LLM Agent
from llm_lab.agent import Agent
from llm_lab.agent.litellm_client import LiteLLMClient
client = LiteLLMClient(model="gpt-4", api_key="your-api-key")
agent = Agent(client=client)
response = agent.process("Hello, how can you help me?")
File Parsing
from llm_lab.filetextio import parsers
content = parsers.parse_document("document.pdf")
Text Preprocessing
from llm_lab.preprocessing import text_normalization
clean_text = text_normalization.normalize_text("messy text ")
Documentation
For complete documentation, visit: https://pwc-me-adv-strategyand.github.io/LLM_Lab/
Requirements
- Python >= 3.10
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
tokens_lab-0.5.9.tar.gz
(22.2 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tokens_lab-0.5.9.tar.gz.
File metadata
- Download URL: tokens_lab-0.5.9.tar.gz
- Upload date:
- Size: 22.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d3a412140d5710e214fdd05f71519ece513d3394e2b5b8d1b91d8974a233eea8
|
|
| MD5 |
32daa09daa6443ca72de068e58ff1450
|
|
| BLAKE2b-256 |
a19536cf065f9d2f42a6a5caba19510f8faa022c5d81ca10e8914ad1380c5cc6
|
File details
Details for the file tokens_lab-0.5.9-py3-none-any.whl.
File metadata
- Download URL: tokens_lab-0.5.9-py3-none-any.whl
- Upload date:
- Size: 29.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0f022e6049ec7c62da1762d6621c9658108856b2322d2a15bc3859b34618f1ad
|
|
| MD5 |
178f469317c0b432b0efd9c115968234
|
|
| BLAKE2b-256 |
044626a364aa7fec991f39f4dbd9319f8a459f7113a2ba35653ce0f87a5e8946
|