01
Build
Ask for a route or a change in the editor's AI panel. The plan is shown for approve / review / reject before anything is written.
ai harness · alpha
The AI gateway is a multi-agent harness inside the editor. Describe a route or change; it plans, asks before acting, then produces blocks, edges and settings that pass the same schemas and graph rules as anything you draw by hand.
agent architecture
Each agent does one job and hands state to the next. Independent tasks run in parallel; a supervisor reviews every result before the orchestrator moves on.
1 Router
router
Classifies the request and checks it's buildable. Unbuildable requests end here, with a reason.
2a Discussion
discussion
Answers questions about your project or the platform.
2b Planner
planner
Writes a plan and can stop for your decision.
2c Human in the loop
humanInTheLoop
Pauses the run. Approve resumes at the task generator, review re-enters at the router, reject ends the run.
3 Task generator
taskGenerator
Breaks the plan into tasks; can hand a too-big fast-path request back to the planner once.
4 Orchestrator
orchestrator
Dispatches every ready task at once with LangGraph Send; when nothing is left, hands off to the summarizer.
5 Builders (in parallel)
blockBuilder · routeConfig · customBlockConfig
Blocks and edges validated against each block's schema and output handles, cycle-checked; route method, path and schemas; custom-block params.
6 Supervisor
supervisor
Checks each builder's result.
7 Summarizer
summarizer
Reports what changed.
tool calling
Agents ground themselves with read-only tools over the docs and the current project. Tool loops are bounded by a per-model iteration limit.
Everything a tool returns is fenced as untrusted data before it enters model context, and anything the model emits that the editor acts on is validated server-side.
search_docs
Semantic search over the Fluxify docs, embedded locally with all-MiniLM-L6-v2 — no embedding API calls.
get_route_details
Reads a route's settings and current canvas from the project.
find_resource
Looks up routes, workflows, integrations, app config keys and custom blocks by name.
get_artifact
Fetches a draft the harness produced earlier in the run.
get_agent_output
Reads another agent's result inside the same run.
get_custom_block_schemas
The parameter contracts of the project's custom blocks.
model routing
Each project picks an AI integration in its settings; the harness resolves the provider and model from it. Keys stay in the server config — nothing is read from the environment or hardcoded.
structured outputs
Agents return zod-validated objects. Constrained decoding is the first line of defence; the parser is the net.
// harness/models/base.ts — how a typed answer is obtained
// 1. Anthropic / Gemini: provider-native structured output (json_schema)
// 2. OpenAI · OpenRouter · Mistral: response_format = { type: "json_object" }
// Ollama: format = "json"
// 3. Then, defensively:
// - read text from content blocks / reasoning fields, never assume a string
// - unwrap a quoted, escaped JSON payload before parsing
// - slice the first *balanced* JSON value (string-aware brace counting)
// - validate with zod; schemas use .nullish() so a model's null passes
// - re-ask up to 3 times, as a user turn — never end a request on an
// assistant or system message
in your workflows
What the harness produces is ordinary Fluxify: routes, workflows and custom blocks that compile like hand-built ones.
01
Ask for a route or a change in the editor's AI panel. The plan is shown for approve / review / reject before anything is written.
02
Questions about your project or the platform go to the discussion agent, grounded in the docs index and your resources.
03
Use HTTP Request or a JS Runner with an npm SDK to call any model API inside a route or workflow — it's just another upstream.