olang-chatbot-resolvers
O-Lang Chatbot Resolver Pack — memory, intent, tone and LLM resolvers.
Install
pip install olang-chatbot-resolvers
Start
export GROQ_API_KEY=your_key_here
olang-chatbot-resolvers
# ✅ Running at http://localhost:8000
# ✅ Memory: sqlite (zero config)
Upgrade to Postgres in production
pip install olang-chatbot-resolvers[postgres]
export DATABASE_URL=postgresql://user:pass@host/db
olang-chatbot-resolvers
# ✅ Memory: postgres
Resolvers
| Resolver | Action | Input | Output |
|---|---|---|---|
| Memory read | memory_read |
session_id, last_n_turns |
history |
| Memory write | memory_write |
session_id, role, content |
turn_index |
| Intent classifier | intent_classifier |
message, allowed_topics |
intent, topic, is_allowed, confidence |
| Tone analyzer | tone_analyzer |
text, required_tone |
score, violations |
| LLM chat | llm_chat |
system_prompt, history, user_message |
reply, token_usage, model |
Use in your .ol workflow
tools:
- name: memory_read
protocol: http
url: http://localhost:8000
- name: memory_write
protocol: http
url: http://localhost:8000
- name: intent_classifier
protocol: http
url: http://localhost:8000
- name: tone_analyzer
protocol: http
url: http://localhost:8000
- name: llm_chat
protocol: http
url: http://localhost:8000
Environment variables
# Required
GROQ_API_KEY=your_groq_key
# Optional — production storage
DATABASE_URL=postgresql://user:pass@host/db
# Optional — custom SQLite path (dev)
SQLITE_PATH=./my_memory.db
# Optional — server config
RESOLVER_HOST=0.0.0.0
RESOLVER_PORT=8000
# Optional — model overrides
LLM_CHAT_MODEL=llama-3.3-70b-versatile
LLM_CHAT_MAX_TOKENS=1024
INTENT_MODEL=llama-3.1-8b-instant
TONE_MODEL=llama-3.1-8b-instant
LLM models
| Constant | Model | Best for |
|---|---|---|
FAST |
llama-3.1-8b-instant |
Classification, short answers |
SMART |
llama-3.3-70b-versatile |
RAG, chatbots, document reasoning |
MIXTRAL |
mixtral-8x7b-32768 |
Complex synthesis, large context |
Default for llm_chat: llama-3.3-70b-versatile
Running tests
pip install olang-chatbot-resolvers[dev]
pytest tests/ -v
# No API key or database required
Contact
Release files for olang-chatbot-resolvers 1.0.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 | |
|---|---|---|---|
| olang_chatbot_resolvers-1.0.0.tar.gz | 15.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| olang_chatbot_resolvers-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 29.7 kB
Release files / olang_chatbot_resolvers-1.0.0.tar.gz
| Download URL | olang_chatbot_resolvers-1.0.0.tar.gz |
|---|---|
| Size | 15.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7c3f2111d77d5b6402b47f6024c03cc1c085e59f6ddcad9b92fc17ddf827eaa3
|
|
BLAKE2b-256 checksum How to use checksums |
e84147dad316a907bd8ccea755b3c907b2b996b83ba62de9116b0bc44d9af3e2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.6
|
Release files / olang_chatbot_resolvers-1.0.0-py3-none-any.whl
| Download URL | olang_chatbot_resolvers-1.0.0-py3-none-any.whl |
|---|---|
| Size | 14.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5257334a439fbc8db02a694710d2eb0d82b9212ee90f60e2be3fd988fd46907c
|
|
BLAKE2b-256 checksum How to use checksums |
4c073306d8255342369926fd3b6c84d98b6c6994e5b38af62064c48097fb4470
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.6
|