zeitlich 0.2.12 → 0.2.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -423,14 +423,14 @@ declare function defineSubagent<TResult extends z$1.ZodType = z$1.ZodType, TCont
423
423
  workflow: string | ((input: {
424
424
  prompt: string;
425
425
  context: TContext;
426
- }) => Promise<ToolHandlerResponse<TResult | null>>);
426
+ }) => Promise<ToolHandlerResponse<z$1.infer<TResult> | null>>);
427
427
  context: TContext;
428
428
  hooks?: SubagentHooks<SubagentArgs, z$1.infer<TResult>>;
429
429
  }): SubagentConfig<TResult>;
430
430
  declare function defineSubagent<TResult extends z$1.ZodType = z$1.ZodType>(config: Omit<SubagentConfig<TResult>, "hooks" | "workflow"> & {
431
431
  workflow: string | ((input: {
432
432
  prompt: string;
433
- }) => Promise<ToolHandlerResponse<TResult | null>>);
433
+ }) => Promise<ToolHandlerResponse<z$1.infer<TResult> | null>>);
434
434
  hooks?: SubagentHooks<SubagentArgs, z$1.infer<TResult>>;
435
435
  }): SubagentConfig<TResult>;
436
436
  /**
@@ -446,7 +446,7 @@ type ContentPart = {
446
446
  /** Message content — plain string or an array of structured content parts */
447
447
  type MessageContent = string | ContentPart[];
448
448
  /** Content returned by a tool handler */
449
- type ToolMessageContent = string;
449
+ type ToolMessageContent = MessageContent;
450
450
  /**
451
451
  * Agent execution status
452
452
  */
@@ -591,7 +591,7 @@ interface ToolResultConfig {
591
591
  /** Content for the tool message (string or complex content parts) */
592
592
  content: ToolMessageContent;
593
593
  }
594
- type SubagentWorkflow<TResult extends z$1.ZodType = z$1.ZodType> = (input: SubagentInput) => Promise<ToolHandlerResponse<TResult | null>>;
594
+ type SubagentWorkflow<TResult extends z$1.ZodType = z$1.ZodType> = (input: SubagentInput) => Promise<ToolHandlerResponse<z$1.infer<TResult> | null>>;
595
595
  /**
596
596
  * Configuration for a subagent that can be spawned by the parent workflow.
597
597
  *
@@ -423,14 +423,14 @@ declare function defineSubagent<TResult extends z$1.ZodType = z$1.ZodType, TCont
423
423
  workflow: string | ((input: {
424
424
  prompt: string;
425
425
  context: TContext;
426
- }) => Promise<ToolHandlerResponse<TResult | null>>);
426
+ }) => Promise<ToolHandlerResponse<z$1.infer<TResult> | null>>);
427
427
  context: TContext;
428
428
  hooks?: SubagentHooks<SubagentArgs, z$1.infer<TResult>>;
429
429
  }): SubagentConfig<TResult>;
430
430
  declare function defineSubagent<TResult extends z$1.ZodType = z$1.ZodType>(config: Omit<SubagentConfig<TResult>, "hooks" | "workflow"> & {
431
431
  workflow: string | ((input: {
432
432
  prompt: string;
433
- }) => Promise<ToolHandlerResponse<TResult | null>>);
433
+ }) => Promise<ToolHandlerResponse<z$1.infer<TResult> | null>>);
434
434
  hooks?: SubagentHooks<SubagentArgs, z$1.infer<TResult>>;
435
435
  }): SubagentConfig<TResult>;
436
436
  /**
@@ -446,7 +446,7 @@ type ContentPart = {
446
446
  /** Message content — plain string or an array of structured content parts */
447
447
  type MessageContent = string | ContentPart[];
448
448
  /** Content returned by a tool handler */
449
- type ToolMessageContent = string;
449
+ type ToolMessageContent = MessageContent;
450
450
  /**
451
451
  * Agent execution status
452
452
  */
@@ -591,7 +591,7 @@ interface ToolResultConfig {
591
591
  /** Content for the tool message (string or complex content parts) */
592
592
  content: ToolMessageContent;
593
593
  }
594
- type SubagentWorkflow<TResult extends z$1.ZodType = z$1.ZodType> = (input: SubagentInput) => Promise<ToolHandlerResponse<TResult | null>>;
594
+ type SubagentWorkflow<TResult extends z$1.ZodType = z$1.ZodType> = (input: SubagentInput) => Promise<ToolHandlerResponse<z$1.infer<TResult> | null>>;
595
595
  /**
596
596
  * Configuration for a subagent that can be spawned by the parent workflow.
597
597
  *