Fix: The agent selected a knowledge base, but the API returned the error: "No dataset is selected". (#13950)

### What problem does this PR solve?

Fix: The agent selected a knowledge base, but the API returned the
error: "No dataset is selected".

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)

---------

Co-authored-by: balibabu <assassin_cike@163.com>
This commit is contained in:
balibabu
2026-04-07 14:16:37 +08:00
committed by GitHub
parent fa08fa2a17
commit 38acf34724
3 changed files with 11 additions and 5 deletions

View File

@@ -71,7 +71,7 @@ export function KnowledgeBaseFormField({
required = false,
}: {
showVariable?: boolean;
name: string;
name?: string;
required?: boolean;
}) {
const form = useFormContext();

View File

@@ -46,7 +46,7 @@ export const RetrievalPartialSchema = {
keywords_similarity_weight: z.coerce.number(),
top_n: z.coerce.number(),
top_k: z.coerce.number(),
kb_ids: z.array(z.string()),
database_ids: z.array(z.string()),
rerank_id: z.string(),
empty_response: z.string(),
cross_languages: z.array(z.string()),