* worker: support AIAgent tools in AI executor * worker: complete nested AIAgent tool execution path * worker: inline AIAgent tool schema usage * fix agent action * frontend: add AI Agent as tool type in flow builder Add the ability to insert a nested AI Agent as a tool within another AI Agent step. Includes type definitions, factory function, graph icon, insert/event wiring, and a dedicated editor component. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * refactor: remove AiAgentToolEditor, reuse FlowModuleComponent for AI agent tools Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * fix: populate all input transforms for nested AI agent tools Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * fix: avoid missing v2_job_status error for nested AI agent tools Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * sqlx * nit * refactor: cleanup nested AI agent tool implementation - Add max nesting depth guard (5) on parent chain traversal - Reject 3+ level nesting explicitly with clear error message - Remove unnecessary flow_step_id tuple scaffolding in tool dispatch - Consolidate get_value() calls using borrow in first match - Replace unsafe `as unknown as FlowModule` casts with agentToolToFlowModule() - Simplify toolKind ternary chain with .includes() lookup - Fix leftover over-indentation from tuple removal - Remove duplicate doc comment on is_completed_input_transform Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: pass flow_step_id and flow_job_id overrides to run_agent for nested AI agents For nested AI agent tools, job.flow_step_id is None and job.parent_job points to the parent agent instead of the flow. This caused memory read/write and flow context resolution to silently fail. handle_ai_agent_job already computes the correct flow_step_id (via runnable_path fallback) and flow_job_id (via parent chain traversal). This change threads those values through run_agent and ToolExecutionContext so all downstream consumers use the correct IDs. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * cleaning * cleaning * move const * fix * refactor: replace defaultToAi boolean with allowedAiTransforms whitelist Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * refactor: propagate root_job at push time, remove flow_job_id_override Instead of threading flow_job_id_override through run_agent and get_flow_context, propagate root_job and flow_innermost_root_job when pushing tool jobs so nested AI agents can find the flow job naturally via the existing job fields. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * refactor: simplify nested AI agent parent chain walk-up Replace the generic depth-limited loop with a single-level check since only flow → agent → nested agent tool is supported. Remove MAX_AGENT_NESTING_DEPTH constant and flatten the module lookup. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: reject 3+ level nested AI agent tools before job creation Check at the parent agent level whether a nested AIAgent tool contains AIAgent sub-tools. If so, return a fatal error immediately, preventing the sub-job from being created and avoiding retry loops. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: resolve deadlock in nested AI agent tool execution Replace channel forwarding with inline DB writes for tool job completions. Nested agents used bounded(1) channels where a sub-tool's forwarded result would fill the parent channel, leaving no room for the agent's own completion — causing a deadlock. Writing directly via add_completed_job/add_completed_job_error bypasses the channel entirely. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Windmill Backend
This folder holds all backend components, the src/ folder only contains files used to build the "root" binary.
Components
| name | description |
|---|---|
| windmill-api | The API server, exposing functionality to other components and the frontend |
| windmill-audit | Contains audit functionality, allowing different components to record important actions |
| windmill-common | Common code shared by all crates |
| windmill-queue | Contains job & flow queuing functionality, commonly written to by the API server and read from by workers |
| windmill-worker | The worker. Used to process and execute flows & jobs. |
| parsers | Contains code to parse signatures in different langauges. |
Compile sqlx for offline ci
cargo sqlx prepare --workspace -- --bin windmill --features enterprise