Open-source AI browser agent for Chrome and Firefox (monorepo) 🧠
JavaScript ai-agentai-agentsai-toolsbrowser-aibrowser-automationbrowser-extensionchrome-aichrome-devtoolschrome-extensionchrome-extensionsfirefox-addonfirefox-addonsfirefox-extensionfirefox-extensionsgemmagemma4minimaxoffline-aioffline-llmqwen
Link workflow editor from workflow docs
Codex release-state testeb7239f5acf7
diff --git a/web/docs/formats/index.html b/web/docs/formats/index.htmlindex d432748de..cb173e907 100644--- a/web/docs/formats/index.html+++ b/web/docs/formats/index.html@@ -29,7 +29,7 @@<section class="doc-section" id="teach"><div class="eyebrow">Learn by demonstration</div><h2>Teach WebBrain a workflow by doing it once</h2><p>Use Teacher mode when you know the browser steps and want to save them without first asking the agent to complete a traced run. The demonstration is tab-scoped and compiles into the same guarded <code>webbrain-workflow/1</code> format as <code>/workflow --save</code>.</p><ol class="step-list"><li><strong>Open the starting page.</strong> Use a regular <code>http(s)</code> page and stop any agent run that currently owns the tab.</li><li><strong>Start teaching.</strong> Enter <code>/teach --start <name></code>. A purple WebBrain Teach indicator appears on the page.</li><li><strong>Perform the workflow manually.</strong> In that tab, make the trusted clicks, complete fields, change checkboxes or radio buttons, submit with Enter, and navigate exactly as the reusable flow should.</li><li><strong>Check progress when useful.</strong> Enter <code>/teach</code> to see the active workflow name and captured action count.</li><li><strong>Compile and save.</strong> Enter <code>/teach --end</code>. Then open <code>/workflow</code> to run, rename, export, or delete the learned workflow.</li></ol><div class="callout tip"><strong class="callout-title">Typed values are never learned</strong><p>The page capture code records a field’s semantic identity, not its contents. Each completed field becomes a runtime parameter, and WebBrain asks for the current value locally whenever the saved workflow runs.</p></div><h3>Capture boundaries</h3><ul><li>Only trusted actions in the top-level page are captured; actions performed by WebBrain itself are excluded.</li><li>The session follows navigation in the same tab and records at most 100 normalized actions.</li><li>Teacher mode and automated agent runs cannot own the same tab at the same time. Finish with <code>/teach --end</code> before starting an agent task.</li><li>Unsupported or unsafe targets are skipped. The save result reports warnings and replay still requires an unambiguous semantic match.</li><li><code>/teach --end</code> closes the temporary teaching session even when compilation cannot produce a workflow, so correct the page or demonstration and start again.</li></ul></section>- <section class="doc-section" id="workflow"><h2>Create from a trace, then move a saved workflow</h2><p>Teacher mode is the manual-demonstration path. If the agent already completed the task successfully with tracing enabled, save that execution instead:</p><ol><li>Enable tracing and complete the task successfully.</li><li>Save it with <code>/workflow --save <name></code>.</li><li>Run <code>/workflow</code> to find its ID.</li><li>Download it with <code>/workflow --export <id></code>.</li><li>On another WebBrain installation, use <code>/workflow --import --file</code>.</li></ol><p>A portable workflow is not the original trace or teaching session. WebBrain removes old element references, CSS selectors, click coordinates, URL query strings and fragments, and typed field values. Typed values become prompts that are collected locally each time the workflow runs.</p><p>The file keeps semantic target descriptions and origin/path scopes so WebBrain can find the current element and fail closed when a match is ambiguous. Normal Act permissions, submission confirmation, and result verification still apply.</p><div class="callout"><strong class="callout-title">Import creates a copy</strong><p>WebBrain assigns a fresh local ID and timestamps instead of overwriting an existing workflow. Portable workflow files are limited to 1 MiB.</p></div></section>+ <section class="doc-section" id="workflow"><h2>Create from a trace, then move a saved workflow</h2><p>Teacher mode is the manual-demonstration path. If the agent already completed the task successfully with tracing enabled, save that execution instead:</p><ol><li>Enable tracing and complete the task successfully.</li><li>Save it with <code>/workflow --save <name></code>.</li><li>Run <code>/workflow</code> to find its ID.</li><li>Download it with <code>/workflow --export <id></code>.</li><li>On another WebBrain installation, use <code>/workflow --import --file</code>.</li></ol><p>Need to inspect or update an exported workflow file? Use the <a href="https://www.webbrain.one/workflow-editor">WebBrain Workflow Editor</a> locally in your browser.</p><p>A portable workflow is not the original trace or teaching session. WebBrain removes old element references, CSS selectors, click coordinates, URL query strings and fragments, and typed field values. Typed values become prompts that are collected locally each time the workflow runs.</p><p>The file keeps semantic target descriptions and origin/path scopes so WebBrain can find the current element and fail closed when a match is ambiguous. Normal Act permissions, submission confirmation, and result verification still apply.</p><div class="callout"><strong class="callout-title">Import creates a copy</strong><p>WebBrain assigns a fresh local ID and timestamps instead of overwriting an existing workflow. Portable workflow files are limited to 1 MiB.</p></div></section><section class="doc-section" id="sharing"><h2>Review before sharing</h2><div class="table-wrap"><table><thead><tr><th>File</th><th>Minimum review</th></tr></thead><tbody><tr><td>Conversation Markdown</td><td>Messages and system notices.</td></tr><tr><td>Trace Markdown or Trace-page JSON</td><td>Prompts, URLs, arguments, results, and any embedded screenshots.</td></tr><tr><td>Settings JSON</td><td>Do not share unless you have intentionally removed every secret and private value.</td></tr><tr><td>Workflow JSON</td><td>Name, source metadata, site origins/path families, target labels, and step intent.</td></tr></tbody></table></div><p>For the complete field-level formats and compatibility rules, see the <a href="https://github.com/webbrain-one/webbrain/blob/main/docs/export-and-workflow-formats.md">technical format reference</a>.</p></section>diff --git a/web/docs/zh/formats/index.html b/web/docs/zh/formats/index.htmlindex 18262a3b1..b14973877 100644--- a/web/docs/zh/formats/index.html+++ b/web/docs/zh/formats/index.html@@ -29,7 +29,7 @@<section class="doc-section" id="teach"><div class="eyebrow">通过演示学习</div><h2>亲自操作一次,教会 WebBrain 一个工作流</h2><p>当你熟悉浏览器操作步骤,又不想先让代理完成一次带轨迹的运行时,可以使用示教模式。演示仅限当前标签页,最终会编译成与 <code>/workflow --save</code> 相同、带安全保护的 <code>webbrain-workflow/1</code> 格式。</p><ol class="step-list"><li><strong>打开起始页面。</strong>使用普通 <code>http(s)</code> 页面,并停止当前占用该标签页的代理运行。</li><li><strong>开始示教。</strong>输入 <code>/teach --start <名称></code>,页面上会出现紫色的 WebBrain Teach 指示器。</li><li><strong>手动完成工作流。</strong>在同一标签页中,按可复用流程执行可信点击、完成字段输入、切换复选框或单选按钮、用 Enter 提交并进行导航。</li><li><strong>按需查看进度。</strong>输入 <code>/teach</code>,查看当前工作流名称和已捕获操作数。</li><li><strong>编译并保存。</strong>输入 <code>/teach --end</code>,再打开 <code>/workflow</code> 运行、重命名、导出或删除学到的工作流。</li></ol><div class="callout tip"><strong class="callout-title">输入值绝不会被学习</strong><p>页面捕获代码只记录字段的语义身份,不读取字段内容。每个完成的字段都会变成运行时参数;以后运行工作流时,WebBrain 会在本地重新询问当前值。</p></div><h3>捕获边界</h3><ul><li>只捕获顶层页面中的可信操作;WebBrain 自己执行的操作不会进入示教记录。</li><li>会话会跟随同一标签页中的导航,最多记录 100 个规范化操作。</li><li>示教模式与自动代理运行不能同时占用同一标签页。启动代理任务前,请先用 <code>/teach --end</code> 结束示教。</li><li>不支持或不安全的目标会被跳过;保存结果会显示警告,重放时仍要求语义目标匹配唯一明确。</li><li>即使无法编译出工作流,<code>/teach --end</code> 也会关闭临时示教会话;请修正页面或演示过程后重新开始。</li></ul></section>- <section class="doc-section" id="workflow"><h2>从轨迹创建,再迁移已保存工作流</h2><p>示教模式适合手动演示。如果代理已经在开启轨迹记录的情况下成功完成任务,也可以直接保存那次执行:</p><ol><li>开启轨迹记录并成功完成任务。</li><li>用 <code>/workflow --save <名称></code> 保存。</li><li>运行 <code>/workflow</code> 查找 ID。</li><li>用 <code>/workflow --export <id></code> 下载。</li><li>在另一套 WebBrain 中使用 <code>/workflow --import --file</code>。</li></ol><p>可移植工作流不是原始轨迹或示教会话。WebBrain 会删除旧元素引用、CSS 选择器、点击坐标、URL 查询字符串和片段,以及曾经输入的字段值。输入值会变成参数,在每次运行时于本地重新收集。</p><p>文件保留语义化目标描述、来源站点和路径范围,因此 WebBrain 可以重新查找当前元素,并在匹配不明确时安全停止。正常的执行模式权限、提交确认和结果验证仍然生效。</p><div class="callout"><strong class="callout-title">导入会创建副本</strong><p>WebBrain 会分配新的本地 ID 和时间戳,不会覆盖现有工作流。可移植工作流文件上限为 1 MiB。</p></div></section>+ <section class="doc-section" id="workflow"><h2>从轨迹创建,再迁移已保存工作流</h2><p>示教模式适合手动演示。如果代理已经在开启轨迹记录的情况下成功完成任务,也可以直接保存那次执行:</p><ol><li>开启轨迹记录并成功完成任务。</li><li>用 <code>/workflow --save <名称></code> 保存。</li><li>运行 <code>/workflow</code> 查找 ID。</li><li>用 <code>/workflow --export <id></code> 下载。</li><li>在另一套 WebBrain 中使用 <code>/workflow --import --file</code>。</li></ol><p>需要检查或修改导出的工作流文件?可在浏览器本地使用 <a href="https://www.webbrain.one/workflow-editor">WebBrain 工作流编辑器</a>。</p><p>可移植工作流不是原始轨迹或示教会话。WebBrain 会删除旧元素引用、CSS 选择器、点击坐标、URL 查询字符串和片段,以及曾经输入的字段值。输入值会变成参数,在每次运行时于本地重新收集。</p><p>文件保留语义化目标描述、来源站点和路径范围,因此 WebBrain 可以重新查找当前元素,并在匹配不明确时安全停止。正常的执行模式权限、提交确认和结果验证仍然生效。</p><div class="callout"><strong class="callout-title">导入会创建副本</strong><p>WebBrain 会分配新的本地 ID 和时间戳,不会覆盖现有工作流。可移植工作流文件上限为 1 MiB。</p></div></section><section class="doc-section" id="sharing"><h2>分享前检查</h2><div class="table-wrap"><table><thead><tr><th>文件</th><th>至少检查</th></tr></thead><tbody><tr><td>对话 Markdown</td><td>消息和系统提示。</td></tr><tr><td>轨迹 Markdown 或轨迹页 JSON</td><td>提示词、URL、参数、结果及内嵌截图。</td></tr><tr><td>设置 JSON</td><td>除非主动删除了所有密钥和隐私值,否则不要分享。</td></tr><tr><td>工作流 JSON</td><td>名称、来源元数据、网站来源和路径范围、目标标签及步骤意图。</td></tr></tbody></table></div><p>完整字段和兼容规则见<a href="https://github.com/webbrain-one/webbrain/blob/main/docs/export-and-workflow-formats.md">技术格式参考(英文)</a>。</p></section>