Skip to content

teach-mode: learn-from-demonstration → compiled skill (the one real gap vs Grok Bot) #1

Open

Description

@wolfqing

Grok Bot's only headline feature with no open equivalent in this stack: watch the operator perform a workflow (browser demonstration), then persist it as a reusable routine.

Proposed shape

  1. Record: capture a browser session (navigation, clicks, form fills) — Playwright codegen or rrweb-style event capture are candidate primitives.
  2. Compile: turn the trace into an OpenClaw skill — a SKILL.md describing intent + steps, plus a deterministic script for the mechanical parts, with the agent handling variation.
  3. Replay with judgment: the skill runs the deterministic path and falls back to the model when the page drifts.

Non-goals (v1): cross-app desktop recording, mobile.

Prior art to evaluate: Playwright codegen, rrweb, WebArena-style trace formats, ClawHub skill conventions.

If you want this to exist, 👍 the issue or comment with your workflow — the first three concrete recorded-workflow examples will shape the trace format.

Maintainer note: design discussion welcome before any code; this issue is the roadmap anchor linked from the README.

Activity

  1. bferanmi806-sketch commented on Aug 16, 2026

    @bferanmi806-sketch

    I’d love to work on this. I traced the current v0.2 path from the computer panel through the Docker/noVNC browser, the gateway’s Playwright CDP connection, routines, and the agent tool loop before proposing an implementation.

    One thing I wanted to confirm first: this issue predates the v0.2 self-built-core merge and still describes compiling demonstrations into an OpenClaw SKILL.md. Current main no longer appears to have an OpenClaw skill runtime, so I think the record → compile → deterministic replay goal still fits, but the artifact probably wants to be native to OpenGrokBot now.

    My current direction would be:

    • record against the bot’s existing persistent Chromium while the operator drives it through the current noVNC panel, rather than launch a second Codegen browser;
    • instrument the existing Playwright/CDP context to capture semantic navigation/click/input/select events;
    • compile those into a small typed workflow rather than arbitrary generated JS;
    • never persist password/secret input values;
    • replay deterministic steps first, then hand control to the agent only when a locator/page has drifted;
    • keep learned workflows separate from routines: a workflow describes how, while a routine can later schedule when it runs.

    I’d probably split it into recorder/trace foundation → deterministic workflow runner → agent/routine integration rather than land teach-mode as one large PR.

    Does that match where you want #1 to go after the v0.2 rewrite? If so, I’m happy to take the first slice

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions