Gå til hovedinnhold

Learn kapi › Explore the engine

Flow workspace

Build a flow on the canvas, run it, and open what each step attached.

A flow is a composition of tools, and the engine runs it as a pipeline over every part of a document. The workspace draws the flow as a graph, runs it in the browser with tracing on, and replays the trace on the same nodes, so a step's effect on each block can be opened. Each chapter loads one teaching scenario; its own walkthrough card points into the canvas.

  1. What a step attachesSegmentation, translation and a check, run as one flow. Each step leaves something on the block: sentence spans as an overlay, a target in another language, findings. Press Run in the workspace and open a node to see what it attached.
  2. Protect before you sendThe redact step replaces sensitive spans with placeholders and vaults the originals; translate works on the protected text; unredact puts the originals back into the translation. The rules live at project level, so the step on the canvas is bare and still knows what to redact.
  3. Segment, then translateSegmentation is an overlay on the content model rather than a structural split: the block stays whole, and the sentence boundaries are stand-off spans the next step reads.
  4. The recipe behind the canvasEvery flow on the canvas serializes to a kapi.yaml recipe, and the project panel shows the defaults form beside the live source. Bindings choose where content enters and where results go, which is the whole difference between an ad-hoc run and a project.
  5. A script as a stepThe script step runs your code over every part in the pipeline, with the same part model the built-in tools see. Edit the code in the panel, run, and read the log.
  6. Build your ownAn empty canvas. Drop tools from the palette, connect them, pick a file from the library or upload one, and run. The recorded native traces in the picker show what the browser cannot run live: parallel workers and the Java bridge.