halimbahae commited on
Commit
dbebde9
·
verified ·
1 Parent(s): c7c1438

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -3,9 +3,11 @@ import streamlit as st
3
  from phi.assistant import Assistant
4
  from phi.tools.arxiv_toolkit import ArxivToolkit
5
  from huggingface_hub import InferenceClient
 
6
 
7
  # Initialize the Hugging Face Inference Client
8
- client = InferenceClient(model="HuggingFaceH4/zephyr-7b-beta")
 
9
 
10
  # Set up the Streamlit app
11
  st.set_page_config(page_title="Chat with Research Papers", layout="wide")
 
3
  from phi.assistant import Assistant
4
  from phi.tools.arxiv_toolkit import ArxivToolkit
5
  from huggingface_hub import InferenceClient
6
+ from phi.llm.huggingface import HuggingFaceLLM # Added for proper LLM wrapping
7
 
8
  # Initialize the Hugging Face Inference Client
9
+ raw_client = InferenceClient(model="HuggingFaceH4/zephyr-7b-beta")
10
+ client = HuggingFaceLLM(client=raw_client) # Wrap the client properly
11
 
12
  # Set up the Streamlit app
13
  st.set_page_config(page_title="Chat with Research Papers", layout="wide")