dsh-taskbridge 1.7.1 → 1.8.0

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.
Files changed (75) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/LICENSE +21 -21
  3. package/README.md +149 -290
  4. package/THIRD_PARTY_NOTICES.txt +23 -23
  5. package/antigravity/agents/dsh-taskbridge.md +31 -0
  6. package/antigravity/skills/dsh-taskbridge/SKILL.md +51 -0
  7. package/codex/dsh-taskbridge.toml +170 -631
  8. package/cordis.patch.yml +6 -6
  9. package/docs/INTRODUCTION.md +119 -295
  10. package/docs/INTRODUCTION.zh.md +134 -279
  11. package/docs/antigravity-integration.md +42 -0
  12. package/docs/auth-contract.md +138 -138
  13. package/docs/claude-code.md +6 -11
  14. package/docs/codex-integration.md +2 -2
  15. package/docs/contracts-stage-b.md +443 -443
  16. package/docs/plugin-market.md +30 -30
  17. package/docs/redaction-contract.md +170 -170
  18. package/docs/releases/1.7.0.zh.md +11 -11
  19. package/docs/releases/1.8.0.zh.md +16 -0
  20. package/docs/runtime-compatibility.md +1 -1
  21. package/docs/taskbridge-upgrade.md +28 -28
  22. package/docs/taskdispatch-upgrade.md +25 -25
  23. package/docs/workspace-contract.md +538 -538
  24. package/docs/workspace-grouping.md +126 -126
  25. package/icon.svg +1 -1
  26. package/lib/client.d.ts +733 -699
  27. package/lib/client.js +7 -7
  28. package/locale/en.json +1 -1
  29. package/locale/zh.json +1 -1
  30. package/package.json +149 -144
  31. package/src/antigravity/installer.js +1046 -0
  32. package/src/antigravity/seam.js +142 -0
  33. package/src/auth/fence.js +361 -361
  34. package/src/auth/grants.js +789 -789
  35. package/src/client/api.js +143 -0
  36. package/src/client/index.jsx +113 -3
  37. package/src/client/sidebar.jsx +862 -862
  38. package/src/client/styles.js +624 -624
  39. package/src/client/task-cleanup.js +304 -304
  40. package/src/client/task-records-table.jsx +217 -217
  41. package/src/client/task-view.js +307 -307
  42. package/src/client/workspace-groups.js +482 -482
  43. package/src/client/workspaces-browser.jsx +770 -770
  44. package/src/codex/agent-ownership.js +270 -270
  45. package/src/codex/installer.js +3 -0
  46. package/src/codex/toml.js +784 -784
  47. package/src/config/redact.js +245 -245
  48. package/src/config/store.js +186 -186
  49. package/src/credentials/seam.js +202 -202
  50. package/src/http/respond.js +6 -5
  51. package/src/http/user-plane.js +72 -0
  52. package/src/index.js +25 -0
  53. package/src/jobs/diagnostics.js +15 -15
  54. package/src/jobs/plan-store.js +1020 -1020
  55. package/src/jobs/review-note.js +63 -63
  56. package/src/jobs/task-descriptions.js +82 -82
  57. package/src/jobs/task-display.js +73 -73
  58. package/src/jobs/task-tree.js +786 -786
  59. package/src/jobs/title.js +134 -134
  60. package/src/mcp/continuation.js +317 -317
  61. package/src/mcp/server.js +4 -1
  62. package/src/model/connectivity.js +371 -371
  63. package/src/model/discovery.js +582 -582
  64. package/src/model/native-catalog.js +68 -68
  65. package/src/model/openai-adapter.js +671 -671
  66. package/src/model/probe.js +264 -264
  67. package/src/model/providers.js +756 -756
  68. package/src/model/routing.js +321 -321
  69. package/src/runtime/permissions.js +1619 -1619
  70. package/src/runtime/question-call.js +162 -162
  71. package/src/runtime/questions.js +909 -909
  72. package/src/runtime/worker-prompt.js +60 -55
  73. package/src/workspace/audit.js +775 -775
  74. package/src/workspace/preflight.js +424 -424
  75. package/src/workspace/worktrees.js +679 -679
