Files
HomeAgent/third_party/homeagent-sdk/example/browser/plg.json
JianFeeeee dd7f41d99a feat(browser): systemd 托管共享浏览器后端 + 全机 agent 标签页架构 v2.2.0
浏览器插件重新定位为本机所有 agent 的统一浏览器操作壳:

1. 主路径:homeagent-browser.service(systemd 托管)
   - chromium --headless --remote-debugging-port=9222
     --user-data-dir=<data>/browser_profiles/shared
   - 独立于 homed 生命周期,崩溃自动重启,登录态持久保存
   - 本机所有 agent(HomeAgent/pi/opencode/deepseekharness 等)
     共享同一实例:登录一次全机可用

2. 每 agent 一个标签页(CDP Target 隔离),同 source 复用已有标签页

3. browser_start 探测链:CDP 9222 在线 → 直连;服务已装未跑 →
   systemctl start 等待就绪;未安装 → 返回 need_install+guide 引导

4. 新工具 browser_install:探测 chromium 二进制 → 写 systemd 单元 →
   daemon-reload + enable --now → 验证 CDP → 返回全机共享使用指南
   (含其他 agent 经 connectOverCDP 接入的说明);无 root 权限时
   返回手动安装命令清单

5. failback:无法联网装 chromium 的机器,重试 start 自动降级本地
   spawn 临时模式(登录态不持久,仅保证功能可用)

工具链打包 v2.2.0 已部署验证:need_install 引导 / install 装服 /
start 复用与开新标签页全链路通过。
2026-08-26 12:22:15 +08:00

21 lines
461 B
JSON
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{
"name": "browser",
"name_zh": "浏览器",
"name_en": "Browser",
"version": "2.2.0",
"description": "统一浏览器插件:搜索、HTTP抓取(quick)、无头渲染(normal)、交互式浏览器(interactive/CDP)",
"author": "HomeAgent",
"entry": "plugin.so",
"tags": [
"web",
"search",
"fetch",
"browser",
"cdp"
],
"targets": "linux/amd64",
"outdir": "dist",
"bundle": true,
"replaces": {},
"source_dirs": []
}