Spaces:
Sleeping
Sleeping
jed-tiotuico
commited on
Commit
•
4cb2b96
1
Parent(s):
ca8d45b
fixed to not display seeded fewshot as user message
Browse files
app.py
CHANGED
@@ -360,15 +360,12 @@ if st.button("Generate Printer Issue Based on Seed Tasks"):
|
|
360 |
model, tokenizer = get_mistral_model_tokenizer(sota_model_name)
|
361 |
input_text = alpaca_input_text_format.format(customer_msg)
|
362 |
st.write(f"```\n{input_text}```")
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
|
367 |
-
|
368 |
-
|
369 |
-
temperature=0.5,
|
370 |
-
)
|
371 |
-
)
|
372 |
|
373 |
# - Generate Customer Tweet
|
374 |
if st.button("Generate Customer Message using Few Shots"):
|
|
|
360 |
model, tokenizer = get_mistral_model_tokenizer(sota_model_name)
|
361 |
input_text = alpaca_input_text_format.format(customer_msg)
|
362 |
st.write(f"```\n{input_text}```")
|
363 |
+
few_shot_prompt_seeded = f"<s>[INST]{input_text}[/INST]\n"
|
364 |
+
st.markdown("Prompt:")
|
365 |
+
st.markdown(f"""```\n{few_shot_prompt_seeded}```""", unsafe_allow_html=True)
|
366 |
+
|
367 |
+
new_customer_msg = write_stream_user_chat_message(user_chat, model, tokenizer, few_shot_prompt_seeded)
|
368 |
+
st.session_state["user_msg_as_prompt"] = new_customer_msg
|
|
|
|
|
|
|
369 |
|
370 |
# - Generate Customer Tweet
|
371 |
if st.button("Generate Customer Message using Few Shots"):
|