File size: 403 Bytes
70c93f7
3cf9169
70c93f7
a1e73e9
 
3cf9169
a1e73e9
 
 
3cf9169
 
a1e73e9
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import streamlit as st
from transformers import pipeline

# Load the model
chatbot = pipeline("text-generation", model="EleutherAI/gpt-neo-1.3B")

# Streamlit app
st.title("Chat with an LLM")
user_input = st.text_input("Your Message:")

if st.button("Send"):
    response = chatbot(user_input, max_length=100, do_sample=True)
    st.text_area("LLM Response:", response[0]["generated_text"], height=200)