Riffle

io.noetivev0.1.1更新于 Oct 9, 2026

Your agent uses the web as text, not screenshots. Several steps per call, only changes come back.

概览

AI 生成的概览

Riffle 让助手通过文本程序驱动真实的 Chrome 浏览器,以文本读取页面,并且只返回发生变化的部分。

功能
Riffle 是一个 MCP 服务器兼 CLI,它会运行自己的临时 Chrome,执行页面 JavaScript,并把每个页面以简短文本行而非 HTML、CSS 或截图交给助手。它提供两个工具:browser_run 接收每行一步的程序(goto、click、fill、select、check、press、hover、scroll、upload、wait、expect、dialog、try、view、eval),一次调用执行全部步骤,在第一个失败步骤处停止并说明是哪一步及原因;browser_view 通过 outline、interactive、read、table REF、find、expand、net、unseen 等视图读取页面。首次查看之后,回复只包含变化的部分,视图还可设置 token 预算。
适用场景
当助手需要操作实时网页而不只是阅读网页时适用:登录、填写表单、点击流程、从页面提取表格,或查看页面背后的 fetch 与 XHR 请求。也适合以真实用户方式驱动本地 Web 应用,并运行真实页面 JavaScript。它不适合视觉回归测试,也无法给出只存在于像素中的答案,不绕过机器人防护或验证码。iframe 内的内容会报告为 content-not-shown,需要弹出窗口的流程无法工作。
运行要求
以 npm 包形式通过 stdio 在本地运行,用 npx @noetive/riffle mcp 启动,也可使用 Go 二进制。机器上必须安装 Chrome 或 Chromium,可用 riffle doctor 检查。未声明任何账号、API 密钥、环境变量或请求头。仅支持桌面端,在原生 Windows 上需通过 cmd 调用 npx。可选参数如 -allow-private、-allow-origin、-upload-dir 和 -keep-state NAME 会改变会话可访问或保留的内容。
安装前请注意
机密以 $secret:name 形式写入并绑定到单一来源,不会回显给助手。页面文本被视为数据并在回复中引用,但不可见文本以及标签与文字不一致的控件仍会被标出。本地与私有地址默认关闭,需设置 -allow-private;上传与 eval 默认关闭。使用 -keep-state NAME 时,Cookie 与站点存储会保存到文件,任何能读取该文件的人都能复用这些登录状态,应避免放入共享备份和同步文件夹。Riffle 不绕过机器人防护或验证码,并在 user agent 中标识自身。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Riffle,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

Riffle

Your agent uses the web as text, not screenshots.

Pages as text. Only what changed comes back. Several steps per call. Fully interactive, without a mouse or keyboard.

[npm] [CI] [Go] [MCP server] [License: ISC]

Why Riffle · Install · Use · Stay signed in · Safe by default · Releases

npx @noetive/riffle init

Claude Code · Cursor · GitHub Copilot · Kiro · Antigravity · any MCP client


Riffle is an MCP server and CLI. It runs Chrome with the page's JavaScript and hands your agent each page as text it can read and act on.

Why Riffle

Your agent sees what a person sees

What is covered, hidden, primary, disabled, struck through or truncated is written on the line, in words. No HTML, no CSS, no images: Riffle turns the page into short lines of text, so your agent reads these facts instead of guessing them from markup or pixels.

modal d1 "Cookie preferences" covers=page  text "We use cookies."  button b1 "Accept all" primary  button b2 "Reject"main covered-by=d1  h1 "Your cart"  list    item "Trail shoe 42" "€89" strike "€69" red | "Qty" | spinbutton f1 "Qty" ="1" | button b3 "Remove"  button b4 "Checkout"

The cart sits behind a cookie dialog, the old price is struck through and the new one is red. covered-by=d1 tells your agent the checkout button sits behind the dialog.

Context that lasts the whole task

