Task 7: Launch Your LangChain AI Assistant
issue with app.py file.
Unable to communicate to port: 7860
Error:
root@controlplane ~/langchain-chatbot via
v3.12.3 (venv) ➜ python app.py
modules.json: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████| 349/349 [00:00<00:00, 4.56MB/s]
config_sentence_transformers.json: 100%|████████████████████████████████████████████████████████████████████████████████| 116/116 [00:00<00:00, 1.67MB/s]
README.md: 10.5kB [00:00, 62.4MB/s]
Warning: You are sending unauthenticated requests to the HF Hub. Please set a HF_TOKEN to enable higher rate limits and faster downloads.
sentence_bert_config.json: 100%|███████████████████████████████████████████████████████████████████████████████████████| 53.0/53.0 [00:00<00:00, 743kB/s]
config.json: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████| 612/612 [00:00<00:00, 6.19MB/s]
model.safetensors: 100%|████████████████████████████████████████████████████████████████████████████████████████████| 90.9M/90.9M [00:01<00:00, 64.2MB/s]
Loading weights: 100%|██████████████████████████████████████████████████████| 103/103 [00:00<00:00, 5776.20it/s, Materializing param=pooler.dense.weight]
BertModel LOAD REPORT from: sentence-transformers/all-MiniLM-L6-v2
**Key | Status | | **
------------------------±-----------±-±
embeddings.position_ids | UNEXPECTED | |
Notes:
- UNEXPECTED :can be ignored when loading from different task/architecture; not ok if you expect identical arch.
tokenizer_config.json: 100%|████████████████████████████████████████████████████████████████████████████████████████████| 350/350 [00:00<00:00, 4.44MB/s]
vocab.txt: 232kB [00:00, 100MB/s]
tokenizer.json: 466kB [00:00, 180MB/s]
special_tokens_map.json: 100%|██████████████████████████████████████████████████████████████████████████████████████████| 112/112 [00:00<00:00, 1.91MB/s]
config.json: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████| 190/190 [00:00<00:00, 3.11MB/s]
Generating comprehensive synthetic knowledge base…
Generated 6 LangChain docs
Generated 4 company docs
Generated 3 technical docs
Generated 15 Q&A test pairs
All files saved to: /root/langchain-chatbot/data/knowledge_base
Generated 14 documents with rich content
Created new vector store at /root/chroma_db
/root/langchain-chatbot/app.py:51: UserWarning: The parameters have been moved from the Blocks constructor to the launch() method in Gradio 6.0: theme. Please pass these parameters to launch() instead.
with gr.Blocks(theme=gr.themes.Soft(), title=“LangChain Chatbot”) as demo:
Traceback (most recent call last):
File “/root/langchain-chatbot/app.py”, line 68, in
chatbot = gr.Chatbot(
^^^^^^^^^^^
File “/root/langchain-lab/venv/lib/python3.12/site-packages/gradio/component_meta.py”, line 194, in wrapper
return fn(self, **kwargs)
^^^^^^^^^^^^^^^^^^
TypeError: Chatbot.init() got an unexpected keyword argument ‘bubble_full_width’