mirror of
https://github.com/danswer-ai/danswer.git
synced 2025-04-08 20:08:36 +02:00
Formatting nits (#2311)
* stream in all cases * update code block * code formatting nits * proper ports * proper ports * remove unnecessary lines
This commit is contained in:
parent
a3b1b1db38
commit
5b1f3c8d4e
@ -248,6 +248,13 @@ class Answer:
|
||||
if self.is_cancelled:
|
||||
return
|
||||
yield cast(str, message.content)
|
||||
if (
|
||||
message.additional_kwargs.get("usage_metadata", {}).get("stop")
|
||||
== "length"
|
||||
):
|
||||
yield StreamStopInfo(
|
||||
stop_reason=StreamStopReason.CONTEXT_LENGTH
|
||||
)
|
||||
|
||||
if not tool_call_chunk:
|
||||
return # no tool call needed
|
||||
|
@ -99,7 +99,6 @@ import ExceptionTraceModal from "@/components/modals/ExceptionTraceModal";
|
||||
|
||||
import { SEARCH_TOOL_NAME } from "./tools/constants";
|
||||
import { useUser } from "@/components/user/UserProvider";
|
||||
import { Stop } from "@phosphor-icons/react";
|
||||
|
||||
const TEMP_USER_MESSAGE_ID = -1;
|
||||
const TEMP_ASSISTANT_MESSAGE_ID = -2;
|
||||
|
@ -364,7 +364,7 @@ export const AIMessage = ({
|
||||
<FileDisplay files={files || []} />
|
||||
|
||||
{typeof content === "string" ? (
|
||||
<div className="overflow-x-visible w-full pr-2">
|
||||
<div className="overflow-x-visible max-w-content-max">
|
||||
<ReactMarkdown
|
||||
key={messageId}
|
||||
className="prose max-w-full text-base"
|
||||
|
@ -230,3 +230,10 @@ form {
|
||||
gap: 1.2rem;
|
||||
align-items: start;
|
||||
}
|
||||
|
||||
ol > li > p,
|
||||
ul > li > p {
|
||||
margin-top: 0;
|
||||
margin-bottom: 0;
|
||||
display: inline; /* Make paragraphs inline to reduce vertical space */
|
||||
}
|
||||
|
@ -65,6 +65,7 @@ module.exports = {
|
||||
maxWidth: {
|
||||
"document-sidebar": "1000px",
|
||||
"message-max": "850px",
|
||||
"content-max": "725px",
|
||||
"searchbar-max": "800px",
|
||||
},
|
||||
colors: {
|
||||
|
Loading…
x
Reference in New Issue
Block a user