Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -5,13 +5,13 @@ from huggingface_hub import InferenceClient
|
|
| 5 |
|
| 6 |
client = InferenceClient("HuggingFaceH4/zephyr-7b-beta") #change the LLM
|
| 7 |
def respond(message, history):
|
| 8 |
-
messages = [{"role": "system", "content": "You are a
|
| 9 |
if history:
|
| 10 |
messages.extend(history)
|
| 11 |
messages.append({"role":"user", "content": message})
|
| 12 |
response = client.chat_completion(
|
| 13 |
messages,
|
| 14 |
-
max_tokens =
|
| 15 |
temperature = 0.5,
|
| 16 |
top_p = 0.7
|
| 17 |
)
|
|
|
|
| 5 |
|
| 6 |
client = InferenceClient("HuggingFaceH4/zephyr-7b-beta") #change the LLM
|
| 7 |
def respond(message, history):
|
| 8 |
+
messages = [{"role": "system", "content": "You are a professional interviewer."}]
|
| 9 |
if history:
|
| 10 |
messages.extend(history)
|
| 11 |
messages.append({"role":"user", "content": message})
|
| 12 |
response = client.chat_completion(
|
| 13 |
messages,
|
| 14 |
+
max_tokens = 50, #change the length
|
| 15 |
temperature = 0.5,
|
| 16 |
top_p = 0.7
|
| 17 |
)
|