@deepseek-ai/dsh-api-workspace-files 0.1.6-alpha.1 → 0.1.7-alpha.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/README.i18n.yaml +2 -2
- package/README.md +27 -24
- package/README.zh.md +27 -24
- package/lib/client.js +41 -35
- package/lib/index.js +135 -132
- package/lib/typert.host.js +127 -173
- package/lib/typert.remote-client.d.ts +10 -9
- package/lib/typert.remote-client.js +116 -152
- package/lib/types/changes.d.ts +8 -11
- package/lib/types/changes.js +106 -46
- package/lib/types/client/change-feed.d.ts +14 -13
- package/lib/types/client/change-feed.js +34 -27
- package/lib/types/client/provider.d.ts +4 -4
- package/lib/types/client/provider.js +13 -6
- package/lib/types/client/types.d.ts +5 -3
- package/lib/types/index.d.ts +13 -30
- package/lib/types/index.js +38 -60
- package/lib/types/types.d.ts +24 -13
- package/package.json +16 -14
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
/* Generated by @deepseek-ai/dsh-typert-generator from the Host FaceModel — do not edit. */
|
|
2
2
|
import { z } from 'zod'
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
const
|
|
4
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_parameter_0$schema$value
|
|
5
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_parameter_0$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
|
|
6
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_parameter_1$schema$value
|
|
7
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_parameter_1$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_parameter_1$schema$value ??= z.string())
|
|
8
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_result$schema$value
|
|
9
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_result$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_result$schema$value ??= z.union([z.object({
|
|
6
10
|
'kind': z.literal("ready").readonly(),
|
|
7
11
|
}), z.object({
|
|
8
12
|
'kind': z.literal("change").readonly(),
|
|
@@ -13,10 +17,13 @@ const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_result$schema
|
|
|
13
17
|
'absolutePath': z.string().readonly(),
|
|
14
18
|
'absent': z.literal(true).readonly(),
|
|
15
19
|
})]).readonly(),
|
|
16
|
-
})])
|
|
17
|
-
|
|
18
|
-
const
|
|
19
|
-
|
|
20
|
+
})]))
|
|
21
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_parameter_0$schema$value
|
|
22
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_parameter_0$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
|
|
23
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_parameter_1$schema$value
|
|
24
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_parameter_1$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_parameter_1$schema$value ??= z.string())
|
|
25
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_result$schema$value
|
|
26
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_result$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_result$schema$value ??= z.object({
|
|
20
27
|
'path': z.string().readonly(),
|
|
21
28
|
'entries': z.array(z.object({
|
|
22
29
|
'name': z.string().readonly(),
|
|
@@ -24,14 +31,18 @@ const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_result$schema = z
|
|
|
24
31
|
'size': z.number().readonly().optional(),
|
|
25
32
|
})).readonly(),
|
|
26
33
|
'truncated': z.boolean().readonly(),
|
|
27
|
-
})
|
|
28
|
-
|
|
29
|
-
const
|
|
30
|
-
|
|
34
|
+
}))
|
|
35
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_0$schema$value
|
|
36
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_0$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
|
|
37
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_1$schema$value
|
|
38
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_1$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_1$schema$value ??= z.string())
|
|
39
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_2$schema$value
|
|
40
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_2$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_2$schema$value ??= z.object({
|
|
31
41
|
'offset': z.number().readonly().optional(),
|
|
32
42
|
'limit': z.number().readonly().optional(),
|
|
33
|
-
})
|
|
34
|
-
|
|
43
|
+
}))
|
|
44
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_result$schema$value
|
|
45
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_result$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_result$schema$value ??= z.object({
|
|
35
46
|
'offset': z.number().readonly(),
|
|
36
47
|
'text': z.string().readonly(),
|
|
37
48
|
'lines': z.number().readonly(),
|
|
@@ -39,49 +50,74 @@ const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_result$schema = z
|
|
|
39
50
|
'absolutePath': z.string().readonly(),
|
|
40
51
|
'version': z.string().readonly(),
|
|
41
52
|
'bytes': z.number().readonly().optional(),
|
|
42
|
-
})
|
|
43
|
-
|
|
44
|
-
const
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
'
|
|
50
|
-
'version': z.string().readonly(),
|
|
51
|
-
'bytes': z.number().readonly().optional(),
|
|
52
|
-
})
|
|
53
|
-
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_0$schema = z.intersection(z.string(), z.unknown())
|
|
54
|
-
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_1$schema = z.string()
|
|
55
|
-
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_2$schema = z.object({
|
|
53
|
+
}))
|
|
54
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_0$schema$value
|
|
55
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_0$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
|
|
56
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_1$schema$value
|
|
57
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_1$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_1$schema$value ??= z.string())
|
|
58
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_2$schema$value
|
|
59
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_2$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_2$schema$value ??= z.object({
|
|
60
|
+
'range': z.object({
|
|
56
61
|
'offset': z.number().readonly().optional(),
|
|
57
62
|
'length': z.number().readonly().optional(),
|
|
58
|
-
})
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
'absolutePath': z.string().readonly(),
|
|
64
|
-
'version': z.string().readonly(),
|
|
65
|
-
'bytes': z.number().readonly().optional(),
|
|
66
|
-
})
|
|
67
|
-
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readRelated_parameter_0$schema = z.intersection(z.string(), z.unknown())
|
|
68
|
-
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readRelated_parameter_1$schema = z.string()
|
|
69
|
-
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readRelated_parameter_2$schema = z.string()
|
|
70
|
-
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readRelated_result$schema = z.object({
|
|
63
|
+
}).readonly().optional(),
|
|
64
|
+
'baseFile': z.string().readonly().optional(),
|
|
65
|
+
}))
|
|
66
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_result$schema$value
|
|
67
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_result$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_result$schema$value ??= z.object({
|
|
71
68
|
'offset': z.number().readonly(),
|
|
72
|
-
'data': z.
|
|
69
|
+
'data': z.instanceof(Uint8Array),
|
|
73
70
|
'eof': z.boolean().readonly(),
|
|
74
71
|
'absolutePath': z.string().readonly(),
|
|
75
72
|
'version': z.string().readonly(),
|
|
76
73
|
'bytes': z.number().readonly().optional(),
|
|
77
|
-
})
|
|
78
|
-
|
|
79
|
-
const
|
|
80
|
-
|
|
74
|
+
}))
|
|
75
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_parameter_0$schema$value
|
|
76
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_parameter_0$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
|
|
77
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_parameter_1$schema$value
|
|
78
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_parameter_1$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_parameter_1$schema$value ??= z.string())
|
|
79
|
+
let _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_result$schema$value
|
|
80
|
+
const _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_result$schema = () => (_deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_result$schema$value ??= z.object({
|
|
81
81
|
'absolutePath': z.string().readonly(),
|
|
82
82
|
'version': z.string().readonly(),
|
|
83
83
|
'bytes': z.number().readonly().optional(),
|
|
84
|
-
})
|
|
84
|
+
}))
|
|
85
|
+
const $resultSnapshot = (input, path) => {
|
|
86
|
+
if (input === null || typeof input !== 'object' || input instanceof Uint8Array) return input
|
|
87
|
+
const toJSON = input.toJSON
|
|
88
|
+
const value = typeof toJSON === 'function' ? toJSON.call(input, path.at(-1)?.toString() ?? 'value') : input
|
|
89
|
+
if (value === null || typeof value !== 'object' || value instanceof Uint8Array) return value
|
|
90
|
+
if (Array.isArray(value)) {
|
|
91
|
+
const items = []
|
|
92
|
+
for (let index = 0, length = value.length; index < length; index++) items.push(value[index])
|
|
93
|
+
return items
|
|
94
|
+
}
|
|
95
|
+
const fields = {}
|
|
96
|
+
for (const key of Object.keys(value)) {
|
|
97
|
+
const item = key === 'toJSON' && value === input ? toJSON : value[key]
|
|
98
|
+
if (key === 'toJSON' && typeof item === 'function') continue
|
|
99
|
+
Object.defineProperty(fields, key, { value: item, enumerable: true, writable: true, configurable: true })
|
|
100
|
+
}
|
|
101
|
+
return fields
|
|
102
|
+
}
|
|
103
|
+
const $resultContainer = (input, path, ancestors, project, snapshot) => {
|
|
104
|
+
if (input === null || typeof input !== 'object') return project(input)
|
|
105
|
+
const owner = !ancestors.has(input)
|
|
106
|
+
if (!owner && ancestors.get(input) !== path.length) throw new TypeError('Remote result contains a circular object')
|
|
107
|
+
if (owner) ancestors.set(input, path.length)
|
|
108
|
+
try { return project(snapshot ? $resultSnapshot(input, path) : input) }
|
|
109
|
+
finally { if (owner) ancestors.delete(input) }
|
|
110
|
+
}
|
|
111
|
+
const $encode1 = (value, writeBytes, path, ancestors) => {
|
|
112
|
+
return value instanceof Uint8Array ? writeBytes(value, path) : value
|
|
113
|
+
}
|
|
114
|
+
const $encode0 = (value, writeBytes, path, ancestors) => {
|
|
115
|
+
return $resultContainer(value, path, ancestors, value => {
|
|
116
|
+
if (value === null || typeof value !== 'object' || Array.isArray(value) || value instanceof Uint8Array) return value
|
|
117
|
+
if (Object.hasOwn(value, 'data')) value['data'] = $encode1(value['data'], writeBytes, [...path, 'data'], ancestors)
|
|
118
|
+
return value
|
|
119
|
+
}, true)
|
|
120
|
+
}
|
|
85
121
|
|
|
86
122
|
export const TYPERT_REMOTE = {
|
|
87
123
|
package: '@deepseek-ai/dsh-api-workspace-files',
|
|
@@ -102,7 +138,17 @@ export const TYPERT_REMOTE = {
|
|
|
102
138
|
codec: {
|
|
103
139
|
mode: 'strict',
|
|
104
140
|
typeSymbol: '@deepseek-ai/dsh-session/types#SessionId',
|
|
105
|
-
|
|
141
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_parameter_0$schema,
|
|
142
|
+
},
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
name: 'path',
|
|
146
|
+
wire: 'path',
|
|
147
|
+
source: 'json',
|
|
148
|
+
codec: {
|
|
149
|
+
mode: 'strict',
|
|
150
|
+
typeSymbol: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/changes:path',
|
|
151
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_parameter_1$schema,
|
|
106
152
|
},
|
|
107
153
|
},
|
|
108
154
|
],
|
|
@@ -110,9 +156,9 @@ export const TYPERT_REMOTE = {
|
|
|
110
156
|
result: {
|
|
111
157
|
mode: 'strict',
|
|
112
158
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceFileWatchFrame',
|
|
113
|
-
|
|
159
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_changes_result$schema,
|
|
114
160
|
},
|
|
115
|
-
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":
|
|
161
|
+
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":331,"column":3},
|
|
116
162
|
},
|
|
117
163
|
{
|
|
118
164
|
id: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/list',
|
|
@@ -129,7 +175,7 @@ export const TYPERT_REMOTE = {
|
|
|
129
175
|
codec: {
|
|
130
176
|
mode: 'strict',
|
|
131
177
|
typeSymbol: '@deepseek-ai/dsh-session/types#SessionId',
|
|
132
|
-
|
|
178
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_parameter_0$schema,
|
|
133
179
|
},
|
|
134
180
|
},
|
|
135
181
|
{
|
|
@@ -139,7 +185,7 @@ export const TYPERT_REMOTE = {
|
|
|
139
185
|
codec: {
|
|
140
186
|
mode: 'strict',
|
|
141
187
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/list:path',
|
|
142
|
-
|
|
188
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_parameter_1$schema,
|
|
143
189
|
},
|
|
144
190
|
},
|
|
145
191
|
],
|
|
@@ -147,9 +193,9 @@ export const TYPERT_REMOTE = {
|
|
|
147
193
|
result: {
|
|
148
194
|
mode: 'strict',
|
|
149
195
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceDirectoryListing',
|
|
150
|
-
|
|
196
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_list_result$schema,
|
|
151
197
|
},
|
|
152
|
-
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":
|
|
198
|
+
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":303,"column":9},
|
|
153
199
|
},
|
|
154
200
|
{
|
|
155
201
|
id: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/read',
|
|
@@ -166,7 +212,7 @@ export const TYPERT_REMOTE = {
|
|
|
166
212
|
codec: {
|
|
167
213
|
mode: 'strict',
|
|
168
214
|
typeSymbol: '@deepseek-ai/dsh-session/types#SessionId',
|
|
169
|
-
|
|
215
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_0$schema,
|
|
170
216
|
},
|
|
171
217
|
},
|
|
172
218
|
{
|
|
@@ -176,7 +222,7 @@ export const TYPERT_REMOTE = {
|
|
|
176
222
|
codec: {
|
|
177
223
|
mode: 'strict',
|
|
178
224
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/read:path',
|
|
179
|
-
|
|
225
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_1$schema,
|
|
180
226
|
},
|
|
181
227
|
},
|
|
182
228
|
{
|
|
@@ -186,7 +232,7 @@ export const TYPERT_REMOTE = {
|
|
|
186
232
|
codec: {
|
|
187
233
|
mode: 'strict',
|
|
188
234
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceFileRange',
|
|
189
|
-
|
|
235
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_parameter_2$schema,
|
|
190
236
|
},
|
|
191
237
|
},
|
|
192
238
|
],
|
|
@@ -194,46 +240,9 @@ export const TYPERT_REMOTE = {
|
|
|
194
240
|
result: {
|
|
195
241
|
mode: 'strict',
|
|
196
242
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceFileText',
|
|
197
|
-
|
|
198
|
-
},
|
|
199
|
-
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":232,"column":9},
|
|
200
|
-
},
|
|
201
|
-
{
|
|
202
|
-
id: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/readAll',
|
|
203
|
-
service: 'workspaceFiles',
|
|
204
|
-
namespace: 'workspaceFiles',
|
|
205
|
-
method: 'readAll',
|
|
206
|
-
invocation: { kind: 'direct' },
|
|
207
|
-
parameters: [
|
|
208
|
-
{
|
|
209
|
-
name: 'workspaceFileScope',
|
|
210
|
-
wire: 'workspaceFileScopeId',
|
|
211
|
-
source: 'lookup',
|
|
212
|
-
lookup: 'workspaceFileScope',
|
|
213
|
-
codec: {
|
|
214
|
-
mode: 'strict',
|
|
215
|
-
typeSymbol: '@deepseek-ai/dsh-session/types#SessionId',
|
|
216
|
-
schema: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readAll_parameter_0$schema,
|
|
217
|
-
},
|
|
218
|
-
},
|
|
219
|
-
{
|
|
220
|
-
name: 'path',
|
|
221
|
-
wire: 'path',
|
|
222
|
-
source: 'json',
|
|
223
|
-
codec: {
|
|
224
|
-
mode: 'strict',
|
|
225
|
-
typeSymbol: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/readAll:path',
|
|
226
|
-
schema: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readAll_parameter_1$schema,
|
|
227
|
-
},
|
|
228
|
-
},
|
|
229
|
-
],
|
|
230
|
-
cancellation: { parameter: 'signal' },
|
|
231
|
-
result: {
|
|
232
|
-
mode: 'strict',
|
|
233
|
-
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceFileBytes',
|
|
234
|
-
schema: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readAll_result$schema,
|
|
243
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_read_result$schema,
|
|
235
244
|
},
|
|
236
|
-
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":
|
|
245
|
+
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":233,"column":9},
|
|
237
246
|
},
|
|
238
247
|
{
|
|
239
248
|
id: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/readBytes',
|
|
@@ -250,7 +259,7 @@ export const TYPERT_REMOTE = {
|
|
|
250
259
|
codec: {
|
|
251
260
|
mode: 'strict',
|
|
252
261
|
typeSymbol: '@deepseek-ai/dsh-session/types#SessionId',
|
|
253
|
-
|
|
262
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_0$schema,
|
|
254
263
|
},
|
|
255
264
|
},
|
|
256
265
|
{
|
|
@@ -260,17 +269,17 @@ export const TYPERT_REMOTE = {
|
|
|
260
269
|
codec: {
|
|
261
270
|
mode: 'strict',
|
|
262
271
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/readBytes:path',
|
|
263
|
-
|
|
272
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_1$schema,
|
|
264
273
|
},
|
|
265
274
|
},
|
|
266
275
|
{
|
|
267
|
-
name: '
|
|
268
|
-
wire: '
|
|
276
|
+
name: 'options',
|
|
277
|
+
wire: 'options',
|
|
269
278
|
source: 'json',
|
|
270
279
|
codec: {
|
|
271
280
|
mode: 'strict',
|
|
272
|
-
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#
|
|
273
|
-
|
|
281
|
+
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceByteReadOptions',
|
|
282
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_parameter_2$schema,
|
|
274
283
|
},
|
|
275
284
|
},
|
|
276
285
|
],
|
|
@@ -278,57 +287,12 @@ export const TYPERT_REMOTE = {
|
|
|
278
287
|
result: {
|
|
279
288
|
mode: 'strict',
|
|
280
289
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceFileBytes',
|
|
281
|
-
|
|
290
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_result$schema,
|
|
291
|
+
decode: value => _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readBytes_result$schema().parse(value),
|
|
292
|
+
encode: (value, writeBytes) => $encode0(value, writeBytes, [], new Map()),
|
|
282
293
|
},
|
|
283
294
|
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":257,"column":9},
|
|
284
295
|
},
|
|
285
|
-
{
|
|
286
|
-
id: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/readRelated',
|
|
287
|
-
service: 'workspaceFiles',
|
|
288
|
-
namespace: 'workspaceFiles',
|
|
289
|
-
method: 'readRelated',
|
|
290
|
-
invocation: { kind: 'direct' },
|
|
291
|
-
parameters: [
|
|
292
|
-
{
|
|
293
|
-
name: 'workspaceFileScope',
|
|
294
|
-
wire: 'workspaceFileScopeId',
|
|
295
|
-
source: 'lookup',
|
|
296
|
-
lookup: 'workspaceFileScope',
|
|
297
|
-
codec: {
|
|
298
|
-
mode: 'strict',
|
|
299
|
-
typeSymbol: '@deepseek-ai/dsh-session/types#SessionId',
|
|
300
|
-
schema: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readRelated_parameter_0$schema,
|
|
301
|
-
},
|
|
302
|
-
},
|
|
303
|
-
{
|
|
304
|
-
name: 'path',
|
|
305
|
-
wire: 'path',
|
|
306
|
-
source: 'json',
|
|
307
|
-
codec: {
|
|
308
|
-
mode: 'strict',
|
|
309
|
-
typeSymbol: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/readRelated:path',
|
|
310
|
-
schema: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readRelated_parameter_1$schema,
|
|
311
|
-
},
|
|
312
|
-
},
|
|
313
|
-
{
|
|
314
|
-
name: 'relativePath',
|
|
315
|
-
wire: 'relativePath',
|
|
316
|
-
source: 'json',
|
|
317
|
-
codec: {
|
|
318
|
-
mode: 'strict',
|
|
319
|
-
typeSymbol: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/readRelated:relativePath',
|
|
320
|
-
schema: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readRelated_parameter_2$schema,
|
|
321
|
-
},
|
|
322
|
-
},
|
|
323
|
-
],
|
|
324
|
-
cancellation: { parameter: 'signal' },
|
|
325
|
-
result: {
|
|
326
|
-
mode: 'strict',
|
|
327
|
-
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceFileBytes',
|
|
328
|
-
schema: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_readRelated_result$schema,
|
|
329
|
-
},
|
|
330
|
-
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":300,"column":9},
|
|
331
|
-
},
|
|
332
296
|
{
|
|
333
297
|
id: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/stat',
|
|
334
298
|
service: 'workspaceFiles',
|
|
@@ -344,7 +308,7 @@ export const TYPERT_REMOTE = {
|
|
|
344
308
|
codec: {
|
|
345
309
|
mode: 'strict',
|
|
346
310
|
typeSymbol: '@deepseek-ai/dsh-session/types#SessionId',
|
|
347
|
-
|
|
311
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_parameter_0$schema,
|
|
348
312
|
},
|
|
349
313
|
},
|
|
350
314
|
{
|
|
@@ -354,7 +318,7 @@ export const TYPERT_REMOTE = {
|
|
|
354
318
|
codec: {
|
|
355
319
|
mode: 'strict',
|
|
356
320
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files#workspaceFiles/stat:path',
|
|
357
|
-
|
|
321
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_parameter_1$schema,
|
|
358
322
|
},
|
|
359
323
|
},
|
|
360
324
|
],
|
|
@@ -362,9 +326,9 @@ export const TYPERT_REMOTE = {
|
|
|
362
326
|
result: {
|
|
363
327
|
mode: 'strict',
|
|
364
328
|
typeSymbol: '@deepseek-ai/dsh-api-workspace-files/types#WorkspaceFileStat',
|
|
365
|
-
|
|
329
|
+
create: _deepseek_ai_dsh_api_workspace_files_workspaceFiles_stat_result$schema,
|
|
366
330
|
},
|
|
367
|
-
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":
|
|
331
|
+
sourceLocation: {"file":"packages/api/workspace-files/src/index.ts","line":290,"column":9},
|
|
368
332
|
},
|
|
369
333
|
],
|
|
370
334
|
}
|
package/lib/types/changes.d.ts
CHANGED
|
@@ -1,26 +1,23 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
* operating system is not watched.
|
|
6
|
-
* Each generation acknowledges its observation queue and resolved workspace
|
|
7
|
-
* root with `ready` before emitting any queued or live changes.
|
|
2
|
+
* Target-scoped filesystem watches and `fs/observed` invalidations for `changes`.
|
|
3
|
+
* Each generation sends `ready` after watcher initialization, then reads current
|
|
4
|
+
* target metadata for matching queued and live invalidations.
|
|
8
5
|
*/
|
|
9
6
|
import type { Context } from '@deepseek-ai/cordis';
|
|
10
7
|
import type { WorkspaceFileWatchFrame } from './types.ts';
|
|
11
|
-
/** Owns
|
|
8
|
+
/** Owns target watches, instrumented observations, and every open `changes` generation. */
|
|
12
9
|
export declare class WorkspaceChangeFeed {
|
|
13
10
|
private readonly ctx;
|
|
14
11
|
private readonly followers;
|
|
15
12
|
/** @param ctx - Host context carrying the filesystem the observations come from. */
|
|
16
13
|
constructor(ctx: Context);
|
|
17
14
|
/**
|
|
18
|
-
* Open one
|
|
15
|
+
* Open one target watch; directory targets remain inside `workspaceRoot`.
|
|
19
16
|
* @param workspaceRoot - the session's workspace root path.
|
|
17
|
+
* @param path - target path, resolved relative to the workspace root; Host metadata determines its type.
|
|
20
18
|
* @param signal - generation cancellation.
|
|
21
|
-
* @returns `ready` after
|
|
22
|
-
* observations made after the generation was first pulled, in emission order.
|
|
19
|
+
* @returns `ready` after watching starts, then current metadata for target invalidations.
|
|
23
20
|
*/
|
|
24
|
-
follow(workspaceRoot: string, signal: AbortSignal): AsyncIterable<WorkspaceFileWatchFrame>;
|
|
21
|
+
follow(workspaceRoot: string, path: string, signal: AbortSignal): AsyncIterable<WorkspaceFileWatchFrame>;
|
|
25
22
|
}
|
|
26
23
|
//# sourceMappingURL=changes.d.ts.map
|