@researai/deepscientist 1.5.0 → 1.5.1
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/AGENTS.md +26 -0
- package/README.md +19 -179
- package/assets/connectors/lingzhu/openclaw-bridge/README.md +124 -0
- package/assets/connectors/lingzhu/openclaw-bridge/index.ts +162 -0
- package/assets/connectors/lingzhu/openclaw-bridge/openclaw.plugin.json +145 -0
- package/assets/connectors/lingzhu/openclaw-bridge/package.json +35 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/cli.ts +180 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/config.ts +196 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/debug-log.ts +111 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/events.ts +4 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/http-handler.ts +1133 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/image-cache.ts +75 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/lingzhu-tools.ts +246 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/transform.ts +541 -0
- package/assets/connectors/lingzhu/openclaw-bridge/src/types.ts +131 -0
- package/assets/connectors/lingzhu/openclaw-bridge/tsconfig.json +14 -0
- package/assets/connectors/lingzhu/openclaw.lingzhu.config.template.json +39 -0
- package/bin/ds.js +233 -53
- package/docs/en/00_QUICK_START.md +134 -0
- package/docs/en/01_SETTINGS_REFERENCE.md +1104 -0
- package/docs/en/02_START_RESEARCH_GUIDE.md +404 -0
- package/docs/en/03_QQ_CONNECTOR_GUIDE.md +325 -0
- package/docs/en/04_LINGZHU_CONNECTOR_GUIDE.md +216 -0
- package/docs/en/05_TUI_GUIDE.md +141 -0
- package/docs/en/06_RUNTIME_AND_CANVAS.md +679 -0
- package/docs/en/07_MEMORY_AND_MCP.md +253 -0
- package/docs/en/08_FIGURE_STYLE_GUIDE.md +97 -0
- package/docs/en/09_DOCTOR.md +108 -0
- package/docs/en/90_ARCHITECTURE.md +245 -0
- package/docs/en/91_DEVELOPMENT.md +195 -0
- package/docs/en/99_ACKNOWLEDGEMENTS.md +29 -0
- package/docs/zh/00_QUICK_START.md +134 -0
- package/docs/zh/01_SETTINGS_REFERENCE.md +1137 -0
- package/docs/zh/02_START_RESEARCH_GUIDE.md +414 -0
- package/docs/zh/03_QQ_CONNECTOR_GUIDE.md +324 -0
- package/docs/zh/04_LINGZHU_CONNECTOR_GUIDE.md +230 -0
- package/docs/zh/05_TUI_GUIDE.md +128 -0
- package/docs/zh/06_RUNTIME_AND_CANVAS.md +271 -0
- package/docs/zh/07_MEMORY_AND_MCP.md +235 -0
- package/docs/zh/08_FIGURE_STYLE_GUIDE.md +97 -0
- package/docs/zh/09_DOCTOR.md +112 -0
- package/docs/zh/99_ACKNOWLEDGEMENTS.md +29 -0
- package/install.sh +32 -8
- package/package.json +4 -2
- package/pyproject.toml +1 -1
- package/src/deepscientist/artifact/guidance.py +9 -2
- package/src/deepscientist/artifact/service.py +482 -22
- package/src/deepscientist/bash_exec/monitor.py +27 -5
- package/src/deepscientist/bash_exec/runtime.py +639 -0
- package/src/deepscientist/bash_exec/service.py +99 -16
- package/src/deepscientist/bridges/base.py +3 -0
- package/src/deepscientist/bridges/connectors.py +292 -13
- package/src/deepscientist/channels/qq.py +19 -2
- package/src/deepscientist/channels/relay.py +1 -0
- package/src/deepscientist/cli.py +32 -25
- package/src/deepscientist/config/models.py +28 -2
- package/src/deepscientist/config/service.py +201 -6
- package/src/deepscientist/connector_runtime.py +2 -0
- package/src/deepscientist/daemon/api/handlers.py +50 -5
- package/src/deepscientist/daemon/api/router.py +1 -0
- package/src/deepscientist/daemon/app.py +442 -15
- package/src/deepscientist/doctor.py +444 -0
- package/src/deepscientist/home.py +1 -0
- package/src/deepscientist/latex_runtime.py +17 -4
- package/src/deepscientist/lingzhu_support.py +182 -0
- package/src/deepscientist/mcp/server.py +49 -2
- package/src/deepscientist/prompts/builder.py +181 -58
- package/src/deepscientist/quest/layout.py +1 -0
- package/src/deepscientist/quest/service.py +63 -2
- package/src/deepscientist/quest/stage_views.py +19 -1
- package/src/deepscientist/runtime_tools/__init__.py +16 -0
- package/src/deepscientist/runtime_tools/builtins.py +19 -0
- package/src/deepscientist/runtime_tools/models.py +29 -0
- package/src/deepscientist/runtime_tools/registry.py +40 -0
- package/src/deepscientist/runtime_tools/service.py +59 -0
- package/src/deepscientist/runtime_tools/tinytex.py +25 -0
- package/src/deepscientist/tinytex.py +276 -0
- package/src/prompts/connectors/lingzhu.md +12 -0
- package/src/prompts/connectors/qq.md +121 -0
- package/src/prompts/system.md +177 -33
- package/src/skills/analysis-campaign/SKILL.md +22 -6
- package/src/skills/baseline/SKILL.md +5 -4
- package/src/skills/decision/SKILL.md +4 -3
- package/src/skills/experiment/SKILL.md +5 -4
- package/src/skills/finalize/SKILL.md +5 -4
- package/src/skills/idea/SKILL.md +5 -4
- package/src/skills/intake-audit/SKILL.md +277 -0
- package/src/skills/intake-audit/references/state-audit-template.md +41 -0
- package/src/skills/rebuttal/SKILL.md +407 -0
- package/src/skills/rebuttal/references/action-plan-template.md +63 -0
- package/src/skills/rebuttal/references/evidence-update-template.md +30 -0
- package/src/skills/rebuttal/references/response-letter-template.md +113 -0
- package/src/skills/rebuttal/references/review-matrix-template.md +55 -0
- package/src/skills/review/SKILL.md +293 -0
- package/src/skills/review/references/experiment-todo-template.md +29 -0
- package/src/skills/review/references/review-report-template.md +83 -0
- package/src/skills/review/references/revision-log-template.md +40 -0
- package/src/skills/scout/SKILL.md +5 -4
- package/src/skills/write/SKILL.md +7 -3
- package/src/tui/dist/components/WelcomePanel.js +17 -43
- package/src/tui/dist/components/messages/BashExecOperationMessage.js +3 -2
- package/src/tui/package.json +1 -1
- package/src/ui/dist/assets/{AiManusChatView-7v-dHngU.js → AiManusChatView-w5lF2Ttt.js} +109 -575
- package/src/ui/dist/assets/{AnalysisPlugin-B_Xmz-KE.js → AnalysisPlugin-DJOED79I.js} +1 -1
- package/src/ui/dist/assets/{AutoFigurePlugin-Cko-0tm1.js → AutoFigurePlugin-DaG61Y0M.js} +63 -8
- package/src/ui/dist/assets/{CliPlugin-BsU0ht7q.js → CliPlugin-CV4LqUB_.js} +43 -609
- package/src/ui/dist/assets/{CodeEditorPlugin-DcMMP0Rt.js → CodeEditorPlugin-DylfAea4.js} +8 -8
- package/src/ui/dist/assets/{CodeViewerPlugin-BqoQ5QyY.js → CodeViewerPlugin-F7saY0LM.js} +5 -5
- package/src/ui/dist/assets/{DocViewerPlugin-D7eHNhU6.js → DocViewerPlugin-COP0c7jf.js} +3 -3
- package/src/ui/dist/assets/{GitDiffViewerPlugin-DLJN42T5.js → GitDiffViewerPlugin-CAS05pT9.js} +1 -1
- package/src/ui/dist/assets/{ImageViewerPlugin-gJMV7MOu.js → ImageViewerPlugin-Bco1CN_w.js} +5 -6
- package/src/ui/dist/assets/{LabCopilotPanel-B857sfxP.js → LabCopilotPanel-CvMlCD99.js} +12 -15
- package/src/ui/dist/assets/LabPlugin-BYankkE4.js +2676 -0
- package/src/ui/dist/assets/LabPlugin-D9jVIo0A.css +2698 -0
- package/src/ui/dist/assets/{LatexPlugin-DWKEo-Wj.js → LatexPlugin-LDSMR-t-.js} +16 -16
- package/src/ui/dist/assets/{MarkdownViewerPlugin-DBzoEmhv.js → MarkdownViewerPlugin-B7o80jgm.js} +4 -4
- package/src/ui/dist/assets/{MarketplacePlugin-DoHc-8vo.js → MarketplacePlugin-CM6ZOcpC.js} +3 -3
- package/src/ui/dist/assets/{NotebookEditor-CKjKH-yS.js → NotebookEditor-Dc61cXmK.js} +3 -3
- package/src/ui/dist/assets/{PdfLoader-zFoL0VPo.js → PdfLoader-DWowuQwx.js} +1 -1
- package/src/ui/dist/assets/{PdfMarkdownPlugin-DXPaL9Nt.js → PdfMarkdownPlugin-BsJM1q_a.js} +3 -3
- package/src/ui/dist/assets/{PdfViewerPlugin-DhK8qCFp.js → PdfViewerPlugin-DB2eEEFQ.js} +10 -10
- package/src/ui/dist/assets/{SearchPlugin-CdSi6krf.js → SearchPlugin-CraThSvt.js} +1 -1
- package/src/ui/dist/assets/{Stepper-V-WiDQJl.js → Stepper-CgocRTPq.js} +1 -1
- package/src/ui/dist/assets/{TextViewerPlugin-hIs1Efiu.js → TextViewerPlugin-B1JGhKtd.js} +4 -4
- package/src/ui/dist/assets/{VNCViewer-DG8b0q2X.js → VNCViewer-CclFC7FM.js} +9 -10
- package/src/ui/dist/assets/{bibtex-HDac6fVW.js → bibtex-D3IKsMl7.js} +1 -1
- package/src/ui/dist/assets/{code-BnBeNxBc.js → code-BP37Xx0p.js} +1 -1
- package/src/ui/dist/assets/{file-content-IRQ3jHb8.js → file-content-BAJSu-9r.js} +1 -1
- package/src/ui/dist/assets/{file-diff-panel-DZoQ9I6r.js → file-diff-panel-DUGeCTuy.js} +1 -1
- package/src/ui/dist/assets/{file-socket-BMCdLc-P.js → file-socket-CXc1Ojf7.js} +1 -1
- package/src/ui/dist/assets/{file-utils-CltILB3w.js → file-utils-2J21jt7M.js} +1 -1
- package/src/ui/dist/assets/{image-Boe6ffhu.js → image-CMMmgvcn.js} +1 -1
- package/src/ui/dist/assets/{index-BlplpvE1.js → index-BaVumsQT.js} +2 -2
- package/src/ui/dist/assets/{index-DZqJ-qAM.js → index-CWgMgpow.js} +60 -2154
- package/src/ui/dist/assets/{index-DO43pFZP.js → index-DmwmJmbW.js} +6372 -8434
- package/src/ui/dist/assets/{index-Bq2bvfkl.css → index-KGt-z-dD.css} +225 -2920
- package/src/ui/dist/assets/{index-2Zf65FZt.js → index-s7aHnNQ4.js} +1 -1
- package/src/ui/dist/assets/{message-square-mUHn_Ssb.js → message-square-CQRfX0Am.js} +1 -1
- package/src/ui/dist/assets/{monaco-fe0arNEU.js → monaco-B4TbdsrF.js} +1 -1
- package/src/ui/dist/assets/{popover-D_7i19qU.js → popover-B8Rokodk.js} +1 -1
- package/src/ui/dist/assets/{project-sync-DyVGrU7H.js → project-sync-D_i96KH4.js} +2 -8
- package/src/ui/dist/assets/{sigma-BzazRyxQ.js → sigma-D12PnzCN.js} +1 -1
- package/src/ui/dist/assets/{tooltip-DN_yjHFH.js → tooltip-B6YrI4aJ.js} +1 -1
- package/src/ui/dist/assets/trash-Bc8jGp0V.js +32 -0
- package/src/ui/dist/assets/{useCliAccess-DV2L2Qxy.js → useCliAccess-mXVCYSZ-.js} +12 -42
- package/src/ui/dist/assets/{useFileDiffOverlay-DyTj-p_V.js → useFileDiffOverlay-Bg6b9H9K.js} +1 -1
- package/src/ui/dist/assets/{wrap-text-ozYHtUwq.js → wrap-text-Drh5GEnL.js} +1 -1
- package/src/ui/dist/assets/{zoom-out-BN9MUyCQ.js → zoom-out-CJj9DZLn.js} +1 -1
- package/src/ui/dist/index.html +2 -2
- package/assets/fonts/Inter-Variable.ttf +0 -0
- package/assets/fonts/NotoSerifSC-Regular-C94HN_ZN.ttf +0 -0
- package/assets/fonts/NunitoSans-Variable.ttf +0 -0
- package/assets/fonts/Satoshi-Medium-ByP-Zb-9.woff2 +0 -0
- package/assets/fonts/SourceSans3-Variable.ttf +0 -0
- package/assets/fonts/ds-fonts.css +0 -83
- package/src/ui/dist/assets/Inter-Variable-VF2RPR_K.ttf +0 -0
- package/src/ui/dist/assets/LabPlugin-bL7rpic8.js +0 -43
- package/src/ui/dist/assets/NotoSerifSC-Regular-C94HN_ZN-C94HN_ZN.ttf +0 -0
- package/src/ui/dist/assets/NunitoSans-Variable-B_ZymHAd.ttf +0 -0
- package/src/ui/dist/assets/Satoshi-Medium-ByP-Zb-9-GkA34YXu.woff2 +0 -0
- package/src/ui/dist/assets/SourceSans3-Variable-CD-WOsSK.ttf +0 -0
- package/src/ui/dist/assets/info-CcsK_htA.js +0 -18
- package/src/ui/dist/assets/user-plus-BusDx-hF.js +0 -79
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as reactExports, j as jsxRuntimeExports,
|
|
1
|
+
import { r as reactExports, j as jsxRuntimeExports, aj as composeRefs, ak as useControllableState, al as Root2$1, am as useId, an as useComposedRefs, ao as composeEventHandlers, ap as Anchor, aq as createPopperScope, ar as Presence, as as Portal$1, at as hideOthers, au as ReactRemoveScroll, av as useFocusGuards, aw as FocusScope, ax as DismissableLayer, ay as Content, az as Arrow, b as cn } from './index-DmwmJmbW.js';
|
|
2
2
|
|
|
3
3
|
// packages/react/context/src/create-context.tsx
|
|
4
4
|
function createContextScope(scopeName, createContextScopeDeps = []) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { s as supportsSocketIo,
|
|
1
|
+
import { s as supportsSocketIo, q as resolveApiBaseUrl, o as lookup, p as useAuthStore } from './index-DmwmJmbW.js';
|
|
2
2
|
|
|
3
3
|
const SOCKET_CACHE = /* @__PURE__ */ new Map();
|
|
4
4
|
function createNoopNotebookSocket() {
|
|
@@ -22,9 +22,7 @@ function acquireSocket(options = {}) {
|
|
|
22
22
|
};
|
|
23
23
|
}
|
|
24
24
|
const endpoint = resolveApiBaseUrl();
|
|
25
|
-
const
|
|
26
|
-
const shareToken = authMode === "share" ? getShareSessionToken() : null;
|
|
27
|
-
const cacheKey = authMode === "share" ? `${endpoint}::share::${shareToken || ""}` : `${endpoint}::user`;
|
|
25
|
+
const cacheKey = `${endpoint}::user`;
|
|
28
26
|
let entry = SOCKET_CACHE.get(cacheKey);
|
|
29
27
|
if (!entry) {
|
|
30
28
|
const socket = lookup(endpoint, {
|
|
@@ -32,10 +30,6 @@ function acquireSocket(options = {}) {
|
|
|
32
30
|
autoConnect: false,
|
|
33
31
|
transports: ["websocket", "polling"],
|
|
34
32
|
auth: (cb) => {
|
|
35
|
-
if (authMode === "share") {
|
|
36
|
-
cb({ token: getShareSessionToken() });
|
|
37
|
-
return;
|
|
38
|
-
}
|
|
39
33
|
const token = useAuthStore.getState().accessToken || (typeof window !== "undefined" ? window.localStorage.getItem("ds_access_token") : null);
|
|
40
34
|
cb({ token: token || null });
|
|
41
35
|
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { z as createLucideIcon } from './index-DmwmJmbW.js';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @license lucide-react v0.511.0 - ISC
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the ISC license.
|
|
7
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
const __iconNode$1 = [
|
|
12
|
+
["path", { d: "M12 5v14", key: "s699le" }],
|
|
13
|
+
["path", { d: "m19 12-7 7-7-7", key: "1idqje" }]
|
|
14
|
+
];
|
|
15
|
+
const ArrowDown = createLucideIcon("arrow-down", __iconNode$1);
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* @license lucide-react v0.511.0 - ISC
|
|
19
|
+
*
|
|
20
|
+
* This source code is licensed under the ISC license.
|
|
21
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
const __iconNode = [
|
|
26
|
+
["path", { d: "M3 6h18", key: "d0wm0j" }],
|
|
27
|
+
["path", { d: "M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6", key: "4alrt4" }],
|
|
28
|
+
["path", { d: "M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2", key: "v07s0e" }]
|
|
29
|
+
];
|
|
30
|
+
const Trash = createLucideIcon("trash", __iconNode);
|
|
31
|
+
|
|
32
|
+
export { ArrowDown as A, Trash as T };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { s as supportsSocketIo,
|
|
1
|
+
import { s as supportsSocketIo, q as resolveApiBaseUrl, o as lookup, p as useAuthStore, G as ConnectionState, r as reactExports, Q as checkProjectAccess } from './index-DmwmJmbW.js';
|
|
2
2
|
|
|
3
3
|
const SOCKET_CACHE = /* @__PURE__ */ new Map();
|
|
4
4
|
const CLIENT_ID_KEY = "ds_cli_client_id";
|
|
@@ -49,9 +49,7 @@ function acquireCliSocket(options = {}) {
|
|
|
49
49
|
};
|
|
50
50
|
}
|
|
51
51
|
const endpoint = resolveApiBaseUrl();
|
|
52
|
-
const
|
|
53
|
-
const shareToken = authMode === "share" ? getShareSessionToken() : null;
|
|
54
|
-
const cacheKey = authMode === "share" ? `${endpoint}::share::${shareToken || ""}` : `${endpoint}::user`;
|
|
52
|
+
const cacheKey = `${endpoint}::user`;
|
|
55
53
|
let entry = SOCKET_CACHE.get(cacheKey);
|
|
56
54
|
if (!entry) {
|
|
57
55
|
const socket = lookup(`${endpoint}/cli`, {
|
|
@@ -61,10 +59,6 @@ function acquireCliSocket(options = {}) {
|
|
|
61
59
|
auth: (cb) => {
|
|
62
60
|
const client_id = getCliClientId();
|
|
63
61
|
const protocol_version = "cli.v1";
|
|
64
|
-
if (authMode === "share") {
|
|
65
|
-
cb({ token: getShareSessionToken(), client_id, protocol_version });
|
|
66
|
-
return;
|
|
67
|
-
}
|
|
68
62
|
const token = useAuthStore.getState().accessToken || (typeof window !== "undefined" ? window.localStorage.getItem("ds_access_token") : null);
|
|
69
63
|
cb({ token: token || null, client_id, protocol_version });
|
|
70
64
|
}
|
|
@@ -370,7 +364,7 @@ const normalizeGatewayError = (message) => {
|
|
|
370
364
|
return message;
|
|
371
365
|
};
|
|
372
366
|
function useCliSocket(options) {
|
|
373
|
-
const { projectId, serverId,
|
|
367
|
+
const { projectId, serverId, handlers } = options;
|
|
374
368
|
const clientIdRef = reactExports.useRef(getCliClientId());
|
|
375
369
|
const reconnectRef = reactExports.useRef(new ReconnectionManager());
|
|
376
370
|
const reconnectingRef = reactExports.useRef(false);
|
|
@@ -387,7 +381,7 @@ function useCliSocket(options) {
|
|
|
387
381
|
bufferedMessages: 0,
|
|
388
382
|
metrics: metricsRef.current.getMetrics()
|
|
389
383
|
}));
|
|
390
|
-
const { socket, release } = reactExports.useMemo(() => acquireCliSocket(
|
|
384
|
+
const { socket, release } = reactExports.useMemo(() => acquireCliSocket(), []);
|
|
391
385
|
const syncMetrics = reactExports.useCallback(() => {
|
|
392
386
|
setStatus((prev) => ({
|
|
393
387
|
...prev,
|
|
@@ -857,8 +851,8 @@ async function uuidV5(name, namespace = CLI_SESSION_NAMESPACE) {
|
|
|
857
851
|
}
|
|
858
852
|
return fallbackUuid(`${namespace}:${name}`);
|
|
859
853
|
}
|
|
860
|
-
async function
|
|
861
|
-
return uuidV5(`${projectId}:${serverId}:
|
|
854
|
+
async function buildDefaultSessionId(projectId, serverId) {
|
|
855
|
+
return uuidV5(`${projectId}:${serverId}:default`);
|
|
862
856
|
}
|
|
863
857
|
async function buildConversationSessionId(projectId, serverId, conversationId) {
|
|
864
858
|
return uuidV5(`${projectId}:${serverId}:${conversationId}`);
|
|
@@ -867,10 +861,6 @@ async function buildChatSessionId(projectId, serverId, chatSessionId) {
|
|
|
867
861
|
return uuidV5(`${projectId}:${serverId}:${chatSessionId}`);
|
|
868
862
|
}
|
|
869
863
|
|
|
870
|
-
const PERMISSION_ORDER = ["none", "view", "edit", "admin", "owner"];
|
|
871
|
-
function maxPermission(a, b) {
|
|
872
|
-
return PERMISSION_ORDER[Math.max(PERMISSION_ORDER.indexOf(a), PERMISSION_ORDER.indexOf(b))];
|
|
873
|
-
}
|
|
874
864
|
function mapProjectRoleToPermission(role) {
|
|
875
865
|
if (!role) return "none";
|
|
876
866
|
if (role === "owner") return "owner";
|
|
@@ -915,22 +905,17 @@ function resolveCliCapabilities(level, granularity) {
|
|
|
915
905
|
|
|
916
906
|
function useCliAccess(options) {
|
|
917
907
|
const { projectId, serverId, readOnly } = options;
|
|
918
|
-
const userId = useAuthStore((state) => state.user?.id);
|
|
919
908
|
const [permission, setPermission] = reactExports.useState("none");
|
|
920
909
|
const [granularity, setGranularity] = reactExports.useState(null);
|
|
921
910
|
const [isLoading, setIsLoading] = reactExports.useState(false);
|
|
922
911
|
const [error, setError] = reactExports.useState(null);
|
|
923
|
-
const isShareView = reactExports.useMemo(
|
|
924
|
-
() => Boolean(projectId && isShareViewForProject(projectId)),
|
|
925
|
-
[projectId]
|
|
926
|
-
);
|
|
927
912
|
reactExports.useEffect(() => {
|
|
928
913
|
if (!projectId || !serverId) {
|
|
929
914
|
setPermission("none");
|
|
930
915
|
setGranularity(null);
|
|
931
916
|
return;
|
|
932
917
|
}
|
|
933
|
-
if (readOnly
|
|
918
|
+
if (readOnly) {
|
|
934
919
|
setPermission("view");
|
|
935
920
|
setGranularity(null);
|
|
936
921
|
return;
|
|
@@ -943,22 +928,8 @@ function useCliAccess(options) {
|
|
|
943
928
|
const access = await checkProjectAccess(projectId);
|
|
944
929
|
if (cancelled) return;
|
|
945
930
|
const rolePermission = mapProjectRoleToPermission(access?.role);
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
if (userId) {
|
|
949
|
-
try {
|
|
950
|
-
const shares = await listCliShares(projectId, serverId);
|
|
951
|
-
const match = shares.users.find((entry) => entry.user_id === userId);
|
|
952
|
-
if (match) {
|
|
953
|
-
sharePermission = match.permission;
|
|
954
|
-
shareGranularity = match.edit_granularity ?? null;
|
|
955
|
-
}
|
|
956
|
-
} catch {
|
|
957
|
-
}
|
|
958
|
-
}
|
|
959
|
-
const effectivePermission = maxPermission(rolePermission, sharePermission);
|
|
960
|
-
setPermission(effectivePermission);
|
|
961
|
-
setGranularity(effectivePermission === "edit" ? shareGranularity : null);
|
|
931
|
+
setPermission(rolePermission);
|
|
932
|
+
setGranularity(null);
|
|
962
933
|
} catch (err) {
|
|
963
934
|
if (cancelled) return;
|
|
964
935
|
setPermission("none");
|
|
@@ -972,16 +943,15 @@ function useCliAccess(options) {
|
|
|
972
943
|
return () => {
|
|
973
944
|
cancelled = true;
|
|
974
945
|
};
|
|
975
|
-
}, [projectId,
|
|
946
|
+
}, [projectId, readOnly, serverId]);
|
|
976
947
|
const capabilities = reactExports.useMemo(() => resolveCliCapabilities(permission, granularity), [permission, granularity]);
|
|
977
948
|
return {
|
|
978
949
|
permission,
|
|
979
950
|
granularity,
|
|
980
951
|
capabilities,
|
|
981
952
|
isLoading,
|
|
982
|
-
error
|
|
983
|
-
isShareView
|
|
953
|
+
error
|
|
984
954
|
};
|
|
985
955
|
}
|
|
986
956
|
|
|
987
|
-
export { useCliSocket as a, buildChatSessionId as b, acquireCliSocket as c, unwrapPayload as d,
|
|
957
|
+
export { useCliSocket as a, buildChatSessionId as b, acquireCliSocket as c, unwrapPayload as d, buildDefaultSessionId as e, buildConversationSessionId as f, getCliClientId as g, nextSeq as n, useCliAccess as u, wrapEnvelope as w };
|
package/src/ui/dist/index.html
CHANGED
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
content="DeepScientist local workspace with ACP-compatible Copilot, quest memory, documents, and git graph."
|
|
10
10
|
/>
|
|
11
11
|
<link rel="stylesheet" href="/ui/assets/fonts/ds-fonts.css" />
|
|
12
|
-
<script type="module" crossorigin src="/ui/assets/index-
|
|
13
|
-
<link rel="stylesheet" crossorigin href="/ui/assets/index-
|
|
12
|
+
<script type="module" crossorigin src="/ui/assets/index-DmwmJmbW.js"></script>
|
|
13
|
+
<link rel="stylesheet" crossorigin href="/ui/assets/index-KGt-z-dD.css">
|
|
14
14
|
</head>
|
|
15
15
|
<body>
|
|
16
16
|
<noscript>DeepScientist Copilot requires JavaScript.</noscript>
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
@font-face {
|
|
2
|
-
font-family: 'DS-Project';
|
|
3
|
-
src: url('/assets/fonts/Satoshi-Medium-ByP-Zb-9.woff2') format('woff2');
|
|
4
|
-
font-weight: 500;
|
|
5
|
-
font-style: normal;
|
|
6
|
-
font-display: swap;
|
|
7
|
-
unicode-range: U+0000-00FF, U+0100-024F, U+1E00-1EFF, U+2000-206F, U+20A0-20CF;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
@font-face {
|
|
11
|
-
font-family: 'DS-Satoshi';
|
|
12
|
-
src: url('/assets/fonts/Satoshi-Medium-ByP-Zb-9.woff2') format('woff2');
|
|
13
|
-
font-weight: 500;
|
|
14
|
-
font-style: normal;
|
|
15
|
-
font-display: swap;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
@font-face {
|
|
19
|
-
font-family: 'DS-Project';
|
|
20
|
-
src: url('/assets/fonts/NotoSerifSC-Regular-C94HN_ZN.ttf') format('truetype');
|
|
21
|
-
font-weight: 400;
|
|
22
|
-
font-style: normal;
|
|
23
|
-
font-display: swap;
|
|
24
|
-
unicode-range: U+3000-303F, U+3400-4DBF, U+4E00-9FFF, U+F900-FAFF, U+FF00-FFEF;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
@font-face {
|
|
28
|
-
font-family: 'DS-Inter';
|
|
29
|
-
src: url('/assets/fonts/Inter-Variable.ttf') format('truetype');
|
|
30
|
-
font-weight: 100 900;
|
|
31
|
-
font-style: normal;
|
|
32
|
-
font-display: swap;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
@font-face {
|
|
36
|
-
font-family: 'DS-SourceSans3';
|
|
37
|
-
src: url('/assets/fonts/SourceSans3-Variable.ttf') format('truetype');
|
|
38
|
-
font-weight: 200 900;
|
|
39
|
-
font-style: normal;
|
|
40
|
-
font-display: swap;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
@font-face {
|
|
44
|
-
font-family: 'DS-NunitoSans';
|
|
45
|
-
src: url('/assets/fonts/NunitoSans-Variable.ttf') format('truetype');
|
|
46
|
-
font-weight: 200 900;
|
|
47
|
-
font-style: normal;
|
|
48
|
-
font-display: swap;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
:root {
|
|
52
|
-
--font-sans: 'DS-SourceSans3', 'DS-Inter', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
53
|
-
--font-reading: 'DS-Inter', 'DS-SourceSans3', 'Inter', 'Noto Sans', sans-serif;
|
|
54
|
-
--font-title: 'DS-Project', 'DS-Satoshi', 'DS-Inter', 'Inter', serif;
|
|
55
|
-
--font-soft: 'DS-NunitoSans', 'DS-SourceSans3', 'DS-Inter', sans-serif;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
.font-project {
|
|
59
|
-
--font-sans: 'DS-SourceSans3', 'DS-Inter', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
60
|
-
--font-reading: 'DS-Inter', 'DS-SourceSans3', 'Inter', 'Noto Sans', sans-serif;
|
|
61
|
-
--font-title: 'DS-Project', 'DS-Satoshi', 'DS-Inter', 'Inter', serif;
|
|
62
|
-
--font-soft: 'DS-NunitoSans', 'DS-SourceSans3', 'DS-Inter', sans-serif;
|
|
63
|
-
--ds-font-family: var(--font-sans);
|
|
64
|
-
font-family: var(--font-sans);
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.font-project .font-sans,
|
|
68
|
-
.font-project .font-default,
|
|
69
|
-
.font-project .markdown-body {
|
|
70
|
-
font-family: var(--font-reading);
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
.font-project .font-title,
|
|
74
|
-
.font-project .tracking-tight,
|
|
75
|
-
.font-project h1,
|
|
76
|
-
.font-project h2,
|
|
77
|
-
.font-project h3 {
|
|
78
|
-
font-family: var(--font-title);
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
.font-project .font-soft {
|
|
82
|
-
font-family: var(--font-soft);
|
|
83
|
-
}
|
|
Binary file
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { u as useI18n, A as useMaxEntitlement, r as reactExports, j as jsxRuntimeExports, D as LabSurface } from './index-DO43pFZP.js';
|
|
2
|
-
|
|
3
|
-
const LAB_FOCUS_EVENT = "ds:lab:focus";
|
|
4
|
-
function LabPlugin({ context, setTitle }) {
|
|
5
|
-
const { t } = useI18n("lab");
|
|
6
|
-
const maxEntitlement = useMaxEntitlement("lab.use");
|
|
7
|
-
const projectId = typeof context.customData?.projectId === "string" ? context.customData.projectId : null;
|
|
8
|
-
const readOnly = Boolean(context.customData?.readOnly);
|
|
9
|
-
const focusType = context.customData?.focusType === "agent" || context.customData?.focusType === "quest" || context.customData?.focusType === "quest-branch" || context.customData?.focusType === "quest-event" || context.customData?.focusType === "overview" ? context.customData.focusType : null;
|
|
10
|
-
const focusId = typeof context.customData?.focusId === "string" ? context.customData.focusId : null;
|
|
11
|
-
const focusBranch = typeof context.customData?.branch === "string" ? context.customData.branch : null;
|
|
12
|
-
const focusEventId = typeof context.customData?.eventId === "string" ? context.customData.eventId : null;
|
|
13
|
-
reactExports.useEffect(() => {
|
|
14
|
-
setTitle(t("plugin_home_title", void 0, "Home"));
|
|
15
|
-
}, [setTitle, t]);
|
|
16
|
-
reactExports.useEffect(() => {
|
|
17
|
-
if (!projectId || !focusType) return;
|
|
18
|
-
if (!focusId && focusType !== "overview") return;
|
|
19
|
-
window.dispatchEvent(
|
|
20
|
-
new CustomEvent(LAB_FOCUS_EVENT, {
|
|
21
|
-
detail: {
|
|
22
|
-
projectId,
|
|
23
|
-
focusType,
|
|
24
|
-
focusId,
|
|
25
|
-
branch: focusBranch,
|
|
26
|
-
eventId: focusEventId
|
|
27
|
-
}
|
|
28
|
-
})
|
|
29
|
-
);
|
|
30
|
-
}, [focusBranch, focusEventId, focusId, focusType, projectId]);
|
|
31
|
-
if (!projectId) {
|
|
32
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex h-full items-center justify-center rounded-2xl border border-[var(--soft-border)] bg-[var(--soft-bg-surface)]", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-sm text-[var(--soft-text-secondary)]", children: t("plugin_project_not_found", void 0, "Project not found.") }) });
|
|
33
|
-
}
|
|
34
|
-
if (!maxEntitlement.isEntitlementLoading && !maxEntitlement.isMaxEntitled) {
|
|
35
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex h-full items-center justify-center rounded-2xl border border-[var(--soft-border)] bg-[var(--soft-bg-surface)]", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "px-6 text-center", children: [
|
|
36
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-sm font-medium text-[var(--soft-text-primary)]", children: t("plugin_plan_access_required", void 0, "Plan access required") }),
|
|
37
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-1 text-xs text-[var(--soft-text-secondary)]", children: t("plugin_max_only_desc", void 0, "Lab is currently available for Max users only.") })
|
|
38
|
-
] }) });
|
|
39
|
-
}
|
|
40
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(LabSurface, { projectId, readOnly });
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export { LabPlugin as default };
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { o as createLucideIcon } from './index-DO43pFZP.js';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* @license lucide-react v0.511.0 - ISC
|
|
5
|
-
*
|
|
6
|
-
* This source code is licensed under the ISC license.
|
|
7
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
const __iconNode = [
|
|
12
|
-
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
13
|
-
["path", { d: "M12 16v-4", key: "1dtifu" }],
|
|
14
|
-
["path", { d: "M12 8h.01", key: "e9boi3" }]
|
|
15
|
-
];
|
|
16
|
-
const Info = createLucideIcon("info", __iconNode);
|
|
17
|
-
|
|
18
|
-
export { Info as I };
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
import { o as createLucideIcon } from './index-DO43pFZP.js';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* @license lucide-react v0.511.0 - ISC
|
|
5
|
-
*
|
|
6
|
-
* This source code is licensed under the ISC license.
|
|
7
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
const __iconNode$4 = [
|
|
12
|
-
["path", { d: "M12 5v14", key: "s699le" }],
|
|
13
|
-
["path", { d: "m19 12-7 7-7-7", key: "1idqje" }]
|
|
14
|
-
];
|
|
15
|
-
const ArrowDown = createLucideIcon("arrow-down", __iconNode$4);
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* @license lucide-react v0.511.0 - ISC
|
|
19
|
-
*
|
|
20
|
-
* This source code is licensed under the ISC license.
|
|
21
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
22
|
-
*/
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
const __iconNode$3 = [
|
|
26
|
-
["circle", { cx: "12", cy: "12", r: "1", key: "41hilf" }],
|
|
27
|
-
["circle", { cx: "19", cy: "12", r: "1", key: "1wjl8i" }],
|
|
28
|
-
["circle", { cx: "5", cy: "12", r: "1", key: "1pcz8c" }]
|
|
29
|
-
];
|
|
30
|
-
const Ellipsis = createLucideIcon("ellipsis", __iconNode$3);
|
|
31
|
-
|
|
32
|
-
/**
|
|
33
|
-
* @license lucide-react v0.511.0 - ISC
|
|
34
|
-
*
|
|
35
|
-
* This source code is licensed under the ISC license.
|
|
36
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
37
|
-
*/
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
const __iconNode$2 = [
|
|
41
|
-
["path", { d: "M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8", key: "14sxne" }],
|
|
42
|
-
["path", { d: "M3 3v5h5", key: "1xhq8a" }],
|
|
43
|
-
["path", { d: "M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16", key: "1hlbsb" }],
|
|
44
|
-
["path", { d: "M16 16h5v5", key: "ccwih5" }]
|
|
45
|
-
];
|
|
46
|
-
const RefreshCcw = createLucideIcon("refresh-ccw", __iconNode$2);
|
|
47
|
-
|
|
48
|
-
/**
|
|
49
|
-
* @license lucide-react v0.511.0 - ISC
|
|
50
|
-
*
|
|
51
|
-
* This source code is licensed under the ISC license.
|
|
52
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
53
|
-
*/
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
const __iconNode$1 = [
|
|
57
|
-
["path", { d: "M3 6h18", key: "d0wm0j" }],
|
|
58
|
-
["path", { d: "M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6", key: "4alrt4" }],
|
|
59
|
-
["path", { d: "M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2", key: "v07s0e" }]
|
|
60
|
-
];
|
|
61
|
-
const Trash = createLucideIcon("trash", __iconNode$1);
|
|
62
|
-
|
|
63
|
-
/**
|
|
64
|
-
* @license lucide-react v0.511.0 - ISC
|
|
65
|
-
*
|
|
66
|
-
* This source code is licensed under the ISC license.
|
|
67
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
68
|
-
*/
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
const __iconNode = [
|
|
72
|
-
["path", { d: "M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2", key: "1yyitq" }],
|
|
73
|
-
["circle", { cx: "9", cy: "7", r: "4", key: "nufk8" }],
|
|
74
|
-
["line", { x1: "19", x2: "19", y1: "8", y2: "14", key: "1bvyxn" }],
|
|
75
|
-
["line", { x1: "22", x2: "16", y1: "11", y2: "11", key: "1shjgl" }]
|
|
76
|
-
];
|
|
77
|
-
const UserPlus = createLucideIcon("user-plus", __iconNode);
|
|
78
|
-
|
|
79
|
-
export { ArrowDown as A, Ellipsis as E, RefreshCcw as R, Trash as T, UserPlus as U };
|