Spaces:
Runtime error
Runtime error
Commit History
-
Update app.py
Verified signature7640325 -
Update chainlit.md
Verified signature82a0260
-
Create chainlit.md
Verified signature69ec8fe -
Create Dockerfile
Verified signatureee05e41 -
Create app.py
Verified signature3ceafa5 -
Create app.py
Verified signature# You can find this code for Chainlit python streaming here (https://docs.chainlit.io/concepts/streaming/python) # OpenAI Chat completion import os from openai import AsyncOpenAI # importing openai for API usage import chainlit as cl # importing chainlit for our app from chainlit.prompt import Prompt, PromptMessage # importing prompt tools from chainlit.playground.providers import ChatOpenAI # importing ChatOpenAI tools from dotenv import load_dotenv load_dotenv() # ChatOpenAI Templates system_template = """You are a helpful assistant who always speaks in a pleasant tone! """ user_template = """{input} Think through your response step by step. """ @cl.on_chat_start # marks a function that will be executed at the start of a user session async def start_chat(): settings = { "model": "gpt-3.5-turbo", "temperature": 0, "max_tokens": 500, "top_p": 1, "frequency_penalty": 0, "presence_penalty": 0, } cl.user_session.set("…e979e5f -
Update README.md
Verified signature27f9af7 -
app.py
Verified signature# You can find this code for Chainlit python streaming here (https://docs.chainlit.io/concepts/streaming/python) # OpenAI Chat completion import os from openai import AsyncOpenAI # importing openai for API usage import chainlit as cl # importing chainlit for our app from chainlit.prompt import Prompt, PromptMessage # importing prompt tools from chainlit.playground.providers import ChatOpenAI # importing ChatOpenAI tools from dotenv import load_dotenv load_dotenv() # ChatOpenAI Templates system_template = """You are a helpful assistant who always speaks in a pleasant tone! """ user_template = """{input} Think through your response step by step. """ @cl.on_chat_start # marks a function that will be executed at the start of a user session async def start_chat(): settings = { "model": "gpt-3.5-turbo", "temperature": 0, "max_tokens": 500, "top_p": 1, "frequency_penalty": 0, "presence_penalty": 0, } cl.user_session.set("…d523b61 -
Create requirements.txt
Verified signatureda73137 -
Create app.py
Verified signaturee232d87 -
initial commit
Verified signatureb2d84c4