diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml
index a4f0d48..6d5ddc7 100644
--- a/.github/ISSUE_TEMPLATE/bug_report.yml
+++ b/.github/ISSUE_TEMPLATE/bug_report.yml
@@ -9,7 +9,7 @@ body:
Thanks for your interest in improving the project! Before submitting, please read our guidelines.
感谢您对改进项目的兴趣!提交前请阅读我们的指南。
- - [Code of Conduct](https://github.com/alibaba/page-agent/blob/main/CODE_OF_CONDUCT.md)
+ - [Code of Conduct](https://github.com/alibaba/page-agent/blob/main/docs/CODE_OF_CONDUCT.md)
- [Contributing Guide](https://github.com/alibaba/page-agent/blob/main/CONTRIBUTING.md)
- type: textarea
diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml
index d13818c..d4182e2 100644
--- a/.github/ISSUE_TEMPLATE/config.yml
+++ b/.github/ISSUE_TEMPLATE/config.yml
@@ -10,5 +10,5 @@ contact_links:
url: https://github.com/alibaba/page-agent/blob/main/CONTRIBUTING.md
about: How to contribute code and ideas. 如何进行贡献与提交代码。
- name: Code of Conduct / 行为准则
- url: https://github.com/alibaba/page-agent/blob/main/CODE_OF_CONDUCT.md
+ url: https://github.com/alibaba/page-agent/blob/main/docs/CODE_OF_CONDUCT.md
about: Community expectations and standards. 社区行为期望与标准。
diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml
index 2d34850..76c686e 100644
--- a/.github/ISSUE_TEMPLATE/feature_request.yml
+++ b/.github/ISSUE_TEMPLATE/feature_request.yml
@@ -9,7 +9,7 @@ body:
Thanks for your interest in improving the project! Before submitting, please read our guidelines.
感谢您对改进项目的兴趣!提交前请阅读我们的指南。
- - [Code of Conduct](https://github.com/alibaba/page-agent/blob/main/CODE_OF_CONDUCT.md)
+ - [Code of Conduct](https://github.com/alibaba/page-agent/blob/main/docs/CODE_OF_CONDUCT.md)
- [Contributing Guide](https://github.com/alibaba/page-agent/blob/main/CONTRIBUTING.md)
- type: textarea
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
index c9da70d..5a0fc96 100644
--- a/.github/PULL_REQUEST_TEMPLATE.md
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -22,4 +22,4 @@ Closes #(issue)
## Requirements / 要求
-- [ ] I have read and follow the [Code of Conduct](CODE_OF_CONDUCT.md) and [Contributing Guide](CONTRIBUTING.md) . / 我已阅读并遵守行为准则。
+- [ ] I have read and follow the [Code of Conduct](../docs/CODE_OF_CONDUCT.md) and [Contributing Guide](../CONTRIBUTING.md) . / 我已阅读并遵守行为准则。
diff --git a/.gitignore b/.gitignore
index b6801aa..0b911cf 100644
--- a/.gitignore
+++ b/.gitignore
@@ -29,11 +29,6 @@ dist-ssr
.env
.env.*
-# Copied files for npm publish (generated by prepublishOnly)
-packages/page-agent/README.md
-packages/page-agent/README-zh.md
-packages/page-agent/LICENSE
-
# extension
.output
.wxt
diff --git a/README.md b/README.md
index d2c4cae..a470f0e 100644
--- a/README.md
+++ b/README.md
@@ -9,7 +9,7 @@
The GUI Agent Living in Your Webpage. Control web interfaces with natural language.
-🌐 **English** | [中文](./README-zh.md)
+🌐 **English** | [中文](./docs/README-zh.md)
👉 🚀 Demo | 📖 Documentation
@@ -19,13 +19,13 @@ The GUI Agent Living in Your Webpage. Control web interfaces with natural langua
## ✨ Features
-- **🎯 Easy integration**
- - No need for `browser extension` / `python` / `headless browser`.
- - Just in-page javascript. Everything happens in your web page.
- - The best tool for your agent to control web pages.
+- **🎯 Easy integration**
+ - No need for `browser extension` / `python` / `headless browser`.
+ - Just in-page javascript. Everything happens in your web page.
+ - The best tool for your agent to control web pages.
- **📖 Text-based DOM manipulation**
- - No screenshots. No OCR or multi-modal LLMs needed.
- - No special permissions required.
+ - No screenshots. No OCR or multi-modal LLMs needed.
+ - No special permissions required.
- **🧠 Bring your own LLMs**
- **🎨 Pretty UI with human-in-the-loop**
- **🐙 Optional [chrome extension](https://alibaba.github.io/page-agent/#/docs/features/chrome-extension) for multi-page tasks.**
@@ -79,7 +79,7 @@ For more programmatic usage, see [📖 Documentations](https://alibaba.github.io
We welcome contributions from the community! Follow our instructions in [CONTRIBUTING.md](CONTRIBUTING.md) for environment setup and local development.
-Please read [Code of Conduct](CODE_OF_CONDUCT.md) before contributing.
+Please read [Code of Conduct](docs/CODE_OF_CONDUCT.md) before contributing.
## 👏 Acknowledgments
diff --git a/CHANGELOG.md b/docs/CHANGELOG.md
similarity index 100%
rename from CHANGELOG.md
rename to docs/CHANGELOG.md
diff --git a/CODE_OF_CONDUCT.md b/docs/CODE_OF_CONDUCT.md
similarity index 100%
rename from CODE_OF_CONDUCT.md
rename to docs/CODE_OF_CONDUCT.md
diff --git a/README-zh.md b/docs/README-zh.md
similarity index 89%
rename from README-zh.md
rename to docs/README-zh.md
index 851c42f..a3405a4 100644
--- a/README-zh.md
+++ b/docs/README-zh.md
@@ -9,7 +9,7 @@
纯 JS 实现的 GUI agent。使用自然语言操作你的 Web 应用。无须后端、客户端、浏览器插件。
-🌐 [English](./README.md) | **中文**
+🌐 [English](../README.md) | **中文**
👉 🚀 Demo | 📖 Documentation
@@ -19,13 +19,13 @@
## ✨ Features
-- **🎯 轻松集成**
- - 无需 `浏览器插件` / `Python` / `无头浏览器`。
- - 纯页面内 JavaScript,一切都在你的网页中完成。
- - The best tool for your agent to control web pages.
+- **🎯 轻松集成**
+ - 无需 `浏览器插件` / `Python` / `无头浏览器`。
+ - 纯页面内 JavaScript,一切都在你的网页中完成。
+ - The best tool for your agent to control web pages.
- **📖 基于文本的 DOM 操作**
- - 无需截图,无需 OCR 或多模态模型。
- - 无需特殊权限。
+ - 无需截图,无需 OCR 或多模态模型。
+ - 无需特殊权限。
- **🧠 用你自己的 LLM**
- **🎨 精美 UI,支持人机协同**
- **🐙 可选的 [Chrome 扩展](https://alibaba.github.io/page-agent/#/docs/features/chrome-extension),支持跨页面任务。**
@@ -77,7 +77,7 @@ await agent.execute('点击登录按钮')
## 🤝 贡献
-欢迎社区贡献!请参阅 [CONTRIBUTING.md](CONTRIBUTING.md) 了解环境配置和本地开发说明。
+欢迎社区贡献!请参阅 [CONTRIBUTING.md](../CONTRIBUTING.md) 了解环境配置和本地开发说明。
请在贡献前阅读[行为准则](CODE_OF_CONDUCT.md)。
@@ -106,7 +106,7 @@ file and in the node_modules directory after installation.
## 📄 许可证
-[MIT License](LICENSE)
+[MIT License](../LICENSE)
---
diff --git a/scripts/sync-version.js b/scripts/sync-version.js
index c73d1dd..736e60f 100644
--- a/scripts/sync-version.js
+++ b/scripts/sync-version.js
@@ -111,7 +111,7 @@ const CDN_DEMO_URL_NEW = `https://cdn.jsdelivr.net/npm/page-agent@${newVersion}/
const CDN_DEMO_CN_URL_OLD = `https://registry.npmmirror.com/page-agent/${oldVersion}/files/dist/iife/page-agent.demo.js`
const CDN_DEMO_CN_URL_NEW = `https://registry.npmmirror.com/page-agent/${newVersion}/files/dist/iife/page-agent.demo.js`
-const filesToUpdateCdn = ['README.md', 'README-zh.md', 'packages/website/src/constants.ts']
+const filesToUpdateCdn = ['README.md', 'docs/README-zh.md', 'packages/website/src/constants.ts']
for (const relPath of filesToUpdateCdn) {
const filePath = join(rootDir, relPath)