mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-06 20:15:17 +02:00
chore: linting
This commit is contained in:
parent
ad475397c4
commit
a160f0dde3
4 changed files with 10 additions and 10 deletions
|
|
@ -198,7 +198,9 @@ class RegenerateRequest(BaseModel):
|
||||||
"""
|
"""
|
||||||
|
|
||||||
search_space_id: int
|
search_space_id: int
|
||||||
user_query: str | None = None # New user query (for edit). None = reload with same query
|
user_query: str | None = (
|
||||||
|
None # New user query (for edit). None = reload with same query
|
||||||
|
)
|
||||||
attachments: list[ChatAttachment] | None = None
|
attachments: list[ChatAttachment] | None = None
|
||||||
mentioned_document_ids: list[int] | None = None
|
mentioned_document_ids: list[int] | None = None
|
||||||
mentioned_surfsense_doc_ids: list[int] | None = None
|
mentioned_surfsense_doc_ids: list[int] | None = None
|
||||||
|
|
|
||||||
|
|
@ -1107,7 +1107,10 @@ export default function NewChatPage() {
|
||||||
setMessageThinkingSteps((prev) => {
|
setMessageThinkingSteps((prev) => {
|
||||||
const newMap = new Map(prev);
|
const newMap = new Map(prev);
|
||||||
// Remove thinking steps for the last two messages
|
// Remove thinking steps for the last two messages
|
||||||
const lastTwoIds = messages.slice(-2).map((m) => m.id).filter((id): id is string => !!id);
|
const lastTwoIds = messages
|
||||||
|
.slice(-2)
|
||||||
|
.map((m) => m.id)
|
||||||
|
.filter((id): id is string => !!id);
|
||||||
for (const id of lastTwoIds) {
|
for (const id of lastTwoIds) {
|
||||||
newMap.delete(id);
|
newMap.delete(id);
|
||||||
}
|
}
|
||||||
|
|
@ -1410,9 +1413,7 @@ export default function NewChatPage() {
|
||||||
m.id === assistantMsgId
|
m.id === assistantMsgId
|
||||||
? {
|
? {
|
||||||
...m,
|
...m,
|
||||||
content: [
|
content: [{ type: "text", text: "Sorry, there was an error. Please try again." }],
|
||||||
{ type: "text", text: "Sorry, there was an error. Please try again." },
|
|
||||||
],
|
|
||||||
}
|
}
|
||||||
: m
|
: m
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -179,10 +179,7 @@ export const ObsidianConfig: FC<ObsidianConfigProps> = ({
|
||||||
Index attachment folders and embedded files
|
Index attachment folders and embedded files
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<Switch
|
<Switch checked={includeAttachments} onCheckedChange={handleIncludeAttachmentsChange} />
|
||||||
checked={includeAttachments}
|
|
||||||
onCheckedChange={handleIncludeAttachmentsChange}
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ import type { FC } from "react";
|
||||||
import { EnumConnectorName } from "@/contracts/enums/connector";
|
import { EnumConnectorName } from "@/contracts/enums/connector";
|
||||||
import type { SearchSourceConnector } from "@/contracts/types/connector.types";
|
import type { SearchSourceConnector } from "@/contracts/types/connector.types";
|
||||||
import { isSelfHosted } from "@/lib/env-config";
|
import { isSelfHosted } from "@/lib/env-config";
|
||||||
import { ConnectorCard } from "../components/connector-card";
|
|
||||||
import { ComposioConnectorCard } from "../components/composio-connector-card";
|
import { ComposioConnectorCard } from "../components/composio-connector-card";
|
||||||
|
import { ConnectorCard } from "../components/connector-card";
|
||||||
import {
|
import {
|
||||||
COMPOSIO_CONNECTORS,
|
COMPOSIO_CONNECTORS,
|
||||||
CRAWLERS,
|
CRAWLERS,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue