prompted workflows: use (nav block, [extract block],) for v1 prompts (#3658)

This commit is contained in:
Jonathan Dobson
2025-10-09 08:52:31 -04:00
committed by GitHub
parent 5e7e346c74
commit 6d89b53ae3
4 changed files with 137 additions and 29 deletions

View File

@@ -160,6 +160,29 @@ class TaskRequest(TaskBase):
return validate_url(url)
class PromptedTaskRequest(TaskRequest):
ai_fallback: bool | None = Field(
default=False,
description="Whether to use AI fallback when the task fails.",
examples=[True, False],
)
publish_workflow: bool | None = Field(
default=False,
description="Whether to publish the workflow created from the prompt.",
examples=[True, False],
)
run_with: str | None = Field(
default=None,
description="The executor to run the task with.",
examples=["code", "agent"],
)
user_prompt: str = Field(
...,
description="The user's prompt for the task.",
examples=["Get a quote for car insurance"],
)
class TaskStatus(StrEnum):
created = "created"
queued = "queued"