clawpipe-booster-browsing
v0.0.1
Published
Opt-in Booster pack that maps natural-language site-action prompts to browsing-skills dispatch descriptors. Bridges clawpipe-ai with github.com/browsing-skills/browsing-skills.
Maintainers
Readme
clawpipe-booster-browsing
Alpha (0.0.x). Expect breaking changes to the dispatch sentinel format and rule API until 1.0.
Opt-in ClawPipe Booster pack that maps natural-language site-action prompts to browsing-skills dispatch descriptors.
Why a separate package
clawpipe-ai's default Booster returns a deterministic answer string
(skipping the LLM). This pack widens that contract: rules return a
deterministic action descriptor that the caller dispatches to a browsing
runner (Chrome bridge, Playwright, Browserbase, etc.).
That contract widening is real, and it doesn't belong in the core SDK. So this lives as a separate opt-in package. Install it only if you're building agent flows that mix LLM calls with browser automation.
Install
npm install clawpipe-ai clawpipe-booster-browsingclawpipe-ai is a peer dependency (>= 3.7.0).
Usage
import { Booster } from 'clawpipe-ai';
import {
browsingRules,
parseBoosterDispatch,
} from 'clawpipe-booster-browsing';
const booster = new Booster();
for (const rule of browsingRules) booster.addRule(rule);
const out = booster.tryResolve('search noise canceling headphones on amazon');
const dispatch = parseBoosterDispatch(out);
if (dispatch) {
// out was 'BOOSTER_DISPATCH:{"runner":"browsing-skills","skill":"amazon.com/search","args":{"query":"noise canceling headphones"}}'
// dispatch = { runner: 'browsing-skills', skill: 'amazon.com/search', args: { query: '...' } }
const data = await runBrowsingSkill(dispatch);
} else if (out) {
// some other Booster rule matched — normal deterministic answer
return out;
} else {
// no rule matched — fall through to the LLM
return await llmFallback();
}Rules included
| Rule | Pattern | Dispatched skill |
|---|---|---|
| browsing.amazon.search | ^(search\|find\|look up) ... on amazon$ | amazon.com/search |
| browsing.booking.search | ^(find\|book) (hotel\|stay\|room) in <City> <dates> [under $N]$ | booking.com/search |
| browsing.x.profile | ^(get\|fetch\|show) (x\|twitter) profile (for) @<handle>$ | x.com/profile-data |
| browsing.linkedin.post | ^(get\|fetch) linkedin post (data) (from\|at) <linkedin.com/posts/...>$ | linkedin.com/post-data |
| browsing.reddit.search | ^(search\|find) reddit (for) <query> [in r/<subreddit>]$ | reddit.com/search |
Patterns are intentionally high precision, not high recall. Mis-dispatching a browser session is more expensive than falling through to the LLM, so each regex requires explicit action verbs.
Dispatch descriptor shape
interface BrowsingDispatch {
runner: 'browsing-skills';
skill: string; // e.g. 'amazon.com/search'
args: Record<string, unknown>;
}The pack does not execute browser actions itself. It only emits a descriptor your code maps to a browsing-skills runner of your choice.
Status
Experimental. The contract widening (action-vs-answer) and the dispatch sentinel format may change before 1.0.
License
MIT