After the first view, every reply carries only what changed. Click "Reject" on the page above and this is the whole reply:

- d1- text "We use cookies."- b1- b2~ main -covered-by=d1

Every view also takes a token budget, so a long page costs what you set: view interactive budget=800.

Fewer turns, less waiting

Your agent writes a program, one step per line, and Riffle runs all of it in one call. A whole sign-in is one turn:

goto https://shop.example/logintry click "Reject"fill "Email" "[email protected]"fill "Password" $secret:shopclick "Sign in"expect url ~ /accountview interactive budget=800

After each step Riffle waits until the page has answered and gone quiet instead of sleeping for a fixed time: about a second after a click, a few seconds after a page loads. The program stops at the first step that fails and says which step and why.

No mouse, no keyboard, no screenshots

Your agent names what to act on by the words on it or by a ref from a view: click "Reject", fill "Email" "[email protected]", click b4. Your agent never steers a pointer, aims at coordinates or reads an image. fill sets a whole field in one step, and press Enter names the key. When a step can't happen, the reply says what is in the way:

failed line 1: click "Checkout": blocked: b4 covered-by d1 "Cookie preferences"

Your agent's next program closes the dialog first.

Instead of

What your agent uses nowWhat it costsWith Riffle
Screenshots and clicks at coordinatesAn image and a turn for every action, and guesses from pixelsText, and several steps per call
A page snapshot or raw HTML after every actionThe whole page again in your agent's context, every timeOnly what changed
Fetching a page as MarkdownIt can read, but it can't click, fill in or sign inA real browser: click, fill in, sign in

Install

bash
npx @noetive/riffle init --client claude-code

Other editors: --client cursor, copilot, kiro, antigravity. Run init with no --client and it configures the editor it finds. --dry-run shows the change without writing it. --keep-state NAME keeps the agent signed in between runs; see Stay signed in.

Any MCP client can use this entry:

json
{  "mcpServers": {    "riffle": { "command": "npx", "args": ["-y", "@noetive/riffle", "mcp"] }  }}

On native Windows, run npx through cmd: "command": "cmd", "args": ["/c", "npx", "-y", "@noetive/riffle", "mcp"]. init writes this form for you.

Or install the binary: go install github.com/noetive/riffle/cmd/riffle@latest, or take one from the releases.

Riffle needs Chrome or Chromium on the machine. Check with:

bash
riffle doctor

Riffle runs its own throwaway Chrome. It never touches your saved passwords or keychain, and it cleans up after itself when it stops.

Use

Your agent gets two tools. browser_run takes a program, one step per line, like the sign-in under Fewer turns, less waiting. browser_view reads the page.

Not sure of the syntax? Ask for view help, or run riffle grammar.

Steps: goto back forward click dblclick fill select check press hover scroll upload wait expect dialog try view eval. Views: outline, interactive, read, table REF, find "text", expand REF, net, unseen.

From a shell:

bash
riffle run  < program.txt      # run a programriffle view interactive        # read the current pageriffle close                   # end the session and its browser

Each editor's agent has a browser of its own, so two windows never drive the same page. Its MCP server names its session on stderr at start; riffle view -s NAME shows that agent's page. Entries that pass the same -s NAME, as in riffle mcp -s shared, share one browser.

Riffle keeps browsers from piling up on your machine. At most four run at once, however many agents use Riffle (riffle serve -max-browsers N to change it). An agent that needs another waits for one to end, then is told which sessions hold them. A session unused for 15 minutes ends, and its next use starts on a blank page and says so. An editor's session ends when the editor stops its MCP server, and a Riffle with nothing to do exits after 30 minutes.

Stay signed in

Name a session in your editor's entry and Riffle keeps its sign-ins. The agent signs in once, and the next time the editor starts it is still signed in.

bash
npx @noetive/riffle init --client claude-code --keep-state shop

or, by hand:

