feat: Integrate Swiper library and enhance chat functionality
- Added Swiper library to package dependencies for improved UI components. - Updated chat API to include summary model ID in message handling, allowing for more flexible model selection. - Enhanced InputField component to manage model selection and state more effectively. - Improved event handling in chat components to support new model features and ensure accurate message processing. - Refactored SVG assets for better visual consistency and updated styles for improved user experience.
This commit is contained in:
@@ -28,7 +28,7 @@ export function useStream() {
|
||||
let renderTimer: number | null = null
|
||||
|
||||
// 启动流式请求
|
||||
const startStream = async (params: { session_id: any; query: any; knowledge_base_ids?: string[]; agent_enabled?: boolean; method: string; url: string }) => {
|
||||
const startStream = async (params: { session_id: any; query: any; knowledge_base_ids?: string[]; agent_enabled?: boolean; summary_model_id?: string; method: string; url: string }) => {
|
||||
// 重置状态
|
||||
output.value = '';
|
||||
error.value = null;
|
||||
@@ -69,6 +69,10 @@ export function useStream() {
|
||||
if (params.knowledge_base_ids !== undefined && params.knowledge_base_ids.length > 0) {
|
||||
postBody.knowledge_base_ids = params.knowledge_base_ids;
|
||||
}
|
||||
// Include summary_model_id if provided (for non-Agent mode)
|
||||
if (params.summary_model_id) {
|
||||
postBody.summary_model_id = params.summary_model_id;
|
||||
}
|
||||
|
||||
await fetchEventSource(url, {
|
||||
method: params.method,
|
||||
|
||||
@@ -16,6 +16,7 @@ export interface ModelConfig {
|
||||
truncate_prompt_tokens?: number;
|
||||
};
|
||||
interface_type?: 'ollama' | 'openai'; // VLLM专用
|
||||
parameter_size?: string; // Ollama模型参数大小 (e.g., "7B", "13B", "70B")
|
||||
};
|
||||
is_default?: boolean;
|
||||
status?: string;
|
||||
|
||||
Reference in New Issue
Block a user