Registry / llm-agents / streamlit-chat

streamlit-chat

JSON →
library0.1.1pypypi✓ verified 84d ago

A Streamlit component for building chatbot UIs. Current version 0.1.1, requires Python >=3.6. The package provides a simple message display component with avatar support, but is in early maintenance mode with no recent updates.

pip install streamlit-chat
INSTALL
IMPORT
SIG · STREAMLIT-CHAT
S
streamlit-chat
llm-agentspythonv0.1.1
Install
15.9s avg
Import
1403ms
Disk
435MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v0.1.1 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 1.786s · 447.2MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 15.9s · import 1.020s · 416MB
435MB installed
● package 435MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

message
from streamlit_chat import message
from st_chat import message
The package is imported as streamlit_chat, not st_chat

Minimal example displaying two chat messages (bot and user).

import streamlit as st from streamlit_chat import message message("Hello, I am a chatbot!", key="chat1") message("Hi there!", is_user=True, key="chat2")
Debug
Known issues
gotchaThe `message` component requires a unique `key` for each call, or Streamlit will raise a DuplicateKey error.
fix
Always pass a unique `key` string (e.g., f"msg_{i}") to each `message()` call.
affects: all
deprecatedThe package uses the old Streamlit component API and may not be compatible with newer Streamlit versions (>=1.27).
fix
Consider using native Streamlit chat elements (`st.chat_message`, `st.chat_input`) instead.
affects: >=1.27
gotchaAvatars are fetched from DiceBear API; network issues can cause avatars to fail silently.
fix
Set custom avatars via the `avatar_style` and `seed` parameters, or ensure internet access.
affects: all
Errors
Common errors & fixes
DuplicateWidgetID: There are multiple identical st_chat_message widgets with the same key.
Each `message()` call must have a unique key.
fix
Use dynamic keys: `message("text", key=f"msg_{i}")`.
ModuleNotFoundError: No module named 'st_chat'
Incorrect import path. The correct module is 'streamlit_chat'.
fix
Run `import streamlit_chat` instead of st_chat.
Upgrade
Version history
0.1.1latest on PyPI · released Jun 25, 2023
Audit
Dependencies

No dependency data recorded yet.

Agent activity
25 hits · last 30 days
node
22
OpenAI (training)
1
Resources
streamlit-chat — pip install streamlit-chat · libregistry