llama3 / app.py
Apoorva96nbd's picture
added app.py
315e6ca
raw
history blame
No virus
342 Bytes
from langchain_community.llms import Ollama
import streamlit as st
llm = Ollama(model="llama3:8b")
st.title("Chatbot using Llama3")
prompt = st.text_area("Enter your prompt:")
if st.button("Generate"):
if prompt:
with st.spinner("Generating response..."):
st.write_stream(llm.stream(prompt, stop=['<|eot_id|>']))