limixbot 0.3.30 → 0.3.32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{ActivityPanel-Ca93mwbG.js → ActivityPanel-DTPq6b6A.js} +1 -1
- package/dist/assets/{App-BNTTjhsV.js → App-Bj6vt28W.js} +10 -10
- package/dist/assets/{AppEventEditor-cfYkXfeJ.js → AppEventEditor-CIN9KfeN.js} +1 -1
- package/dist/assets/{BotSettingsDialog-DSlyshDi.js → BotSettingsDialog-CiDt0xV-.js} +1 -1
- package/dist/assets/{BrowserPanel-KrCVA3c6.js → BrowserPanel-CYEYQdY9.js} +1 -1
- package/dist/assets/{BrowserProfilesManager-C-Vt0eJi.js → BrowserProfilesManager-BZviBIr_.js} +1 -1
- package/dist/assets/{CloudAddDialog-D6ATLiSR.js → CloudAddDialog-CKOoPJ3V.js} +1 -1
- package/dist/assets/{ComputerFilesPane-DvNcD0u0.js → ComputerFilesPane-DIDi3dyq.js} +1 -1
- package/dist/assets/{ComputerPanel-BButaK92.js → ComputerPanel-CIfRLDu5.js} +2 -2
- package/dist/assets/{DataPanel-iOCJJ-ic.js → DataPanel-Cg_iZFBB.js} +1 -1
- package/dist/assets/{DesktopViewer-DbEC8oPW.js → DesktopViewer-CdrtMd2T.js} +1 -1
- package/dist/assets/{FilesView-tnqRwvfh.js → FilesView-DnL4MjaW.js} +1 -1
- package/dist/assets/{GrokMoveDialog-DcD2N9NJ.js → GrokMoveDialog-C6j6PaOl.js} +1 -1
- package/dist/assets/{InspectorPanel-neNG3E93.js → InspectorPanel-AS99t3t_.js} +1 -1
- package/dist/assets/{KeyboardShortcutsModal-CGzUNFhz.js → KeyboardShortcutsModal-B9MXqWn_.js} +1 -1
- package/dist/assets/{LiveDesktop-DJnRvtY5.js → LiveDesktop-CeMAfpqi.js} +1 -1
- package/dist/assets/{LocalVmWorkspace-B4yOJABf.js → LocalVmWorkspace-BjpJidzP.js} +1 -1
- package/dist/assets/{MacLocalControl-ClcDNzDl.js → MacLocalControl-10Me_JS2.js} +1 -1
- package/dist/assets/{MarkdownFilePreview-ufl-s03V.js → MarkdownFilePreview-BqtpdMVD.js} +1 -1
- package/dist/assets/{MenuMotion-Dj4rtEj4.js → MenuMotion-DEol1e9x.js} +1 -1
- package/dist/assets/{NewBotDialog-BniS1lPX.js → NewBotDialog-VLJL3Wg1.js} +1 -1
- package/dist/assets/{PhoneAppDialog-CG3KQVI4.js → PhoneAppDialog-DA5gvq4c.js} +1 -1
- package/dist/assets/{PlacesRail-bn7tEIBM.js → PlacesRail-CLjAh1E0.js} +1 -1
- package/dist/assets/{PluginsPanel-DHTTKAon.js → PluginsPanel-vWuf5IUu.js} +1 -1
- package/dist/assets/{ProIntroduction-uJD0s7Me.js → ProIntroduction-Di0HbUFO.js} +1 -1
- package/dist/assets/{RemoteAgentSettingsPanel-DCKwqq0d.js → RemoteAgentSettingsPanel-Cfw7teQ2.js} +1 -1
- package/dist/assets/{RoomPanel-aIa7Diz1.js → RoomPanel-Beu1uKue.js} +1 -1
- package/dist/assets/{RoutinesPage-CLHjhuBJ.js → RoutinesPage-B2nYtQla.js} +1 -1
- package/dist/assets/SettingsModal-CxvxkC4x.js +19 -0
- package/dist/assets/{ShareTeamDialog-BOzHCj2n.js → ShareTeamDialog-CIgmHhv0.js} +1 -1
- package/dist/assets/{SignedInSites-C-nx8of8.js → SignedInSites-DdJipkZg.js} +1 -1
- package/dist/assets/{TeamLibraryPanel-Bp1ZcEZQ.js → TeamLibraryPanel-BbDoilAy.js} +1 -1
- package/dist/assets/{TeamMapPage-BL5CHTBF.js → TeamMapPage-BdJoToiU.js} +1 -1
- package/dist/assets/{TriggersPage-BEHK5XH1.js → TriggersPage-tsPRVnW8.js} +1 -1
- package/dist/assets/{VisibilitySection-DxR_98SK.js → VisibilitySection-DtqlyqWE.js} +1 -1
- package/dist/assets/{WebhookTrigger-DaoCLzsd.js → WebhookTrigger-uKcCBfwA.js} +1 -1
- package/dist/assets/{WorksOnGrid-DrO1qcZh.js → WorksOnGrid-W7nCND-A.js} +1 -1
- package/dist/assets/{abnfDiagram-YUKMZFIV-BcUIfOEe.js → abnfDiagram-YUKMZFIV-1x7ZPsZh.js} +1 -1
- package/dist/assets/{activity-BNFKxy1b.js → activity-GpccG6_T.js} +1 -1
- package/dist/assets/{architectureDiagram-47P4ROYG-C7ht62Bt.js → architectureDiagram-47P4ROYG-DPgLYL_N.js} +1 -1
- package/dist/assets/{blockDiagram-E7TT5TSB-CaczmOHs.js → blockDiagram-E7TT5TSB-B8UWaM8D.js} +1 -1
- package/dist/assets/{c4Diagram-CRA5TL53-DSPaJBwh.js → c4Diagram-CRA5TL53-PhITusI3.js} +1 -1
- package/dist/assets/{calendar-days-DU-aFzFs.js → calendar-days-P76kOKJY.js} +1 -1
- package/dist/assets/channel-CJO5KL4z.js +1 -0
- package/dist/assets/{chunk-2Q5K7J3B-D4erYHrR.js → chunk-2Q5K7J3B-C-oGd3d2.js} +1 -1
- package/dist/assets/{chunk-5VM5RSS4-D8syTc7K.js → chunk-5VM5RSS4-CVMG7tfk.js} +1 -1
- package/dist/assets/{chunk-7TKQ45FW-qZ8vN88Y.js → chunk-7TKQ45FW-DIyFSChV.js} +1 -1
- package/dist/assets/{chunk-AW2ZBBNX-COZ0RY0p.js → chunk-AW2ZBBNX-C3UOIXSH.js} +1 -1
- package/dist/assets/{chunk-FVRAUYC3-B9WP6gNL.js → chunk-FVRAUYC3-DVAx09Rs.js} +2 -2
- package/dist/assets/{chunk-HTAEGDNF-DpLxKDYN.js → chunk-HTAEGDNF-BI4rDzDQ.js} +1 -1
- package/dist/assets/{chunk-JWPE2WC7-CyI6_v_4.js → chunk-JWPE2WC7-B6xY9PZq.js} +1 -1
- package/dist/assets/{chunk-KQW6MTUR-C3xLM0DV.js → chunk-KQW6MTUR-ws1ilD7-.js} +1 -1
- package/dist/assets/{chunk-XXDRQBXY-C7oc9LKJ.js → chunk-XXDRQBXY-BwfcVKlj.js} +1 -1
- package/dist/assets/{classDiagram-v2-K4WV4PDN-DtYcyxMZ.js → classDiagram-v2-K4WV4PDN-DPeRWn_e.js} +1 -1
- package/dist/assets/{coins-C8BnHs7A.js → coins-VtDzkYpc.js} +1 -1
- package/dist/assets/{core-CuBqcMgK.js → core-CV44ZFYc.js} +1 -1
- package/dist/assets/{cose-bilkent-JH36ORCC-BACClH_n.js → cose-bilkent-JH36ORCC-CR5hRFOZ.js} +1 -1
- package/dist/assets/{cynefin-EF2NZ3EQ-DZo-gx9_.js → cynefin-EF2NZ3EQ-BdW2wt4-.js} +1 -1
- package/dist/assets/{cynefinDiagram-3GCD6N5R-CB9Tufy-.js → cynefinDiagram-3GCD6N5R-EhtqWRNM.js} +1 -1
- package/dist/assets/{dagre-W4DXFKR2-QmMefB-F.js → dagre-W4DXFKR2-Di0n1jqp.js} +1 -1
- package/dist/assets/{diagram-2UJZ2QOL-BB9UdSXb.js → diagram-2UJZ2QOL-CgMGoKY7.js} +1 -1
- package/dist/assets/{diagram-OVF4WLC6-BT1xV_u3.js → diagram-OVF4WLC6-BXlgzlCn.js} +1 -1
- package/dist/assets/{diagram-PFPMY2P6-Bb8Gcrwm.js → diagram-PFPMY2P6-CdQkKIW8.js} +1 -1
- package/dist/assets/{diagram-UMYRVEAY-CuhVtw_K.js → diagram-UMYRVEAY-DZl5kJRn.js} +1 -1
- package/dist/assets/{diagram-YEKJPTXX-BKeM2V-v.js → diagram-YEKJPTXX-Bzz0W_ze.js} +1 -1
- package/dist/assets/{diagram-ZIFT7M5P-CWJdSX39.js → diagram-ZIFT7M5P-CMS1E0WQ.js} +1 -1
- package/dist/assets/{ebnfDiagram-VR2GEFS7-CQt0qwgC.js → ebnfDiagram-VR2GEFS7-DoPCvtki.js} +1 -1
- package/dist/assets/{elk-IJKZMXRS-DTpYboxu.js → elk-IJKZMXRS-Bj-Bb2qu.js} +1 -1
- package/dist/assets/{erDiagram-O2IAPWRE-CRmD7TiT.js → erDiagram-O2IAPWRE-CB5nst9m.js} +1 -1
- package/dist/assets/{file-up-DA-MGVqh.js → file-up-C-A7EgY2.js} +1 -1
- package/dist/assets/{flowDiagram-OXPTDLAJ-C3OIuz51.js → flowDiagram-OXPTDLAJ-CCgbFCEu.js} +1 -1
- package/dist/assets/{ganttDiagram-R7TSEDQI-DRztzQgb.js → ganttDiagram-R7TSEDQI-DQVyHiAx.js} +1 -1
- package/dist/assets/{gitGraphDiagram-XJZIOB7I-DljlrTI8.js → gitGraphDiagram-XJZIOB7I-jS2mWNam.js} +1 -1
- package/dist/assets/{import-name-D7OVVg4a.js → import-name-X30o5z1B.js} +1 -1
- package/dist/assets/{index-Bt5WwBKC.js → index-D8oAKMU6.js} +2 -2
- package/dist/assets/{index-C6I9mMp7.js → index-SxUH0lfM.js} +1 -1
- package/dist/assets/{infoDiagram-5W2HQ5XZ-sZgtYSBR.js → infoDiagram-5W2HQ5XZ-DzRRVnLP.js} +1 -1
- package/dist/assets/{ishikawaDiagram-K3B6WC7H-C3hf18HZ.js → ishikawaDiagram-K3B6WC7H-BHZdIugB.js} +1 -1
- package/dist/assets/{journeyDiagram-COXZFDF6-Cx7iVI1Y.js → journeyDiagram-COXZFDF6-DNwsxsaw.js} +1 -1
- package/dist/assets/{kanban-definition-P3RFRI5V-BCfPOAwE.js → kanban-definition-P3RFRI5V-DpBOTH95.js} +1 -1
- package/dist/assets/{mcp-servers-byTznZvJ.js → mcp-servers-DjbULZwc.js} +1 -1
- package/dist/assets/{mermaid.core-u5mM9R6c.js → mermaid.core-DuHmv3Xq.js} +4 -4
- package/dist/assets/{mindmap-definition-LZFPQGKD-Bl1ss-w7.js → mindmap-definition-LZFPQGKD-BBiNJgPA.js} +1 -1
- package/dist/assets/{minimize-CQhJEKJt.js → minimize-CRS6u26E.js} +1 -1
- package/dist/assets/{monitor-DUalxLhV.js → monitor-CyzqeASh.js} +1 -1
- package/dist/assets/{new-bot-B_nigkqj.js → new-bot-Bs8pJ7Bw.js} +1 -1
- package/dist/assets/{org-library-tjVQPsZw.js → org-library-CC1En5aB.js} +1 -1
- package/dist/assets/{package-format-TOf-oPLr.js → package-format-BCGzeYHa.js} +1 -1
- package/dist/assets/{pegDiagram-BGZESJAR-DYVS4bK_.js → pegDiagram-BGZESJAR-DqEbd745.js} +1 -1
- package/dist/assets/{pieDiagram-CAPJLFHJ-Dd2OI03J.js → pieDiagram-CAPJLFHJ-D9U2FmuX.js} +1 -1
- package/dist/assets/{quadrantDiagram-GDMTTRAM-DftvCum7.js → quadrantDiagram-GDMTTRAM-PKCaSgAj.js} +1 -1
- package/dist/assets/{rail-5xabqdtQ.js → rail-DKRV3i4L.js} +1 -1
- package/dist/assets/{railroadDiagram-SM67HX2B-CMUXYZoX.js → railroadDiagram-SM67HX2B-DqwQrNIl.js} +1 -1
- package/dist/assets/{remote-desktop-panel-CnvMPI4j.js → remote-desktop-panel-B3m0CdWN.js} +1 -1
- package/dist/assets/{requirementDiagram-X7JNWC4A-TUFFobBi.js → requirementDiagram-X7JNWC4A-DyFQPw-w.js} +1 -1
- package/dist/assets/{sankeyDiagram-UM26HJRW-BoWUtM1O.js → sankeyDiagram-UM26HJRW-D_-3g90K.js} +1 -1
- package/dist/assets/{sequenceDiagram-ZO4K6R2Y-BJGhu1J3.js → sequenceDiagram-ZO4K6R2Y-BxkfrM9A.js} +1 -1
- package/dist/assets/{sizeCapture-INFHLROL-BjWOwFei.js → sizeCapture-INFHLROL-VDgtfHsZ.js} +1 -1
- package/dist/assets/{stateDiagram-v2-TBUQTH76-BHnqACBE.js → stateDiagram-v2-TBUQTH76-ey-mFs--.js} +1 -1
- package/dist/assets/{styles-DnwnyZpR.js → styles-Dd_7YOJG.js} +3 -3
- package/dist/assets/{swimlanes-N4OXWK64-w7Jh9mLp.js → swimlanes-N4OXWK64-DYpwISFq.js} +1 -1
- package/dist/assets/swimlanesDiagram-K3J5GTZL-BNLJTe-b.js +8 -0
- package/dist/assets/{team-share-iEP9Zjr-.js → team-share-CVqY6tnj.js} +1 -1
- package/dist/assets/{timeline-definition-YOQAKGHF-D0trOSBD.js → timeline-definition-YOQAKGHF-D9iKG2OF.js} +1 -1
- package/dist/assets/{usecaseDiagram-VIAY4XPW-A_NiPbx_.js → usecaseDiagram-VIAY4XPW-Bfbw61-j.js} +1 -1
- package/dist/assets/{vennDiagram-BLWOH2XV-iEyMv06N.js → vennDiagram-BLWOH2XV-DYVrjpQ_.js} +1 -1
- package/dist/assets/{vi-C-E3a4Tv.js → vi-DrsTFzsG.js} +2 -2
- package/dist/assets/{wardleyDiagram-YMQ3BMBF-yIcnyDG1.js → wardleyDiagram-YMQ3BMBF-3Aod1B1D.js} +1 -1
- package/dist/assets/{xychartDiagram-TAQBALBS-BbKfuPA4.js → xychartDiagram-TAQBALBS-BgJsKil4.js} +1 -1
- package/dist/index.html +2 -2
- package/dist/rail.html +4 -4
- package/dist-server/index.js +695 -692
- package/dist-server/package.json +1 -1
- package/dist-server/server/limix-hub-download.js +8 -0
- package/dist-server/server/limix-skill-hub.js +3 -2
- package/dist-server/server/limix-transfer-version.js +36 -0
- package/dist-server/server/workspace-backup-http.js +2 -2
- package/dist-server/server/workspace-backup.js +6 -10
- package/dist-server/workspace-backup.worker.js +19 -18
- package/package.json +1 -1
- package/skills/agent-reach/references/capabilities.md +19 -26
- package/skills/agent-reach/references/maintenance.md +11 -11
- package/skills/agent-reach/references/sessions.md +32 -41
- package/skills/rea-video/SKILL.md +35 -96
- package/skills/rea-video/references/audio.md +21 -87
- package/skills/rea-video/references/materials.md +9 -28
- package/skills/rea-video/references/memory.md +5 -6
- package/skills/rea-video/references/output-template.md +17 -46
- package/skills/rea-video/references/remake.md +23 -35
- package/skills/rea-video/references/review.md +16 -36
- package/skills/rea-video/references/setup.md +21 -40
- package/skills/rea-video/references/taxonomy.md +39 -137
- package/skills/windows-computer-automation/SKILL.md +1 -1
- package/skills/windows-computer-automation/assets/HERIONIX-LEADER-PROMPT.md +12 -22
- package/dist/assets/SettingsModal-Dx_ELHpv.js +0 -19
- package/dist/assets/channel-BXNHTVIL.js +0 -1
- package/dist/assets/swimlanesDiagram-K3J5GTZL-zIHpuU63.js +0 -8
package/dist-server/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"type":"module","version":"0.3.
|
|
1
|
+
{"type":"module","version":"0.3.32"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/** A catalog may outlive a move between skills/ and quarantine/. The caller still verifies the catalog's SHA-256 before installing. */
|
|
2
|
+
export async function fetchHubFile(root, area, id, path, fetcher) {
|
|
3
|
+
const first = area === 'quarantine' ? 'quarantine' : 'skills';
|
|
4
|
+
const response = await fetcher(`${root}/${first}/${id}/${path}`);
|
|
5
|
+
if (response.status !== 404)
|
|
6
|
+
return response;
|
|
7
|
+
return fetcher(`${root}/${first === 'skills' ? 'quarantine' : 'skills'}/${id}/${path}`);
|
|
8
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { fetchHubFile } from "./limix-hub-download.js";
|
|
1
2
|
// Limix Skill Hub client: keeps a cached copy of the hub catalog, installs a skill only after every file matches the
|
|
2
3
|
// SHA-256 the catalog pins, and never installs scripts, binaries or MCP files unless the owner allows tools for that
|
|
3
4
|
// one skill. Installed skills wait in the store ("Kho Kĩ Năng (Skills)"), switched on but on no bot until one is added to it. Auto Sync (catalog refresh) is on by default,
|
|
@@ -84,7 +85,7 @@ const isToolFile = (path) => SCRIPT.test(path) || MCP_FILE.test(path);
|
|
|
84
85
|
const sha = (data) => createHash("sha256").update(data).digest("hex");
|
|
85
86
|
export function hubSkillBlocked(entry) {
|
|
86
87
|
if (entry.area === "quarantine" || entry.security_status === "quarantined")
|
|
87
|
-
return lxs("
|
|
88
|
+
return lxs("Bộ quét đánh dấu rủi ro và cách ly skill; cần xem các phát hiện trước khi dùng.", "The scanner flagged risks and quarantined this skill; review the findings before use.");
|
|
88
89
|
if (entry.approval_status === "quarantined" || entry.approval_status === "rejected")
|
|
89
90
|
return lxs("Skill bị từ chối.", "This skill was rejected.");
|
|
90
91
|
return null;
|
|
@@ -138,7 +139,7 @@ export async function installHubSkill(id, options = {}) {
|
|
|
138
139
|
return { error: lxs(`Danh mục thiếu mã kiểm tra cho ${path}`, `The catalog has no checksum for ${path}`) };
|
|
139
140
|
let response;
|
|
140
141
|
try {
|
|
141
|
-
response = await
|
|
142
|
+
response = await fetchHubFile(rawUrl("").replace(/\/$/, ""), entry.area, id, path, fetchText);
|
|
142
143
|
}
|
|
143
144
|
catch (cause) {
|
|
144
145
|
return { error: lxs(`Không tải được ${path}: `, `Couldn't download ${path}: `) + (cause instanceof Error ? cause.message : String(cause)) };
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
function parsed(value) {
|
|
2
|
+
const match = /^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/.exec(value);
|
|
3
|
+
if (!match)
|
|
4
|
+
throw new Error('Không xác định được phiên bản bản sao lưu hoặc ứng dụng. Hãy dùng bản Limix Bot chính thức.');
|
|
5
|
+
const core = match.slice(1, 4).map(Number);
|
|
6
|
+
const pre = match[4]?.split('.') ?? [];
|
|
7
|
+
if (core.some(n => !Number.isSafeInteger(n)) || pre.some(n => /^\d+$/.test(n) && (n.length > 1 && n.startsWith('0') || !Number.isSafeInteger(Number(n)))))
|
|
8
|
+
throw new Error('Phiên bản không hợp lệ.');
|
|
9
|
+
return { core, pre };
|
|
10
|
+
}
|
|
11
|
+
/** Offline transfer only accepts an app at least as new as the exporting app, including prerelease ordering. */
|
|
12
|
+
export function assertTransferVersion(exported, current) {
|
|
13
|
+
const source = parsed(exported), target = parsed(current);
|
|
14
|
+
let order = 0;
|
|
15
|
+
for (let i = 0; i < 3 && !order; i++)
|
|
16
|
+
order = Math.sign(source.core[i] - target.core[i]);
|
|
17
|
+
if (!order) {
|
|
18
|
+
if (!source.pre.length && target.pre.length)
|
|
19
|
+
order = 1;
|
|
20
|
+
else if (source.pre.length && !target.pre.length)
|
|
21
|
+
order = -1;
|
|
22
|
+
else
|
|
23
|
+
for (let i = 0; i < Math.max(source.pre.length, target.pre.length) && !order; i++) {
|
|
24
|
+
const a = source.pre[i], b = target.pre[i];
|
|
25
|
+
if (a === undefined)
|
|
26
|
+
order = -1;
|
|
27
|
+
else if (b === undefined)
|
|
28
|
+
order = 1;
|
|
29
|
+
else if (a !== b)
|
|
30
|
+
order = /^\d+$/.test(a) && /^\d+$/.test(b) ? Math.sign(Number(a) - Number(b))
|
|
31
|
+
: /^\d+$/.test(a) ? -1 : /^\d+$/.test(b) ? 1 : a < b ? -1 : 1;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
if (order > 0)
|
|
35
|
+
throw new Error('This backup was made by a newer Limix Bot version. Hãy cập nhật Limix Bot lên bản bằng hoặc mới hơn ' + exported + ' trước khi nhập dữ liệu.');
|
|
36
|
+
}
|
|
@@ -137,7 +137,7 @@ export function createWorkspaceBackupRoutes(options) {
|
|
|
137
137
|
return true;
|
|
138
138
|
}
|
|
139
139
|
if (method === "POST" && path === `${PREFIX}/export`) {
|
|
140
|
-
const body = z.object({ password: passwordSchema, clientState: z.record(z.string(), z.string()).default({}) }).parse(await options.readBody(req, MAX_CLIENT_STATE_BYTES + 8 * 1024));
|
|
140
|
+
const body = z.object({ password: passwordSchema, omitMedia: z.boolean().default(false), clientState: z.record(z.string(), z.string()).default({}) }).parse(await options.readBody(req, MAX_CLIENT_STATE_BYTES + 8 * 1024));
|
|
141
141
|
if (Buffer.byteLength(JSON.stringify(body.clientState)) > MAX_CLIENT_STATE_BYTES)
|
|
142
142
|
throw failure("Saved drafts exceed the 2 MB backup preference limit.", 413);
|
|
143
143
|
const clientState = Object.fromEntries(Object.entries(body.clientState).filter(([key]) => WORKSPACE_BACKUP_CLIENT_KEYS.includes(key)));
|
|
@@ -146,7 +146,7 @@ export function createWorkspaceBackupRoutes(options) {
|
|
|
146
146
|
replacePrevious(auth, ["download"]);
|
|
147
147
|
if (artifacts.size >= 4)
|
|
148
148
|
throw failure("There are already four backup files in progress. Restart or wait an hour before creating another.", 409);
|
|
149
|
-
return createWorkspaceBackup(options.dataDir, { password: body.password, clientState, appVersion: options.appVersion });
|
|
149
|
+
return createWorkspaceBackup(options.dataDir, { password: body.password, clientState, appVersion: options.appVersion, omitMedia: body.omitMedia });
|
|
150
150
|
}));
|
|
151
151
|
try {
|
|
152
152
|
check(req, auth);
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { assertTransferVersion } from "./limix-transfer-version.js";
|
|
1
2
|
// Encrypted filesystem snapshot: quiesce writers before create/commit; restore runs before config/store load.
|
|
2
3
|
import { createCipheriv, createDecipheriv, createHash, randomBytes, randomUUID, scrypt } from "node:crypto";
|
|
3
4
|
import { chmodSync, closeSync, constants, cpSync, createReadStream, createWriteStream, existsSync, fstatSync, fsyncSync, lstatSync, mkdirSync, openSync, readFileSync, readdirSync, readSync, realpathSync, renameSync, rmSync, writeFileSync, writeSync, } from "node:fs";
|
|
@@ -368,6 +369,8 @@ export async function createWorkspaceBackupSnapshot(dataDir, options, jobId) {
|
|
|
368
369
|
if (!prefix && excluded(name))
|
|
369
370
|
continue;
|
|
370
371
|
const path = prefix ? `${prefix}/${name}` : name;
|
|
372
|
+
if (options.omitMedia && (/^(?:attachments|uploads|media|screenshots)(?:\/|$)/i.test(path) || /\.(?:png|jpe?g|gif|webp|avif|bmp|ico|svg|heic|heif|tiff?|dng|mp4|m4v|mkv|mov|webm|avi|mpeg|mpg|3gp|m2ts|mts|flv|wmv|mp3|wav|ogg|flac|m4a|aac|opus|wma|aiff?)$/i.test(name)))
|
|
373
|
+
continue;
|
|
371
374
|
if (excludedWorkspaceAuthPath(path) || ephemeralWorkspaceTokenPath(path) || redownloadedOrgLibraryPath(path) || liveDataEnginePath(path))
|
|
372
375
|
continue;
|
|
373
376
|
if (privacy && omittedAsTeamPrivate(path, privacy))
|
|
@@ -485,7 +488,7 @@ export async function createWorkspaceBackupSnapshot(dataDir, options, jobId) {
|
|
|
485
488
|
directories: entries.filter((entry) => entry.type === "directory").length, bytes,
|
|
486
489
|
bots: countJsonArray(join(snapshot, "data", "bots.json")), groups: countJsonArray(join(snapshot, "data", "groups.json")),
|
|
487
490
|
...databaseCounts(join(snapshot, "data", "messages.db")),
|
|
488
|
-
exclusions: EXCLUSION_NOTES, warnings,
|
|
491
|
+
exclusions: options.omitMedia ? [...EXCLUSION_NOTES, "Media files and attachment/upload folders are omitted from this offline transfer."] : EXCLUSION_NOTES, warnings,
|
|
489
492
|
};
|
|
490
493
|
const manifest = {
|
|
491
494
|
summary, sourceDataDir: resolve(dataDir), clientState: options.clientState ?? {}, entries,
|
|
@@ -715,15 +718,8 @@ export async function stageWorkspaceBackup(dataDir, archivePath, options) {
|
|
|
715
718
|
const tar = await import("tar");
|
|
716
719
|
await tar.x({ file: plaintext, cwd: staged, strict: true, preservePaths: false, umask: 0o077, noChmod: true, brotli: false, zstd: false });
|
|
717
720
|
const manifest = validateStaged(staged, expected);
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
for (let i = 0; i < 3; i++) {
|
|
721
|
-
if (versions[0][i] > versions[1][i])
|
|
722
|
-
throw new Error("This backup was made by a newer Limix Bot version. Update the app before restoring it.");
|
|
723
|
-
if (versions[0][i] < versions[1][i])
|
|
724
|
-
break;
|
|
725
|
-
}
|
|
726
|
-
}
|
|
721
|
+
if (options.currentAppVersion !== undefined)
|
|
722
|
+
assertTransferVersion(manifest.summary.appVersion, options.currentAppVersion);
|
|
727
723
|
rmSync(plaintext);
|
|
728
724
|
writeJson(join(job.directory, "ready.json"), { id: job.id, summary: manifest.summary });
|
|
729
725
|
return { id: job.id, summary: manifest.summary };
|
|
@@ -1641,21 +1641,22 @@ ges', 'thread_state')").all().length!==2)throw new Error("The backup does not co
|
|
|
1641
1641
|
iles written outside this server cannot be frozen by the backup gate.","Conversation text and user files are not redacted and may contain secrets you pasted. Keep the encrypted backup private.",RESTORE_WARNING],bytes=0,skippedLinks=0,skippedDependencies=0,skippedWorkLinks=0,copiedLinks=0;try{let root=realpathSync(dataDir2);for(let[name,snapshotName]of Object.entries(SNAPSHOT_DATABASES)){let sourceDb=join13(root,name);if(!existsSync3(sourceDb))continue;if(lstatSync2(sourceDb).isSymbolicLink())throw new Error(
|
|
1642
1642
|
`The ${name==="messages.db"?"message":"runtime"} database must not be a symbolic link.`);let db=new DatabaseSync3(sourceDb,{readOnly:!0,timeout:5e3}),completionPulse=setInterval(()=>{},25);try{await backup(db,join13(snapshot,snapshotName))}finally{clearInterval(completionPulse),db.close()}let snapshotDb=new DatabaseSync3(join13(snapshot,snapshotName));try{snapshotDb.exec("PRAGMA journal_mode = DELETE")}finally{snapshotDb.close()}}let teamPrivate=teamPrivateThreads({starters:join13(root,"thread-s\
|
|
1643
1643
|
tarters.json"),groups:join13(root,"groups.json"),bots:join13(root,"bots.json")}),privacy=teamPrivate&&{...teamPrivate,attachments:teamPrivateAttachments(root,join13(snapshot,SNAPSHOT_DATABASES["messages.db"]),teamPrivate)};privacy&&(stripTeamPrivate({messages:join13(snapshot,SNAPSHOT_DATABASES["messages.db"]),runtime:join13(snapshot,SNAPSHOT_DATABASES["runtime.db"])},privacy),warnings.push(TEAM_PRIVATE_NOTE));let walk=(directory,prefix="",chain=[root])=>{for(let name of readdirSync3(directory).sort()){
|
|
1644
|
-
if(!prefix&&excluded(name))continue;let path2=prefix?`${prefix}/${name}`:name;if(excludedWorkspaceAuthPath(path2)||ephemeralWorkspaceTokenPath(path2)||redownloadedOrgLibraryPath(path2)||liveDataEnginePath(path2)||privacy&&omittedAsTeamPrivate(
|
|
1645
|
-
|
|
1646
|
-
try{target=realpathSync(source)}catch{throw new Error(`Cannot back up dangling symbolic link: ${path2}`)}let rel=relative2(root,target);if(rel===".."||rel.startsWith(`..${process.platform==="win32"?"\\":"/"}`)||isAbsolute3(rel))throw new Error(
|
|
1647
|
-
continue}let workspace=/^workspaces\/[^/]+\//.exec(path2)?.[0];if(!workspace||!portableRel.startsWith(workspace))throw new Error(`Cannot back up user-created symbolic link; replace it with regular files first: ${path2}`);if(chain.some(
|
|
1648
|
-
exceeds the 100,000-entry backup limit.");let caseTwin=foldedPaths.get(path2.toLowerCase());if(caseTwin)throw new Error(`Cannot back up names that differ only by letter case, which collide on Windows and macOS; rename one first: ${caseTwin}
|
|
1649
|
-
let copied;if(path2==="config.json"||path2==="webhooks.json"||privacy&&(path2==="bots.json"||path2==="routines.json")){let value=privateJson(source);if(path2==="config.json")writeJson(destination,portableWorkspaceConfig(value));else if(path2===
|
|
1650
|
-
|
|
1651
|
-
source,destination);if(bytes+=copied.size,bytes>MAX_WORKSPACE_BACKUP_BYTES)throw new Error("The workspace exceeds the 10 GB backup limit.");entries.push({path:path2,type:"file",...copied})}else throw new Error(`Cannot back
|
|
1652
|
-
|
|
1653
|
-
appVersion:options2.appVersion??"unknown",files:entries.filter(entry=>entry.type==="file").length,directories:entries.filter(entry=>entry.type==="directory").length,bytes,bots:countJsonArray(join13(snapshot,"data","
|
|
1654
|
-
|
|
1655
|
-
path,
|
|
1656
|
-
|
|
1657
|
-
"
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1644
|
+
if(!prefix&&excluded(name))continue;let path2=prefix?`${prefix}/${name}`:name;if(options2.omitMedia&&(/^(?:attachments|uploads|media|screenshots)(?:\/|$)/i.test(path2)||/\.(?:png|jpe?g|gif|webp|avif|bmp|ico|svg|heic|heif|tiff?|dng|mp4|m4v|mkv|mov|webm|avi|mpeg|mpg|3gp|m2ts|mts|flv|wmv|mp3|wav|ogg|flac|m4a|aac|opus|wma|aiff?)$/i.test(name))||excludedWorkspaceAuthPath(path2)||ephemeralWorkspaceTokenPath(path2)||redownloadedOrgLibraryPath(path2)||liveDataEnginePath(path2)||privacy&&omittedAsTeamPrivate(
|
|
1645
|
+
path2,privacy))continue;if(forbiddenArchivePath(path2))throw new Error("A workspace filename conflicts with a protected authentication or runtime path.");if(!validRelative(path2))throw new Error(`Cannot back up a name that cannot be restored on every supported platform, such as one with ":" or "\\", a trailing dot or space, or a Windows device name like CON or AUX; rename it first: ${path2}`);let source=join13(directory,name),stat=lstatSync2(source);if(name==="node_modules"&&(stat.isDirectory()||
|
|
1646
|
+
stat.isSymbolicLink())){skippedDependencies++;continue}if(stat.isSymbolicLink()&&path2.startsWith("task-workspaces/")){managedTaskSkillLink(source,path2,[root,resolve2(dataDir2)])?skippedLinks++:skippedWorkLinks++;continue}if(stat.isSymbolicLink()){let target;try{target=realpathSync(source)}catch{throw new Error(`Cannot back up dangling symbolic link: ${path2}`)}let rel=relative2(root,target);if(rel===".."||rel.startsWith(`..${process.platform==="win32"?"\\":"/"}`)||isAbsolute3(rel))throw new Error(
|
|
1647
|
+
`Cannot back up symbolic link outside the workspace: ${path2}`);let portableRel=rel.replaceAll("\\","/");if(/^workspaces\/[^/]+\/\.(?:claude|agents|grok)\/skills\/[^/]+$/.test(path2)&&portableRel.startsWith(`workspaces/${path2.split("/")[1]}/skills/`)){skippedLinks++;continue}let workspace=/^workspaces\/[^/]+\//.exec(path2)?.[0];if(!workspace||!portableRel.startsWith(workspace))throw new Error(`Cannot back up user-created symbolic link; replace it with regular files first: ${path2}`);if(chain.some(
|
|
1648
|
+
folder2=>folder2===target||folder2.startsWith(`${target}${sep}`)))throw userErrorThrown("serverError.backup.recursiveLink",{path:path2});source=target,stat=lstatSync2(source),copiedLinks++}if(entries.length>=MAX_WORKSPACE_BACKUP_FILES)throw new Error("The workspace exceeds the 100,000-entry backup limit.");let caseTwin=foldedPaths.get(path2.toLowerCase());if(caseTwin)throw new Error(`Cannot back up names that differ only by letter case, which collide on Windows and macOS; rename one first: ${caseTwin}\
|
|
1649
|
+
and ${path2}`);foldedPaths.set(path2.toLowerCase(),path2);let destination=join13(snapshot,"data",path2);if(stat.isDirectory())folder(destination),entries.push({path:path2,type:"directory",size:0,mode:448}),walk(source,path2,[...chain,source]);else if(stat.isFile()){let copied;if(path2==="config.json"||path2==="webhooks.json"||privacy&&(path2==="bots.json"||path2==="routines.json")){let value=privateJson(source);if(path2==="config.json")writeJson(destination,portableWorkspaceConfig(value));else if(path2===
|
|
1650
|
+
"bots.json")writeJson(destination,withoutTeamPrivate(value,privacy));else if(path2==="routines.json")writeJson(destination,routinesWithoutTeamPrivate(value,privateJson(join13(root,"bots.json")),privacy));else{if(!record3(value))throw new Error("Invalid webhook definitions in workspace backup.");if(Array.isArray(value.webhooks))for(let webhook of value.webhooks)record3(webhook)&&(delete webhook.secretHash,delete webhook.sealedSecret);if(Array.isArray(value.deleted))for(let entry of value.deleted)
|
|
1651
|
+
record3(entry)&&record3(entry.webhook)&&delete entry.webhook.sealedSecret;writeJson(destination,value)}copied={size:lstatSync2(destination).size,mode:384,sha256:hashFile(destination)}}else copied=copyRegular(SNAPSHOT_DATABASES[path2]?join13(snapshot,SNAPSHOT_DATABASES[path2]):source,destination);if(bytes+=copied.size,bytes>MAX_WORKSPACE_BACKUP_BYTES)throw new Error("The workspace exceeds the 10 GB backup limit.");entries.push({path:path2,type:"file",...copied})}else throw new Error(`Cannot back \
|
|
1652
|
+
up special or live runtime file: ${path2}`)}};walk(root),skippedLinks&&warnings.push(`${skippedLinks} managed skill discovery link(s) were omitted and are recreated by the app.`),skippedDependencies&&warnings.push(`${skippedDependencies} installed dependency folder(s) (node_modules) were omitted; reinstall them in the project after restoring.`),copiedLinks&&warnings.push(`${copiedLinks} symbolic link(s) inside a workspace were saved as copies of what they point to; restoring creates regular file\
|
|
1653
|
+
s and folders there.`),skippedWorkLinks&&warnings.push(`${skippedWorkLinks} symbolic link(s) in conversation work folders were omitted; what they point to is outside this backup.`);let summary={format:"openmaus.workspace-backup",version:1,id:job.id,createdAt:new Date().toISOString(),appVersion:options2.appVersion??"unknown",files:entries.filter(entry=>entry.type==="file").length,directories:entries.filter(entry=>entry.type==="directory").length,bytes,bots:countJsonArray(join13(snapshot,"data","b\
|
|
1654
|
+
ots.json")),groups:countJsonArray(join13(snapshot,"data","groups.json")),...databaseCounts(join13(snapshot,"data","messages.db")),exclusions:options2.omitMedia?[...EXCLUSION_NOTES,"Media files and attachment/upload folders are omitted from this offline transfer."]:EXCLUSION_NOTES,warnings},manifest={summary,sourceDataDir:resolve2(dataDir2),clientState:options2.clientState??{},entries};writeJson(join13(snapshot,"manifest.json"),manifest),validateManifest(privateJson(join13(snapshot,"manifest.json")));
|
|
1655
|
+
let path=join13(job.directory,"workspace.ombbackup"),iv=randomBytes(12),header=Buffer.concat([MAGIC,salt,iv]),cipher=createCipheriv("aes-256-gcm",key,iv);cipher.setAAD(header),writeFileSync2(path,header,{mode:384,flag:"wx"});let tar=await Promise.resolve().then(()=>(init_index_min(),index_min_exports));await pipeline(tar.c({cwd:snapshot,portable:!0,strict:!0},["manifest.json","data"]),cipher,createWriteStream(path,{flags:"a",mode:384}));let fd=openSync3(path,"a");try{writeSync2(fd,cipher.getAuthTag()),
|
|
1656
|
+
fsyncSync2(fd)}finally{closeSync3(fd)}return rmSync2(snapshot,{recursive:!0,force:!0}),{id:job.id,path,summary}}catch(error62){throw rmSync2(job.directory,{recursive:!0,force:!0}),error62}finally{key.fill(0)}}function validateManifest(value){if(!record3(value)||!record3(value.summary)||value.summary.format!=="openmaus.workspace-backup"||value.summary.version!==1||typeof value.summary.id!="string"||!ID.test(value.summary.id)||typeof value.summary.createdAt!="string"||!Number.isFinite(Date.parse(value.
|
|
1657
|
+
summary.createdAt))||typeof value.summary.appVersion!="string"||typeof value.sourceDataDir!="string"||!(posix.isAbsolute(value.sourceDataDir)||win32.isAbsolute(value.sourceDataDir))||value.sourceDataDir.length>4096||value.sourceDataDir.includes("\0")||value.sourceDataDir===posix.parse(value.sourceDataDir).root||value.sourceDataDir===win32.parse(value.sourceDataDir).root||value.sourceDataDir.replaceAll("\\","/").split("/").some(part=>part==="."||part==="..")||Object.keys(value).some(key=>!["summa\
|
|
1658
|
+
ry","sourceDataDir","clientState","entries"].includes(key))||Object.keys(value.summary).some(key=>!["format","version","id","createdAt","appVersion","files","directories","bytes","bots","groups","threads","messages","exclusions","warnings"].includes(key))||!record3(value.clientState)||!Object.values(value.clientState).every(item=>typeof item=="string")||!Array.isArray(value.entries)||value.entries.length>MAX_WORKSPACE_BACKUP_FILES)throw new Error("Invalid or unsupported workspace backup metadata\
|
|
1659
|
+
.");if(Object.keys(value.clientState).some(key=>!WORKSPACE_BACKUP_CLIENT_KEYS.includes(key))||Buffer.byteLength(JSON.stringify(value.clientState))>2*1024**2)throw new Error("Invalid or oversized workspace client preferences.");for(let key of["files","directories","bytes","bots","groups","threads","messages"])if(!Number.isSafeInteger(value.summary[key])||value.summary[key]<0)throw new Error("Invalid workspace backup summary.");for(let key of["exclusions","warnings"])if(!Array.isArray(value.summary[key])||
|
|
1660
|
+
!value.summary[key].every(item=>typeof item=="string"))throw new Error("Invalid workspace backup summary.");let names=new Map,bytes=0,files=0;for(let raw of value.entries){if(!record3(raw)||typeof raw.path!="string"||!validRelative(raw.path)||forbiddenArchivePath(raw.path)||Object.keys(raw).some(key=>!["path","type","size","mode","sha256"].includes(key))||!["file","directory"].includes(String(raw.type))||!Number.isSafeInteger(raw.size)||raw.size<0||![384,448].includes(raw.mode)||names.has(raw.path.
|
|
1661
|
+
toLowerCase()))throw new Error("Unsafe or duplicate workspace backup entry.");if(names.set(raw.path.toLowerCase(),String(raw.type)),raw.type==="file"){if(typeof raw.sha256!="string"||!/^[0-9a-f]{64}$/.test(raw.sha256))throw new Error("A backup file has no valid checksum.");bytes+=raw.size,files++}else if(raw.size!==0)throw new Error("A backup directory has an invalid size.")}if(bytes>MAX_WORKSPACE_BACKUP_BYTES||bytes!==value.summary.bytes||files!==value.summary.files||names.size-files!==value.summary.
|
|
1662
|
+
directories)throw new Error("Workspace backup contents do not match their summary or exceed the limit.");for(let path of names.keys()){let parts=path.split("/");for(let i=1;i<parts.length;i++)if(names.get(parts.slice(0,i).join("/"))!=="directory")throw new Error("A backup entry has an unsafe parent.")}return value}var{dataDir,options,jobId}=workerData;try{parentPort.postMessage({result:await createWorkspaceBackupSnapshot(dataDir,options,jobId)})}catch(error62){parentPort.postMessage({error:error62 instanceof Error?error62.message:"The workspace backup could not finish.",...userErrorFields(error62)})}
|
package/package.json
CHANGED
|
@@ -1,31 +1,24 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Capability scope
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
Read when the user asks what can be fetched or how complete a result is. Declared capabilities, not guaranteed results.
|
|
3
|
+
Use when the user asks what can be fetched or whether results are complete. These are bundled-release declarations, not proof that every site/account/action has passed a live check.
|
|
5
4
|
|
|
6
|
-
|
|
5
|
+
Distinguish public evidence available through native web tools, additional Reach actions declared by `agent-reach channels`, and specifically verified local operations. Installation, saved sessions and network reachability do not establish functional acceptance. Reuse the dedicated browser's saved session; request personal login only when the chosen path actually needs it.
|
|
7
6
|
|
|
8
|
-
|
|
9
|
-
- **Reach 补充**:当前发布版声明的动作,见 `agent-reach channels`。需要配置时先复用专用浏览器已保存的会话,所选路径实际要求登录时才本人登录。
|
|
10
|
-
- **本机已验证**:只列本机最近成功验收的具体动作;安装、保存会话和网络可达均不等于业务验收。
|
|
11
|
-
|
|
12
|
-
## 本版渠道
|
|
13
|
-
|
|
14
|
-
| 渠道 | 公开路径可尝试 | Reach 补充与边界 |
|
|
7
|
+
| Channel | Public evidence to try | Reach actions and boundaries |
|
|
15
8
|
|---|---|---|
|
|
16
|
-
| GitHub |
|
|
17
|
-
| YouTube |
|
|
18
|
-
|
|
|
19
|
-
| Reddit |
|
|
20
|
-
| X/Twitter |
|
|
21
|
-
|
|
|
22
|
-
| Instagram |
|
|
23
|
-
| Facebook |
|
|
24
|
-
| LinkedIn |
|
|
25
|
-
| BOSS |
|
|
26
|
-
| V2EX |
|
|
27
|
-
|
|
|
28
|
-
| Web | Agent
|
|
29
|
-
|
|
|
9
|
+
| GitHub | Public repositories, README, issues/PRs | Repository search/read, issue/PR content and returned comments; evaluate private permissions separately |
|
|
10
|
+
| YouTube | Search, title, description; native tools may retrieve comments/subtitle text | search/read/subtitle/transcribe; no unified comments action; track lists are not subtitle content; transcription needs its tools |
|
|
11
|
+
| Bilibili | Search/description; some public APIs return comments and parent IDs | search/read/hot/subtitle; no unified comments action; subtitle availability varies |
|
|
12
|
+
| Reddit | Search, posts, partial comments/public JSON parent IDs | Browser search/read/subreddit; login depends on path; no guarantee of complete reply trees; no posting comments |
|
|
13
|
+
| X/Twitter | Public single posts from search; some official embeds return full text | search/profile/tweets/thread; single-post access does not prove reply-feed access or completeness |
|
|
14
|
+
| Xiaohongshu | Public lists/index may return note IDs, authors and titles; never invent empty fields | search/read/comments; descriptions, top-level comments and loaded replies only; no completeness or image/video understanding claim |
|
|
15
|
+
| Instagram | Some indexes and shallow profile information; app-shell HTML is not post content | search users/profile/posts descriptions; no unified comments action or implied image/video comprehension |
|
|
16
|
+
| Facebook | Some indexes/HTML snippets, possibly truncated | search/profile; no unified full-detail/comments action; snippets are not full content |
|
|
17
|
+
| LinkedIn | Public job search and public JDs | jobs/read tries public pages first; use in-site OpenCLI directly only when requested; not every job is readable |
|
|
18
|
+
| BOSS | Indexed job summaries | search/read job lists/JDs; never infer salary numbers from encoded values; fallback depends on declared channel capabilities |
|
|
19
|
+
| V2EX | Public topics/content/replies | hot/node/read/user; report only returned scope, not hidden/missing replies |
|
|
20
|
+
| Xueqiu | Some public quotes/indexes | quote/search/hot_posts/hot_stocks; verify quote and community paths separately |
|
|
21
|
+
| Web | Agent's native search/read | Reach web search/read is anonymous fallback; snippets, app shells and verification pages are not complete content |
|
|
22
|
+
| Xiaoyuzhou | Episode page title/description | transcribe full episode; user-supplied Groq key via `agent-reach configure groq-key` |
|
|
30
23
|
|
|
31
|
-
|
|
24
|
+
Describe browser features as available to enable/try, never as complete-comment access after login. If the user skips login, deliver the public evidence already obtained.
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Maintenance
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Read for update failures, browser failures, channel errors or uninstall requests.
|
|
4
4
|
|
|
5
|
-
-
|
|
6
|
-
-
|
|
7
|
-
-
|
|
8
|
-
-
|
|
9
|
-
-
|
|
10
|
-
- `PLATFORM_BLOCKED
|
|
11
|
-
-
|
|
12
|
-
-
|
|
13
|
-
-
|
|
5
|
+
- `agent-reach update` updates Reach, added channel tools and skills. `agent-reach update --check` checks only. Update only with the user's authorization.
|
|
6
|
+
- `agent-reach doctor --text` reads local status without network. `agent-reach check <channel> --text` performs one live check; `--search` tests search/jobs only. Installation success is not functional acceptance.
|
|
7
|
+
- Browser: `agent-reach browser status`, `browser setup`, `browser stop`. After fixing connectivity, retry a failed CloakBrowser download using `browser setup --retry-cloak`.
|
|
8
|
+
- Distinguish dependency download, browser connection, login, page load and rate-limit failures. A network timeout does not prove an expired login.
|
|
9
|
+
- Record upstream errors and versions. If authorized, update once. Do not patch installed upstream tools or loop retries.
|
|
10
|
+
- Stop the attempt on `PLATFORM_BLOCKED`, `RATE_LIMITED`, `NEED_LOGIN` or `BUSY`. Resume after the necessary user/external action; do not repeatedly open windows.
|
|
11
|
+
- Keys/proxy: `agent-reach configure groq-key | openai-key | proxy | github-token`; the user provides values. Never log secrets.
|
|
12
|
+
- `Port <n> belongs to an unmanaged browser` means another program owns the dedicated port (default 9222). Do not close it. If authorized, set a free port with `agent-reach configure browser-port <port>`.
|
|
13
|
+
- Uninstall: show scope using `agent-reach uninstall --dry-run`, then execute `agent-reach uninstall` when authorized. Remove Reach-managed resources only; preserve other files and browsers.
|
|
@@ -1,41 +1,32 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
##
|
|
6
|
-
|
|
7
|
-
-
|
|
8
|
-
-
|
|
9
|
-
- `agent-reach
|
|
10
|
-
-
|
|
11
|
-
-
|
|
12
|
-
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
-
|
|
28
|
-
-
|
|
29
|
-
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
- Boss 直聘站内搜索走 OpenCLI,共用专用浏览器。职位详情若因上游误报要求登录,不要让用户反复登录。
|
|
34
|
-
- B 站只在读字幕时把已有登录交给 B 站官方命令行工具;普通搜索不准备浏览器。
|
|
35
|
-
- 雪球社区动作需要登录;会话几小时内过期,过期后重复登录步骤。
|
|
36
|
-
|
|
37
|
-
## 退出和删除
|
|
38
|
-
|
|
39
|
-
- `agent-reach logout <渠道>`:清除专用浏览器里该站的登录和渠道自己的状态,其他网站保留。
|
|
40
|
-
- `agent-reach remove <渠道>`:去掉渠道,同时清该站登录和存储,其他网站保留。清理失败时渠道记录保留并返回错误,用户可重试。
|
|
41
|
-
- 两者之后都不再自动复制该站登录。
|
|
1
|
+
# Sessions and dedicated browser
|
|
2
|
+
|
|
3
|
+
Read for login/logout, account changes or `NEED_LOGIN`.
|
|
4
|
+
|
|
5
|
+
## Browser lifecycle
|
|
6
|
+
- Browser channels share one dedicated profile, separate from the user's everyday Chrome. Never close or modify the everyday browser.
|
|
7
|
+
- Prefer CloakBrowser. If download/install fails, reuse installed Chrome and remember the fallback instead of downloading repeatedly. Retry explicitly with `agent-reach browser setup --retry-cloak` after connectivity is fixed.
|
|
8
|
+
- `agent-reach add <channel>` prepares Node, OpenCLI, browser and extension at versions tested by the bundled release. Chrome fallback on Windows may require one user-confirmed Add to Chrome action.
|
|
9
|
+
- Queries are headless by default. Only `agent-reach login <channel>` opens a visible login window. While open, queries use that window without closing it. Wait for the user to finish login. Later queries return to headless after it closes.
|
|
10
|
+
- Managed browser idle timeout is ten minutes. Calls and real page operations reset it; the next call reopens the browser. Sessions save periodically during login, so closing the window is unnecessary.
|
|
11
|
+
- Limits: two simultaneous queries per platform, four total; excess calls queue for up to two minutes then return `BUSY`. Space searches on the same platform by at least ten seconds. Login, logout and browser reinstall wait for running queries.
|
|
12
|
+
- Inspect/manage using `agent-reach browser status`, `browser setup`, `browser stop`.
|
|
13
|
+
|
|
14
|
+
## Reuse existing sessions
|
|
15
|
+
1. On first use, if Chrome is connected to the OpenCLI extension, copy only that site's cookies once into the dedicated browser. Do not copy the whole browser directory, other sites or passwords; do not modify the source.
|
|
16
|
+
2. Reuse the saved session thereafter without periodic recopying. Cookie presence does not establish valid login; verify the requested operation.
|
|
17
|
+
3. If the extension is disconnected, do not promise automatic reuse or conclude the user is logged out. Use Reach's saved session.
|
|
18
|
+
4. List multiple sources using `agent-reach browser profiles`; select explicitly with `agent-reach browser use <ID>` rather than switching randomly.
|
|
19
|
+
5. `agent-reach login <channel> --import-existing` explicitly recopies that site's session without a window. If no session or OpenCLI Bridge is available, return `NEED_SETUP` and preserve the saved session.
|
|
20
|
+
6. After manual login, logout or remove, do not import automatically again; a logged-out account must not silently reappear.
|
|
21
|
+
|
|
22
|
+
## Interactive login
|
|
23
|
+
Request login only when an actual operation returns `NEED_LOGIN` and the remaining task needs that path. A login button on a page is not evidence that login is required.
|
|
24
|
+
Run `agent-reach login <channel>` and let the user sign in personally. Never request passwords or output cookies. Follow any returned `next` instructions; native channels such as Xueqiu may need `agent-reach login <channel> --sync`. Repeat the original operation to verify success.
|
|
25
|
+
|
|
26
|
+
## Platform differences and removal
|
|
27
|
+
- BOSS site search uses OpenCLI and the shared dedicated browser. Do not repeat login for an upstream false-positive job-detail requirement.
|
|
28
|
+
- Bilibili passes saved login to its official CLI only for subtitles; ordinary search does not prepare a browser.
|
|
29
|
+
- Xueqiu community operations require login; sessions may expire within hours.
|
|
30
|
+
- `agent-reach logout <channel>` removes that site's login/channel state only.
|
|
31
|
+
- `agent-reach remove <channel>` removes that channel and its site state only. On cleanup failure retain the channel record and return an error for explicit retry.
|
|
32
|
+
- Neither logout nor remove may trigger automatic reimport of the site's login.
|