File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
genkit-tools/common/src/types Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -115,11 +115,11 @@ const ToolResponseSchemaBase = z.object({
115115/**
116116 * Tool response part.
117117 */
118- export type ToolResponsePart = z . infer < typeof ToolResponseSchemaBase > & {
118+ export type ToolResponse = z . infer < typeof ToolResponseSchemaBase > & {
119119 content ?: Part [ ] ;
120120} ;
121121
122- export const ToolResponseSchema : z . ZodType < ToolResponsePart > =
122+ export const ToolResponseSchema : z . ZodType < ToolResponse > =
123123 ToolResponseSchemaBase . extend ( {
124124 content : z . array ( z . any ( ) ) . optional ( ) ,
125125 // TODO: switch to this once we have effective recursive schema support across the board.
@@ -134,6 +134,8 @@ export const ToolResponsePartSchema = EmptyPartSchema.extend({
134134 toolResponse : ToolResponseSchema ,
135135} ) ;
136136
137+ export type ToolResponsePart = z . infer < typeof ToolResponsePartSchema > ;
138+
137139/**
138140 * Zod schema of a data part.
139141 */
You can’t perform that action at this time.
0 commit comments