@@ -1,68 +1,68 @@
1
- /**
2
- * Read the providers already registered with DSH, including their exact model
3
- * capabilities. This is the source for the delegate settings selector; it does
4
- * not read or copy endpoints, credentials, or adapter configuration.
5
- */
6
- export async function listNativeProviderCatalog(llm) {
7
- if (llm === null || typeof llm?.listProviders !== 'function'
8
- || typeof llm?.listModels !== 'function'
9
- || typeof llm?.resolveModelInfo !== 'function') {
10
- return { providers: [], error: 'native provider catalog is unavailable' };
11
- }
12
-
13
- let registered;
14
- try {
15
- registered = await llm.listProviders();
16
- } catch {
17
- return { providers: [], error: 'native provider catalog could not be read' };
18
- }
19
- if (!Array.isArray(registered)) return { providers: [], error: 'native provider catalog returned an invalid list' };
20
-
21
- const providers = [];
22
- for (const entry of registered.slice(0, 64)) {
23
- const id = typeof entry === 'string' ? entry : entry?.id;
24
- const name = typeof entry === 'object' && typeof entry?.name === 'string' ? entry.name : id;
25
- if (typeof id !== 'string' || id === '' || id.startsWith('dsh-delegate:')) continue;
26
- const provider = { id: id.slice(0, 160), name: String(name ?? id).slice(0, 160), models: [], error: null };
27
-
28
- let listed;
29
- try {
30
- listed = await llm.listModels(id);
31
- } catch {
32
- provider.error = 'model list could not be read';
33
- providers.push(provider);
34
- continue;
35
- }
36
- if (!Array.isArray(listed)) {
37
- provider.error = 'model list returned an invalid response';
38
- providers.push(provider);
39
- continue;
40
- }
41
-
42
- const models = listed.slice(0, 128).map((model) => (typeof model === 'string' ? { id: model } : model));
43
- const resolved = await Promise.all(models.map(async (model) => {
44
- const modelId = typeof model?.id === 'string' ? model.id : '';
45
- if (modelId === '' || modelId.length > 160) return null;
46
- try {
47
- const info = await llm.resolveModelInfo(id, modelId);
48
- if (info === null || typeof info !== 'object') return null;
49
- const efforts = Array.isArray(info.reasoning?.efforts)
50
- ? info.reasoning.efforts.map((effort) => (typeof effort === 'string' ? effort : effort?.id))
51
- .filter((effort) => typeof effort === 'string' && effort !== '').slice(0, 64)
52
- : [];
53
- return {
54
- id: modelId,
55
- name: String(info.name ?? model.name ?? modelId).slice(0, 160),
56
- efforts: [...new Set(efforts)],
57
- contextWindow: Number.isInteger(info.context?.contextWindow) ? info.context.contextWindow : null,
58
- };
59
- } catch {
60
- return null;
61
- }
62
- }));
63
- provider.models = resolved.filter(Boolean);
64
- if (provider.models.length === 0) provider.error = 'no exact models are available on this provider';
65
- providers.push(provider);
66
- }
67
- return { providers, error: null };
68
- }
1
+ /**
2
+ * Read the providers already registered with DSH, including their exact model
3
+ * capabilities. This is the source for the delegate settings selector; it does
4
+ * not read or copy endpoints, credentials, or adapter configuration.
5
+ */
6
+ export async function listNativeProviderCatalog(llm) {
7
+ if (llm === null || typeof llm?.listProviders !== 'function'
8
+ || typeof llm?.listModels !== 'function'
9
+ || typeof llm?.resolveModelInfo !== 'function') {
10
+ return { providers: [], error: 'native provider catalog is unavailable' };
11
+ }
12
+
13
+ let registered;
14
+ try {
15
+ registered = await llm.listProviders();
16
+ } catch {
17
+ return { providers: [], error: 'native provider catalog could not be read' };
18
+ }
19
+ if (!Array.isArray(registered)) return { providers: [], error: 'native provider catalog returned an invalid list' };
20
+
21
+ const providers = [];
22
+ for (const entry of registered.slice(0, 64)) {
23
+ const id = typeof entry === 'string' ? entry : entry?.id;
24
+ const name = typeof entry === 'object' && typeof entry?.name === 'string' ? entry.name : id;
25
+ if (typeof id !== 'string' || id === '' || id.startsWith('dsh-delegate:')) continue;
26
+ const provider = { id: id.slice(0, 160), name: String(name ?? id).slice(0, 160), models: [], error: null };
27
+
28
+ let listed;
29
+ try {
30
+ listed = await llm.listModels(id);
31
+ } catch {
32
+ provider.error = 'model list could not be read';
33
+ providers.push(provider);
34
+ continue;
35
+ }
36
+ if (!Array.isArray(listed)) {
37
+ provider.error = 'model list returned an invalid response';
38
+ providers.push(provider);
39
+ continue;
40
+ }
41
+
42
+ const models = listed.slice(0, 128).map((model) => (typeof model === 'string' ? { id: model } : model));
43
+ const resolved = await Promise.all(models.map(async (model) => {
44
+ const modelId = typeof model?.id === 'string' ? model.id : '';
45
+ if (modelId === '' || modelId.length > 160) return null;
46
+ try {
47
+ const info = await llm.resolveModelInfo(id, modelId);
48
+ if (info === null || typeof info !== 'object') return null;
49
+ const efforts = Array.isArray(info.reasoning?.efforts)
50
+ ? info.reasoning.efforts.map((effort) => (typeof effort === 'string' ? effort : effort?.id))
51
+ .filter((effort) => typeof effort === 'string' && effort !== '').slice(0, 64)
52
+ : [];
53
+ return {
54
+ id: modelId,
55
+ name: String(info.name ?? model.name ?? modelId).slice(0, 160),
56
+ efforts: [...new Set(efforts)],
57
+ contextWindow: Number.isInteger(info.context?.contextWindow) ? info.context.contextWindow : null,
58
+ };
59
+ } catch {
60
+ return null;
61
+ }
62
+ }));
63
+ provider.models = resolved.filter(Boolean);
64
+ if (provider.models.length === 0) provider.error = 'no exact models are available on this provider';
65
+ providers.push(provider);
66
+ }
67
+ return { providers, error: null };
68
+ }