Show thoughts
')
response = response.replace("", "
")
return response
css = """
.thoughts {
border: 1px solid #ccc;
padding: 10px;
background-color: #000000;
border-radius: 5px;
}
details summary {
cursor: pointer;
padding: 5px;
background-color: #000000;
border-radius: 5px;
font-weight: bold;
}
details summary::-webkit-details-marker {
display: none;
}
details summary:after {
content: " ▶";
}
details[open] summary:after {
content: " ▼";
}
"""
with gr.Blocks(css=css) as demo:
gr.Markdown("## Chat with Superthoughts lite! (1.7B)")
gr.Markdown("**Warning:** The first output from the AI may take a few moments. After the first message, it should work at a decent speed.")
chatbot = gr.Chatbot()
msg = gr.Textbox()
system_message = gr.Textbox(value="You must always include