diff --git a/docs/index.html b/docs/index.html index aa2068e..3b622f6 100644 --- a/docs/index.html +++ b/docs/index.html @@ -196,15 +196,20 @@
  • vs /loop & /goal
  • Get started
  • Install + first loop
  • +
  • Core syntax ยท the five decisions
  • done when โ€” verify
  • The cycle + reflect
  • Human gates
  • +
  • The rest of the syntax
  • Composing
  • +
  • The rest of the syntax
  • In practice
  • Real workflows
  • LoopFlow by role
  • Starter templates
  • -
  • Running it
  • +
  • Run it
  • +
  • Running a loop
  • +
  • In VS Code
  • Live dashboard
  • Your global library
  • Go deeper
  • @@ -217,21 +222,35 @@
    -

    LoopFlow, the tutorial

    - +

    Stop babysitting the agent.

    +
    Write the goal once โ€” the loop plans, acts, reflects on red, and stops only when the check is green, at the gates you set.

    LoopFlow is a small natural-language DSL for loop engineering. A .loop file describes a self-correcting, human-gated coding workflow โ€” its objective, the context it may read, the actions it may take, how it verifies itself, and when it stops. This page teaches the whole language from the first line to full A-to-Z pipelines, every section grounded in a real example you can run.

    -
    -
    -
    a claude sessionโ— โ— โ—
    -
    +
    +
    /loopflow run rate-limit.loopโ— โ— โ—
    +
    +
    โฏ /loopflow run rate-limit.loop
    +
    goal: requests are rate-limited per API key
    +
    โ†ป cycle 1 ยท plan โ†’ act โ†’ observe
    +
    โ— Bash pnpm test rate-limit
    +
    โœ— 2 failing: resets-after-window, per-key-isolation
    +
    ~ reflect: the window resets per key, not globally
    +
    โ— Edit src/api/limiter.ts
    +
    โ†ป cycle 2 ยท plan โ†’ act โ†’ observe
    +
    โ— Bash pnpm test rate-limit
    +
    โœ“ all green โ€” done-when satisfied
    +
    โ— Bash git checkout -b rate-limiting
    +
    โ› gate: open a pull request? โ–ธ approved
    +
    โ— Bash git push origin rate-limiting ยท gh pr create
    +
    โ—ผ done โ€” PR #128 opened, never touched main
    +
    โ€” you wrote the goal once; the loop did the rest.
    -
    -
    โ€ฆor one loop
    -
    # run in chat:  /loopflow run rate-limit.loop
    -# (the agent knows LoopFlow from AGENTS.md โ€” your repo's memory)
    +  
    +

    โ†“ the one .loop that drove the run above โ€” the whole job, written once

    -git: +
    +
    rate-limit.loop
    +
    git:
       work on a branch
       commit when the goal is met
       open a pull request
    @@ -245,10 +264,8 @@ 

    LoopFlow, the tutorial

    also: run a security check when it fails: reflect, then plan again after 6 tries: stop and warn "thrashing"
    -
    Skill: /loopflow runs it ยท Memory: AGENTS.md + reflect ยท Git: branch + commit + PR, never main
    -
    +
    Skill: /loopflow runs it ยท Memory: AGENTS.md + reflect ยท Git: branch + commit + PR, never main
    -

    Left: a dozen messages, and it still pushed to main. Right: the whole job, written once โ€” it runs, verifies, and stops only when it's really done.

    @@ -272,6 +289,7 @@

    What is a loop basic

    Verificationdone whenHow do we know it worked? Stoppingwhenโ€ฆ / after N triesWhen do we stop โ€” done, or thrashing? +

    These five are the core syntax โ€” the engine. Everything else in the language either composes loops into bigger workflows (pipeline, flow, for each) or configures a run (the rest of the syntax) โ€” you'll meet those after the core.

    Here are all five decisions as one real loop โ€” every line is one of the rows above:

    loop "fix the failing test":                       # the work
       goal: the cart total is correct with a coupon    # Objective
    @@ -370,7 +388,7 @@ 

    vs Claude Code's /loop and /goal<

    Getting started setup

    That's the why. From here down is the deep dive โ€” set LoopFlow up once, then learn the language line by line.

    -

    Prerequisites: Node 18+, the Claude Code CLI (LoopFlow drives it), and a git repo to work in. The primary way to use LoopFlow is a Claude Code chat โ€” type /loopflow and the assistant writes and runs the loop with you, watching every step and answering gates inline. (Prefer to write .loop files by hand? The VS Code extension is there too โ€” see below โ€” but the chat is the recommended path.) One command installs everything:

    +

    Prerequisites: Node 18+, the Claude Code CLI (LoopFlow drives it), and a git repo to work in. The primary way to use LoopFlow is a Claude Code chat โ€” type /loopflow and the assistant writes and runs the loop with you, watching every step and answering gates inline. (Prefer to write .loop files by hand? The VS Code extension is there too โ€” see Running a loop โ–ธ In VS Code โ€” but the chat is the recommended path.) One command installs everything:

    1 ยท Install with npm

    From your repo, run the installer. In one step it writes the /loopflow skill and AGENTS.md (the full language reference) into the project:

    @@ -412,16 +430,7 @@

    2 ยท Run your first loop โ€” in a Claude Code chat

    -

    Optional ยท author by hand in VS Code if you prefer an editor

    -

    The chat above is the main way to use LoopFlow. If you'd rather write .loop files by hand, the optional LoopFlow VS Code extension helps โ€” Extensions โ–ธ search โ€œLoopFlowโ€ โ–ธ Install โ€” then open any .loop file:

    -
      -
    • Syntax highlighting for the whole language โ€” goal, done when, gates, flow, for each, git:.
    • -
    • Completion + formatting โ€” keyword snippets so you type a loop from muscle memory, not a cheat sheet.
    • -
    • A โ–ถ Run button on every loop (the LoopFlow: Run this loop CodeLens) โ€” and you choose where it runs via the loop.runMode setting: open an interactive Claude Code session, or a headless output-panel trace.
    • -
    • New from template (command palette โ†’ LoopFlow: New from template) โ€” scaffold a ready-to-edit .loop bundle.
    • -
    • A soft linter that nudges, never blocks โ€” "this loop has no way to verify it's done", "add a thrash guard".
    • -
    -

    Same file, same engine: prompt the agent to generate a loop, or open VS Code and write the .loop yourself. The chat is the first-class way to run; the extension is the first-class way to author by hand.

    +

    Prefer to write .loop files by hand in an editor? The optional LoopFlow VS Code extension โ€” highlighting, completion, a โ–ถ Run button, and New from template โ€” is covered under Running a loop โ–ธ In VS Code. The chat is the first-class way to run; the extension is the first-class way to author by hand.

    Safe from the first run: with no git: block, LoopFlow works on a branch and commits when the goal is met, and never pushes to main/master โ€” see the git keyword.

    Rather learn hands-on?

    @@ -555,6 +564,29 @@

    Composing โ€” pipeline, flow, for each scaling u

    The full grammar โ€” pipelines, flow chains, and for each iteration, with worked examples โ€” is in the manual and the keyword reference.

    + +
    +

    The rest of the syntax beyond the core

    +

    The five decisions (plus the cycle) are the whole engine. Everything else in the language either composes loops into bigger workflows or configures a run โ€” none of it changes how a single loop thinks. Here's the rest at a glance; each construct links to its keyword reference page.

    + + + + + + + + + + + + + + + + +
    ConstructWhat it does
    Compose โ€” scale one loop into many
    pipeline ยท stageRun stages in order; a failing stage halts the rest. An epic โ†’ a pipeline, a story โ†’ a stage. More โ†‘
    flow ยท run / then runChain whole .loop files; each step's summary carries forward (with the result of picks a specific earlier step).
    for each โ€ฆ inRun a template loop once per item in a YAML/Markdown plan โ€” A-to-Z over every story.
    Augment a loop
    use skills:Named skills the loop may invoke during plan/act โ€” coordinate proven skills instead of one mega-prompt.
    remember inCross-run memory: read past lessons on start, append the run's outcome on stop, so the loop improves over time.
    also:Extra finishing passes run after the goal is met (skipped on failure).
    plan from "file"Execute a plan you wrote instead of one the agent generates.
    Ops & reuse โ€” configure the run
    git:Version-control policy โ€” branch / commit cadence / push / PR. Never pushes to main by default.
    models:Tier the model by phase โ€” a fast model to plan/reflect, a strong one to act.
    use the X methodImport a reusable preset (its own .loop) that another repo can share.
    schedule: ยท target: ยท notify:The config tier โ€” when it runs, where it runs, and who to tell when it's done.
    +
    + @@ -704,7 +736,14 @@

    Starter templates โ€” don't write from scratch c
    -

    Running a loop intermediate

    +

    Running a loop how to run

    +

    Three ways to work with a .loop โ€” write it, then run it. Same file, same engine:

    + + + + + +
    What you wantUseHow
    1 ยท Write the loop by handthe VS Code extension โ€” syntax highlighting, completion, a soft linteropen a .loop in VS Code
    2 ยท Run it in Claude Code recommendedthe /loopflow skill โ€” watch every step, answer gates inline/loopflow run <file>
    3 ยท Run it headlessthe CLI โ€” CI, scripts, cron, no chat in the looploop-run run <file>

    Every command below runs the same kind of file โ€” here's the one referenced throughout this section:

    # examples/fix_test.loop
     loop "fix the failing checkout tax test":
    @@ -718,6 +757,17 @@ 

    In a Claude Code chat recommended โ€” the main w
    /loopflow "fix the failing checkout tax test"   # write a .loop from a request
     /loopflow run examples/fix_test.loop            # run it, right here in the chat

    You stay in the chat the whole time: you watch each step, you answer the gate, and the loop ends on a real green test โ€” not the assistant saying "done". This is the only mode where a long interactive discovery works, because the human is already in the loop.

    + +

    In VS Code optional โ€” author by hand

    +

    Reach for the extension when you'd rather write .loop files by hand in an editor. Install it from Extensions โ–ธ search "LoopFlow" โ–ธ Install, then open any .loop file:

    +
      +
    • Syntax highlighting, hover docs, and context-aware tab-completion for every construct โ€” including the latest vocabulary (use skills, remember in, flow, for each, and done when the skill "โ€ฆ" approves / scores N or more).
    • +
    • A โ–ถ Run CodeLens above each definition. You choose where it runs via loop.runMode: ask (prompt each time), session (open a Claude Code session in the integrated terminal โ€” watch every step, answer gates in chat), or output (headless, streamed into the VS Code output panel with native gate dialogs).
    • +
    • A soft linter that nudges, never blocks: "this loop has no way to verify it's done", "add a thrash guard".
    • +
    • New Loop from template โ€” from File โ–ธ New Fileโ€ฆ, an Explorer folder right-click, or the Command Palette โ€” scaffolds a best-practice loop (bugfix, feature, security, โ€ฆ the full library) into your workspace, # TODO lines marked.
    • +
    +

    Same file, same engine: the chat is the first-class way to run; the extension is the first-class way to author by hand.

    +

    Headless CLI

    loop-run run   examples/ship_feature.loop  # drive Claude Code, glyph trace
     loop-run run   examples/ship_feature.loop --live  # โ€ฆplus a live browser dashboard
    @@ -736,15 +786,6 @@ 

    Watch it run โ€” live dashboard interm live=true # /loopflow shows the live dashboard during in-session runs

    The page streams over Server-Sent Events (each event carries an id; the server replays on connect and dedupes on reconnect), is self-contained โ€” no external assets โ€” and binds to 127.0.0.1 only.

    -

    In VS Code optional โ€” for hand-authoring

    -

    Secondary to the chat โ€” reach for the extension only when you want to write .loop files by hand in an editor. It turns a plain text file into a real authoring surface: it knows the grammar, catches a loop that can't finish before you run it, lets you launch a run without leaving the editor, and drops in a ready-made best-practice loop to start from. What you get:

    -
      -
    • Syntax highlighting, hover docs, and context-aware tab-completion for every construct โ€” including the latest vocabulary (use skills, remember in, flow, for each, and done when the skill "โ€ฆ" approves / scores N or more).
    • -
    • A โ–ถ Run CodeLens above each definition. When you click it, you choose where it runs (the loop.runMode setting): open a Claude Code session โ€” an interactive run in the integrated terminal where you watch every step and answer gates in chat โ€” or the VS Code output panel (headless, with a live trace and native gate dialogs). Set loop.runMode to ask (prompt each time), session, or output.
    • -
    • A soft linter that nudges (never blocks): "this loop has no way to verify it's done", "add a thrash guard".
    • -
    • New Loop from template โ€” reachable from File โ–ธ New Fileโ€ฆ, an Explorer folder right-click, or the Command Palette โ€” scaffolds a ready-to-edit, best-practice loop into your workspace in one pick, from the same library loop init ships: bugfix, feature, brownfield-feature, refactor; cicd-check, security, clean-architecture, test-coverage, review-diff; and the multi-file flows greenfield-app and load-spec (which pull in their supporting discover/design/story-template + sprint.yaml). Each lands with its # TODO lines marked for you to fill in.
    • -
    -

    Troubleshooting

    @@ -787,7 +828,7 @@

    Your global library โ€” save a loop, run it in any repo done when check, its reflect-and-retry, its gates, and its look at scope with it. Running it re-applies all of that, identically, anywhere. It's a reusable guarantee you built once โ€” not a prompt you re-type and re-trust. -
    Claude is the first-class home for LoopFlow. The library and every /loopflow command live in the chat โ€” that's where you watch each step and answer gates as the loop runs. VS Code is the second seat: handy for editing a .loop with highlighting and a โ–ถ Run button, but the loop still runs through Claude. If you only ever use one surface, use the chat.
    +
    Claude is the first-class home for LoopFlow. The library and every /loopflow command live in the chat โ€” that's where you watch each step and answer gates as the loop runs. VS Code is the second seat: handy for editing a .loop with highlighting and a โ–ถ Run button, but the loop still runs through Claude. If you only ever use one surface, use the chat.
    @@ -890,60 +931,6 @@

    Go deeper

    document.querySelectorAll("section[id]").forEach(function(s){ obs.observe(s); }); })(); -// ---- animated agent terminal: human types, agent streams ---- -(function(){ - var el=document.getElementById('agentterm'); if(!el) return; - var T=[ - {c:'tl-dim',t:'$ claude'}, - {c:'tl-u',t:'โฏ add rate limiting to the API'}, - {c:'tl-tool',t:'โ— Edit src/api/limiter.ts'}, - {c:'tl-dim',t:' + token-bucket limiter, 100 req/min'}, - {c:'tl-ok',t:'โœ“ Done โ€” added a limiter.'}, - {c:'tl-u',t:'โฏ did you add tests?'}, - {c:'tl-tool',t:'โ— Write tests/limiter.test.ts'}, - {c:'tl-ok',t:'โœ“ Added 3 tests.'}, - {c:'tl-u',t:'โฏ run them'}, - {c:'tl-tool',t:'โ— Bash pnpm test rate-limit'}, - {c:'tl-bad',t:' โœ— 2 failing: resets-after-window, per-key-isolation'}, - {c:'tl-u',t:'โฏ fix them, then re-run'}, - {c:'tl-tool',t:'โ— Edit src/api/limiter.ts'}, - {c:'tl-tool',t:'โ— Bash pnpm test rate-limit'}, - {c:'tl-ok',t:' โœ“ 5 passing'}, - {c:'tl-u',t:'โฏ now the whole suite โ€” do not break anything'}, - {c:'tl-tool',t:'โ— Bash pnpm test'}, - {c:'tl-bad',t:' โœ— 1 failing: checkout.spec.ts (shared middleware)'}, - {c:'tl-u',t:'โฏ ugh. fix that too'}, - {c:'tl-tool',t:'โ— Edit src/middleware/index.ts'}, - {c:'tl-tool',t:'โ— Bash pnpm test'}, - {c:'tl-ok',t:' โœ“ all green'}, - {c:'tl-u',t:'โฏ now the security scan'}, - {c:'tl-tool',t:'โ— Bash semgrep --severity=high'}, - {c:'tl-bad',t:' โœ— 1 high: unbounded map โ†’ memory DoS'}, - {c:'tl-u',t:'โฏ fix it. and do NOT push to main'}, - {c:'tl-tool',t:'โ— Edit src/api/limiter.ts'}, - {c:'tl-tool',t:'โ— Bash git commit -am "rate limiting"'}, - {c:'tl-tool',t:'โ— Bash git push origin main'}, - {c:'tl-bad',t:'โš  pushed to main.'}, - {c:'tl-u',t:'โฏ you literally said DO NOT push to main'}, - {c:'tl-dim',t:'โ€” and tomorrow, you type all of this again.'} - ]; - var i=0, cur; - function restart(){ el.innerHTML=''; i=0; startLine(); } - function blockCursor(){ var c=document.createElement('span'); c.className='tcur'; return c; } - function startLine(){ - if(i>=T.length){ setTimeout(restart, 5000); return; } - cur=document.createElement('div'); cur.className='ln '+T[i].c; el.appendChild(cur); - if(T[i].c==='tl-u'){ var cursor=blockCursor(); cur.appendChild(cursor); typeOut(T[i].t, 0, cursor); } - else { cur.textContent=T[i].t; el.scrollTop=el.scrollHeight; i++; setTimeout(startLine, 430); } - } - function typeOut(text, j, cursor){ - if(j>=text.length){ cursor.remove(); el.scrollTop=el.scrollHeight; i++; setTimeout(startLine, 780); return; } - cursor.insertAdjacentText('beforebegin', text.charAt(j)); el.scrollTop=el.scrollHeight; - setTimeout(function(){ typeOut(text, j+1, cursor); }, 58); - } - startLine(); -})(); - diff --git a/docs/keywords/after-n-tries.html b/docs/keywords/after-n-tries.html index cb2fbf4..2c3ada9 100644 --- a/docs/keywords/after-n-tries.html +++ b/docs/keywords/after-n-tries.html @@ -20,7 +20,7 @@
    Keywords / after N tries (thrash guard)

    after N tries (thrash guard)

    -
    Stop & warn if it gets stuck. Control & transitions
    +
    Stop & warn if it gets stuck. Core syntax

    Syntax

    after N tries: stop and warn "<message>"

    What it does

    diff --git a/docs/keywords/allow.html b/docs/keywords/allow.html index 751bf76..98adcb0 100644 --- a/docs/keywords/allow.html +++ b/docs/keywords/allow.html @@ -20,7 +20,7 @@
    Keywords / allow / ask me before

    allow / ask me before

    -
    The action policy: auto vs confirm. Building blocks
    +
    The action policy: auto vs confirm. Core syntax

    Syntax

    allow edits automatically, but ask me before migrations or pushes

    What it does

    diff --git a/docs/keywords/also.html b/docs/keywords/also.html index eac6cae..0ac7b07 100644 --- a/docs/keywords/also.html +++ b/docs/keywords/also.html @@ -20,7 +20,7 @@
    Keywords / also

    also

    -
    Finishing passes after the goal is met. Building blocks
    +
    Finishing passes after the goal is met. Augment

    Syntax

    also: <pass>, <pass>

    What it does

    diff --git a/docs/keywords/done-when.html b/docs/keywords/done-when.html index 762b813..bfaad2a 100644 --- a/docs/keywords/done-when.html +++ b/docs/keywords/done-when.html @@ -20,7 +20,7 @@
    Keywords / done when

    done when

    -
    How a loop verifies itself. Building blocks
    +
    How a loop verifies itself. Core syntax

    Syntax

    done when <predicate>

    What it does

    diff --git a/docs/keywords/each-cycle.html b/docs/keywords/each-cycle.html index e125aa5..22b2b2e 100644 --- a/docs/keywords/each-cycle.html +++ b/docs/keywords/each-cycle.html @@ -20,7 +20,7 @@
    Keywords / each cycle

    each cycle

    -
    The repeated steps, in order. Building blocks
    +
    The repeated steps, in order. Core syntax

    Syntax

    each cycle: plan, then act, then observe

    What it does

    diff --git a/docs/keywords/flow.html b/docs/keywords/flow.html index d08d72f..9fe5a9e 100644 --- a/docs/keywords/flow.html +++ b/docs/keywords/flow.html @@ -20,7 +20,7 @@
    Keywords / flow

    flow

    -
    Chain whole .loop files in order. Structure
    +
    Chain whole .loop files in order. Compose

    Syntax

    flow "<name>":
       run "a.loop"
    diff --git a/docs/keywords/for-each.html b/docs/keywords/for-each.html
    index d118204..02e20e8 100644
    --- a/docs/keywords/for-each.html
    +++ b/docs/keywords/for-each.html
    @@ -20,7 +20,7 @@
     
    Keywords / for each

    for each

    -
    Run a template once per item. Structure
    +
    Run a template once per item. Compose

    Syntax

    for each <var> in "<file>":
       run "<template.loop>"
    diff --git a/docs/keywords/goal.html b/docs/keywords/goal.html index 646f5e9..e954a3a 100644 --- a/docs/keywords/goal.html +++ b/docs/keywords/goal.html @@ -20,7 +20,7 @@
    Keywords / goal

    goal

    -
    What "done" means, in plain language. Building blocks
    +
    What "done" means, in plain language. Core syntax

    Syntax

    goal: <text>

    What it does

    diff --git a/docs/keywords/index.html b/docs/keywords/index.html index 84f6785..687c741 100644 --- a/docs/keywords/index.html +++ b/docs/keywords/index.html @@ -22,15 +22,20 @@

    Keywords

    Every construct in the LoopFlow language โ€” one page each, with syntax, what it does, examples, and a diagram where it helps.

    Learning the language top-to-bottom? Read the tutorial. This is the by-keyword reference.

    -
    Structure
    - -
    Building blocks
    - -
    Control & transitions
    - +
    Core syntax โ€” the five decisionsThe engine. Objective, context, actions, verification, stopping โ€” plus the cycle that drives them, and where a human steps in.
    +
    The five decisions
    + +
    The cycle
    +
    Human-in-the-loop
    + +
    The rest of the syntaxEverything that composes loops into bigger workflows or configures a run โ€” none of it changes how a single loop thinks.
    +
    Compose โ€” scale one loop into many
    + +
    Augment a loop
    +
    Ops & reuse
    - +
    LoopFlow ยท the keyword reference. New here? Start with the tutorial or learn by playing LoopFlow Lab.
    \ No newline at end of file diff --git a/docs/keywords/look-at.html b/docs/keywords/look-at.html index 3401f24..e5e2895 100644 --- a/docs/keywords/look-at.html +++ b/docs/keywords/look-at.html @@ -20,7 +20,7 @@
    Keywords / look at

    look at

    -
    Scope the context the agent reads. Building blocks
    +
    Scope the context the agent reads. Core syntax

    Syntax

    look at: <files>, and the last failure

    What it does

    diff --git a/docs/keywords/loop.html b/docs/keywords/loop.html index ebc3435..7ebb783 100644 --- a/docs/keywords/loop.html +++ b/docs/keywords/loop.html @@ -20,7 +20,7 @@
    Keywords / loop

    loop

    -
    A self-correcting unit of work. Structure
    +
    A self-correcting unit of work. Compose

    Syntax

    loop "<name>":

    What it does

    diff --git a/docs/keywords/pipeline.html b/docs/keywords/pipeline.html index 4bd6052..d26ed6d 100644 --- a/docs/keywords/pipeline.html +++ b/docs/keywords/pipeline.html @@ -20,7 +20,7 @@
    Keywords / pipeline

    pipeline

    -
    Stages in order; fail-fast. Structure
    +
    Stages in order; fail-fast. Compose

    Syntax

    pipeline "<name>":
       stage <name>: โ€ฆ
    diff --git a/docs/keywords/plan-from.html b/docs/keywords/plan-from.html index 8492d84..664b3bd 100644 --- a/docs/keywords/plan-from.html +++ b/docs/keywords/plan-from.html @@ -20,7 +20,7 @@
    Keywords / plan from

    plan from

    -
    Read the plan from a file you control. Ops & reuse
    +
    Read the plan from a file you control. Augment

    Syntax

    plan from "docs/plan.md"

    What it does

    diff --git a/docs/keywords/reflect.html b/docs/keywords/reflect.html index 0db3f3a..5eb8f0f 100644 --- a/docs/keywords/reflect.html +++ b/docs/keywords/reflect.html @@ -20,7 +20,7 @@
    Keywords / reflect

    reflect

    -
    Turn a failure into the next plan. Building blocks
    +
    Turn a failure into the next plan. Core syntax

    Syntax

    when it fails: reflect, then plan again

    What it does

    diff --git a/docs/keywords/remember-in.html b/docs/keywords/remember-in.html new file mode 100644 index 0000000..94f54d3 --- /dev/null +++ b/docs/keywords/remember-in.html @@ -0,0 +1,39 @@ + + +remember in โ€” LoopFlow keyword + + + + + +
    +
    Keywords / remember in
    +

    remember in

    +
    Cross-run memory โ€” read past lessons on start, append the outcome on stop. Augment
    +

    Syntax

    +
    remember in "<file.md>"
    +

    What it does

    +

    Names a Markdown file the loop treats as its memory. On start it reads the file and feeds those lessons into the first plan; on stop it appends a dated entry recording how the run went. Across runs, the loop learns from its own history instead of starting cold each time.

    +

    Example

    +
    loop "keep the flaky e2e suite green":
    +  goal: the end-to-end suite passes three times in a row
    +  remember in "loop.memory.md"
    +  done when "pnpm test:e2e --repeat 3" passes
    +  each cycle: plan, then act, then observe
    +  when it fails: reflect, then plan again
    a loop that carries lessons between runs + +

    Related

    + +
    LoopFlow ยท the keyword reference. New here? Start with the tutorial or learn by playing LoopFlow Lab.
    +
    diff --git a/docs/keywords/run.html b/docs/keywords/run.html index 5a50f87..992ca7c 100644 --- a/docs/keywords/run.html +++ b/docs/keywords/run.html @@ -20,7 +20,7 @@
    Keywords / run / then run

    run / then run

    -
    A step inside a flow. Structure
    +
    A step inside a flow. Compose

    Syntax

    run "<file.loop>"
     then run "<file.loop>"
    diff --git a/docs/keywords/stage.html b/docs/keywords/stage.html
    index 61b0085..eadeece 100644
    --- a/docs/keywords/stage.html
    +++ b/docs/keywords/stage.html
    @@ -20,7 +20,7 @@
     
    Keywords / stage

    stage

    -
    One step of a pipeline โ€” a story. Structure
    +
    One step of a pipeline โ€” a story. Compose

    Syntax

    stage <name>:
       goal: โ€ฆ
    diff --git a/docs/keywords/style.css b/docs/keywords/style.css index b7c2176..4cf87e3 100644 --- a/docs/keywords/style.css +++ b/docs/keywords/style.css @@ -42,6 +42,7 @@ code.inl{background:var(--panel2); border:1px solid var(--line); border-radius:6 .badge{display:inline-block; font-family:var(--ui); font-weight:700; font-size:10px; letter-spacing:1.4px; text-transform:uppercase; padding:3px 10px; border-radius:20px; vertical-align:middle;} .cat-structure{color:var(--blue); border:1px solid color-mix(in srgb,var(--blue) 50%,transparent);} +.cat-core{color:var(--fwd); border:1px solid color-mix(in srgb,var(--fwd) 50%,transparent);} .cat-definition{color:var(--fwd); border:1px solid color-mix(in srgb,var(--fwd) 50%,transparent);} .cat-flow{color:var(--reflect); border:1px solid color-mix(in srgb,var(--reflect) 50%,transparent);} .cat-human{color:var(--gate); border:1px solid color-mix(in srgb,var(--gate) 50%,transparent);} @@ -69,8 +70,11 @@ footer{color:var(--muted); font-size:12px; border-top:1px solid var(--line); mar footer a{color:var(--muted);} footer a:hover{color:var(--ink);} /* index grid */ +.tierhdr{font-family:var(--display); font-weight:700; font-size:22px; letter-spacing:-.2px; color:var(--ink); + margin:38px 0 2px; padding-bottom:8px; border-bottom:1px solid var(--line);} +.tierhdr .sub{display:block; font-family:var(--ui); font-weight:400; font-size:13px; color:var(--muted); letter-spacing:0; margin-top:3px;} .grouphdr{font-family:var(--ui); font-weight:700; letter-spacing:1.6px; text-transform:uppercase; font-size:11px; - color:var(--fwd); margin:30px 0 10px;} + color:var(--fwd); margin:22px 0 10px;} .kwgrid{display:grid; grid-template-columns:repeat(auto-fill,minmax(232px,1fr)); gap:12px;} .kwcard{display:block; border:1px solid var(--line); border-radius:13px; padding:14px 15px; background:linear-gradient(180deg,rgba(255,255,255,.04),rgba(255,255,255,.012)); transition:border-color .15s, transform .1s;} diff --git a/docs/keywords/use-skills.html b/docs/keywords/use-skills.html new file mode 100644 index 0000000..6364777 --- /dev/null +++ b/docs/keywords/use-skills.html @@ -0,0 +1,39 @@ + + +use skills โ€” LoopFlow keyword + + + + + +
    +
    Keywords / use skills
    +

    use skills

    +
    Named skills the loop may invoke during plan and act. Augment
    +

    Syntax

    +
    use skills: <skill-a>, <skill-b>
    +

    What it does

    +

    Lists skills the agent is allowed to call while it works โ€” so the loop coordinates proven, reusable skills instead of one mega-prompt. Pair it with done when the skill "<name>" approves to let a review skill decide the verdict.

    +

    Example

    +
    loop "harden the upload endpoint":
    +  goal: no high-severity findings in the upload path
    +  use skills: security-review, code-review
    +  done when the skill "security-review" approves
    +  each cycle: plan, then act, then observe
    +  when it fails: reflect, then plan again
    a loop that drives two named skills + +

    Related

    + +
    LoopFlow ยท the keyword reference. New here? Start with the tutorial or learn by playing LoopFlow Lab.
    +
    diff --git a/docs/keywords/when.html b/docs/keywords/when.html index f41d89a..60fbe55 100644 --- a/docs/keywords/when.html +++ b/docs/keywords/when.html @@ -20,7 +20,7 @@
    Keywords / when โ€ฆ (transitions)

    when โ€ฆ (transitions)

    -
    Rules evaluated after each observe. Control & transitions
    +
    Rules evaluated after each observe. Core syntax

    Syntax

    when it passes and the goal is met: stop
     when it fails: reflect, then plan again
    

    SymptomFix