format with biome

This commit is contained in:
thierryverse 2025-11-14 00:42:19 +02:00
parent 77d49ca11c
commit 81ee04c2a5
21 changed files with 1602 additions and 1752 deletions

View file

@ -1,38 +1,35 @@
"use client";
import {
type ChatHandler,
ChatSection as LlamaIndexChatSection,
} from "@llamaindex/chat-ui";
import { type ChatHandler, ChatSection as LlamaIndexChatSection } from "@llamaindex/chat-ui";
import { useParams } from "next/navigation";
import { ChatInputUI } from "@/components/chat/ChatInputGroup";
import { ChatMessagesUI } from "@/components/chat/ChatMessages";
import type { Document } from "@/hooks/use-documents";
interface ChatInterfaceProps {
handler: ChatHandler;
onDocumentSelectionChange?: (documents: Document[]) => void;
selectedDocuments?: Document[];
onConnectorSelectionChange?: (connectorTypes: string[]) => void;
selectedConnectors?: string[];
searchMode?: "DOCUMENTS" | "CHUNKS";
onSearchModeChange?: (mode: "DOCUMENTS" | "CHUNKS") => void;
topK?: number;
onTopKChange?: (topK: number) => void;
handler: ChatHandler;
onDocumentSelectionChange?: (documents: Document[]) => void;
selectedDocuments?: Document[];
onConnectorSelectionChange?: (connectorTypes: string[]) => void;
selectedConnectors?: string[];
searchMode?: "DOCUMENTS" | "CHUNKS";
onSearchModeChange?: (mode: "DOCUMENTS" | "CHUNKS") => void;
topK?: number;
onTopKChange?: (topK: number) => void;
}
export default function ChatInterface({
handler,
onDocumentSelectionChange,
selectedDocuments = [],
onConnectorSelectionChange,
selectedConnectors = [],
searchMode,
onSearchModeChange,
topK = 10,
onTopKChange,
handler,
onDocumentSelectionChange,
selectedDocuments = [],
onConnectorSelectionChange,
selectedConnectors = [],
searchMode,
onSearchModeChange,
topK = 10,
onTopKChange,
}: ChatInterfaceProps) {
const { chat_id, search_space_id } = useParams();
const { chat_id, search_space_id } = useParams();
return (
<LlamaIndexChatSection handler={handler} className="flex h-full max-w-7xl mx-auto">