mirror of
https://github.com/langgenius/dify.git
synced 2026-06-14 04:31:07 +08:00
38 lines
871 B
TypeScript
38 lines
871 B
TypeScript
// This file is auto-generated by @hey-api/openapi-ts
|
|
|
|
import * as z from 'zod'
|
|
|
|
/**
|
|
* ExternalRetrievalTestResponse
|
|
*/
|
|
export const zExternalRetrievalTestResponse = z.union([
|
|
z.record(z.string(), z.unknown()),
|
|
z.array(z.record(z.string(), z.unknown())),
|
|
])
|
|
|
|
/**
|
|
* BedrockRetrievalSetting
|
|
*
|
|
* Retrieval settings for Amazon Bedrock knowledge base queries.
|
|
*/
|
|
export const zBedrockRetrievalSetting = z.object({
|
|
score_threshold: z.number().optional().default(0),
|
|
top_k: z.int().nullish(),
|
|
})
|
|
|
|
/**
|
|
* BedrockRetrievalPayload
|
|
*/
|
|
export const zBedrockRetrievalPayload = z.object({
|
|
knowledge_id: z.string(),
|
|
query: z.string(),
|
|
retrieval_setting: zBedrockRetrievalSetting,
|
|
})
|
|
|
|
export const zPostTestRetrievalBody = zBedrockRetrievalPayload
|
|
|
|
/**
|
|
* Bedrock retrieval test completed
|
|
*/
|
|
export const zPostTestRetrievalResponse = zExternalRetrievalTestResponse
|