mirror of
https://github.com/langgenius/dify.git
synced 2026-06-15 21:41:16 +08:00
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: QuantumGhost <obelisk.reg+git@gmail.com>
55 lines
1.3 KiB
TypeScript
55 lines
1.3 KiB
TypeScript
// This file is auto-generated by @hey-api/openapi-ts
|
|
|
|
import * as z from 'zod'
|
|
|
|
/**
|
|
* InstructionTemplatePayload
|
|
*/
|
|
export const zInstructionTemplatePayload = z.object({
|
|
type: z.string(),
|
|
})
|
|
|
|
/**
|
|
* LLMMode
|
|
*
|
|
* Enum class for large language model mode.
|
|
*/
|
|
export const zLlmMode = z.enum(['chat', 'completion'])
|
|
|
|
/**
|
|
* ModelConfig
|
|
*/
|
|
export const zModelConfig = z.object({
|
|
completion_params: z.record(z.string(), z.unknown()).optional(),
|
|
mode: zLlmMode,
|
|
name: z.string(),
|
|
provider: z.string(),
|
|
})
|
|
|
|
/**
|
|
* InstructionGeneratePayload
|
|
*/
|
|
export const zInstructionGeneratePayload = z.object({
|
|
current: z.string().optional().default(''),
|
|
flow_id: z.string(),
|
|
ideal_output: z.string().optional().default(''),
|
|
instruction: z.string(),
|
|
language: z.string().optional().default('javascript'),
|
|
model_config: zModelConfig,
|
|
node_id: z.string().optional().default(''),
|
|
})
|
|
|
|
export const zPostInstructionGenerateBody = zInstructionGeneratePayload
|
|
|
|
/**
|
|
* Instruction generated successfully
|
|
*/
|
|
export const zPostInstructionGenerateResponse = z.record(z.string(), z.unknown())
|
|
|
|
export const zPostInstructionGenerateTemplateBody = zInstructionTemplatePayload
|
|
|
|
/**
|
|
* Template retrieved successfully
|
|
*/
|
|
export const zPostInstructionGenerateTemplateResponse = z.record(z.string(), z.unknown())
|