page-agent
AGENTS.md29k starsChanged 5 months agoMITView on GitHub
This is a monorepo with npm workspaces: Internal packages: Source-first monorepo: library package.json exports point to src/*.ts during development. At publish time, scripts/pre-publish.js promotes publishConfig fields to top-level (swapping to dist/), and scripts/post-publish.js restores the originals. workspaces in package.json must be in topological order. All communication is async and isolated:
Trending
Less talk lately.about the whole repository
Who's talking about alibaba/page-agent
- @midu.dev“¡Ojo con esta biblioteca de JavaScript! Controlar cualquier web con lenguaje natural. ✓ Convierte acciones …”Bluesky · Mar 7, 2026 · 9 likes
- @camilleroux.com“PageAgent d'Alibaba te laisse contrôler n'importe quelle interface web en langage naturel, direct en …”Bluesky · Mar 19, 2026 · 6 likes
- @csaba.bsky.social“github.com/alibaba/pag... - AI agent that lives on your web page beui.dev - Animated React components …”Bluesky · Aug 17, 2026 · 5 likes
- @alexiskirke.bsky.social“I came across this impressive open-source project on GitHub: PageAgent lets you control web interfaces with …”Bluesky · Mar 19, 2026 · 4 likes
- @arifsolmaz.bsky.social“Turn any webpage into an AI-controllable interface with natural language commands - no extensions, no …”Bluesky · Mar 26, 2026 · 3 likes
The biggest 5 of 67 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 67
Talked about on GitHub, Bluesky and Hacker News (67 times).
On GitHub · 45
- May 4, 2026HTML Report and Development Suggestions — h4ckf0r0day/obscura1 reaction · 1 comment
- Nov 7, 2026Add Page Agent (alibaba/page-agent) — reacher-z/Awesome-CUA0 reactions
- Nov 7, 2026Curate CUA resources batch w1-021 (clickcast, browser-copilot, +3 more) — reacher-z/Awesome-CUA0 reactions
- Oct 31, 2026page-agent 的 demo CDN 脚本与仓库介绍 — diaoyunxi/blog0 reactions · 6 comments
- Oct 25, 2026chore(deps): bump the production-minor-and-patch group across 1 directory with 9 updates — xiaoniuge36/interview-agent0 reactions
40 more on GitHub
- Oct 15, 2026chore(deps): bump the minor-and-patch group across 1 directory with 29 updates — DavidKk/vercel-web-scripts0 reactions · 1 comment
- Oct 15, 2026chore(deps): bump the minor-and-patch group across 1 directory with 30 updates — DavidKk/vercel-web-scripts0 reactions · 2 comments
- Oct 11, 2026chore(deps): bump the production-minor-and-patch group across 1 directory with 8 updates — xiaoniuge36/interview-agent0 reactions · 1 comment
- Oct 6, 2026agent-skills.github.alibaba.page-agent: init at 1.12.4 — sudosubin/agents.nix0 reactions
- Sep 20, 2026chore(deps): bump the production-minor-and-patch group across 1 directory with 9 updates — xiaoniuge36/interview-agent0 reactions · 1 comment
- Sep 13, 2026chore(deps): bump the production-minor-and-patch group across 1 directory with 8 updates — xiaoniuge36/interview-agent0 reactions · 1 comment
- Sep 10, 2026Bump the minor-and-patch group across 1 directory with 24 updates — hamadalrumaihi/cid0 reactions · 2 comments
- Jul 7, 2026Add controlled PageAgent operator guide to GrowthOps — AIOpsome/growthops0 reactions
- Jul 6, 2026page-agent: 알리바바의 인-페이지 GUI 에이전트 — roomedia/ax-trend0 reactions · 1 comment
- Jul 6, 2026🔥 Github trending [alibaba/page-agent] — web1992/github-trending0 reactions
- Jul 5, 2026📱 SNS 콘텐츠 - 2026-07-06 00:13 KST — leaf468/autothreads0 reactions
- Jul 5, 2026🤖 AI 트렌드 리포트 - 2026-07-06 00:13 KST — leaf468/autothreads0 reactions
- Jul 4, 2026🔥 GitHub Trending AI 早报 · 2026-07-05 · Top 8 项目 — Mystery406/ai-xiaohongshu-daily0 reactions
- Jul 4, 2026📱 SNS 콘텐츠 - 2026-07-05 00:05 KST — leaf468/autothreads0 reactions
- Jul 4, 2026🤖 AI 트렌드 리포트 - 2026-07-05 00:05 KST — leaf468/autothreads0 reactions
- Jul 4, 2026🔥 GitHub Trending AI 晚报 · 2026-07-04 · Top 8 项目 — Mystery406/ai-xiaohongshu-daily0 reactions
- Jun 29, 2026chore(deps): bump page-agent from 1.5.11 to 1.10.0 — mammut001/pipi-shrimp-agent0 reactions · 3 comments
- Jun 26, 2026Add Page Agent under Single-Agent Frameworks — alvinreal/awesome-opensource-ai0 reactions
- Jun 22, 2026[AI/POC] Evaluate PageAgent as LoveBud in-page AI mode execution layer — skerishKang/LoveBud0 reactions · 1 comment
- Jun 22, 2026Build(deps): Bump the minor-and-patch group across 1 directory with 10 updates — sulistta/finder-imagent0 reactions
- Jun 15, 2026Build(deps): Bump the minor-and-patch group across 1 directory with 11 updates — sulistta/finder-imagent0 reactions · 1 comment
- Jun 3, 2026Bump page-agent from 1.5.11 to 1.10.0 — mammut001/pipi-shrimp-agent0 reactions · 5 comments
- May 20, 2026Migrate blog from Jekyll to Next.js + MDX with Web3-style UI — Weo0o0/Weo0o0.github.io0 reactions
- May 19, 2026chore(deps): bump the production-dependencies group across 1 directory with 2 updates — lsiten/page-agent-extention0 reactions · 1 comment
- May 18, 2026Build(deps): Bump the minor-and-patch group across 1 directory with 10 updates — sulistta/finder-imagent0 reactions · 1 comment
- May 11, 2026Build(deps): Bump the minor-and-patch group across 1 directory with 7 updates — sulistta/finder-imagent0 reactions · 1 comment
- May 4, 2026chore(deps): bump @page-agent/page-controller from 1.8.0 to 1.8.1 in the production-dependencies group — lsiten/page-agent-extention0 reactions · 2 comments
- May 1, 2026chore(deps): bump page-agent from 1.5.11 to 1.8.1 — mammut001/pipi-shrimp-agent0 reactions · 2 comments
- Apr 15, 2026Browser(Chromium) Extension Support — xalgorix/xalgorix0 reactions · 5 comments
- Apr 15, 2026The ability to log in to a webpage, click through all menus, and report the results (Adding new features and performing the operation) — Tabbit-Browser/Tabbit-Devtools-Skill0 reactions · 1 comment
- Apr 14, 2026build(deps): bump page-agent from 1.5.8 to 1.7.1 — LeonJi0545/Page-agent-UI0 reactions
- Mar 30, 2026chore(deps): bump the npm-minor-patch group across 1 directory with 21 updates — satyamohapatro1234/NexusLearn0 reactions · 2 comments
- Mar 24, 2026GitHub AI Trending Daily | 2026年3月12日 — aazh2026/aazh2026.github.io0 reactions
- Mar 24, 2026GitHub 趋势雷达 | 2026-03-08 — aazh2026/aazh2026.github.io0 reactions
- Mar 20, 2026add repository — weihubeats/Asuna0 reactions · 1 comment
- Mar 17, 2026build(deps): bump page-agent from 1.5.6 to 1.5.8 — LeonJi0545/Page-agent-UI0 reactions
- Mar 16, 2026chore(deps): bump the npm-minor-patch group in /web with 20 updates — satyamohapatro1234/NexusLearn0 reactions · 2 comments
- Mar 11, 2026📈 Bản tin xu hướng AI mã nguồn mở 2026-03-11 — compasify/agents-radar0 reactions
- Jan 14, 2026feat(allowScopes): add `@page-agent` scope — cnpm/unpkg-white-list0 reactions · 3 comments
- Dec 15, 2025feat: add package `page-agent` — cnpm/unpkg-white-list0 reactions · 3 comments
On Bluesky · 19
- Mar 7, 2026¡Ojo con esta biblioteca de JavaScript! Controlar cualquier web con lenguaje natural. ✓ Convierte acciones de 10 clics en una sola frase ✓… — @midu.dev9 likes and reposts
- Mar 19, 2026PageAgent d'Alibaba te laisse contrôler n'importe quelle interface web en langage naturel, direct en JavaScript dans la page — pas… — @camilleroux.com6 likes and reposts · 1 reply
- Aug 17, 2026github.com/alibaba/pag... - AI agent that lives on your web page beui.dev - Animated React components sevalla.com - Deploy apps without… — @csaba.bsky.social5 likes and reposts
- Mar 19, 2026I came across this impressive open-source project on GitHub: PageAgent lets you control web interfaces with natural language using a… — @alexiskirke.bsky.social4 likes and reposts · 1 reply
- Mar 26, 2026Turn any webpage into an AI-controllable interface with natural language commands - no extensions, no Python, just JavaScript that lets… — @arifsolmaz.bsky.social3 likes and reposts
14 more on Bluesky
- Mar 7, 2026🔥 Hot Repo! 🔥 (100+ new stars) 📦 alibaba / page-agent ⭐ 937 (+104) 🗒 TypeScript JavaScript in-page GUI agent. Control web interfaces… — @github-trending.bsky.social3 likes and reposts
- Jun 28, 2026🎉 Celebrating! 🎉 (500+ new stars) 📦 alibaba / page-agent ⭐ 20,321 (+530) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending-js.bsky.social2 likes and reposts · 1 reply
- Jul 8, 2026🎉 Celebrating! 🎉 (500+ new stars) 📦 alibaba / page-agent ⭐ 24,811 (+892) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending-js.bsky.social1 likes and repost · 1 reply
- Jul 4, 2026💎 Hidden Gem! 💎 (1000+ new stars) 📦 alibaba / page-agent ⭐ 22,711 (+1,110) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending.bsky.social1 likes and repost · 1 reply
- Jul 3, 2026🎉 Celebrating! 🎉 (500+ new stars) 📦 alibaba / page-agent ⭐ 21,988 (+949) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending-js.bsky.social1 likes and repost · 1 reply
- Jun 25, 2026🚀 Skyrocketing! 🚀 (200+ new stars) 📦 alibaba / page-agent ⭐ 19,597 (+280) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending.bsky.social1 likes and repost · 1 reply
- Jun 23, 2026🚀 Skyrocketing! 🚀 (200+ new stars) 📦 alibaba / page-agent ⭐ 19,164 (+425) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending-js.bsky.social1 likes and repost · 1 reply
- Apr 8, 2026🎉 Celebrating! 🎉 (500+ new stars) 📦 alibaba / page-agent ⭐ 16,082 (+610) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending-js.bsky.social1 likes and repost · 1 reply
- Mar 15, 2026🎉 Celebrating! 🎉 (500+ new stars) 📦 alibaba / page-agent ⭐ 8,687 (+558) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending-js.bsky.social1 likes and repost · 1 reply
- Mar 11, 2026💎 Hidden Gem! 💎 (1000+ new stars) 📦 alibaba / page-agent ⭐ 4,255 (+1,206) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending.bsky.social1 likes and repost · 1 reply
- Mar 9, 2026Webページに埋め込むことで自然言語で操作を可能にするAIブラウザ自動化フレームワークらしい DOM中心で実装されており既存のツールより手軽にAIネイティブアプリ化できるのが良さそうかな yug1224 starred alibaba/page-agent… — @yug1224.com1 likes and repost
- Mar 7, 2026🔥 Hot Repo! 🔥 (100+ new stars) 📦 alibaba / page-agent ⭐ 938 (+104) 🗒 TypeScript JavaScript in-page GUI agent. Control web interfaces… — @github-trending-js.bsky.social1 likes and repost
- Jul 5, 2026READMEで確認できた芯はかなり本物ですぅ。PageAgent は『ページの中で動く』GUI agent で、拡張なし・スクショなし・DOMベース、1行scriptで試せる。ここは普通に強いですぅ。 https://github.com/alibaba/page-agent — @lutie-echosphere.bsky.social0 likes and reposts · 1 reply
- Mar 11, 2026💎 Hidden Gem! 💎 (1000+ new stars) 📦 alibaba / page-agent ⭐ 4,255 (+1,206) 🗒 TypeScript JavaScript in-page GUI agent. Control web… — @github-trending-js.bsky.social0 likes and reposts · 1 reply
On Hacker News · 3
- Mar 21, 2026Page-Agent.js: The GUI Agent Living in Your Webpage3 points
- Jul 4, 2026Alibaba/page-agent: in-page GUI agent. Control web interfaces2 points
- Mar 10, 2026Page Agent – JavaScript in-page GUI agent2 points
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.
Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository6 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- git-cleanupSkill
- maintain-model-listSkill
- pre-impl-discussionSkill
- submit-pr-from-current-changesSkill
- update-changelogSkill
The file
We split this AGENTS.md into the rules it gives an agent
8 rules. About 0 are common, 6 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 59
All communication is async and isolated:
- Distinctive: line 120
If tool needs DOM ops, add method to PageController first
- Very specific: line 125
Add implementation in packages/page-controller/src/actions.ts
- Distinctive: line 131
Test value: Do not add redundant tests or directly translate implementation code into assertions.
- Very specific: line 135
Adding tests to a new package: create vitest.config.ts in the package and add a "test": "vitest run" script.
- Distinctive: line 149
Every change you make should not only implement the desired functionality but also improve the quality of the codebase
- Distinctive: line 150
All code and comments must be in English.
- Distinctive: line 151
Do not try to hide errors or risks.
≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Instructions for Coding Assistants
Project Overview
This is a monorepo with npm workspaces:
- Page Agent (
packages/page-agent/) - Main entry with built-in UI Panel, published aspage-agenton npm - Extension (
packages/extension/) - Browser extension (WXT + React) - Website (
packages/website/) - React docs and landing page. When working on website, followpackages/website/AGENTS.md
Internal packages:
- Core (
packages/core/) - PageAgentCore without UI (npm:@page-agent/core) - LLMs (
packages/llms/) - LLM client with reflection-before-action mental model - Page Controller (
packages/page-controller/) - DOM operations and visual feedback (SimulatorMask), independent of LLM - UI (
packages/ui/) - Panel and i18n. Decoupled from PageAgent
Development Commands
npm start # Start website dev server
npm run build # Build all packages
npm run build:libs # Build all libraries
npm run build:ext # Build and zip the extension package
npm run typecheck # Typecheck all packages
npm run test # Run unit tests across all workspaces
npm run lint # ESLintArchitecture
Monorepo Structure
Source-first monorepo: library package.json exports point to src/*.ts during development. At publish time, scripts/pre-publish.js promotes publishConfig fields to top-level (swapping to dist/), and scripts/post-publish.js restores the originals.
packages/
├── core/ # npm: "@page-agent/core" ⭐ Core agent logic (headless)
├── page-agent/ # npm: "page-agent" entry class (with UI + controller + demo builds)
├── website/ # @page-agent/website (private)
├── llms/ # @page-agent/llms
├── extension/ # Browser extension
├── page-controller/ # @page-agent/page-controller
└── ui/ # @page-agent/uiworkspaces in package.json must be in topological order.
Module Boundaries
- Page Agent: Main entry with UI. Extends PageAgentCore and adds Panel. Imports from
@page-agent/core,@page-agent/ui - Core: PageAgentCore without UI. Imports from
@page-agent/llms,@page-agent/page-controller - LLMs: LLM client with MacroToolInput contract. No dependency on page-agent
- UI: Panel and i18n. Decoupled from PageAgent via PanelAgentAdapter interface
- Page Controller: DOM operations with optional visual feedback (SimulatorMask). No LLM dependency. Enable mask via
enableMask: trueconfig
PageController ↔ PageAgent Communication
All communication is async and isolated:
// PageAgent delegates DOM operations to PageController
await this.pageController.updateTree()
await this.pageController.clickElement(index)
await this.pageController.inputText(index, text)
await this.pageController.scroll({ down: true, numPages: 1 })
// PageController exposes state via async methods
const simplifiedHTML = await this.pageController.getSimplifiedHTML()
const pageInfo = await this.pageController.getPageInfo()DOM Pipeline
- DOM Extraction: Live DOM →
FlatDomTreeviapage-controller/src/dom/dom_tree/ - Dehydration: DOM tree → simplified text for LLM
- LLM Processing: AI returns action plans (page-agent)
- Indexed Operations: PageAgent calls PageController by element index
Key Files Reference
Page Agent (packages/page-agent/)
| File | Description |
src/PageAgent.ts | ⭐ Main class with UI, extends PageAgentCore |
src/demo.ts | IIFE demo entry (auto-init with demo API) |
Core (packages/core/)
| File | Description |
src/PageAgentCore.ts | ⭐ Core agent class without UI |
src/tools/ | Tool definitions calling PageController |
src/config/ | Configuration types and constants |
src/prompts/ | System prompt templates |
LLMs (packages/llms/)
| File | Description |
src/index.ts | ⭐ LLM class with retry logic |
src/types.ts | MacroToolInput, AgentBrain, LLMConfig |
src/OpenAIClient.ts | OpenAI-compatible client |
Page Controller (packages/page-controller/)
| File | Description |
src/PageController.ts | ⭐ Main controller class with optional mask support |
src/SimulatorMask.ts | Visual overlay blocking user interaction during automation |
src/actions.ts | Element interactions (click, input, scroll) |
src/dom/dom_tree/index.js | Core DOM extraction engine |
Adding New Features
New Agent Tool
- Implement in
packages/core/src/tools/index.ts - If tool needs DOM ops, add method to PageController first
- Tool calls
this.pageController.methodName()for DOM interactions
New PageController Action
- Add implementation in
packages/page-controller/src/actions.ts - Expose via async method in
PageController.ts - Export from
packages/page-controller/src/index.ts
Testing
- Test value: Do not add redundant tests or directly translate implementation code into assertions. Test meaningful behavior and realistic failure modes.
- Framework: Vitest (unit tests only for now; future E2E goes to
packages/e2e/with Playwright) - Location: co-located,
src/foo.test.tsnext tosrc/foo.ts - Coverage today:
packages/llmsonly — other packages will follow incrementally - Adding tests to a new package: create
vitest.config.tsin the package and add a"test": "vitest run"script. Rootnpm testandnode scripts/ci.jspick it up through npm workspaces. - Live tests (hit real external APIs, slow/costly): name them
*.live.test.ts, exclude them from the package'stestscript, and expose them via atest:livescript. Rootnpm run test:liveruns all of them; they never run innpm testor CI. Template:packages/llms. - Template: See @page-agent/llms
npm test # all packages with a test script
npm test -w @page-agent/llms # single package
cd packages/llms && npx vitest # watch mode in one packageCode Standards
- Explicit typing for exported/public APIs
- ESLint relaxes some unsafe rules for rapid iteration
- Every change you make should not only implement the desired functionality but also improve the quality of the codebase
- All code and comments must be in English.
- Do not try to hide errors or risks. They are valuable feedbacks for developers and users. Make them visible and actionable.
- Traceability and predictability is more important than success rate.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

