Spaces:
Build error
Build error
Commit History
-
Upload requirement.txt
Verified signatureNeed for proper functioning.ee63df8 -
Rename main1.py to app.py
Verified signatureapp.pyb0eb407 -
Upload main1.py
Verified signature<code>The given code is a Streamlit app that allows users to interact with multiple language models (LLMs) via the Hugging Face API. Here are the key components:</code> <h3>Model Selection:</h3> Users can choose from various pre-trained models, including “Mistral-7B-Instruct-v0.2,” “Mistral-7B-Instruct-v0.3,” “GPT-2,” “BLOOM,” and “OPT.” The selected model determines the LLM used for generating responses. <h3>User Input:</h3> Users can enter their messages in the text input field. The input is then used as a prompt for the LLM. <h3>LLM Initialization:</h3> The get_llm function initializes the selected LLM based on the chosen model. Parameters like max_length and temperature are set for response generation. <h3>Chat Prompt Template:</h3> The PromptTemplate defines a chat message format, including placeholders for user input. The template is used to create a full prompt for the LLM. <h3>Response Generation:</h3> When the user submits a message, it’s added to the chat history. The LLM ge…96bc16a -
initial commit
Verified signature8ad5140