autolearn-mcp
自动学习浏览器 MCP Server:让任意支持 MCP 的 AI 助手(Trae / Claude / Cursor / Codex...) 成为你的"眼睛和手"——自主探索 Web 系统、回放学会的操作、并把经验沉淀成三层记忆 (情景轨迹 / 语义知识 / 操作技能),越用越聪明。
大脑由 AI 助手担任(无需单独的 LLM API Key),本包只提供感知、执行与记忆。
安装
# 推荐:uvx 一键运行(无需管理 Python 环境)
uvx autolearn-mcp
# 或 pip 安装
pip install autolearn-mcp
autolearn-install # 首次使用:下载 Chromium 内核(约 200MB,仅需一次)
要求:Python ≥ 3.10。首次启动会自动检测并下载 Chromium(进度走 stderr)。
国内网络建议配镜像:
pip install autolearn-mcp -i https://pypi.tuna.tsinghua.edu.cn/simple
配置
配置文件位于 ~/.autolearn/.env(也可用环境变量 / AUTOLEARN_HOME 自定义目录):
TARGET_URL=http://your-system/ # 目标系统地址(建议测试环境)
AUTO_USERNAME= # 可选:自动登录账号
AUTO_PASSWORD= # 可选:自动登录密码
HEADLESS=false # 是否无头模式(人工登录需要 false)
接入 AI 工具
Trae / Claude Desktop / Cursor(通用 stdio):
{
"mcpServers": {
"autolearn": { "command": "uvx", "args": ["autolearn-mcp"] }
}
}
Claude Code:
claude mcp add autolearn -- uvx autolearn-mcp
Codex CLI(config.toml):
[mcp_servers.autolearn]
command = "uvx"
args = ["autolearn-mcp"]
工具清单
| 工具 | 作用 |
|---|---|
open_system(url, goal) |
打开目标系统,开始探索会话(自动建记录) |
auto_login() |
用 .env 凭据自动登录(成功自动保存登录态) |
save_login_state() |
保存登录态,下次免登录 |
perceive_page() |
读取页面可交互元素(iframe 穿透 + 自动截图) |
act(action_json, expect_name) |
执行动作(点击/输入/链式),返回最新页面状态 |
run_skill(skill_id, params) |
回放已沉淀的操作技能(自愈 + 校验) |
recall(query) |
检索记忆,任务前注入历史经验 |
export_memory_digest() |
导出未消化轨迹,供大脑蒸馏 |
save_semantic_memory() / save_skill() |
写入语义知识 / 操作技能 |
finish(summary) |
结束会话 |
典型用法
open_system打开系统(首次人工登录,之后auto_login免密)- 让 AI 助手自主探索:它感知页面 → 决策 → 执行 → 记录
- 会话结束调用沉淀工具,轨迹蒸馏为记忆
- 下次同类任务
run_skill直接回放,越用越快
数据全部落在本地 ~/.autolearn/(记忆、截图、登录态),不上传任何服务器。
Metadata
Release files for autolearn-mcp 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| autolearn_mcp-0.1.0.tar.gz | 20.9 kB | With provenance | Details for autolearn_mcp-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| autolearn_mcp-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for autolearn_mcp-0.1.0-py3-none-any.whl |
Total release size: 48.8 kB
Release files / autolearn_mcp-0.1.0.tar.gz
| Download URL | autolearn_mcp-0.1.0.tar.gz |
|---|---|
| Size | 20.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2ed7838a23d02f915c3536bf4e1a59f95b78e4481d20132ba3e83bfad0ee7582
|
|
BLAKE2b-256 checksum How to use checksums |
7986245c43bd270e45cb99fc1126327ea380f9fb0a053afa30a7a00c7bbb7dd3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 29, 2026.
Transparency logRelease files / autolearn_mcp-0.1.0-py3-none-any.whl
| Download URL | autolearn_mcp-0.1.0-py3-none-any.whl |
|---|---|
| Size | 28.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b21d409f75b43bcc287730e18bbd8ef9999381e6668e9da5b5374d32c764bc49
|
|
BLAKE2b-256 checksum How to use checksums |
c8e7616d1b5ba3b0e9a6b3c262171b11096d3bfefd96433f9e25338f79770498
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 29, 2026.
Transparency logSecurity for autolearn-mcp 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for autolearn_mcp-0.1.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 29, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.