json
{ "mcpServers": { "riffle": { "command": "npx", "args": ["-y", "@noetive/riffle", "mcp", "-keep-state", "shop"] } } }
  • What survives. Cookies and site storage are saved after every call, so they outlast the editor restarting, Riffle stopping and the browser crashing. Starting again sends nothing to any site: the first request is the agent's own.
  • Where it is kept. At start Riffle names the file in its MCP server log. Only you can read it, but whoever can read it can use those sign-ins: keep it out of shared backups and synced folders. To sign the session out of everything, close the editors that use the name and delete the file.
  • One name, one browser. Editors whose entries use the same name share one browser and one set of sign-ins. Give each project its own name to keep them apart. A name is lower case letters, digits, - and _.
  • Limits still hold. A session started with -allow-origin gets back only the sign-ins of the sites it allows, and none for private addresses unless -allow-private is set. What a limit leaves out stays kept for a session allowed it.
  • What is not kept. Storage is kept for the site the agent is on when each call ends, not for a site it only passed through within a call, nor for a frame from another site. Storage is kept for up to 50 sites; the one used longest ago goes first. A site whose storage cannot be put back is reported to the agent as event unrestored, and the session starts without it; it stays kept.

What you can do with it

  • Pull a table out of a page. table REF returns rows as TSV, whatever the markup.
  • See what the page calls. view net lists the fetch and XHR requests behind it.
  • Test your own web app. Drive localhost the way a user would, with real page JavaScript running. Start Riffle with -allow-private, for example riffle mcp -allow-private in your editor's entry, so it may reach local addresses.
  • Stay signed in between runs. Sign in once with -keep-state NAME, and the agent is still signed in the next time the editor starts. See Stay signed in.

Pages run in real time, as in any browser, and keep running while your agent thinks: a countdown, an expiring sign-in or a panel that opens later moves on between calls, and the next reply tells what changed.

Riffle also says so when a step did not do what it asked, such as a form that was refused, so the agent can fix it and go on.

Safe by default

  • Secrets are written as $secret:name, tied to one origin, and never shown back to the agent.
  • Text a person couldn't see on the page is counted, and shown only when you ask, inside a marker that says it's page data.
  • A control whose hidden label contradicts the words on it is flagged name-differs.
  • Page text is data. Replies quote it, so a page can't pass it off as your instructions.
  • Local and private network addresses are off until you turn them on with -allow-private, so a page cannot send the agent into your network or a cloud metadata service.
  • Uploads and eval are off until you turn them on. -allow-origin and -upload-dir limit where a session can go and what it can send. A Riffle that restarts after a crash keeps the limits it was given.
  • Sign-ins end with their session, unless you keep them with -keep-state NAME. Kept sign-ins are in a file only you can read; delete it to forget them. A session gets back only the sign-ins its limits allow.

What it isn't

  • Not a screenshot tool. If the answer is only in the pixels, Riffle can't give it to you.
  • Not a way around bot protection or CAPTCHAs. It doesn't try. Every request says it comes from Riffle: the user agent ends in Riffle/<version>.
  • Not a test framework for visual regressions. Use a tool built for that.
  • Chrome and Chromium only. Content inside iframes is reported as content-not-shown, not read.
  • Links that open a mail or phone app do nothing, and a new window opens in the same tab, so flows that need a pop-up do not work.

Works with the rest of Noetive

Riffle runs alone. It also pairs with another Noetive service:

  • Semantik is a semantic message broker. An agent that reads a page can publish what it found, and its peers find it by meaning, with no topic names to agree on.

Develop

bash
make buildmake testmake lintgo test -tags integration ./...   # drives a real Chrome

See CONTRIBUTING.md. Report security issues as described in SECURITY.md.

License

ISC. Copyright (c) 2026 Noetive.io

来源:README.md,提交 0189ddf

工具

0
工具元数据尚未被收录。

版本历史

1
  1. v0.1.1最新Oct 9, 2026