@khorsheed/dsh-reader 0.3.0 → 0.3.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.
Files changed (87) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/README.en.md +26 -121
  3. package/README.i18n.yaml +3 -3
  4. package/README.md +26 -121
  5. package/cordis.patch.yml +7 -0
  6. package/lib/client.js +29054 -6698
  7. package/lib/index.js +3416 -334
  8. package/lib/typert.host.js +2145 -259
  9. package/lib/typert.remote-client.d.ts +97 -3
  10. package/lib/typert.remote-client.js +1590 -250
  11. package/lib/types/captions.d.ts +99 -0
  12. package/lib/types/captions.js +236 -0
  13. package/lib/types/client/MediaPlayer.d.ts +55 -0
  14. package/lib/types/client/MediaPlayer.js +106 -0
  15. package/lib/types/client/NotesView.d.ts +57 -0
  16. package/lib/types/client/NotesView.js +124 -0
  17. package/lib/types/client/ReaderPane.d.ts +20 -3
  18. package/lib/types/client/ReaderPane.js +860 -164
  19. package/lib/types/client/SpeakerLegend.d.ts +18 -0
  20. package/lib/types/client/SpeakerLegend.js +26 -0
  21. package/lib/types/client/canvas-sync.d.ts +84 -0
  22. package/lib/types/client/canvas-sync.js +59 -0
  23. package/lib/types/client/contract.d.ts +130 -3
  24. package/lib/types/client/extract-article.d.ts +38 -1
  25. package/lib/types/client/extract-article.js +501 -28
  26. package/lib/types/client/icons.d.ts +1 -1
  27. package/lib/types/client/icons.js +1 -1
  28. package/lib/types/client/index.js +81 -2
  29. package/lib/types/client/locales.d.ts +279 -11
  30. package/lib/types/client/locales.js +278 -10
  31. package/lib/types/client/notes.d.ts +142 -0
  32. package/lib/types/client/notes.js +334 -0
  33. package/lib/types/client/parse-rss.js +40 -0
  34. package/lib/types/client/preset-visibility.d.ts +93 -0
  35. package/lib/types/client/preset-visibility.js +115 -0
  36. package/lib/types/client/selectors.d.ts +5 -0
  37. package/lib/types/client/selectors.js +5 -0
  38. package/lib/types/client/session.d.ts +21 -1
  39. package/lib/types/client/session.js +12 -0
  40. package/lib/types/client/store.js +4 -1
  41. package/lib/types/client/translate.d.ts +26 -1
  42. package/lib/types/client/translate.js +29 -12
  43. package/lib/types/client/useLocalTranscript.d.ts +43 -0
  44. package/lib/types/client/useLocalTranscript.js +129 -0
  45. package/lib/types/client/useMedia.d.ts +68 -0
  46. package/lib/types/client/useMedia.js +299 -0
  47. package/lib/types/client/useMediaStates.d.ts +9 -0
  48. package/lib/types/client/useMediaStates.js +43 -0
  49. package/lib/types/client/useNotes.d.ts +110 -0
  50. package/lib/types/client/useNotes.js +423 -0
  51. package/lib/types/client/usePolish.d.ts +47 -0
  52. package/lib/types/client/usePolish.js +162 -0
  53. package/lib/types/index.d.ts +6 -0
  54. package/lib/types/index.js +3 -0
  55. package/lib/types/local-transcribe.d.ts +171 -0
  56. package/lib/types/local-transcribe.js +473 -0
  57. package/lib/types/media-host.d.ts +91 -0
  58. package/lib/types/media-host.js +230 -0
  59. package/lib/types/media.d.ts +100 -0
  60. package/lib/types/media.js +207 -0
  61. package/lib/types/notes-types.d.ts +158 -0
  62. package/lib/types/notes-types.js +8 -0
  63. package/lib/types/notes.d.ts +213 -0
  64. package/lib/types/notes.js +718 -0
  65. package/lib/types/polish.d.ts +41 -0
  66. package/lib/types/polish.js +136 -0
  67. package/lib/types/remote.d.ts +118 -0
  68. package/lib/types/remote.js +151 -1
  69. package/lib/types/service.d.ts +71 -1
  70. package/lib/types/service.js +280 -59
  71. package/lib/types/skill.d.ts +20 -0
  72. package/lib/types/skill.js +78 -0
  73. package/lib/types/store.js +30 -8
  74. package/lib/types/tool.d.ts +23 -0
  75. package/lib/types/tool.js +40 -0
  76. package/lib/types/tools.d.ts +69 -0
  77. package/lib/types/tools.js +400 -0
  78. package/lib/types/types.d.ts +87 -0
  79. package/lib/types/types.js +66 -0
  80. package/lib/types/xiaoyuzhou.d.ts +43 -0
  81. package/lib/types/xiaoyuzhou.js +134 -0
  82. package/lib/types/ytdlp.d.ts +111 -0
  83. package/lib/types/ytdlp.js +269 -0
  84. package/package.json +29 -20
  85. package/lib/invariant.js +0 -38
  86. package/lib/types/invariant.d.ts +0 -29
  87. package/lib/types/invariant.js +0 -38
@@ -1,32 +1,99 @@
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
+ import { createTypertRemoteInfo } from '@deepseek-ai/dsh-typert-protocol/remote-info'
5
+
6
+ let _khorsheed_dsh_reader_reader_addNote_parameter_0$schema$value
7
+ const _khorsheed_dsh_reader_reader_addNote_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_addNote_parameter_0$schema$value ??= z.object({
8
+ 'block': z.number().readonly(),
9
+ 'start': z.number().readonly().optional(),
10
+ 'quote': z.string().readonly(),
11
+ 'translated': z.string().readonly().optional(),
12
+ 'comment': z.string().readonly().optional(),
13
+ 'time': z.number().readonly().optional(),
14
+ 'entryId': z.string().readonly(),
15
+ 'title': z.string().readonly(),
16
+ 'url': z.string().readonly().optional(),
17
+ 'source': z.string().readonly().optional(),
18
+ }))
19
+ let _khorsheed_dsh_reader_reader_addNote_result$schema$value
20
+ const _khorsheed_dsh_reader_reader_addNote_result$schema = () => (_khorsheed_dsh_reader_reader_addNote_result$schema$value ??= z.union([z.literal("empty"), z.object({
21
+ 'id': z.string().readonly().describe('`n1`, `n2`… per article, never reused — the model cites notes by it.'),
22
+ 'anchor': z.object({
23
+ 'block': z.number().readonly(),
24
+ 'start': z.number().readonly().optional(),
25
+ 'quote': z.string().readonly(),
26
+ 'translated': z.string().readonly().optional().describe('The translated text, when the selection was made in the translated view.'),
27
+ 'time': z.number().readonly().optional().describe('A video / audio transcript paragraph\'s start (seconds): where ▶ plays from.'),
28
+ }).readonly(),
29
+ 'comment': z.string().readonly().optional(),
30
+ 'replies': z.array(z.object({
31
+ 'by': z.union([z.literal("user"), z.literal("agent")]).readonly(),
32
+ 'text': z.string().readonly(),
33
+ 'sessionId': z.string().readonly().optional().describe('The conversation it came from, so the reader can go back to it.'),
34
+ 'editedFrom': z.literal("agent").readonly().optional().describe('Set when the reader rewrote a line the model wrote.'),
35
+ 'at': z.string().readonly(),
36
+ })).readonly().optional().describe('Conclusions and additions, oldest first.'),
37
+ 'syncedTo': z.array(z.object({
38
+ 'canvasId': z.string().readonly(),
39
+ 'cardId': z.string().readonly(),
40
+ 'canvasTitle': z.string().readonly().describe('The canvas\'s title when it was synced (for the 「已在…」 mark).'),
41
+ 'at': z.string().readonly(),
42
+ })).readonly().optional().describe('Canvas cards made from it (a later edit does not reach them).'),
43
+ 'createdAt': z.string().readonly(),
44
+ 'updatedAt': z.string().readonly(),
45
+ }), z.literal("full")]))
46
+ let _khorsheed_dsh_reader_reader_addReply_parameter_0$schema$value
47
+ const _khorsheed_dsh_reader_reader_addReply_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_addReply_parameter_0$schema$value ??= z.object({
48
+ 'entryId': z.string(),
49
+ 'noteId': z.string(),
50
+ 'text': z.string(),
51
+ }))
52
+ let _khorsheed_dsh_reader_reader_addReply_result$schema$value
53
+ const _khorsheed_dsh_reader_reader_addReply_result$schema = () => (_khorsheed_dsh_reader_reader_addReply_result$schema$value ??= z.union([z.literal("not-found"), z.literal("ok"), z.literal("empty"), z.literal("full")]))
4
54
  let _khorsheed_dsh_reader_reader_addSource_parameter_0$schema$value
5
55
  const _khorsheed_dsh_reader_reader_addSource_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_addSource_parameter_0$schema$value ??= z.object({
6
56
  'url': z.string(),
7
57
  'label': z.string().optional(),
8
58
  }))
9
59
  let _khorsheed_dsh_reader_reader_addSource_result$schema$value
10
- const _khorsheed_dsh_reader_reader_addSource_result$schema = () => (_khorsheed_dsh_reader_reader_addSource_result$schema$value ??= z.union([z.literal("unavailable"), z.object({
60
+ const _khorsheed_dsh_reader_reader_addSource_result$schema = () => (_khorsheed_dsh_reader_reader_addSource_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("duplicate"), z.object({
11
61
  'outcome': z.union([z.literal("subscribed"), z.literal("saved-link")]).readonly(),
12
62
  'kind': z.union([z.literal("rss"), z.literal("link")]).readonly(),
13
63
  'id': z.string().readonly(),
14
64
  'label': z.string().readonly(),
15
65
  'failure': z.object({
16
- 'code': z.union([z.literal("unreadable"), z.literal("empty"), z.literal("blocked"), z.literal("login"), z.literal("unsupported-type"), z.literal("redirected"), z.literal("unreachable"), z.literal("http")]).readonly(),
66
+ 'code': z.union([z.literal("blocked"), z.literal("http"), z.literal("unreadable"), z.literal("empty"), z.literal("login"), z.literal("unsupported-type"), z.literal("redirected"), z.literal("unreachable")]).readonly(),
17
67
  'message': z.string().readonly(),
18
- }).readonly().optional(),
19
- }), z.literal("invalid-url"), z.literal("duplicate"), z.literal("unsupported-content"), z.literal("fetch-failed"), z.object({
68
+ }).readonly().optional().describe('Present when the source was saved but its body cannot be previewed. The add still succeeded: the URL is a link the reader now owns. This is the verdict\'s reason, not a failure — which is why it rides the outcome instead of becoming one more refusal that loses the link.'),
69
+ }), z.literal("invalid-url"), z.literal("unsupported-content"), z.literal("fetch-failed"), z.object({
20
70
  'outcome': z.literal("fetch-failed").readonly(),
21
- 'reason': z.string().readonly(),
71
+ 'reason': z.string().readonly().describe('The fetch seam\'s message, verbatim — a refused connection, a timeout, a byte cap.'),
22
72
  })]))
73
+ let _khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0$schema$value
74
+ const _khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0$schema$value ??= z.object({
75
+ 'entryId': z.string(),
76
+ 'force': z.boolean(),
77
+ }))
78
+ let _khorsheed_dsh_reader_reader_cancelLocalTranscript_result$schema$value
79
+ const _khorsheed_dsh_reader_reader_cancelLocalTranscript_result$schema = () => (_khorsheed_dsh_reader_reader_cancelLocalTranscript_result$schema$value ??= z.object({
80
+ 'entryId': z.string().readonly(),
81
+ 'state': z.union([z.literal("failed"), z.literal("unavailable"), z.literal("done"), z.literal("idle"), z.literal("queued"), z.literal("fetching"), z.literal("needs-models"), z.literal("transcribing"), z.literal("speakers")]).readonly(),
82
+ 'progress': z.number().readonly().optional().describe('0–1 across fetching the audio and transcribing it.'),
83
+ 'ahead': z.number().readonly().optional().describe('Jobs ahead in the engine\'s queue.'),
84
+ 'bytes': z.number().readonly().optional().describe('Bytes of speech models still to download (`needs-models`).'),
85
+ 'html': z.string().readonly().optional().describe('The transcript so far (or in full, once `done`).'),
86
+ 'language': z.string().readonly().optional().describe('The language the transcript is in, once known.'),
87
+ 'speakers': z.number().readonly().optional().describe('How many voices the transcript has, once the speakers pass settled it.'),
88
+ 'error': z.string().readonly().optional(),
89
+ }))
23
90
  let _khorsheed_dsh_reader_reader_capabilities_result$schema$value
24
91
  const _khorsheed_dsh_reader_reader_capabilities_result$schema = () => (_khorsheed_dsh_reader_reader_capabilities_result$schema$value ??= z.object({
25
92
  'protocolVersion': z.literal(1).readonly(),
26
- 'hasFs': z.boolean().readonly(),
27
- 'hasSideChat': z.boolean().readonly(),
28
- 'nextRefreshAt': z.string().readonly().optional(),
29
- 'lastRefreshAt': z.string().readonly().optional(),
93
+ 'hasFs': z.boolean().readonly().describe('False when no filesystem is mounted: state lives in memory and is lost on restart.'),
94
+ 'hasSideChat': z.boolean().readonly().describe('False when no side-chat service is mounted: the side-chat gesture must hide.'),
95
+ 'nextRefreshAt': z.string().readonly().optional().describe('ISO-8601 timestamp of the next scheduled refresh, when one is armed.'),
96
+ 'lastRefreshAt': z.string().readonly().optional().describe('ISO-8601 timestamp of the last completed refresh run, when there was one. The list shows it so a reader can decide whether the snapshot is stale enough to be worth a fetch.'),
30
97
  }))
31
98
  let _khorsheed_dsh_reader_reader_clearRecent_result$schema$value
32
99
  const _khorsheed_dsh_reader_reader_clearRecent_result$schema = () => (_khorsheed_dsh_reader_reader_clearRecent_result$schema$value ??= z.object({
@@ -42,17 +109,40 @@ const _khorsheed_dsh_reader_reader_createTag_parameter_0$schema = () => (_khorsh
42
109
  'name': z.string(),
43
110
  }))
44
111
  let _khorsheed_dsh_reader_reader_createTag_result$schema$value
45
- const _khorsheed_dsh_reader_reader_createTag_result$schema = () => (_khorsheed_dsh_reader_reader_createTag_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("ok"), z.literal("empty"), z.literal("not-found"), z.literal("duplicate"), z.object({
46
- 'id': z.string().readonly(),
47
- 'name': z.string().readonly(),
112
+ const _khorsheed_dsh_reader_reader_createTag_result$schema = () => (_khorsheed_dsh_reader_reader_createTag_result$schema$value ??= z.union([z.literal("not-found"), z.literal("unavailable"), z.literal("duplicate"), z.literal("ok"), z.literal("empty"), z.literal("invalid"), z.object({
113
+ 'id': z.string().readonly().describe('Stable id — renaming a tag must not rewrite every entry that carries it.'),
114
+ 'name': z.string().readonly().describe('The reader-facing name, unique case-insensitively.'),
48
115
  'createdAt': z.string().readonly(),
49
- }), z.literal("invalid")]))
116
+ })]))
117
+ let _khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0$schema$value
118
+ const _khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0$schema$value ??= z.object({
119
+ 'entryId': z.string(),
120
+ 'discussionId': z.string(),
121
+ }))
122
+ let _khorsheed_dsh_reader_reader_deleteDiscussion_result$schema$value
123
+ const _khorsheed_dsh_reader_reader_deleteDiscussion_result$schema = () => (_khorsheed_dsh_reader_reader_deleteDiscussion_result$schema$value ??= z.union([z.literal("not-found"), z.literal("ok"), z.literal("empty"), z.literal("full")]))
124
+ let _khorsheed_dsh_reader_reader_deleteNote_parameter_0$schema$value
125
+ const _khorsheed_dsh_reader_reader_deleteNote_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_deleteNote_parameter_0$schema$value ??= z.object({
126
+ 'entryId': z.string(),
127
+ 'noteId': z.string(),
128
+ }))
129
+ let _khorsheed_dsh_reader_reader_deleteNote_result$schema$value
130
+ const _khorsheed_dsh_reader_reader_deleteNote_result$schema = () => (_khorsheed_dsh_reader_reader_deleteNote_result$schema$value ??= z.union([z.literal("not-found"), z.literal("ok"), z.literal("empty"), z.literal("full")]))
50
131
  let _khorsheed_dsh_reader_reader_deleteTag_parameter_0$schema$value
51
132
  const _khorsheed_dsh_reader_reader_deleteTag_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_deleteTag_parameter_0$schema$value ??= z.object({
52
133
  'id': z.string(),
53
134
  }))
54
135
  let _khorsheed_dsh_reader_reader_deleteTag_result$schema$value
55
- const _khorsheed_dsh_reader_reader_deleteTag_result$schema = () => (_khorsheed_dsh_reader_reader_deleteTag_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("ok"), z.literal("empty"), z.literal("not-found"), z.literal("duplicate"), z.literal("invalid")]))
136
+ const _khorsheed_dsh_reader_reader_deleteTag_result$schema = () => (_khorsheed_dsh_reader_reader_deleteTag_result$schema$value ??= z.union([z.literal("not-found"), z.literal("unavailable"), z.literal("duplicate"), z.literal("ok"), z.literal("empty"), z.literal("invalid")]))
137
+ let _khorsheed_dsh_reader_reader_editReply_parameter_0$schema$value
138
+ const _khorsheed_dsh_reader_reader_editReply_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_editReply_parameter_0$schema$value ??= z.object({
139
+ 'entryId': z.string(),
140
+ 'noteId': z.string(),
141
+ 'index': z.number(),
142
+ 'text': z.string(),
143
+ }))
144
+ let _khorsheed_dsh_reader_reader_editReply_result$schema$value
145
+ const _khorsheed_dsh_reader_reader_editReply_result$schema = () => (_khorsheed_dsh_reader_reader_editReply_result$schema$value ??= z.union([z.literal("not-found"), z.literal("ok"), z.literal("empty"), z.literal("full")]))
56
146
  let _khorsheed_dsh_reader_reader_entryFetchStates_parameter_0$schema$value
57
147
  const _khorsheed_dsh_reader_reader_entryFetchStates_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_entryFetchStates_parameter_0$schema$value ??= z.object({
58
148
  'entryIds': z.array(z.string()),
@@ -74,9 +164,74 @@ const _khorsheed_dsh_reader_reader_entryFetchStates_result$schema = () => (_khor
74
164
  'state': z.literal("failed").readonly(),
75
165
  'at': z.string().readonly(),
76
166
  'message': z.string().readonly(),
77
- 'code': z.union([z.literal("unreadable"), z.literal("empty"), z.literal("blocked"), z.literal("login"), z.literal("unsupported-type"), z.literal("redirected"), z.literal("unreachable"), z.literal("http")]).readonly().optional(),
167
+ 'code': z.union([z.literal("blocked"), z.literal("http"), z.literal("unreadable"), z.literal("empty"), z.literal("login"), z.literal("unsupported-type"), z.literal("redirected"), z.literal("unreachable")]).readonly().optional(),
78
168
  })])),
79
169
  }))
170
+ let _khorsheed_dsh_reader_reader_entryNotes_parameter_0$schema$value
171
+ const _khorsheed_dsh_reader_reader_entryNotes_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_entryNotes_parameter_0$schema$value ??= z.object({
172
+ 'entryId': z.string(),
173
+ }))
174
+ let _khorsheed_dsh_reader_reader_entryNotes_result$schema$value
175
+ const _khorsheed_dsh_reader_reader_entryNotes_result$schema = () => (_khorsheed_dsh_reader_reader_entryNotes_result$schema$value ??= z.object({
176
+ 'entry': z.object({
177
+ 'entryId': z.string().readonly(),
178
+ 'title': z.string().readonly(),
179
+ 'url': z.string().readonly().optional(),
180
+ 'source': z.string().readonly().optional().describe('The source\'s display label (the feed\'s name, or the site).'),
181
+ 'notes': z.array(z.object({
182
+ 'id': z.string().readonly().describe('`n1`, `n2`… per article, never reused — the model cites notes by it.'),
183
+ 'anchor': z.object({
184
+ 'block': z.number().readonly(),
185
+ 'start': z.number().readonly().optional(),
186
+ 'quote': z.string().readonly(),
187
+ 'translated': z.string().readonly().optional().describe('The translated text, when the selection was made in the translated view.'),
188
+ 'time': z.number().readonly().optional().describe('A video / audio transcript paragraph\'s start (seconds): where ▶ plays from.'),
189
+ }).readonly(),
190
+ 'comment': z.string().readonly().optional(),
191
+ 'replies': z.array(z.object({
192
+ 'by': z.union([z.literal("user"), z.literal("agent")]).readonly(),
193
+ 'text': z.string().readonly(),
194
+ 'sessionId': z.string().readonly().optional().describe('The conversation it came from, so the reader can go back to it.'),
195
+ 'editedFrom': z.literal("agent").readonly().optional().describe('Set when the reader rewrote a line the model wrote.'),
196
+ 'at': z.string().readonly(),
197
+ })).readonly().optional().describe('Conclusions and additions, oldest first.'),
198
+ 'syncedTo': z.array(z.object({
199
+ 'canvasId': z.string().readonly(),
200
+ 'cardId': z.string().readonly(),
201
+ 'canvasTitle': z.string().readonly().describe('The canvas\'s title when it was synced (for the 「已在…」 mark).'),
202
+ 'at': z.string().readonly(),
203
+ })).readonly().optional().describe('Canvas cards made from it (a later edit does not reach them).'),
204
+ 'createdAt': z.string().readonly(),
205
+ 'updatedAt': z.string().readonly(),
206
+ })).readonly(),
207
+ 'sessions': z.array(z.object({
208
+ 'sessionId': z.string().readonly(),
209
+ 'title': z.string().readonly().optional(),
210
+ 'lastAt': z.string().readonly(),
211
+ })).readonly(),
212
+ 'discussions': z.array(z.object({
213
+ 'id': z.string().readonly().describe('`d1`, `d2`… per article, never reused.'),
214
+ 'kind': z.union([z.literal("check"), z.literal("discussion")]).readonly(),
215
+ 'sessionId': z.string().readonly().optional(),
216
+ 'title': z.string().readonly(),
217
+ 'points': z.array(z.object({
218
+ 'text': z.string().readonly(),
219
+ 'para': z.number().readonly().optional().describe('¶ number (1-based), when the point cites the article.'),
220
+ })).readonly(),
221
+ 'aside': z.string().readonly().optional().describe('One line for what went fine (「其余 2 题讲到位了」).'),
222
+ 'syncedTo': z.array(z.object({
223
+ 'canvasId': z.string().readonly(),
224
+ 'cardId': z.string().readonly(),
225
+ 'canvasTitle': z.string().readonly().describe('The canvas\'s title when it was synced (for the 「已在…」 mark).'),
226
+ 'at': z.string().readonly(),
227
+ })).readonly().optional().describe('Canvas cards made from it.'),
228
+ 'createdAt': z.string().readonly(),
229
+ })).readonly().optional().describe('Discussion notes, newest first.'),
230
+ 'nextNote': z.number().readonly().describe('The next note number; ids are never reused, so a deleted n3 stays deleted.'),
231
+ 'nextDiscussion': z.number().readonly().optional().describe('The next discussion number, never reused either.'),
232
+ 'updatedAt': z.string().readonly(),
233
+ }).optional(),
234
+ }))
80
235
  let _khorsheed_dsh_reader_reader_entryTags_parameter_0$schema$value
81
236
  const _khorsheed_dsh_reader_reader_entryTags_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_entryTags_parameter_0$schema$value ??= z.object({
82
237
  'entryId': z.string(),
@@ -84,8 +239,8 @@ const _khorsheed_dsh_reader_reader_entryTags_parameter_0$schema = () => (_khorsh
84
239
  let _khorsheed_dsh_reader_reader_entryTags_result$schema$value
85
240
  const _khorsheed_dsh_reader_reader_entryTags_result$schema = () => (_khorsheed_dsh_reader_reader_entryTags_result$schema$value ??= z.object({
86
241
  'tags': z.array(z.object({
87
- 'id': z.string().readonly(),
88
- 'name': z.string().readonly(),
242
+ 'id': z.string().readonly().describe('Stable id — renaming a tag must not rewrite every entry that carries it.'),
243
+ 'name': z.string().readonly().describe('The reader-facing name, unique case-insensitively.'),
89
244
  'createdAt': z.string().readonly(),
90
245
  })),
91
246
  }))
@@ -109,10 +264,10 @@ const _khorsheed_dsh_reader_reader_fetchImage_parameter_0$schema = () => (_khors
109
264
  }))
110
265
  let _khorsheed_dsh_reader_reader_fetchImage_result$schema$value
111
266
  const _khorsheed_dsh_reader_reader_fetchImage_result$schema = () => (_khorsheed_dsh_reader_reader_fetchImage_result$schema$value ??= z.object({
112
- 'url': z.string().readonly(),
113
- 'mime': z.string().readonly().optional(),
114
- 'base64': z.string().readonly().optional(),
115
- 'error': z.string().readonly().optional(),
267
+ 'url': z.string().readonly().describe('The URL the pane asked about (echoed, so a late answer can be matched).'),
268
+ 'mime': z.string().readonly().optional().describe('The image\'s declared content type, when the fetch produced bytes.'),
269
+ 'base64': z.string().readonly().optional().describe('The image bytes, base64-encoded, when the fetch produced them.'),
270
+ 'error': z.string().readonly().optional().describe('Why the rescue failed, when it did.'),
116
271
  }))
117
272
  let _khorsheed_dsh_reader_reader_getBodies_parameter_0$schema$value
118
273
  const _khorsheed_dsh_reader_reader_getBodies_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_getBodies_parameter_0$schema$value ??= z.object({
@@ -124,9 +279,9 @@ const _khorsheed_dsh_reader_reader_getBodies_result$schema = () => (_khorsheed_d
124
279
  'id': z.string().readonly(),
125
280
  'raw': z.string().readonly().optional(),
126
281
  'truncated': z.boolean().readonly().optional(),
127
- 'error': z.string().readonly().optional(),
128
- 'title': z.string().readonly().optional(),
129
- 'excerpt': z.string().readonly().optional(),
282
+ 'error': z.string().readonly().optional().describe('Present when the payload could not be produced (fetch failed, no fs, …).'),
283
+ 'title': z.string().readonly().optional().describe('The captured article title for a link source\'s single entry, when a past extraction stored it (see {@link ReaderEntryAnnotation.title}). The wall prefers it over the URL-derived label.'),
284
+ 'excerpt': z.string().readonly().optional().describe('The captured excerpt, with the title.'),
130
285
  })),
131
286
  }))
132
287
  let _khorsheed_dsh_reader_reader_getCachePolicy_result$schema$value
@@ -144,15 +299,15 @@ const _khorsheed_dsh_reader_reader_getEntryBody_parameter_0$schema = () => (_kho
144
299
  let _khorsheed_dsh_reader_reader_getEntryBody_result$schema$value
145
300
  const _khorsheed_dsh_reader_reader_getEntryBody_result$schema = () => (_khorsheed_dsh_reader_reader_getEntryBody_result$schema$value ??= z.object({
146
301
  'entryId': z.string().readonly(),
147
- 'cached': z.boolean().readonly(),
148
- 'fresh': z.boolean().readonly(),
149
- 'fromFeed': z.boolean().readonly(),
302
+ 'cached': z.boolean().readonly().describe('True when this body is a cached fetch rather than the feed\'s own payload.'),
303
+ 'fresh': z.boolean().readonly().describe('False when the cache\'s deadline has passed: the view offers the fetch.'),
304
+ 'fromFeed': z.boolean().readonly().describe('True when the feed\'s payload already carries full text for this entry.'),
150
305
  'html': z.string().readonly().optional(),
151
306
  'fetchedAt': z.string().readonly().optional(),
152
307
  'truncated': z.boolean().readonly().optional(),
153
- 'scriptFigures': z.number().readonly().optional(),
154
- 'rendered': z.boolean().readonly().optional(),
155
- 'error': z.string().readonly().optional(),
308
+ 'scriptFigures': z.number().readonly().optional().describe('Figures this page draws with scripts — the detail view says so.'),
309
+ 'rendered': z.boolean().readonly().optional().describe('True when this body came from a rendered fetch (the「重新抓取」route reads it).'),
310
+ 'error': z.string().readonly().optional().describe('Why a fetch could not produce a body, when one was attempted.'),
156
311
  }))
157
312
  let _khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0$schema$value
158
313
  const _khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0$schema$value ??= z.object({
@@ -192,13 +347,13 @@ const _khorsheed_dsh_reader_reader_getStorageStats_result$schema = () => (_khors
192
347
  'bodies': z.object({
193
348
  'entries': z.number().readonly(),
194
349
  'chars': z.number().readonly(),
195
- }).readonly(),
350
+ }).readonly().describe('The cached article bodies (what TTL + maxEntries govern).'),
196
351
  'translations': z.object({
197
- 'entries': z.number().readonly(),
198
- 'chars': z.number().readonly(),
199
- 'memoryEntries': z.number().readonly(),
200
- 'memoryChars': z.number().readonly(),
201
- }).readonly(),
352
+ 'entries': z.number().readonly().describe('How many entries carry a segment map.'),
353
+ 'chars': z.number().readonly().describe('The maps\' combined size.'),
354
+ 'memoryEntries': z.number().readonly().describe('The global memory\'s sentence count (0 when no table exists).'),
355
+ 'memoryChars': z.number().readonly().describe('The global memory\'s size (0 when no table exists).'),
356
+ }).readonly().describe('The two translation tiers: per-entry maps, and the global sentence memory.'),
202
357
  }))
203
358
  let _khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0$schema$value
204
359
  const _khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0$schema$value ??= z.object({
@@ -216,7 +371,7 @@ const _khorsheed_dsh_reader_reader_listBackfillCandidates_result$schema = () =>
216
371
  'entryId': z.string().readonly(),
217
372
  'url': z.string().readonly(),
218
373
  'label': z.string().readonly(),
219
- 'lastError': z.string().readonly().optional(),
374
+ 'lastError': z.string().readonly().optional().describe('Why a previous attempt failed, when one did (and when it is worth retrying).'),
220
375
  })),
221
376
  }))
222
377
  let _khorsheed_dsh_reader_reader_listRecent_result$schema$value
@@ -225,8 +380,8 @@ const _khorsheed_dsh_reader_reader_listRecent_result$schema = () => (_khorsheed_
225
380
  'entryId': z.string().readonly(),
226
381
  'sourceId': z.string().readonly(),
227
382
  'title': z.string().readonly(),
228
- 'url': z.string().readonly().optional(),
229
- 'readAt': z.string().readonly(),
383
+ 'url': z.string().readonly().optional().describe('The article URL, for reopening an entry the feed no longer publishes.'),
384
+ 'readAt': z.string().readonly().describe('When it was opened (ISO-8601).'),
230
385
  })),
231
386
  }))
232
387
  let _khorsheed_dsh_reader_reader_listSources_result$schema$value
@@ -237,28 +392,106 @@ const _khorsheed_dsh_reader_reader_listSources_result$schema = () => (_khorsheed
237
392
  'url': z.string().readonly(),
238
393
  'label': z.string().readonly(),
239
394
  'enabled': z.boolean().readonly(),
240
- 'addedAt': z.string().readonly(),
395
+ 'addedAt': z.string().readonly().describe('When the reader added it (ISO-8601). The browser needs this to order the wall and the management list by "when did this arrive": a saved link carries no publication date at all, so without this field it sorts as the oldest thing on the wall — which is exactly where a reader who just added it will not look.'),
241
396
  'fetchedAt': z.string().readonly().optional(),
242
- 'status': z.union([z.literal("ok"), z.literal("error"), z.literal("fetching")]).readonly().optional(),
397
+ 'status': z.union([z.literal("error"), z.literal("ok"), z.literal("fetching")]).readonly().optional(),
243
398
  'error': z.string().readonly().optional(),
244
399
  'truncated': z.boolean().readonly().optional(),
245
400
  'hasBody': z.boolean().readonly(),
246
401
  'failure': z.object({
247
- 'code': z.union([z.literal("unreadable"), z.literal("empty"), z.literal("blocked"), z.literal("login"), z.literal("unsupported-type"), z.literal("redirected"), z.literal("unreachable"), z.literal("http")]).readonly(),
402
+ 'code': z.union([z.literal("blocked"), z.literal("http"), z.literal("unreadable"), z.literal("empty"), z.literal("login"), z.literal("unsupported-type"), z.literal("redirected"), z.literal("unreachable")]).readonly(),
248
403
  'message': z.string().readonly(),
249
- }).readonly().optional(),
250
- 'resolvedFrom': z.string().readonly().optional(),
404
+ }).readonly().optional().describe('Present when this source has no previewable body (see {@link ReaderPreviewFailure}).'),
405
+ 'resolvedFrom': z.string().readonly().optional().describe('The URL the reader pasted, when the source was resolved to a canonical version (see {@link ReaderSource.resolvedFrom}).'),
251
406
  })),
252
407
  }))
253
408
  let _khorsheed_dsh_reader_reader_listTags_result$schema$value
254
409
  const _khorsheed_dsh_reader_reader_listTags_result$schema = () => (_khorsheed_dsh_reader_reader_listTags_result$schema$value ??= z.object({
255
410
  'tags': z.array(z.object({
256
- 'id': z.string().readonly(),
257
- 'name': z.string().readonly(),
411
+ 'id': z.string().readonly().describe('Stable id — renaming a tag must not rewrite every entry that carries it.'),
412
+ 'name': z.string().readonly().describe('The reader-facing name, unique case-insensitively.'),
258
413
  'createdAt': z.string().readonly(),
259
414
  })),
260
415
  'counts': z.record(z.string(), z.number()),
261
416
  }))
417
+ let _khorsheed_dsh_reader_reader_localTranscript_parameter_0$schema$value
418
+ const _khorsheed_dsh_reader_reader_localTranscript_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_localTranscript_parameter_0$schema$value ??= z.object({
419
+ 'entryId': z.string(),
420
+ }))
421
+ let _khorsheed_dsh_reader_reader_localTranscript_result$schema$value
422
+ const _khorsheed_dsh_reader_reader_localTranscript_result$schema = () => (_khorsheed_dsh_reader_reader_localTranscript_result$schema$value ??= z.object({
423
+ 'entryId': z.string().readonly(),
424
+ 'state': z.union([z.literal("failed"), z.literal("unavailable"), z.literal("done"), z.literal("idle"), z.literal("queued"), z.literal("fetching"), z.literal("needs-models"), z.literal("transcribing"), z.literal("speakers")]).readonly(),
425
+ 'progress': z.number().readonly().optional().describe('0–1 across fetching the audio and transcribing it.'),
426
+ 'ahead': z.number().readonly().optional().describe('Jobs ahead in the engine\'s queue.'),
427
+ 'bytes': z.number().readonly().optional().describe('Bytes of speech models still to download (`needs-models`).'),
428
+ 'html': z.string().readonly().optional().describe('The transcript so far (or in full, once `done`).'),
429
+ 'language': z.string().readonly().optional().describe('The language the transcript is in, once known.'),
430
+ 'speakers': z.number().readonly().optional().describe('How many voices the transcript has, once the speakers pass settled it.'),
431
+ 'error': z.string().readonly().optional(),
432
+ }))
433
+ let _khorsheed_dsh_reader_reader_markSynced_parameter_0$schema$value
434
+ const _khorsheed_dsh_reader_reader_markSynced_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_markSynced_parameter_0$schema$value ??= z.object({
435
+ 'entryId': z.string(),
436
+ 'noteId': z.string().optional(),
437
+ 'discussionId': z.string().optional(),
438
+ 'canvasId': z.string(),
439
+ 'cardId': z.string(),
440
+ 'canvasTitle': z.string(),
441
+ }))
442
+ let _khorsheed_dsh_reader_reader_markSynced_result$schema$value
443
+ const _khorsheed_dsh_reader_reader_markSynced_result$schema = () => (_khorsheed_dsh_reader_reader_markSynced_result$schema$value ??= z.union([z.literal("not-found"), z.literal("ok"), z.literal("empty"), z.literal("full")]))
444
+ let _khorsheed_dsh_reader_reader_mediaStates_parameter_0$schema$value
445
+ const _khorsheed_dsh_reader_reader_mediaStates_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_mediaStates_parameter_0$schema$value ??= z.object({
446
+ 'entryIds': z.array(z.string()),
447
+ }))
448
+ let _khorsheed_dsh_reader_reader_mediaStates_result$schema$value
449
+ const _khorsheed_dsh_reader_reader_mediaStates_result$schema = () => (_khorsheed_dsh_reader_reader_mediaStates_result$schema$value ??= z.object({
450
+ 'engine': z.boolean().readonly(),
451
+ 'states': z.record(z.string(), z.object({
452
+ 'state': z.union([z.literal("failed"), z.literal("none"), z.literal("local"), z.literal("queued"), z.literal("fetching"), z.literal("platform"), z.literal("transcribing")]).readonly(),
453
+ 'progress': z.number().readonly().optional().describe('0–1, while transcribing.'),
454
+ 'ahead': z.number().readonly().optional().describe('Jobs ahead in the engine\'s queue, while queued.'),
455
+ })).readonly().readonly(),
456
+ }))
457
+ let _khorsheed_dsh_reader_reader_mediaTranscript_parameter_0$schema$value
458
+ const _khorsheed_dsh_reader_reader_mediaTranscript_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_mediaTranscript_parameter_0$schema$value ??= z.object({
459
+ 'entryId': z.string(),
460
+ 'url': z.string(),
461
+ }))
462
+ let _khorsheed_dsh_reader_reader_mediaTranscript_result$schema$value
463
+ const _khorsheed_dsh_reader_reader_mediaTranscript_result$schema = () => (_khorsheed_dsh_reader_reader_mediaTranscript_result$schema$value ??= z.object({
464
+ 'entryId': z.string(),
465
+ 'html': z.string().optional(),
466
+ 'captions': z.union([z.literal("failed"), z.literal("none"), z.literal("platform")]),
467
+ 'language': z.string().optional(),
468
+ 'error': z.string().optional(),
469
+ }))
470
+ let _khorsheed_dsh_reader_reader_nameSpeaker_parameter_0$schema$value
471
+ const _khorsheed_dsh_reader_reader_nameSpeaker_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_nameSpeaker_parameter_0$schema$value ??= z.object({
472
+ 'entryId': z.string(),
473
+ 'speaker': z.number(),
474
+ 'name': z.string(),
475
+ }))
476
+ let _khorsheed_dsh_reader_reader_nameSpeaker_result$schema$value
477
+ const _khorsheed_dsh_reader_reader_nameSpeaker_result$schema = () => (_khorsheed_dsh_reader_reader_nameSpeaker_result$schema$value ??= z.record(z.string(), z.string()))
478
+ let _khorsheed_dsh_reader_reader_noteCounts_result$schema$value
479
+ const _khorsheed_dsh_reader_reader_noteCounts_result$schema = () => (_khorsheed_dsh_reader_reader_noteCounts_result$schema$value ??= z.object({
480
+ 'counts': z.record(z.string(), z.number()),
481
+ }))
482
+ let _khorsheed_dsh_reader_reader_polish_parameter_0$schema$value
483
+ const _khorsheed_dsh_reader_reader_polish_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_polish_parameter_0$schema$value ??= z.object({
484
+ 'entryId': z.string(),
485
+ }))
486
+ let _khorsheed_dsh_reader_reader_polish_result$schema$value
487
+ const _khorsheed_dsh_reader_reader_polish_result$schema = () => (_khorsheed_dsh_reader_reader_polish_result$schema$value ??= z.union([z.literal(null), z.object({
488
+ 'total': z.number().readonly().describe('Paragraphs in the article (the ¶ numbering the model read).'),
489
+ 'done': z.number().readonly(),
490
+ 'paragraphs': z.record(z.string(), z.string()).readonly().readonly().describe('¶ number (1-based, as a string key) → the agent\'s translation.'),
491
+ 'off': z.array(z.number()).readonly().describe('Paragraphs the reader turned back to the machine translation.'),
492
+ 'updatedAt': z.string().readonly(),
493
+ 'complete': z.boolean().readonly(),
494
+ })]))
262
495
  let _khorsheed_dsh_reader_reader_pruneTags_result$schema$value
263
496
  const _khorsheed_dsh_reader_reader_pruneTags_result$schema = () => (_khorsheed_dsh_reader_reader_pruneTags_result$schema$value ??= z.object({
264
497
  'removed': z.number(),
@@ -271,6 +504,17 @@ const _khorsheed_dsh_reader_reader_quoteToSideChat_parameter_0$schema = () => (_
271
504
  }))
272
505
  let _khorsheed_dsh_reader_reader_quoteToSideChat_result$schema$value
273
506
  const _khorsheed_dsh_reader_reader_quoteToSideChat_result$schema = () => (_khorsheed_dsh_reader_reader_quoteToSideChat_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("ok")]))
507
+ let _khorsheed_dsh_reader_reader_recordDiscussion_parameter_0$schema$value
508
+ const _khorsheed_dsh_reader_reader_recordDiscussion_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_recordDiscussion_parameter_0$schema$value ??= z.object({
509
+ 'entryId': z.string().readonly(),
510
+ 'title': z.string().readonly(),
511
+ 'url': z.string().readonly().optional(),
512
+ 'source': z.string().readonly().optional(),
513
+ 'sessionId': z.string(),
514
+ 'sessionTitle': z.string().optional(),
515
+ }))
516
+ let _khorsheed_dsh_reader_reader_recordDiscussion_result$schema$value
517
+ const _khorsheed_dsh_reader_reader_recordDiscussion_result$schema = () => (_khorsheed_dsh_reader_reader_recordDiscussion_result$schema$value ??= z.union([z.literal("ok"), z.literal("empty")]))
274
518
  let _khorsheed_dsh_reader_reader_recordRead_parameter_0$schema$value
275
519
  const _khorsheed_dsh_reader_reader_recordRead_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_recordRead_parameter_0$schema$value ??= z.object({
276
520
  'entryId': z.string(),
@@ -298,12 +542,12 @@ let _khorsheed_dsh_reader_reader_rememberSentences_parameter_0$schema$value
298
542
  const _khorsheed_dsh_reader_reader_rememberSentences_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_rememberSentences_parameter_0$schema$value ??= z.object({
299
543
  'pair': z.string(),
300
544
  'entries': z.array(z.object({
301
- 'hash': z.string().readonly(),
545
+ 'hash': z.string().readonly().describe('The client\'s `translationHash(source)`, stored opaquely.'),
302
546
  'source': z.string().readonly(),
303
547
  'target': z.string().readonly(),
304
548
  })),
305
549
  'recalled': z.array(z.object({
306
- 'hash': z.string().readonly(),
550
+ 'hash': z.string().readonly().describe('The client\'s `translationHash(source)`, stored opaquely.'),
307
551
  'source': z.string().readonly(),
308
552
  'target': z.string().readonly(),
309
553
  })).optional(),
@@ -320,14 +564,14 @@ const _khorsheed_dsh_reader_reader_removeSource_parameter_0$schema = () => (_kho
320
564
  'entryIds': z.array(z.string()).optional(),
321
565
  }))
322
566
  let _khorsheed_dsh_reader_reader_removeSource_result$schema$value
323
- const _khorsheed_dsh_reader_reader_removeSource_result$schema = () => (_khorsheed_dsh_reader_reader_removeSource_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("ok"), z.literal("not-found"), z.literal("invalid-url"), z.literal("invalid-time"), z.literal("duplicate")]))
567
+ const _khorsheed_dsh_reader_reader_removeSource_result$schema = () => (_khorsheed_dsh_reader_reader_removeSource_result$schema$value ??= z.union([z.literal("not-found"), z.literal("unavailable"), z.literal("duplicate"), z.literal("ok"), z.literal("invalid-url"), z.literal("invalid-time")]))
324
568
  let _khorsheed_dsh_reader_reader_renameTag_parameter_0$schema$value
325
569
  const _khorsheed_dsh_reader_reader_renameTag_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_renameTag_parameter_0$schema$value ??= z.object({
326
570
  'id': z.string(),
327
571
  'name': z.string(),
328
572
  }))
329
573
  let _khorsheed_dsh_reader_reader_renameTag_result$schema$value
330
- const _khorsheed_dsh_reader_reader_renameTag_result$schema = () => (_khorsheed_dsh_reader_reader_renameTag_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("ok"), z.literal("empty"), z.literal("not-found"), z.literal("duplicate"), z.literal("invalid")]))
574
+ const _khorsheed_dsh_reader_reader_renameTag_result$schema = () => (_khorsheed_dsh_reader_reader_renameTag_result$schema$value ??= z.union([z.literal("not-found"), z.literal("unavailable"), z.literal("duplicate"), z.literal("ok"), z.literal("empty"), z.literal("invalid")]))
331
575
  let _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0$schema$value
332
576
  const _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_setCachePolicy_parameter_0$schema$value ??= z.object({
333
577
  'ttlHours': z.number(),
@@ -335,7 +579,64 @@ const _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0$schema = () => (_k
335
579
  'translationBudgetChars': z.number().optional(),
336
580
  }))
337
581
  let _khorsheed_dsh_reader_reader_setCachePolicy_result$schema$value
338
- const _khorsheed_dsh_reader_reader_setCachePolicy_result$schema = () => (_khorsheed_dsh_reader_reader_setCachePolicy_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("ok"), z.literal("empty"), z.literal("not-found"), z.literal("duplicate"), z.literal("invalid")]))
582
+ const _khorsheed_dsh_reader_reader_setCachePolicy_result$schema = () => (_khorsheed_dsh_reader_reader_setCachePolicy_result$schema$value ??= z.union([z.literal("not-found"), z.literal("unavailable"), z.literal("duplicate"), z.literal("ok"), z.literal("empty"), z.literal("invalid")]))
583
+ let _khorsheed_dsh_reader_reader_setPolishOff_parameter_0$schema$value
584
+ const _khorsheed_dsh_reader_reader_setPolishOff_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_setPolishOff_parameter_0$schema$value ??= z.object({
585
+ 'entryId': z.string(),
586
+ 'paragraph': z.number(),
587
+ 'off': z.boolean(),
588
+ }))
589
+ let _khorsheed_dsh_reader_reader_setPolishOff_result$schema$value
590
+ const _khorsheed_dsh_reader_reader_setPolishOff_result$schema = () => (_khorsheed_dsh_reader_reader_setPolishOff_result$schema$value ??= z.union([z.literal(null), z.object({
591
+ 'total': z.number().readonly().describe('Paragraphs in the article (the ¶ numbering the model read).'),
592
+ 'done': z.number().readonly(),
593
+ 'paragraphs': z.record(z.string(), z.string()).readonly().readonly().describe('¶ number (1-based, as a string key) → the agent\'s translation.'),
594
+ 'off': z.array(z.number()).readonly().describe('Paragraphs the reader turned back to the machine translation.'),
595
+ 'updatedAt': z.string().readonly(),
596
+ 'complete': z.boolean().readonly(),
597
+ })]))
598
+ let _khorsheed_dsh_reader_reader_snapshotEntry_parameter_0$schema$value
599
+ const _khorsheed_dsh_reader_reader_snapshotEntry_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_snapshotEntry_parameter_0$schema$value ??= z.object({
600
+ 'entryId': z.string().readonly(),
601
+ 'title': z.string().readonly(),
602
+ 'url': z.string().readonly().optional(),
603
+ 'source': z.string().readonly().optional(),
604
+ 'paragraphs': z.array(z.string()),
605
+ }))
606
+ let _khorsheed_dsh_reader_reader_snapshotEntry_result$schema$value
607
+ const _khorsheed_dsh_reader_reader_snapshotEntry_result$schema = () => (_khorsheed_dsh_reader_reader_snapshotEntry_result$schema$value ??= z.union([z.literal("ok"), z.literal("empty")]))
608
+ let _khorsheed_dsh_reader_reader_speakerNames_parameter_0$schema$value
609
+ const _khorsheed_dsh_reader_reader_speakerNames_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_speakerNames_parameter_0$schema$value ??= z.object({
610
+ 'entryId': z.string(),
611
+ }))
612
+ let _khorsheed_dsh_reader_reader_speakerNames_result$schema$value
613
+ const _khorsheed_dsh_reader_reader_speakerNames_result$schema = () => (_khorsheed_dsh_reader_reader_speakerNames_result$schema$value ??= z.record(z.string(), z.string()))
614
+ let _khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0$schema$value
615
+ const _khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0$schema$value ??= z.object({
616
+ 'entryId': z.string(),
617
+ 'url': z.string(),
618
+ 'media': z.object({
619
+ 'kind': z.union([z.literal("video"), z.literal("audio")]).readonly(),
620
+ 'provider': z.union([z.literal("youtube"), z.literal("bilibili"), z.literal("xiaoyuzhou"), z.literal("enclosure")]).readonly(),
621
+ 'ref': z.string().readonly().describe('The platform\'s id (YouTube video id, Bilibili BV id) or the audio URL.'),
622
+ 'durationSec': z.number().readonly().optional(),
623
+ 'thumbnail': z.string().readonly().optional(),
624
+ }),
625
+ 'title': z.string().optional(),
626
+ 'confirmModels': z.boolean().optional(),
627
+ }))
628
+ let _khorsheed_dsh_reader_reader_startLocalTranscript_result$schema$value
629
+ const _khorsheed_dsh_reader_reader_startLocalTranscript_result$schema = () => (_khorsheed_dsh_reader_reader_startLocalTranscript_result$schema$value ??= z.object({
630
+ 'entryId': z.string().readonly(),
631
+ 'state': z.union([z.literal("failed"), z.literal("unavailable"), z.literal("done"), z.literal("idle"), z.literal("queued"), z.literal("fetching"), z.literal("needs-models"), z.literal("transcribing"), z.literal("speakers")]).readonly(),
632
+ 'progress': z.number().readonly().optional().describe('0–1 across fetching the audio and transcribing it.'),
633
+ 'ahead': z.number().readonly().optional().describe('Jobs ahead in the engine\'s queue.'),
634
+ 'bytes': z.number().readonly().optional().describe('Bytes of speech models still to download (`needs-models`).'),
635
+ 'html': z.string().readonly().optional().describe('The transcript so far (or in full, once `done`).'),
636
+ 'language': z.string().readonly().optional().describe('The language the transcript is in, once known.'),
637
+ 'speakers': z.number().readonly().optional().describe('How many voices the transcript has, once the speakers pass settled it.'),
638
+ 'error': z.string().readonly().optional(),
639
+ }))
339
640
  let _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0$schema$value
340
641
  const _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_storeEntryBody_parameter_0$schema$value ??= z.object({
341
642
  'entryId': z.string(),
@@ -344,21 +645,21 @@ const _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0$schema = () => (_k
344
645
  'truncated': z.boolean().optional(),
345
646
  'scriptFigures': z.number().optional(),
346
647
  'bodyHash': z.string().optional(),
347
- 'title': z.string().optional(),
348
- 'excerpt': z.string().optional(),
648
+ 'title': z.string().optional().describe('The article\'s own title, as extracted — the saved link\'s card upgrade.'),
649
+ 'excerpt': z.string().optional().describe('A short excerpt (abstract / first paragraph), with the title.'),
349
650
  }))
350
651
  let _khorsheed_dsh_reader_reader_storeEntryBody_result$schema$value
351
652
  const _khorsheed_dsh_reader_reader_storeEntryBody_result$schema = () => (_khorsheed_dsh_reader_reader_storeEntryBody_result$schema$value ??= z.object({
352
653
  'entryId': z.string().readonly(),
353
- 'cached': z.boolean().readonly(),
354
- 'fresh': z.boolean().readonly(),
355
- 'fromFeed': z.boolean().readonly(),
654
+ 'cached': z.boolean().readonly().describe('True when this body is a cached fetch rather than the feed\'s own payload.'),
655
+ 'fresh': z.boolean().readonly().describe('False when the cache\'s deadline has passed: the view offers the fetch.'),
656
+ 'fromFeed': z.boolean().readonly().describe('True when the feed\'s payload already carries full text for this entry.'),
356
657
  'html': z.string().readonly().optional(),
357
658
  'fetchedAt': z.string().readonly().optional(),
358
659
  'truncated': z.boolean().readonly().optional(),
359
- 'scriptFigures': z.number().readonly().optional(),
360
- 'rendered': z.boolean().readonly().optional(),
361
- 'error': z.string().readonly().optional(),
660
+ 'scriptFigures': z.number().readonly().optional().describe('Figures this page draws with scripts — the detail view says so.'),
661
+ 'rendered': z.boolean().readonly().optional().describe('True when this body came from a rendered fetch (the「重新抓取」route reads it).'),
662
+ 'error': z.string().readonly().optional().describe('Why a fetch could not produce a body, when one was attempted.'),
362
663
  }))
363
664
  let _khorsheed_dsh_reader_reader_tagEntry_parameter_0$schema$value
364
665
  const _khorsheed_dsh_reader_reader_tagEntry_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_tagEntry_parameter_0$schema$value ??= z.object({
@@ -367,7 +668,15 @@ const _khorsheed_dsh_reader_reader_tagEntry_parameter_0$schema = () => (_khorshe
367
668
  'on': z.boolean(),
368
669
  }))
369
670
  let _khorsheed_dsh_reader_reader_tagEntry_result$schema$value
370
- const _khorsheed_dsh_reader_reader_tagEntry_result$schema = () => (_khorsheed_dsh_reader_reader_tagEntry_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("ok"), z.literal("empty"), z.literal("not-found"), z.literal("duplicate"), z.literal("invalid")]))
671
+ const _khorsheed_dsh_reader_reader_tagEntry_result$schema = () => (_khorsheed_dsh_reader_reader_tagEntry_result$schema$value ??= z.union([z.literal("not-found"), z.literal("unavailable"), z.literal("duplicate"), z.literal("ok"), z.literal("empty"), z.literal("invalid")]))
672
+ let _khorsheed_dsh_reader_reader_updateNote_parameter_0$schema$value
673
+ const _khorsheed_dsh_reader_reader_updateNote_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_updateNote_parameter_0$schema$value ??= z.object({
674
+ 'entryId': z.string(),
675
+ 'noteId': z.string(),
676
+ 'comment': z.string(),
677
+ }))
678
+ let _khorsheed_dsh_reader_reader_updateNote_result$schema$value
679
+ const _khorsheed_dsh_reader_reader_updateNote_result$schema = () => (_khorsheed_dsh_reader_reader_updateNote_result$schema$value ??= z.union([z.literal("not-found"), z.literal("ok"), z.literal("empty"), z.literal("full")]))
371
680
  let _khorsheed_dsh_reader_reader_updateSource_parameter_0$schema$value
372
681
  const _khorsheed_dsh_reader_reader_updateSource_parameter_0$schema = () => (_khorsheed_dsh_reader_reader_updateSource_parameter_0$schema$value ??= z.object({
373
682
  'id': z.string(),
@@ -377,27 +686,359 @@ const _khorsheed_dsh_reader_reader_updateSource_parameter_0$schema = () => (_kho
377
686
  'timeOfDay': z.string().optional(),
378
687
  }))
379
688
  let _khorsheed_dsh_reader_reader_updateSource_result$schema$value
380
- const _khorsheed_dsh_reader_reader_updateSource_result$schema = () => (_khorsheed_dsh_reader_reader_updateSource_result$schema$value ??= z.union([z.literal("unavailable"), z.literal("ok"), z.literal("not-found"), z.literal("invalid-url"), z.literal("invalid-time"), z.literal("duplicate")]))
689
+ const _khorsheed_dsh_reader_reader_updateSource_result$schema = () => (_khorsheed_dsh_reader_reader_updateSource_result$schema$value ??= z.union([z.literal("not-found"), z.literal("unavailable"), z.literal("duplicate"), z.literal("ok"), z.literal("invalid-url"), z.literal("invalid-time")]))
690
+ let _khorsheed_dsh_reader_reader_addNote_parameter_0_strict$schema$value
691
+ const _khorsheed_dsh_reader_reader_addNote_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_addNote_parameter_0_strict$schema$value ??= z.strictObject({
692
+ 'block': z.number().readonly(),
693
+ 'start': z.number().readonly().optional(),
694
+ 'quote': z.string().readonly(),
695
+ 'translated': z.string().readonly().optional(),
696
+ 'comment': z.string().readonly().optional(),
697
+ 'time': z.number().readonly().optional(),
698
+ 'entryId': z.string().readonly(),
699
+ 'title': z.string().readonly(),
700
+ 'url': z.string().readonly().optional(),
701
+ 'source': z.string().readonly().optional(),
702
+ }))
703
+ let _khorsheed_dsh_reader_reader_addReply_parameter_0_strict$schema$value
704
+ const _khorsheed_dsh_reader_reader_addReply_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_addReply_parameter_0_strict$schema$value ??= z.strictObject({
705
+ 'entryId': z.string(),
706
+ 'noteId': z.string(),
707
+ 'text': z.string(),
708
+ }))
709
+ let _khorsheed_dsh_reader_reader_addSource_parameter_0_strict$schema$value
710
+ const _khorsheed_dsh_reader_reader_addSource_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_addSource_parameter_0_strict$schema$value ??= z.strictObject({
711
+ 'url': z.string(),
712
+ 'label': z.string().optional(),
713
+ }))
714
+ let _khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0_strict$schema$value
715
+ const _khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0_strict$schema$value ??= z.strictObject({
716
+ 'entryId': z.string(),
717
+ 'force': z.boolean(),
718
+ }))
719
+ let _khorsheed_dsh_reader_reader_createTag_parameter_0_strict$schema$value
720
+ const _khorsheed_dsh_reader_reader_createTag_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_createTag_parameter_0_strict$schema$value ??= z.strictObject({
721
+ 'name': z.string(),
722
+ }))
723
+ let _khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0_strict$schema$value
724
+ const _khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0_strict$schema$value ??= z.strictObject({
725
+ 'entryId': z.string(),
726
+ 'discussionId': z.string(),
727
+ }))
728
+ let _khorsheed_dsh_reader_reader_deleteNote_parameter_0_strict$schema$value
729
+ const _khorsheed_dsh_reader_reader_deleteNote_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_deleteNote_parameter_0_strict$schema$value ??= z.strictObject({
730
+ 'entryId': z.string(),
731
+ 'noteId': z.string(),
732
+ }))
733
+ let _khorsheed_dsh_reader_reader_deleteTag_parameter_0_strict$schema$value
734
+ const _khorsheed_dsh_reader_reader_deleteTag_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_deleteTag_parameter_0_strict$schema$value ??= z.strictObject({
735
+ 'id': z.string(),
736
+ }))
737
+ let _khorsheed_dsh_reader_reader_editReply_parameter_0_strict$schema$value
738
+ const _khorsheed_dsh_reader_reader_editReply_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_editReply_parameter_0_strict$schema$value ??= z.strictObject({
739
+ 'entryId': z.string(),
740
+ 'noteId': z.string(),
741
+ 'index': z.number(),
742
+ 'text': z.string(),
743
+ }))
744
+ let _khorsheed_dsh_reader_reader_entryFetchStates_parameter_0_strict$schema$value
745
+ const _khorsheed_dsh_reader_reader_entryFetchStates_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_entryFetchStates_parameter_0_strict$schema$value ??= z.strictObject({
746
+ 'entryIds': z.array(z.string()),
747
+ }))
748
+ let _khorsheed_dsh_reader_reader_entryNotes_parameter_0_strict$schema$value
749
+ const _khorsheed_dsh_reader_reader_entryNotes_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_entryNotes_parameter_0_strict$schema$value ??= z.strictObject({
750
+ 'entryId': z.string(),
751
+ }))
752
+ let _khorsheed_dsh_reader_reader_entryTags_parameter_0_strict$schema$value
753
+ const _khorsheed_dsh_reader_reader_entryTags_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_entryTags_parameter_0_strict$schema$value ??= z.strictObject({
754
+ 'entryId': z.string(),
755
+ }))
756
+ let _khorsheed_dsh_reader_reader_fetchEntryBody_parameter_0_strict$schema$value
757
+ const _khorsheed_dsh_reader_reader_fetchEntryBody_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_fetchEntryBody_parameter_0_strict$schema$value ??= z.strictObject({
758
+ 'entryId': z.string(),
759
+ 'url': z.string(),
760
+ }))
761
+ let _khorsheed_dsh_reader_reader_fetchImage_parameter_0_strict$schema$value
762
+ const _khorsheed_dsh_reader_reader_fetchImage_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_fetchImage_parameter_0_strict$schema$value ??= z.strictObject({
763
+ 'url': z.string(),
764
+ }))
765
+ let _khorsheed_dsh_reader_reader_getBodies_parameter_0_strict$schema$value
766
+ const _khorsheed_dsh_reader_reader_getBodies_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_getBodies_parameter_0_strict$schema$value ??= z.strictObject({
767
+ 'ids': z.array(z.string()),
768
+ }))
769
+ let _khorsheed_dsh_reader_reader_getEntryBody_parameter_0_strict$schema$value
770
+ const _khorsheed_dsh_reader_reader_getEntryBody_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_getEntryBody_parameter_0_strict$schema$value ??= z.strictObject({
771
+ 'entryId': z.string(),
772
+ 'url': z.string(),
773
+ 'feedHtml': z.string().optional(),
774
+ }))
775
+ let _khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0_strict$schema$value
776
+ const _khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0_strict$schema$value ??= z.strictObject({
777
+ 'entryId': z.string(),
778
+ }))
779
+ let _khorsheed_dsh_reader_reader_getRawBody_parameter_0_strict$schema$value
780
+ const _khorsheed_dsh_reader_reader_getRawBody_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_getRawBody_parameter_0_strict$schema$value ??= z.strictObject({
781
+ 'entryId': z.string(),
782
+ }))
783
+ let _khorsheed_dsh_reader_reader_getSentenceTranslations_parameter_0_strict$schema$value
784
+ const _khorsheed_dsh_reader_reader_getSentenceTranslations_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_getSentenceTranslations_parameter_0_strict$schema$value ??= z.strictObject({
785
+ 'pair': z.string(),
786
+ 'hashes': z.array(z.string()),
787
+ }))
788
+ let _khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0_strict$schema$value
789
+ const _khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0_strict$schema$value ??= z.strictObject({
790
+ 'entries': z.array(z.strictObject({
791
+ 'entryId': z.string(),
792
+ 'url': z.string(),
793
+ 'label': z.string(),
794
+ 'hasBody': z.boolean(),
795
+ })),
796
+ 'limit': z.number().optional(),
797
+ }))
798
+ let _khorsheed_dsh_reader_reader_localTranscript_parameter_0_strict$schema$value
799
+ const _khorsheed_dsh_reader_reader_localTranscript_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_localTranscript_parameter_0_strict$schema$value ??= z.strictObject({
800
+ 'entryId': z.string(),
801
+ }))
802
+ let _khorsheed_dsh_reader_reader_markSynced_parameter_0_strict$schema$value
803
+ const _khorsheed_dsh_reader_reader_markSynced_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_markSynced_parameter_0_strict$schema$value ??= z.strictObject({
804
+ 'entryId': z.string(),
805
+ 'noteId': z.string().optional(),
806
+ 'discussionId': z.string().optional(),
807
+ 'canvasId': z.string(),
808
+ 'cardId': z.string(),
809
+ 'canvasTitle': z.string(),
810
+ }))
811
+ let _khorsheed_dsh_reader_reader_mediaStates_parameter_0_strict$schema$value
812
+ const _khorsheed_dsh_reader_reader_mediaStates_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_mediaStates_parameter_0_strict$schema$value ??= z.strictObject({
813
+ 'entryIds': z.array(z.string()),
814
+ }))
815
+ let _khorsheed_dsh_reader_reader_mediaTranscript_parameter_0_strict$schema$value
816
+ const _khorsheed_dsh_reader_reader_mediaTranscript_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_mediaTranscript_parameter_0_strict$schema$value ??= z.strictObject({
817
+ 'entryId': z.string(),
818
+ 'url': z.string(),
819
+ }))
820
+ let _khorsheed_dsh_reader_reader_nameSpeaker_parameter_0_strict$schema$value
821
+ const _khorsheed_dsh_reader_reader_nameSpeaker_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_nameSpeaker_parameter_0_strict$schema$value ??= z.strictObject({
822
+ 'entryId': z.string(),
823
+ 'speaker': z.number(),
824
+ 'name': z.string(),
825
+ }))
826
+ let _khorsheed_dsh_reader_reader_polish_parameter_0_strict$schema$value
827
+ const _khorsheed_dsh_reader_reader_polish_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_polish_parameter_0_strict$schema$value ??= z.strictObject({
828
+ 'entryId': z.string(),
829
+ }))
830
+ let _khorsheed_dsh_reader_reader_quoteToSideChat_parameter_0_strict$schema$value
831
+ const _khorsheed_dsh_reader_reader_quoteToSideChat_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_quoteToSideChat_parameter_0_strict$schema$value ??= z.strictObject({
832
+ 'contextKey': z.string(),
833
+ 'label': z.string(),
834
+ 'text': z.string(),
835
+ }))
836
+ let _khorsheed_dsh_reader_reader_recordDiscussion_parameter_0_strict$schema$value
837
+ const _khorsheed_dsh_reader_reader_recordDiscussion_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_recordDiscussion_parameter_0_strict$schema$value ??= z.strictObject({
838
+ 'entryId': z.string().readonly(),
839
+ 'title': z.string().readonly(),
840
+ 'url': z.string().readonly().optional(),
841
+ 'source': z.string().readonly().optional(),
842
+ 'sessionId': z.string(),
843
+ 'sessionTitle': z.string().optional(),
844
+ }))
845
+ let _khorsheed_dsh_reader_reader_recordRead_parameter_0_strict$schema$value
846
+ const _khorsheed_dsh_reader_reader_recordRead_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_recordRead_parameter_0_strict$schema$value ??= z.strictObject({
847
+ 'entryId': z.string(),
848
+ 'sourceId': z.string(),
849
+ 'title': z.string(),
850
+ 'url': z.string().optional(),
851
+ }))
852
+ let _khorsheed_dsh_reader_reader_refresh_parameter_0_strict$schema$value
853
+ const _khorsheed_dsh_reader_reader_refresh_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_refresh_parameter_0_strict$schema$value ??= z.strictObject({
854
+ 'ids': z.array(z.string()).optional(),
855
+ }))
856
+ let _khorsheed_dsh_reader_reader_rememberSentences_parameter_0_strict$schema$value
857
+ const _khorsheed_dsh_reader_reader_rememberSentences_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_rememberSentences_parameter_0_strict$schema$value ??= z.strictObject({
858
+ 'pair': z.string(),
859
+ 'entries': z.array(z.strictObject({
860
+ 'hash': z.string().readonly().describe('The client\'s `translationHash(source)`, stored opaquely.'),
861
+ 'source': z.string().readonly(),
862
+ 'target': z.string().readonly(),
863
+ })),
864
+ 'recalled': z.array(z.strictObject({
865
+ 'hash': z.string().readonly().describe('The client\'s `translationHash(source)`, stored opaquely.'),
866
+ 'source': z.string().readonly(),
867
+ 'target': z.string().readonly(),
868
+ })).optional(),
869
+ 'entryId': z.string().optional(),
870
+ 'bodyHash': z.string().optional(),
871
+ }))
872
+ let _khorsheed_dsh_reader_reader_removeSource_parameter_0_strict$schema$value
873
+ const _khorsheed_dsh_reader_reader_removeSource_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_removeSource_parameter_0_strict$schema$value ??= z.strictObject({
874
+ 'id': z.string(),
875
+ 'entryIds': z.array(z.string()).optional(),
876
+ }))
877
+ let _khorsheed_dsh_reader_reader_renameTag_parameter_0_strict$schema$value
878
+ const _khorsheed_dsh_reader_reader_renameTag_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_renameTag_parameter_0_strict$schema$value ??= z.strictObject({
879
+ 'id': z.string(),
880
+ 'name': z.string(),
881
+ }))
882
+ let _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0_strict$schema$value
883
+ const _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_setCachePolicy_parameter_0_strict$schema$value ??= z.strictObject({
884
+ 'ttlHours': z.number(),
885
+ 'maxEntries': z.number().optional(),
886
+ 'translationBudgetChars': z.number().optional(),
887
+ }))
888
+ let _khorsheed_dsh_reader_reader_setPolishOff_parameter_0_strict$schema$value
889
+ const _khorsheed_dsh_reader_reader_setPolishOff_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_setPolishOff_parameter_0_strict$schema$value ??= z.strictObject({
890
+ 'entryId': z.string(),
891
+ 'paragraph': z.number(),
892
+ 'off': z.boolean(),
893
+ }))
894
+ let _khorsheed_dsh_reader_reader_snapshotEntry_parameter_0_strict$schema$value
895
+ const _khorsheed_dsh_reader_reader_snapshotEntry_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_snapshotEntry_parameter_0_strict$schema$value ??= z.strictObject({
896
+ 'entryId': z.string().readonly(),
897
+ 'title': z.string().readonly(),
898
+ 'url': z.string().readonly().optional(),
899
+ 'source': z.string().readonly().optional(),
900
+ 'paragraphs': z.array(z.string()),
901
+ }))
902
+ let _khorsheed_dsh_reader_reader_speakerNames_parameter_0_strict$schema$value
903
+ const _khorsheed_dsh_reader_reader_speakerNames_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_speakerNames_parameter_0_strict$schema$value ??= z.strictObject({
904
+ 'entryId': z.string(),
905
+ }))
906
+ let _khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0_strict$schema$value
907
+ const _khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0_strict$schema$value ??= z.strictObject({
908
+ 'entryId': z.string(),
909
+ 'url': z.string(),
910
+ 'media': z.strictObject({
911
+ 'kind': z.union([z.literal("video"), z.literal("audio")]).readonly(),
912
+ 'provider': z.union([z.literal("youtube"), z.literal("bilibili"), z.literal("xiaoyuzhou"), z.literal("enclosure")]).readonly(),
913
+ 'ref': z.string().readonly().describe('The platform\'s id (YouTube video id, Bilibili BV id) or the audio URL.'),
914
+ 'durationSec': z.number().readonly().optional(),
915
+ 'thumbnail': z.string().readonly().optional(),
916
+ }),
917
+ 'title': z.string().optional(),
918
+ 'confirmModels': z.boolean().optional(),
919
+ }))
920
+ let _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0_strict$schema$value
921
+ const _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_storeEntryBody_parameter_0_strict$schema$value ??= z.strictObject({
922
+ 'entryId': z.string(),
923
+ 'url': z.string(),
924
+ 'html': z.string(),
925
+ 'truncated': z.boolean().optional(),
926
+ 'scriptFigures': z.number().optional(),
927
+ 'bodyHash': z.string().optional(),
928
+ 'title': z.string().optional().describe('The article\'s own title, as extracted — the saved link\'s card upgrade.'),
929
+ 'excerpt': z.string().optional().describe('A short excerpt (abstract / first paragraph), with the title.'),
930
+ }))
931
+ let _khorsheed_dsh_reader_reader_tagEntry_parameter_0_strict$schema$value
932
+ const _khorsheed_dsh_reader_reader_tagEntry_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_tagEntry_parameter_0_strict$schema$value ??= z.strictObject({
933
+ 'entryId': z.string(),
934
+ 'tagId': z.string(),
935
+ 'on': z.boolean(),
936
+ }))
937
+ let _khorsheed_dsh_reader_reader_updateNote_parameter_0_strict$schema$value
938
+ const _khorsheed_dsh_reader_reader_updateNote_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_updateNote_parameter_0_strict$schema$value ??= z.strictObject({
939
+ 'entryId': z.string(),
940
+ 'noteId': z.string(),
941
+ 'comment': z.string(),
942
+ }))
943
+ let _khorsheed_dsh_reader_reader_updateSource_parameter_0_strict$schema$value
944
+ const _khorsheed_dsh_reader_reader_updateSource_parameter_0_strict$schema = () => (_khorsheed_dsh_reader_reader_updateSource_parameter_0_strict$schema$value ??= z.strictObject({
945
+ 'id': z.string(),
946
+ 'enabled': z.boolean().optional(),
947
+ 'label': z.string().optional(),
948
+ 'url': z.string().optional(),
949
+ 'timeOfDay': z.string().optional(),
950
+ }))
381
951
 
382
- export const TYPERT_REMOTE = {
952
+ export const TYPERT_REMOTE = createTypertRemoteInfo({
383
953
  package: '@khorsheed/dsh-reader',
384
- descriptors: [
385
- {
386
- id: '@khorsheed/dsh-reader#reader/addSource',
954
+ methods: {
955
+ 'reader/addNote': {
956
+ service: 'readerRemote',
957
+ description: 'Keep one excerpt (and its comment).',
958
+ invocation: { kind: 'direct' },
959
+ parameters: [
960
+ {
961
+ name: 'request',
962
+ source: 'json',
963
+ codec: {
964
+ mode: 'strict',
965
+ typeSymbol: '@khorsheed/dsh-reader/types#ReaderNoteInput',
966
+ create: _khorsheed_dsh_reader_reader_addNote_parameter_0$schema,
967
+ schema: _khorsheed_dsh_reader_reader_addNote_parameter_0$schema(),
968
+ jsonSchema: {"type":"object","properties":{"block":{"type":"number"},"start":{"type":"number"},"quote":{"type":"string"},"translated":{"type":"string"},"comment":{"type":"string"},"time":{"type":"number"},"entryId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"},"source":{"type":"string"}},"required":["block","quote","entryId","title"],"additionalProperties":true},
969
+ },
970
+ strictCodec: {
971
+ mode: 'strict',
972
+ typeSymbol: '@khorsheed/dsh-reader/types#ReaderNoteInput',
973
+ create: _khorsheed_dsh_reader_reader_addNote_parameter_0_strict$schema,
974
+ schema: _khorsheed_dsh_reader_reader_addNote_parameter_0_strict$schema(),
975
+ jsonSchema: {"type":"object","properties":{"block":{"type":"number"},"start":{"type":"number"},"quote":{"type":"string"},"translated":{"type":"string"},"comment":{"type":"string"},"time":{"type":"number"},"entryId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"},"source":{"type":"string"}},"required":["block","quote","entryId","title"],"additionalProperties":false},
976
+ },
977
+ },
978
+ ],
979
+ result: {
980
+ mode: 'strict',
981
+ typeSymbol: '@khorsheed/dsh-reader#reader/addNote:result',
982
+ create: _khorsheed_dsh_reader_reader_addNote_result$schema,
983
+ schema: _khorsheed_dsh_reader_reader_addNote_result$schema(),
984
+ jsonSchema: {"oneOf":[{"type":"string","enum":["empty","full"]},{"type":"object","properties":{"id":{"type":"string","description":"`n1`, `n2`… per article, never reused — the model cites notes by it."},"anchor":{"type":"object","properties":{"block":{"type":"number"},"start":{"type":"number"},"quote":{"type":"string"},"translated":{"type":"string","description":"The translated text, when the selection was made in the translated view."},"time":{"type":"number","description":"A video / audio transcript paragraph's start (seconds): where ▶ plays from."}},"required":["block","quote"],"additionalProperties":true},"comment":{"type":"string"},"replies":{"type":"array","items":{"type":"object","properties":{"by":{"type":"string","enum":["user","agent"]},"text":{"type":"string"},"sessionId":{"type":"string","description":"The conversation it came from, so the reader can go back to it."},"editedFrom":{"type":"string","const":"agent","description":"Set when the reader rewrote a line the model wrote."},"at":{"type":"string"}},"required":["by","text","at"],"additionalProperties":true},"description":"Conclusions and additions, oldest first."},"syncedTo":{"type":"array","items":{"type":"object","properties":{"canvasId":{"type":"string"},"cardId":{"type":"string"},"canvasTitle":{"type":"string","description":"The canvas's title when it was synced (for the 「已在…」 mark)."},"at":{"type":"string"}},"required":["canvasId","cardId","canvasTitle","at"],"additionalProperties":true},"description":"Canvas cards made from it (a later edit does not reach them)."},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","anchor","createdAt","updatedAt"],"additionalProperties":true}]},
985
+ },
986
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":322,"column":3},
987
+ },
988
+ 'reader/addReply': {
989
+ service: 'readerRemote',
990
+ description: 'Add the reader\'s own line under a note.',
991
+ invocation: { kind: 'direct' },
992
+ parameters: [
993
+ {
994
+ name: 'request',
995
+ source: 'json',
996
+ codec: {
997
+ mode: 'strict',
998
+ typeSymbol: '@khorsheed/dsh-reader#reader/addReply:request',
999
+ create: _khorsheed_dsh_reader_reader_addReply_parameter_0$schema,
1000
+ schema: _khorsheed_dsh_reader_reader_addReply_parameter_0$schema(),
1001
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"},"text":{"type":"string"}},"required":["entryId","noteId","text"],"additionalProperties":true},
1002
+ },
1003
+ strictCodec: {
1004
+ mode: 'strict',
1005
+ typeSymbol: '@khorsheed/dsh-reader#reader/addReply:request',
1006
+ create: _khorsheed_dsh_reader_reader_addReply_parameter_0_strict$schema,
1007
+ schema: _khorsheed_dsh_reader_reader_addReply_parameter_0_strict$schema(),
1008
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"},"text":{"type":"string"}},"required":["entryId","noteId","text"],"additionalProperties":false},
1009
+ },
1010
+ },
1011
+ ],
1012
+ result: {
1013
+ mode: 'strict',
1014
+ typeSymbol: '@khorsheed/dsh-reader/types#ReaderNoteOutcome',
1015
+ create: _khorsheed_dsh_reader_reader_addReply_result$schema,
1016
+ schema: _khorsheed_dsh_reader_reader_addReply_result$schema(),
1017
+ jsonSchema: {"type":"string","enum":["not-found","ok","empty","full"]},
1018
+ },
1019
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":346,"column":3},
1020
+ },
1021
+ 'reader/addSource': {
387
1022
  service: 'readerRemote',
388
- namespace: 'reader',
389
- method: 'addSource',
1023
+ description: 'Add a source; the host decides whether the URL is a feed or an article.',
390
1024
  invocation: { kind: 'direct' },
391
1025
  parameters: [
392
1026
  {
393
1027
  name: 'request',
394
- wire: 'request',
395
1028
  source: 'json',
396
1029
  codec: {
397
1030
  mode: 'strict',
398
1031
  typeSymbol: '@khorsheed/dsh-reader#reader/addSource:request',
399
1032
  create: _khorsheed_dsh_reader_reader_addSource_parameter_0$schema,
400
1033
  schema: _khorsheed_dsh_reader_reader_addSource_parameter_0$schema(),
1034
+ jsonSchema: {"type":"object","properties":{"url":{"type":"string"},"label":{"type":"string"}},"required":["url"],"additionalProperties":true},
1035
+ },
1036
+ strictCodec: {
1037
+ mode: 'strict',
1038
+ typeSymbol: '@khorsheed/dsh-reader#reader/addSource:request',
1039
+ create: _khorsheed_dsh_reader_reader_addSource_parameter_0_strict$schema,
1040
+ schema: _khorsheed_dsh_reader_reader_addSource_parameter_0_strict$schema(),
1041
+ jsonSchema: {"type":"object","properties":{"url":{"type":"string"},"label":{"type":"string"}},"required":["url"],"additionalProperties":false},
401
1042
  },
402
1043
  },
403
1044
  ],
@@ -406,14 +1047,46 @@ export const TYPERT_REMOTE = {
406
1047
  typeSymbol: '@khorsheed/dsh-reader#reader/addSource:result',
407
1048
  create: _khorsheed_dsh_reader_reader_addSource_result$schema,
408
1049
  schema: _khorsheed_dsh_reader_reader_addSource_result$schema(),
1050
+ jsonSchema: {"oneOf":[{"type":"string","enum":["unavailable","duplicate","invalid-url","unsupported-content","fetch-failed"]},{"type":"object","properties":{"outcome":{"type":"string","enum":["subscribed","saved-link"]},"kind":{"type":"string","enum":["rss","link"]},"id":{"type":"string"},"label":{"type":"string"},"failure":{"type":"object","properties":{"code":{"type":"string","enum":["blocked","http","unreadable","empty","login","unsupported-type","redirected","unreachable"]},"message":{"type":"string"}},"required":["code","message"],"additionalProperties":true,"description":"Present when the source was saved but its body cannot be previewed. The add still succeeded: the URL is a link the reader now owns. This is the verdict's reason, not a failure — which is why it rides the outcome instead of becoming one more refusal that loses the link."}},"required":["outcome","kind","id","label"],"additionalProperties":true},{"type":"object","properties":{"outcome":{"type":"string","const":"fetch-failed"},"reason":{"type":"string","description":"The fetch seam's message, verbatim — a refused connection, a timeout, a byte cap."}},"required":["outcome","reason"],"additionalProperties":true}]},
409
1051
  },
410
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":72,"column":3},
1052
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":79,"column":3},
411
1053
  },
412
- {
413
- id: '@khorsheed/dsh-reader#reader/capabilities',
1054
+ 'reader/cancelLocalTranscript': {
414
1055
  service: 'readerRemote',
415
- namespace: 'reader',
416
- method: 'capabilities',
1056
+ description: 'Leave (withdraws a queued job) or, with `force`, stop an entry\'s local transcription.',
1057
+ invocation: { kind: 'direct' },
1058
+ parameters: [
1059
+ {
1060
+ name: 'request',
1061
+ source: 'json',
1062
+ codec: {
1063
+ mode: 'strict',
1064
+ typeSymbol: '@khorsheed/dsh-reader#reader/cancelLocalTranscript:request',
1065
+ create: _khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0$schema,
1066
+ schema: _khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0$schema(),
1067
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"force":{"type":"boolean"}},"required":["entryId","force"],"additionalProperties":true},
1068
+ },
1069
+ strictCodec: {
1070
+ mode: 'strict',
1071
+ typeSymbol: '@khorsheed/dsh-reader#reader/cancelLocalTranscript:request',
1072
+ create: _khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0_strict$schema,
1073
+ schema: _khorsheed_dsh_reader_reader_cancelLocalTranscript_parameter_0_strict$schema(),
1074
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"force":{"type":"boolean"}},"required":["entryId","force"],"additionalProperties":false},
1075
+ },
1076
+ },
1077
+ ],
1078
+ result: {
1079
+ mode: 'strict',
1080
+ typeSymbol: '@khorsheed/dsh-reader/types#LocalTranscriptStatus',
1081
+ create: _khorsheed_dsh_reader_reader_cancelLocalTranscript_result$schema,
1082
+ schema: _khorsheed_dsh_reader_reader_cancelLocalTranscript_result$schema(),
1083
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"state":{"type":"string","enum":["failed","unavailable","done","idle","queued","fetching","needs-models","transcribing","speakers"]},"progress":{"type":"number","description":"0–1 across fetching the audio and transcribing it."},"ahead":{"type":"number","description":"Jobs ahead in the engine's queue."},"bytes":{"type":"number","description":"Bytes of speech models still to download (`needs-models`)."},"html":{"type":"string","description":"The transcript so far (or in full, once `done`)."},"language":{"type":"string","description":"The language the transcript is in, once known."},"speakers":{"type":"number","description":"How many voices the transcript has, once the speakers pass settled it."},"error":{"type":"string"}},"required":["entryId","state"],"additionalProperties":true},
1084
+ },
1085
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":410,"column":3},
1086
+ },
1087
+ 'reader/capabilities': {
1088
+ service: 'readerRemote',
1089
+ description: 'Capability handshake: what the browser may rely on in this composition.',
417
1090
  invocation: { kind: 'direct' },
418
1091
  parameters: [
419
1092
  ],
@@ -422,14 +1095,13 @@ export const TYPERT_REMOTE = {
422
1095
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderCapabilities',
423
1096
  create: _khorsheed_dsh_reader_reader_capabilities_result$schema,
424
1097
  schema: _khorsheed_dsh_reader_reader_capabilities_result$schema(),
1098
+ jsonSchema: {"type":"object","properties":{"protocolVersion":{"type":"number","const":1},"hasFs":{"type":"boolean","description":"False when no filesystem is mounted: state lives in memory and is lost on restart."},"hasSideChat":{"type":"boolean","description":"False when no side-chat service is mounted: the side-chat gesture must hide."},"nextRefreshAt":{"type":"string","description":"ISO-8601 timestamp of the next scheduled refresh, when one is armed."},"lastRefreshAt":{"type":"string","description":"ISO-8601 timestamp of the last completed refresh run, when there was one. The list shows it so a reader can decide whether the snapshot is stale enough to be worth a fetch."}},"required":["protocolVersion","hasFs","hasSideChat"],"additionalProperties":true},
425
1099
  },
426
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":60,"column":3},
1100
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":67,"column":3},
427
1101
  },
428
- {
429
- id: '@khorsheed/dsh-reader#reader/clearRecent',
1102
+ 'reader/clearRecent': {
430
1103
  service: 'readerRemote',
431
- namespace: 'reader',
432
- method: 'clearRecent',
1104
+ description: 'Forget every recent entry.',
433
1105
  invocation: { kind: 'direct' },
434
1106
  parameters: [
435
1107
  ],
@@ -438,14 +1110,13 @@ export const TYPERT_REMOTE = {
438
1110
  typeSymbol: '@khorsheed/dsh-reader#reader/clearRecent:result',
439
1111
  create: _khorsheed_dsh_reader_reader_clearRecent_result$schema,
440
1112
  schema: _khorsheed_dsh_reader_reader_clearRecent_result$schema(),
1113
+ jsonSchema: {"type":"object","properties":{"removed":{"type":"number"}},"required":["removed"],"additionalProperties":true},
441
1114
  },
442
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":285,"column":3},
1115
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":292,"column":3},
443
1116
  },
444
- {
445
- id: '@khorsheed/dsh-reader#reader/clearTranslations',
1117
+ 'reader/clearTranslations': {
446
1118
  service: 'readerRemote',
447
- namespace: 'reader',
448
- method: 'clearTranslations',
1119
+ description: 'Forget every translation: the global memory and every entry map.',
449
1120
  invocation: { kind: 'direct' },
450
1121
  parameters: [
451
1122
  ],
@@ -454,25 +1125,31 @@ export const TYPERT_REMOTE = {
454
1125
  typeSymbol: '@khorsheed/dsh-reader#reader/clearTranslations:result',
455
1126
  create: _khorsheed_dsh_reader_reader_clearTranslations_result$schema,
456
1127
  schema: _khorsheed_dsh_reader_reader_clearTranslations_result$schema(),
1128
+ jsonSchema: {"type":"object","properties":{"clearedEntries":{"type":"number"},"clearedMemory":{"type":"boolean"}},"required":["clearedEntries","clearedMemory"],"additionalProperties":true},
457
1129
  },
458
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":209,"column":3},
1130
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":216,"column":3},
459
1131
  },
460
- {
461
- id: '@khorsheed/dsh-reader#reader/createTag',
1132
+ 'reader/createTag': {
462
1133
  service: 'readerRemote',
463
- namespace: 'reader',
464
- method: 'createTag',
1134
+ description: 'Create a tag, or return the existing one with the same name.',
465
1135
  invocation: { kind: 'direct' },
466
1136
  parameters: [
467
1137
  {
468
1138
  name: 'request',
469
- wire: 'request',
470
1139
  source: 'json',
471
1140
  codec: {
472
1141
  mode: 'strict',
473
1142
  typeSymbol: '@khorsheed/dsh-reader#reader/createTag:request',
474
1143
  create: _khorsheed_dsh_reader_reader_createTag_parameter_0$schema,
475
1144
  schema: _khorsheed_dsh_reader_reader_createTag_parameter_0$schema(),
1145
+ jsonSchema: {"type":"object","properties":{"name":{"type":"string"}},"required":["name"],"additionalProperties":true},
1146
+ },
1147
+ strictCodec: {
1148
+ mode: 'strict',
1149
+ typeSymbol: '@khorsheed/dsh-reader#reader/createTag:request',
1150
+ create: _khorsheed_dsh_reader_reader_createTag_parameter_0_strict$schema,
1151
+ schema: _khorsheed_dsh_reader_reader_createTag_parameter_0_strict$schema(),
1152
+ jsonSchema: {"type":"object","properties":{"name":{"type":"string"}},"required":["name"],"additionalProperties":false},
476
1153
  },
477
1154
  },
478
1155
  ],
@@ -481,25 +1158,97 @@ export const TYPERT_REMOTE = {
481
1158
  typeSymbol: '@khorsheed/dsh-reader#reader/createTag:result',
482
1159
  create: _khorsheed_dsh_reader_reader_createTag_result$schema,
483
1160
  schema: _khorsheed_dsh_reader_reader_createTag_result$schema(),
1161
+ jsonSchema: {"oneOf":[{"type":"string","enum":["not-found","unavailable","duplicate","ok","empty","invalid"]},{"type":"object","properties":{"id":{"type":"string","description":"Stable id — renaming a tag must not rewrite every entry that carries it."},"name":{"type":"string","description":"The reader-facing name, unique case-insensitively."},"createdAt":{"type":"string"}},"required":["id","name","createdAt"],"additionalProperties":true}]},
1162
+ },
1163
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":228,"column":3},
1164
+ },
1165
+ 'reader/deleteDiscussion': {
1166
+ service: 'readerRemote',
1167
+ description: 'Delete one discussion note.',
1168
+ invocation: { kind: 'direct' },
1169
+ parameters: [
1170
+ {
1171
+ name: 'request',
1172
+ source: 'json',
1173
+ codec: {
1174
+ mode: 'strict',
1175
+ typeSymbol: '@khorsheed/dsh-reader#reader/deleteDiscussion:request',
1176
+ create: _khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0$schema,
1177
+ schema: _khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0$schema(),
1178
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"discussionId":{"type":"string"}},"required":["entryId","discussionId"],"additionalProperties":true},
1179
+ },
1180
+ strictCodec: {
1181
+ mode: 'strict',
1182
+ typeSymbol: '@khorsheed/dsh-reader#reader/deleteDiscussion:request',
1183
+ create: _khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0_strict$schema,
1184
+ schema: _khorsheed_dsh_reader_reader_deleteDiscussion_parameter_0_strict$schema(),
1185
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"discussionId":{"type":"string"}},"required":["entryId","discussionId"],"additionalProperties":false},
1186
+ },
1187
+ },
1188
+ ],
1189
+ result: {
1190
+ mode: 'strict',
1191
+ typeSymbol: '@khorsheed/dsh-reader/types#ReaderNoteOutcome',
1192
+ create: _khorsheed_dsh_reader_reader_deleteDiscussion_result$schema,
1193
+ schema: _khorsheed_dsh_reader_reader_deleteDiscussion_result$schema(),
1194
+ jsonSchema: {"type":"string","enum":["not-found","ok","empty","full"]},
1195
+ },
1196
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":364,"column":3},
1197
+ },
1198
+ 'reader/deleteNote': {
1199
+ service: 'readerRemote',
1200
+ description: 'Delete one note.',
1201
+ invocation: { kind: 'direct' },
1202
+ parameters: [
1203
+ {
1204
+ name: 'request',
1205
+ source: 'json',
1206
+ codec: {
1207
+ mode: 'strict',
1208
+ typeSymbol: '@khorsheed/dsh-reader#reader/deleteNote:request',
1209
+ create: _khorsheed_dsh_reader_reader_deleteNote_parameter_0$schema,
1210
+ schema: _khorsheed_dsh_reader_reader_deleteNote_parameter_0$schema(),
1211
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"}},"required":["entryId","noteId"],"additionalProperties":true},
1212
+ },
1213
+ strictCodec: {
1214
+ mode: 'strict',
1215
+ typeSymbol: '@khorsheed/dsh-reader#reader/deleteNote:request',
1216
+ create: _khorsheed_dsh_reader_reader_deleteNote_parameter_0_strict$schema,
1217
+ schema: _khorsheed_dsh_reader_reader_deleteNote_parameter_0_strict$schema(),
1218
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"}},"required":["entryId","noteId"],"additionalProperties":false},
1219
+ },
1220
+ },
1221
+ ],
1222
+ result: {
1223
+ mode: 'strict',
1224
+ typeSymbol: '@khorsheed/dsh-reader/types#ReaderNoteOutcome',
1225
+ create: _khorsheed_dsh_reader_reader_deleteNote_result$schema,
1226
+ schema: _khorsheed_dsh_reader_reader_deleteNote_result$schema(),
1227
+ jsonSchema: {"type":"string","enum":["not-found","ok","empty","full"]},
484
1228
  },
485
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":221,"column":3},
1229
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":334,"column":3},
486
1230
  },
487
- {
488
- id: '@khorsheed/dsh-reader#reader/deleteTag',
1231
+ 'reader/deleteTag': {
489
1232
  service: 'readerRemote',
490
- namespace: 'reader',
491
- method: 'deleteTag',
1233
+ description: 'Delete a tag and remove it from every entry.',
492
1234
  invocation: { kind: 'direct' },
493
1235
  parameters: [
494
1236
  {
495
1237
  name: 'request',
496
- wire: 'request',
497
1238
  source: 'json',
498
1239
  codec: {
499
1240
  mode: 'strict',
500
1241
  typeSymbol: '@khorsheed/dsh-reader#reader/deleteTag:request',
501
1242
  create: _khorsheed_dsh_reader_reader_deleteTag_parameter_0$schema,
502
1243
  schema: _khorsheed_dsh_reader_reader_deleteTag_parameter_0$schema(),
1244
+ jsonSchema: {"type":"object","properties":{"id":{"type":"string"}},"required":["id"],"additionalProperties":true},
1245
+ },
1246
+ strictCodec: {
1247
+ mode: 'strict',
1248
+ typeSymbol: '@khorsheed/dsh-reader#reader/deleteTag:request',
1249
+ create: _khorsheed_dsh_reader_reader_deleteTag_parameter_0_strict$schema,
1250
+ schema: _khorsheed_dsh_reader_reader_deleteTag_parameter_0_strict$schema(),
1251
+ jsonSchema: {"type":"object","properties":{"id":{"type":"string"}},"required":["id"],"additionalProperties":false},
503
1252
  },
504
1253
  },
505
1254
  ],
@@ -508,25 +1257,64 @@ export const TYPERT_REMOTE = {
508
1257
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderAnnotationOutcome',
509
1258
  create: _khorsheed_dsh_reader_reader_deleteTag_result$schema,
510
1259
  schema: _khorsheed_dsh_reader_reader_deleteTag_result$schema(),
1260
+ jsonSchema: {"type":"string","enum":["not-found","unavailable","duplicate","ok","empty","invalid"]},
511
1261
  },
512
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":233,"column":3},
1262
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":240,"column":3},
513
1263
  },
514
- {
515
- id: '@khorsheed/dsh-reader#reader/entryFetchStates',
1264
+ 'reader/editReply': {
516
1265
  service: 'readerRemote',
517
- namespace: 'reader',
518
- method: 'entryFetchStates',
1266
+ description: 'Rewrite (or, with empty text, remove) one line under a note.',
1267
+ invocation: { kind: 'direct' },
1268
+ parameters: [
1269
+ {
1270
+ name: 'request',
1271
+ source: 'json',
1272
+ codec: {
1273
+ mode: 'strict',
1274
+ typeSymbol: '@khorsheed/dsh-reader#reader/editReply:request',
1275
+ create: _khorsheed_dsh_reader_reader_editReply_parameter_0$schema,
1276
+ schema: _khorsheed_dsh_reader_reader_editReply_parameter_0$schema(),
1277
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"},"index":{"type":"number"},"text":{"type":"string"}},"required":["entryId","noteId","index","text"],"additionalProperties":true},
1278
+ },
1279
+ strictCodec: {
1280
+ mode: 'strict',
1281
+ typeSymbol: '@khorsheed/dsh-reader#reader/editReply:request',
1282
+ create: _khorsheed_dsh_reader_reader_editReply_parameter_0_strict$schema,
1283
+ schema: _khorsheed_dsh_reader_reader_editReply_parameter_0_strict$schema(),
1284
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"},"index":{"type":"number"},"text":{"type":"string"}},"required":["entryId","noteId","index","text"],"additionalProperties":false},
1285
+ },
1286
+ },
1287
+ ],
1288
+ result: {
1289
+ mode: 'strict',
1290
+ typeSymbol: '@khorsheed/dsh-reader/types#ReaderNoteOutcome',
1291
+ create: _khorsheed_dsh_reader_reader_editReply_result$schema,
1292
+ schema: _khorsheed_dsh_reader_reader_editReply_result$schema(),
1293
+ jsonSchema: {"type":"string","enum":["not-found","ok","empty","full"]},
1294
+ },
1295
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":352,"column":3},
1296
+ },
1297
+ 'reader/entryFetchStates': {
1298
+ service: 'readerRemote',
1299
+ description: 'What the plugin holds per entry: a body, a stored raw payload, or a failure.',
519
1300
  invocation: { kind: 'direct' },
520
1301
  parameters: [
521
1302
  {
522
1303
  name: 'request',
523
- wire: 'request',
524
1304
  source: 'json',
525
1305
  codec: {
526
1306
  mode: 'strict',
527
1307
  typeSymbol: '@khorsheed/dsh-reader#reader/entryFetchStates:request',
528
1308
  create: _khorsheed_dsh_reader_reader_entryFetchStates_parameter_0$schema,
529
1309
  schema: _khorsheed_dsh_reader_reader_entryFetchStates_parameter_0$schema(),
1310
+ jsonSchema: {"type":"object","properties":{"entryIds":{"type":"array","items":{"type":"string"}}},"required":["entryIds"],"additionalProperties":true},
1311
+ },
1312
+ strictCodec: {
1313
+ mode: 'strict',
1314
+ typeSymbol: '@khorsheed/dsh-reader#reader/entryFetchStates:request',
1315
+ create: _khorsheed_dsh_reader_reader_entryFetchStates_parameter_0_strict$schema,
1316
+ schema: _khorsheed_dsh_reader_reader_entryFetchStates_parameter_0_strict$schema(),
1317
+ jsonSchema: {"type":"object","properties":{"entryIds":{"type":"array","items":{"type":"string"}}},"required":["entryIds"],"additionalProperties":false},
530
1318
  },
531
1319
  },
532
1320
  ],
@@ -535,25 +1323,64 @@ export const TYPERT_REMOTE = {
535
1323
  typeSymbol: '@khorsheed/dsh-reader#reader/entryFetchStates:result',
536
1324
  create: _khorsheed_dsh_reader_reader_entryFetchStates_result$schema,
537
1325
  schema: _khorsheed_dsh_reader_reader_entryFetchStates_result$schema(),
1326
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
538
1327
  },
539
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":156,"column":3},
1328
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":163,"column":3},
540
1329
  },
541
- {
542
- id: '@khorsheed/dsh-reader#reader/entryTags',
1330
+ 'reader/entryNotes': {
543
1331
  service: 'readerRemote',
544
- namespace: 'reader',
545
- method: 'entryTags',
1332
+ description: 'One article\'s notes and the conversations that discussed it.',
1333
+ invocation: { kind: 'direct' },
1334
+ parameters: [
1335
+ {
1336
+ name: 'request',
1337
+ source: 'json',
1338
+ codec: {
1339
+ mode: 'strict',
1340
+ typeSymbol: '@khorsheed/dsh-reader#reader/entryNotes:request',
1341
+ create: _khorsheed_dsh_reader_reader_entryNotes_parameter_0$schema,
1342
+ schema: _khorsheed_dsh_reader_reader_entryNotes_parameter_0$schema(),
1343
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
1344
+ },
1345
+ strictCodec: {
1346
+ mode: 'strict',
1347
+ typeSymbol: '@khorsheed/dsh-reader#reader/entryNotes:request',
1348
+ create: _khorsheed_dsh_reader_reader_entryNotes_parameter_0_strict$schema,
1349
+ schema: _khorsheed_dsh_reader_reader_entryNotes_parameter_0_strict$schema(),
1350
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":false},
1351
+ },
1352
+ },
1353
+ ],
1354
+ result: {
1355
+ mode: 'strict',
1356
+ typeSymbol: '@khorsheed/dsh-reader#reader/entryNotes:result',
1357
+ create: _khorsheed_dsh_reader_reader_entryNotes_result$schema,
1358
+ schema: _khorsheed_dsh_reader_reader_entryNotes_result$schema(),
1359
+ jsonSchema: {"type":"object","properties":{"entry":{"type":"object","properties":{"entryId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"},"source":{"type":"string","description":"The source's display label (the feed's name, or the site)."},"notes":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"`n1`, `n2`… per article, never reused — the model cites notes by it."},"anchor":{"type":"object","properties":{"block":{"type":"number"},"start":{"type":"number"},"quote":{"type":"string"},"translated":{"type":"string","description":"The translated text, when the selection was made in the translated view."},"time":{"type":"number","description":"A video / audio transcript paragraph's start (seconds): where ▶ plays from."}},"required":["block","quote"],"additionalProperties":true},"comment":{"type":"string"},"replies":{"type":"array","items":{"type":"object","properties":{"by":{"type":"string","enum":["user","agent"]},"text":{"type":"string"},"sessionId":{"type":"string","description":"The conversation it came from, so the reader can go back to it."},"editedFrom":{"type":"string","const":"agent","description":"Set when the reader rewrote a line the model wrote."},"at":{"type":"string"}},"required":["by","text","at"],"additionalProperties":true},"description":"Conclusions and additions, oldest first."},"syncedTo":{"type":"array","items":{"type":"object","properties":{"canvasId":{"type":"string"},"cardId":{"type":"string"},"canvasTitle":{"type":"string","description":"The canvas's title when it was synced (for the 「已在…」 mark)."},"at":{"type":"string"}},"required":["canvasId","cardId","canvasTitle","at"],"additionalProperties":true},"description":"Canvas cards made from it (a later edit does not reach them)."},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","anchor","createdAt","updatedAt"],"additionalProperties":true}},"sessions":{"type":"array","items":{"type":"object","properties":{"sessionId":{"type":"string"},"title":{"type":"string"},"lastAt":{"type":"string"}},"required":["sessionId","lastAt"],"additionalProperties":true}},"discussions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"`d1`, `d2`… per article, never reused."},"kind":{"type":"string","enum":["check","discussion"]},"sessionId":{"type":"string"},"title":{"type":"string"},"points":{"type":"array","items":{"type":"object","properties":{"text":{"type":"string"},"para":{"type":"number","description":"¶ number (1-based), when the point cites the article."}},"required":["text"],"additionalProperties":true}},"aside":{"type":"string","description":"One line for what went fine (「其余 2 题讲到位了」)."},"syncedTo":{"type":"array","items":{"type":"object","properties":{"canvasId":{"type":"string"},"cardId":{"type":"string"},"canvasTitle":{"type":"string","description":"The canvas's title when it was synced (for the 「已在…」 mark)."},"at":{"type":"string"}},"required":["canvasId","cardId","canvasTitle","at"],"additionalProperties":true},"description":"Canvas cards made from it."},"createdAt":{"type":"string"}},"required":["id","kind","title","points","createdAt"],"additionalProperties":true},"description":"Discussion notes, newest first."},"nextNote":{"type":"number","description":"The next note number; ids are never reused, so a deleted n3 stays deleted."},"nextDiscussion":{"type":"number","description":"The next discussion number, never reused either."},"updatedAt":{"type":"string"}},"required":["entryId","title","notes","sessions","nextNote","updatedAt"],"additionalProperties":true}},"required":[],"additionalProperties":true},
1360
+ },
1361
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":309,"column":9},
1362
+ },
1363
+ 'reader/entryTags': {
1364
+ service: 'readerRemote',
1365
+ description: 'The tags on one entry.',
546
1366
  invocation: { kind: 'direct' },
547
1367
  parameters: [
548
1368
  {
549
1369
  name: 'request',
550
- wire: 'request',
551
1370
  source: 'json',
552
1371
  codec: {
553
1372
  mode: 'strict',
554
1373
  typeSymbol: '@khorsheed/dsh-reader#reader/entryTags:request',
555
1374
  create: _khorsheed_dsh_reader_reader_entryTags_parameter_0$schema,
556
1375
  schema: _khorsheed_dsh_reader_reader_entryTags_parameter_0$schema(),
1376
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
1377
+ },
1378
+ strictCodec: {
1379
+ mode: 'strict',
1380
+ typeSymbol: '@khorsheed/dsh-reader#reader/entryTags:request',
1381
+ create: _khorsheed_dsh_reader_reader_entryTags_parameter_0_strict$schema,
1382
+ schema: _khorsheed_dsh_reader_reader_entryTags_parameter_0_strict$schema(),
1383
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":false},
557
1384
  },
558
1385
  },
559
1386
  ],
@@ -562,25 +1389,31 @@ export const TYPERT_REMOTE = {
562
1389
  typeSymbol: '@khorsheed/dsh-reader#reader/entryTags:result',
563
1390
  create: _khorsheed_dsh_reader_reader_entryTags_result$schema,
564
1391
  schema: _khorsheed_dsh_reader_reader_entryTags_result$schema(),
1392
+ jsonSchema: {"type":"object","properties":{"tags":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Stable id — renaming a tag must not rewrite every entry that carries it."},"name":{"type":"string","description":"The reader-facing name, unique case-insensitively."},"createdAt":{"type":"string"}},"required":["id","name","createdAt"],"additionalProperties":true}}},"required":["tags"],"additionalProperties":true},
565
1393
  },
566
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":245,"column":3},
1394
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":252,"column":3},
567
1395
  },
568
- {
569
- id: '@khorsheed/dsh-reader#reader/fetchEntryBody',
1396
+ 'reader/fetchEntryBody': {
570
1397
  service: 'readerRemote',
571
- namespace: 'reader',
572
- method: 'fetchEntryBody',
1398
+ description: 'Fetch one entry\'s article (the network half; the browser extracts).',
573
1399
  invocation: { kind: 'direct' },
574
1400
  parameters: [
575
1401
  {
576
1402
  name: 'request',
577
- wire: 'request',
578
1403
  source: 'json',
579
1404
  codec: {
580
1405
  mode: 'strict',
581
1406
  typeSymbol: '@khorsheed/dsh-reader#reader/fetchEntryBody:request',
582
1407
  create: _khorsheed_dsh_reader_reader_fetchEntryBody_parameter_0$schema,
583
1408
  schema: _khorsheed_dsh_reader_reader_fetchEntryBody_parameter_0$schema(),
1409
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"}},"required":["entryId","url"],"additionalProperties":true},
1410
+ },
1411
+ strictCodec: {
1412
+ mode: 'strict',
1413
+ typeSymbol: '@khorsheed/dsh-reader#reader/fetchEntryBody:request',
1414
+ create: _khorsheed_dsh_reader_reader_fetchEntryBody_parameter_0_strict$schema,
1415
+ schema: _khorsheed_dsh_reader_reader_fetchEntryBody_parameter_0_strict$schema(),
1416
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"}},"required":["entryId","url"],"additionalProperties":false},
584
1417
  },
585
1418
  },
586
1419
  ],
@@ -589,25 +1422,31 @@ export const TYPERT_REMOTE = {
589
1422
  typeSymbol: '@khorsheed/dsh-reader#reader/fetchEntryBody:result',
590
1423
  create: _khorsheed_dsh_reader_reader_fetchEntryBody_result$schema,
591
1424
  schema: _khorsheed_dsh_reader_reader_fetchEntryBody_result$schema(),
1425
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"raw":{"type":"string"},"rawFile":{"type":"string"},"truncated":{"type":"boolean"},"error":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
592
1426
  },
593
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":116,"column":3},
1427
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":123,"column":3},
594
1428
  },
595
- {
596
- id: '@khorsheed/dsh-reader#reader/fetchImage',
1429
+ 'reader/fetchImage': {
597
1430
  service: 'readerRemote',
598
- namespace: 'reader',
599
- method: 'fetchImage',
1431
+ description: 'Fetch one image the browser could not load cross-origin (CORP / hotlink-protected), so the pane can re-point the failed `<img>` at the bytes. Called per failed image, never for a healthy one.',
600
1432
  invocation: { kind: 'direct' },
601
1433
  parameters: [
602
1434
  {
603
1435
  name: 'request',
604
- wire: 'request',
605
1436
  source: 'json',
606
1437
  codec: {
607
1438
  mode: 'strict',
608
1439
  typeSymbol: '@khorsheed/dsh-reader#reader/fetchImage:request',
609
1440
  create: _khorsheed_dsh_reader_reader_fetchImage_parameter_0$schema,
610
1441
  schema: _khorsheed_dsh_reader_reader_fetchImage_parameter_0$schema(),
1442
+ jsonSchema: {"type":"object","properties":{"url":{"type":"string"}},"required":["url"],"additionalProperties":true},
1443
+ },
1444
+ strictCodec: {
1445
+ mode: 'strict',
1446
+ typeSymbol: '@khorsheed/dsh-reader#reader/fetchImage:request',
1447
+ create: _khorsheed_dsh_reader_reader_fetchImage_parameter_0_strict$schema,
1448
+ schema: _khorsheed_dsh_reader_reader_fetchImage_parameter_0_strict$schema(),
1449
+ jsonSchema: {"type":"object","properties":{"url":{"type":"string"}},"required":["url"],"additionalProperties":false},
611
1450
  },
612
1451
  },
613
1452
  ],
@@ -616,25 +1455,31 @@ export const TYPERT_REMOTE = {
616
1455
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderImageResult',
617
1456
  create: _khorsheed_dsh_reader_reader_fetchImage_result$schema,
618
1457
  schema: _khorsheed_dsh_reader_reader_fetchImage_result$schema(),
1458
+ jsonSchema: {"type":"object","properties":{"url":{"type":"string","description":"The URL the pane asked about (echoed, so a late answer can be matched)."},"mime":{"type":"string","description":"The image's declared content type, when the fetch produced bytes."},"base64":{"type":"string","description":"The image bytes, base64-encoded, when the fetch produced them."},"error":{"type":"string","description":"Why the rescue failed, when it did."}},"required":["url"],"additionalProperties":true},
619
1459
  },
620
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":133,"column":3},
1460
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":140,"column":3},
621
1461
  },
622
- {
623
- id: '@khorsheed/dsh-reader#reader/getBodies',
1462
+ 'reader/getBodies': {
624
1463
  service: 'readerRemote',
625
- namespace: 'reader',
626
- method: 'getBodies',
1464
+ description: 'Hand back raw payloads for the browser to parse.',
627
1465
  invocation: { kind: 'direct' },
628
1466
  parameters: [
629
1467
  {
630
1468
  name: 'request',
631
- wire: 'request',
632
1469
  source: 'json',
633
1470
  codec: {
634
1471
  mode: 'strict',
635
1472
  typeSymbol: '@khorsheed/dsh-reader#reader/getBodies:request',
636
1473
  create: _khorsheed_dsh_reader_reader_getBodies_parameter_0$schema,
637
1474
  schema: _khorsheed_dsh_reader_reader_getBodies_parameter_0$schema(),
1475
+ jsonSchema: {"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}}},"required":["ids"],"additionalProperties":true},
1476
+ },
1477
+ strictCodec: {
1478
+ mode: 'strict',
1479
+ typeSymbol: '@khorsheed/dsh-reader#reader/getBodies:request',
1480
+ create: _khorsheed_dsh_reader_reader_getBodies_parameter_0_strict$schema,
1481
+ schema: _khorsheed_dsh_reader_reader_getBodies_parameter_0_strict$schema(),
1482
+ jsonSchema: {"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}}},"required":["ids"],"additionalProperties":false},
638
1483
  },
639
1484
  },
640
1485
  ],
@@ -643,14 +1488,13 @@ export const TYPERT_REMOTE = {
643
1488
  typeSymbol: '@khorsheed/dsh-reader#reader/getBodies:result',
644
1489
  create: _khorsheed_dsh_reader_reader_getBodies_result$schema,
645
1490
  schema: _khorsheed_dsh_reader_reader_getBodies_result$schema(),
1491
+ jsonSchema: {"type":"object","properties":{"bodies":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"raw":{"type":"string"},"truncated":{"type":"boolean"},"error":{"type":"string","description":"Present when the payload could not be produced (fetch failed, no fs, …)."},"title":{"type":"string","description":"The captured article title for a link source's single entry, when a past extraction stored it (see {@link ReaderEntryAnnotation.title}). The wall prefers it over the URL-derived label."},"excerpt":{"type":"string","description":"The captured excerpt, with the title."}},"required":["id"],"additionalProperties":true}}},"required":["bodies"],"additionalProperties":true},
646
1492
  },
647
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":102,"column":9},
1493
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":109,"column":9},
648
1494
  },
649
- {
650
- id: '@khorsheed/dsh-reader#reader/getCachePolicy',
1495
+ 'reader/getCachePolicy': {
651
1496
  service: 'readerRemote',
652
- namespace: 'reader',
653
- method: 'getCachePolicy',
1497
+ description: 'Read or set how long a fetched body is served (and the translation budget).',
654
1498
  invocation: { kind: 'direct' },
655
1499
  parameters: [
656
1500
  ],
@@ -659,25 +1503,31 @@ export const TYPERT_REMOTE = {
659
1503
  typeSymbol: '@khorsheed/dsh-reader#reader/getCachePolicy:result',
660
1504
  create: _khorsheed_dsh_reader_reader_getCachePolicy_result$schema,
661
1505
  schema: _khorsheed_dsh_reader_reader_getCachePolicy_result$schema(),
1506
+ jsonSchema: {"type":"object","properties":{"ttlHours":{"type":"number"},"maxEntries":{"type":"number"},"translationBudgetChars":{"type":"number"}},"required":["ttlHours","maxEntries","translationBudgetChars"],"additionalProperties":true},
662
1507
  },
663
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":251,"column":3},
1508
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":258,"column":3},
664
1509
  },
665
- {
666
- id: '@khorsheed/dsh-reader#reader/getEntryBody',
1510
+ 'reader/getEntryBody': {
667
1511
  service: 'readerRemote',
668
- namespace: 'reader',
669
- method: 'getEntryBody',
1512
+ description: 'What the detail view should render for one entry, and whether a fetch is worth offering.',
670
1513
  invocation: { kind: 'direct' },
671
1514
  parameters: [
672
1515
  {
673
1516
  name: 'request',
674
- wire: 'request',
675
1517
  source: 'json',
676
1518
  codec: {
677
1519
  mode: 'strict',
678
1520
  typeSymbol: '@khorsheed/dsh-reader#reader/getEntryBody:request',
679
- create: _khorsheed_dsh_reader_reader_getEntryBody_parameter_0$schema,
680
- schema: _khorsheed_dsh_reader_reader_getEntryBody_parameter_0$schema(),
1521
+ create: _khorsheed_dsh_reader_reader_getEntryBody_parameter_0$schema,
1522
+ schema: _khorsheed_dsh_reader_reader_getEntryBody_parameter_0$schema(),
1523
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"feedHtml":{"type":"string"}},"required":["entryId","url"],"additionalProperties":true},
1524
+ },
1525
+ strictCodec: {
1526
+ mode: 'strict',
1527
+ typeSymbol: '@khorsheed/dsh-reader#reader/getEntryBody:request',
1528
+ create: _khorsheed_dsh_reader_reader_getEntryBody_parameter_0_strict$schema,
1529
+ schema: _khorsheed_dsh_reader_reader_getEntryBody_parameter_0_strict$schema(),
1530
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"feedHtml":{"type":"string"}},"required":["entryId","url"],"additionalProperties":false},
681
1531
  },
682
1532
  },
683
1533
  ],
@@ -686,25 +1536,31 @@ export const TYPERT_REMOTE = {
686
1536
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderEntryBodyView',
687
1537
  create: _khorsheed_dsh_reader_reader_getEntryBody_result$schema,
688
1538
  schema: _khorsheed_dsh_reader_reader_getEntryBody_result$schema(),
1539
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"cached":{"type":"boolean","description":"True when this body is a cached fetch rather than the feed's own payload."},"fresh":{"type":"boolean","description":"False when the cache's deadline has passed: the view offers the fetch."},"fromFeed":{"type":"boolean","description":"True when the feed's payload already carries full text for this entry."},"html":{"type":"string"},"fetchedAt":{"type":"string"},"truncated":{"type":"boolean"},"scriptFigures":{"type":"number","description":"Figures this page draws with scripts — the detail view says so."},"rendered":{"type":"boolean","description":"True when this body came from a rendered fetch (the「重新抓取」route reads it)."},"error":{"type":"string","description":"Why a fetch could not produce a body, when one was attempted."}},"required":["entryId","cached","fresh","fromFeed"],"additionalProperties":true},
689
1540
  },
690
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":110,"column":3},
1541
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":117,"column":3},
691
1542
  },
692
- {
693
- id: '@khorsheed/dsh-reader#reader/getEntryTranslation',
1543
+ 'reader/getEntryTranslation': {
694
1544
  service: 'readerRemote',
695
- namespace: 'reader',
696
- method: 'getEntryTranslation',
1545
+ description: 'One entry\'s exact-fit translation record (segment map resolved), when usable.',
697
1546
  invocation: { kind: 'direct' },
698
1547
  parameters: [
699
1548
  {
700
1549
  name: 'request',
701
- wire: 'request',
702
1550
  source: 'json',
703
1551
  codec: {
704
1552
  mode: 'strict',
705
1553
  typeSymbol: '@khorsheed/dsh-reader#reader/getEntryTranslation:request',
706
1554
  create: _khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0$schema,
707
1555
  schema: _khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0$schema(),
1556
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
1557
+ },
1558
+ strictCodec: {
1559
+ mode: 'strict',
1560
+ typeSymbol: '@khorsheed/dsh-reader#reader/getEntryTranslation:request',
1561
+ create: _khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0_strict$schema,
1562
+ schema: _khorsheed_dsh_reader_reader_getEntryTranslation_parameter_0_strict$schema(),
1563
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":false},
708
1564
  },
709
1565
  },
710
1566
  ],
@@ -713,25 +1569,31 @@ export const TYPERT_REMOTE = {
713
1569
  typeSymbol: '@khorsheed/dsh-reader#reader/getEntryTranslation:result',
714
1570
  create: _khorsheed_dsh_reader_reader_getEntryTranslation_result$schema,
715
1571
  schema: _khorsheed_dsh_reader_reader_getEntryTranslation_result$schema(),
1572
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
716
1573
  },
717
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":179,"column":3},
1574
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":186,"column":3},
718
1575
  },
719
- {
720
- id: '@khorsheed/dsh-reader#reader/getRawBody',
1576
+ 'reader/getRawBody': {
721
1577
  service: 'readerRemote',
722
- namespace: 'reader',
723
- method: 'getRawBody',
1578
+ description: 'A stored raw payload, so the browser can extract it later.',
724
1579
  invocation: { kind: 'direct' },
725
1580
  parameters: [
726
1581
  {
727
1582
  name: 'request',
728
- wire: 'request',
729
1583
  source: 'json',
730
1584
  codec: {
731
1585
  mode: 'strict',
732
1586
  typeSymbol: '@khorsheed/dsh-reader#reader/getRawBody:request',
733
1587
  create: _khorsheed_dsh_reader_reader_getRawBody_parameter_0$schema,
734
1588
  schema: _khorsheed_dsh_reader_reader_getRawBody_parameter_0$schema(),
1589
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
1590
+ },
1591
+ strictCodec: {
1592
+ mode: 'strict',
1593
+ typeSymbol: '@khorsheed/dsh-reader#reader/getRawBody:request',
1594
+ create: _khorsheed_dsh_reader_reader_getRawBody_parameter_0_strict$schema,
1595
+ schema: _khorsheed_dsh_reader_reader_getRawBody_parameter_0_strict$schema(),
1596
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":false},
735
1597
  },
736
1598
  },
737
1599
  ],
@@ -740,25 +1602,31 @@ export const TYPERT_REMOTE = {
740
1602
  typeSymbol: '@khorsheed/dsh-reader#reader/getRawBody:result',
741
1603
  create: _khorsheed_dsh_reader_reader_getRawBody_result$schema,
742
1604
  schema: _khorsheed_dsh_reader_reader_getRawBody_result$schema(),
1605
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"raw":{"type":"string"},"url":{"type":"string"},"truncated":{"type":"boolean"},"error":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
743
1606
  },
744
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":162,"column":3},
1607
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":169,"column":3},
745
1608
  },
746
- {
747
- id: '@khorsheed/dsh-reader#reader/getSentenceTranslations',
1609
+ 'reader/getSentenceTranslations': {
748
1610
  service: 'readerRemote',
749
- namespace: 'reader',
750
- method: 'getSentenceTranslations',
1611
+ description: 'Translations for exactly the asked sentence hashes of one pair — never the whole table.',
751
1612
  invocation: { kind: 'direct' },
752
1613
  parameters: [
753
1614
  {
754
1615
  name: 'request',
755
- wire: 'request',
756
1616
  source: 'json',
757
1617
  codec: {
758
1618
  mode: 'strict',
759
1619
  typeSymbol: '@khorsheed/dsh-reader#reader/getSentenceTranslations:request',
760
1620
  create: _khorsheed_dsh_reader_reader_getSentenceTranslations_parameter_0$schema,
761
1621
  schema: _khorsheed_dsh_reader_reader_getSentenceTranslations_parameter_0$schema(),
1622
+ jsonSchema: {"type":"object","properties":{"pair":{"type":"string"},"hashes":{"type":"array","items":{"type":"string"}}},"required":["pair","hashes"],"additionalProperties":true},
1623
+ },
1624
+ strictCodec: {
1625
+ mode: 'strict',
1626
+ typeSymbol: '@khorsheed/dsh-reader#reader/getSentenceTranslations:request',
1627
+ create: _khorsheed_dsh_reader_reader_getSentenceTranslations_parameter_0_strict$schema,
1628
+ schema: _khorsheed_dsh_reader_reader_getSentenceTranslations_parameter_0_strict$schema(),
1629
+ jsonSchema: {"type":"object","properties":{"pair":{"type":"string"},"hashes":{"type":"array","items":{"type":"string"}}},"required":["pair","hashes"],"additionalProperties":false},
762
1630
  },
763
1631
  },
764
1632
  ],
@@ -767,14 +1635,13 @@ export const TYPERT_REMOTE = {
767
1635
  typeSymbol: '@khorsheed/dsh-reader#reader/getSentenceTranslations:result',
768
1636
  create: _khorsheed_dsh_reader_reader_getSentenceTranslations_result$schema,
769
1637
  schema: _khorsheed_dsh_reader_reader_getSentenceTranslations_result$schema(),
1638
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
770
1639
  },
771
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":185,"column":3},
1640
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":192,"column":3},
772
1641
  },
773
- {
774
- id: '@khorsheed/dsh-reader#reader/getStorageStats',
1642
+ 'reader/getStorageStats': {
775
1643
  service: 'readerRemote',
776
- namespace: 'reader',
777
- method: 'getStorageStats',
1644
+ description: 'Per-tier cache usage, aggregated on the host (the tables never cross).',
778
1645
  invocation: { kind: 'direct' },
779
1646
  parameters: [
780
1647
  ],
@@ -783,25 +1650,31 @@ export const TYPERT_REMOTE = {
783
1650
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderStorageStats',
784
1651
  create: _khorsheed_dsh_reader_reader_getStorageStats_result$schema,
785
1652
  schema: _khorsheed_dsh_reader_reader_getStorageStats_result$schema(),
1653
+ jsonSchema: {"type":"object","properties":{"bodies":{"type":"object","properties":{"entries":{"type":"number"},"chars":{"type":"number"}},"required":["entries","chars"],"additionalProperties":true,"description":"The cached article bodies (what TTL + maxEntries govern)."},"translations":{"type":"object","properties":{"entries":{"type":"number","description":"How many entries carry a segment map."},"chars":{"type":"number","description":"The maps' combined size."},"memoryEntries":{"type":"number","description":"The global memory's sentence count (0 when no table exists)."},"memoryChars":{"type":"number","description":"The global memory's size (0 when no table exists)."}},"required":["entries","chars","memoryEntries","memoryChars"],"additionalProperties":true,"description":"The two translation tiers: per-entry maps, and the global sentence memory."}},"required":["bodies","translations"],"additionalProperties":true},
786
1654
  },
787
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":203,"column":3},
1655
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":210,"column":3},
788
1656
  },
789
- {
790
- id: '@khorsheed/dsh-reader#reader/listBackfillCandidates',
1657
+ 'reader/listBackfillCandidates': {
791
1658
  service: 'readerRemote',
792
- namespace: 'reader',
793
- method: 'listBackfillCandidates',
1659
+ description: 'Which entries still need their full text (the automatic backfill\'s work list).',
794
1660
  invocation: { kind: 'direct' },
795
1661
  parameters: [
796
1662
  {
797
1663
  name: 'request',
798
- wire: 'request',
799
1664
  source: 'json',
800
1665
  codec: {
801
1666
  mode: 'strict',
802
1667
  typeSymbol: '@khorsheed/dsh-reader#reader/listBackfillCandidates:request',
803
1668
  create: _khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0$schema,
804
1669
  schema: _khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0$schema(),
1670
+ jsonSchema: {"type":"object","properties":{"entries":{"type":"array","items":{"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"label":{"type":"string"},"hasBody":{"type":"boolean"}},"required":["entryId","url","label","hasBody"],"additionalProperties":true}},"limit":{"type":"number"}},"required":["entries"],"additionalProperties":true},
1671
+ },
1672
+ strictCodec: {
1673
+ mode: 'strict',
1674
+ typeSymbol: '@khorsheed/dsh-reader#reader/listBackfillCandidates:request',
1675
+ create: _khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0_strict$schema,
1676
+ schema: _khorsheed_dsh_reader_reader_listBackfillCandidates_parameter_0_strict$schema(),
1677
+ jsonSchema: {"type":"object","properties":{"entries":{"type":"array","items":{"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"label":{"type":"string"},"hasBody":{"type":"boolean"}},"required":["entryId","url","label","hasBody"],"additionalProperties":false}},"limit":{"type":"number"}},"required":["entries"],"additionalProperties":false},
805
1678
  },
806
1679
  },
807
1680
  ],
@@ -810,14 +1683,13 @@ export const TYPERT_REMOTE = {
810
1683
  typeSymbol: '@khorsheed/dsh-reader#reader/listBackfillCandidates:result',
811
1684
  create: _khorsheed_dsh_reader_reader_listBackfillCandidates_result$schema,
812
1685
  schema: _khorsheed_dsh_reader_reader_listBackfillCandidates_result$schema(),
1686
+ jsonSchema: {"type":"object","properties":{"candidates":{"type":"array","items":{"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"label":{"type":"string"},"lastError":{"type":"string","description":"Why a previous attempt failed, when one did (and when it is worth retrying)."}},"required":["entryId","url","label"],"additionalProperties":true}}},"required":["candidates"],"additionalProperties":true},
813
1687
  },
814
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":168,"column":3},
1688
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":175,"column":3},
815
1689
  },
816
- {
817
- id: '@khorsheed/dsh-reader#reader/listRecent',
1690
+ 'reader/listRecent': {
818
1691
  service: 'readerRemote',
819
- namespace: 'reader',
820
- method: 'listRecent',
1692
+ description: 'The entries the reader opened, newest first.',
821
1693
  invocation: { kind: 'direct' },
822
1694
  parameters: [
823
1695
  ],
@@ -826,14 +1698,13 @@ export const TYPERT_REMOTE = {
826
1698
  typeSymbol: '@khorsheed/dsh-reader#reader/listRecent:result',
827
1699
  create: _khorsheed_dsh_reader_reader_listRecent_result$schema,
828
1700
  schema: _khorsheed_dsh_reader_reader_listRecent_result$schema(),
1701
+ jsonSchema: {"type":"object","properties":{"entries":{"type":"array","items":{"type":"object","properties":{"entryId":{"type":"string"},"sourceId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string","description":"The article URL, for reopening an entry the feed no longer publishes."},"readAt":{"type":"string","description":"When it was opened (ISO-8601)."}},"required":["entryId","sourceId","title","readAt"],"additionalProperties":true}}},"required":["entries"],"additionalProperties":true},
829
1702
  },
830
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":279,"column":3},
1703
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":286,"column":3},
831
1704
  },
832
- {
833
- id: '@khorsheed/dsh-reader#reader/listSources',
1705
+ 'reader/listSources': {
834
1706
  service: 'readerRemote',
835
- namespace: 'reader',
836
- method: 'listSources',
1707
+ description: 'The configured sources, without payloads.',
837
1708
  invocation: { kind: 'direct' },
838
1709
  parameters: [
839
1710
  ],
@@ -842,14 +1713,13 @@ export const TYPERT_REMOTE = {
842
1713
  typeSymbol: '@khorsheed/dsh-reader#reader/listSources:result',
843
1714
  create: _khorsheed_dsh_reader_reader_listSources_result$schema,
844
1715
  schema: _khorsheed_dsh_reader_reader_listSources_result$schema(),
1716
+ jsonSchema: {"type":"object","properties":{"sources":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["rss","link"]},"url":{"type":"string"},"label":{"type":"string"},"enabled":{"type":"boolean"},"addedAt":{"type":"string","description":"When the reader added it (ISO-8601). The browser needs this to order the wall and the management list by \"when did this arrive\": a saved link carries no publication date at all, so without this field it sorts as the oldest thing on the wall — which is exactly where a reader who just added it will not look."},"fetchedAt":{"type":"string"},"status":{"type":"string","enum":["error","ok","fetching"]},"error":{"type":"string"},"truncated":{"type":"boolean"},"hasBody":{"type":"boolean"},"failure":{"type":"object","properties":{"code":{"type":"string","enum":["blocked","http","unreadable","empty","login","unsupported-type","redirected","unreachable"]},"message":{"type":"string"}},"required":["code","message"],"additionalProperties":true,"description":"Present when this source has no previewable body (see {@link ReaderPreviewFailure})."},"resolvedFrom":{"type":"string","description":"The URL the reader pasted, when the source was resolved to a canonical version (see {@link ReaderSource.resolvedFrom})."}},"required":["id","kind","url","label","enabled","addedAt","hasBody"],"additionalProperties":true}}},"required":["sources"],"additionalProperties":true},
845
1717
  },
846
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":66,"column":9},
1718
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":73,"column":9},
847
1719
  },
848
- {
849
- id: '@khorsheed/dsh-reader#reader/listTags',
1720
+ 'reader/listTags': {
850
1721
  service: 'readerRemote',
851
- namespace: 'reader',
852
- method: 'listTags',
1722
+ description: 'The tag vocabulary, with how many entries carry each tag.',
853
1723
  invocation: { kind: 'direct' },
854
1724
  parameters: [
855
1725
  ],
@@ -858,14 +1728,226 @@ export const TYPERT_REMOTE = {
858
1728
  typeSymbol: '@khorsheed/dsh-reader#reader/listTags:result',
859
1729
  create: _khorsheed_dsh_reader_reader_listTags_result$schema,
860
1730
  schema: _khorsheed_dsh_reader_reader_listTags_result$schema(),
1731
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
1732
+ },
1733
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":222,"column":3},
1734
+ },
1735
+ 'reader/localTranscript': {
1736
+ service: 'readerRemote',
1737
+ description: 'Where an entry\'s local transcription stands, with the transcript so far.',
1738
+ invocation: { kind: 'direct' },
1739
+ parameters: [
1740
+ {
1741
+ name: 'request',
1742
+ source: 'json',
1743
+ codec: {
1744
+ mode: 'strict',
1745
+ typeSymbol: '@khorsheed/dsh-reader#reader/localTranscript:request',
1746
+ create: _khorsheed_dsh_reader_reader_localTranscript_parameter_0$schema,
1747
+ schema: _khorsheed_dsh_reader_reader_localTranscript_parameter_0$schema(),
1748
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
1749
+ },
1750
+ strictCodec: {
1751
+ mode: 'strict',
1752
+ typeSymbol: '@khorsheed/dsh-reader#reader/localTranscript:request',
1753
+ create: _khorsheed_dsh_reader_reader_localTranscript_parameter_0_strict$schema,
1754
+ schema: _khorsheed_dsh_reader_reader_localTranscript_parameter_0_strict$schema(),
1755
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":false},
1756
+ },
1757
+ },
1758
+ ],
1759
+ result: {
1760
+ mode: 'strict',
1761
+ typeSymbol: '@khorsheed/dsh-reader/types#LocalTranscriptStatus',
1762
+ create: _khorsheed_dsh_reader_reader_localTranscript_result$schema,
1763
+ schema: _khorsheed_dsh_reader_reader_localTranscript_result$schema(),
1764
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"state":{"type":"string","enum":["failed","unavailable","done","idle","queued","fetching","needs-models","transcribing","speakers"]},"progress":{"type":"number","description":"0–1 across fetching the audio and transcribing it."},"ahead":{"type":"number","description":"Jobs ahead in the engine's queue."},"bytes":{"type":"number","description":"Bytes of speech models still to download (`needs-models`)."},"html":{"type":"string","description":"The transcript so far (or in full, once `done`)."},"language":{"type":"string","description":"The language the transcript is in, once known."},"speakers":{"type":"number","description":"How many voices the transcript has, once the speakers pass settled it."},"error":{"type":"string"}},"required":["entryId","state"],"additionalProperties":true},
1765
+ },
1766
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":386,"column":3},
1767
+ },
1768
+ 'reader/markSynced': {
1769
+ service: 'readerRemote',
1770
+ description: 'Remember that a note or a discussion note became a canvas card.',
1771
+ invocation: { kind: 'direct' },
1772
+ parameters: [
1773
+ {
1774
+ name: 'request',
1775
+ source: 'json',
1776
+ codec: {
1777
+ mode: 'strict',
1778
+ typeSymbol: '@khorsheed/dsh-reader#reader/markSynced:request',
1779
+ create: _khorsheed_dsh_reader_reader_markSynced_parameter_0$schema,
1780
+ schema: _khorsheed_dsh_reader_reader_markSynced_parameter_0$schema(),
1781
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"},"discussionId":{"type":"string"},"canvasId":{"type":"string"},"cardId":{"type":"string"},"canvasTitle":{"type":"string"}},"required":["entryId","canvasId","cardId","canvasTitle"],"additionalProperties":true},
1782
+ },
1783
+ strictCodec: {
1784
+ mode: 'strict',
1785
+ typeSymbol: '@khorsheed/dsh-reader#reader/markSynced:request',
1786
+ create: _khorsheed_dsh_reader_reader_markSynced_parameter_0_strict$schema,
1787
+ schema: _khorsheed_dsh_reader_reader_markSynced_parameter_0_strict$schema(),
1788
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"},"discussionId":{"type":"string"},"canvasId":{"type":"string"},"cardId":{"type":"string"},"canvasTitle":{"type":"string"}},"required":["entryId","canvasId","cardId","canvasTitle"],"additionalProperties":false},
1789
+ },
1790
+ },
1791
+ ],
1792
+ result: {
1793
+ mode: 'strict',
1794
+ typeSymbol: '@khorsheed/dsh-reader/types#ReaderNoteOutcome',
1795
+ create: _khorsheed_dsh_reader_reader_markSynced_result$schema,
1796
+ schema: _khorsheed_dsh_reader_reader_markSynced_result$schema(),
1797
+ jsonSchema: {"type":"string","enum":["not-found","ok","empty","full"]},
1798
+ },
1799
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":358,"column":3},
1800
+ },
1801
+ 'reader/mediaStates': {
1802
+ service: 'readerRemote',
1803
+ description: 'The wall\'s video / audio cards: what each one\'s transcript is (captions, local, transcribing…).',
1804
+ invocation: { kind: 'direct' },
1805
+ parameters: [
1806
+ {
1807
+ name: 'request',
1808
+ source: 'json',
1809
+ codec: {
1810
+ mode: 'strict',
1811
+ typeSymbol: '@khorsheed/dsh-reader#reader/mediaStates:request',
1812
+ create: _khorsheed_dsh_reader_reader_mediaStates_parameter_0$schema,
1813
+ schema: _khorsheed_dsh_reader_reader_mediaStates_parameter_0$schema(),
1814
+ jsonSchema: {"type":"object","properties":{"entryIds":{"type":"array","items":{"type":"string"}}},"required":["entryIds"],"additionalProperties":true},
1815
+ },
1816
+ strictCodec: {
1817
+ mode: 'strict',
1818
+ typeSymbol: '@khorsheed/dsh-reader#reader/mediaStates:request',
1819
+ create: _khorsheed_dsh_reader_reader_mediaStates_parameter_0_strict$schema,
1820
+ schema: _khorsheed_dsh_reader_reader_mediaStates_parameter_0_strict$schema(),
1821
+ jsonSchema: {"type":"object","properties":{"entryIds":{"type":"array","items":{"type":"string"}}},"required":["entryIds"],"additionalProperties":false},
1822
+ },
1823
+ },
1824
+ ],
1825
+ result: {
1826
+ mode: 'strict',
1827
+ typeSymbol: '@khorsheed/dsh-reader/types#MediaCardStates',
1828
+ create: _khorsheed_dsh_reader_reader_mediaStates_result$schema,
1829
+ schema: _khorsheed_dsh_reader_reader_mediaStates_result$schema(),
1830
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
1831
+ },
1832
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":404,"column":3},
1833
+ },
1834
+ 'reader/mediaTranscript': {
1835
+ service: 'readerRemote',
1836
+ description: 'A video entry\'s transcript from its platform captions (stored; `none` when it has none).',
1837
+ invocation: { kind: 'direct' },
1838
+ parameters: [
1839
+ {
1840
+ name: 'request',
1841
+ source: 'json',
1842
+ codec: {
1843
+ mode: 'strict',
1844
+ typeSymbol: '@khorsheed/dsh-reader#reader/mediaTranscript:request',
1845
+ create: _khorsheed_dsh_reader_reader_mediaTranscript_parameter_0$schema,
1846
+ schema: _khorsheed_dsh_reader_reader_mediaTranscript_parameter_0$schema(),
1847
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"}},"required":["entryId","url"],"additionalProperties":true},
1848
+ },
1849
+ strictCodec: {
1850
+ mode: 'strict',
1851
+ typeSymbol: '@khorsheed/dsh-reader#reader/mediaTranscript:request',
1852
+ create: _khorsheed_dsh_reader_reader_mediaTranscript_parameter_0_strict$schema,
1853
+ schema: _khorsheed_dsh_reader_reader_mediaTranscript_parameter_0_strict$schema(),
1854
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"}},"required":["entryId","url"],"additionalProperties":false},
1855
+ },
1856
+ },
1857
+ ],
1858
+ result: {
1859
+ mode: 'strict',
1860
+ typeSymbol: '@khorsheed/dsh-reader#reader/mediaTranscript:result',
1861
+ create: _khorsheed_dsh_reader_reader_mediaTranscript_result$schema,
1862
+ schema: _khorsheed_dsh_reader_reader_mediaTranscript_result$schema(),
1863
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"html":{"type":"string"},"captions":{"type":"string","enum":["failed","none","platform"]},"language":{"type":"string"},"error":{"type":"string"}},"required":["entryId","captions"],"additionalProperties":true},
1864
+ },
1865
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":370,"column":3},
1866
+ },
1867
+ 'reader/nameSpeaker': {
1868
+ service: 'readerRemote',
1869
+ description: 'Name one speaker of a transcript (empty: back to 说话人 A…); answers all the names.',
1870
+ invocation: { kind: 'direct' },
1871
+ parameters: [
1872
+ {
1873
+ name: 'request',
1874
+ source: 'json',
1875
+ codec: {
1876
+ mode: 'strict',
1877
+ typeSymbol: '@khorsheed/dsh-reader#reader/nameSpeaker:request',
1878
+ create: _khorsheed_dsh_reader_reader_nameSpeaker_parameter_0$schema,
1879
+ schema: _khorsheed_dsh_reader_reader_nameSpeaker_parameter_0$schema(),
1880
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"speaker":{"type":"number"},"name":{"type":"string"}},"required":["entryId","speaker","name"],"additionalProperties":true},
1881
+ },
1882
+ strictCodec: {
1883
+ mode: 'strict',
1884
+ typeSymbol: '@khorsheed/dsh-reader#reader/nameSpeaker:request',
1885
+ create: _khorsheed_dsh_reader_reader_nameSpeaker_parameter_0_strict$schema,
1886
+ schema: _khorsheed_dsh_reader_reader_nameSpeaker_parameter_0_strict$schema(),
1887
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"speaker":{"type":"number"},"name":{"type":"string"}},"required":["entryId","speaker","name"],"additionalProperties":false},
1888
+ },
1889
+ },
1890
+ ],
1891
+ result: {
1892
+ mode: 'strict',
1893
+ typeSymbol: '@khorsheed/dsh-reader#reader/nameSpeaker:result',
1894
+ create: _khorsheed_dsh_reader_reader_nameSpeaker_result$schema,
1895
+ schema: _khorsheed_dsh_reader_reader_nameSpeaker_result$schema(),
1896
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
1897
+ },
1898
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":398,"column":3},
1899
+ },
1900
+ 'reader/noteCounts': {
1901
+ service: 'readerRemote',
1902
+ description: 'How many notes each article carries.',
1903
+ invocation: { kind: 'direct' },
1904
+ parameters: [
1905
+ ],
1906
+ result: {
1907
+ mode: 'strict',
1908
+ typeSymbol: '@khorsheed/dsh-reader#reader/noteCounts:result',
1909
+ create: _khorsheed_dsh_reader_reader_noteCounts_result$schema,
1910
+ schema: _khorsheed_dsh_reader_reader_noteCounts_result$schema(),
1911
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
1912
+ },
1913
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":316,"column":9},
1914
+ },
1915
+ 'reader/polish': {
1916
+ service: 'readerRemote',
1917
+ description: 'The article\'s 润色 layer (the agent\'s translation), when there is one for its current text.',
1918
+ invocation: { kind: 'direct' },
1919
+ parameters: [
1920
+ {
1921
+ name: 'request',
1922
+ source: 'json',
1923
+ codec: {
1924
+ mode: 'strict',
1925
+ typeSymbol: '@khorsheed/dsh-reader#reader/polish:request',
1926
+ create: _khorsheed_dsh_reader_reader_polish_parameter_0$schema,
1927
+ schema: _khorsheed_dsh_reader_reader_polish_parameter_0$schema(),
1928
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
1929
+ },
1930
+ strictCodec: {
1931
+ mode: 'strict',
1932
+ typeSymbol: '@khorsheed/dsh-reader#reader/polish:request',
1933
+ create: _khorsheed_dsh_reader_reader_polish_parameter_0_strict$schema,
1934
+ schema: _khorsheed_dsh_reader_reader_polish_parameter_0_strict$schema(),
1935
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":false},
1936
+ },
1937
+ },
1938
+ ],
1939
+ result: {
1940
+ mode: 'strict',
1941
+ typeSymbol: '@khorsheed/dsh-reader#reader/polish:result',
1942
+ create: _khorsheed_dsh_reader_reader_polish_result$schema,
1943
+ schema: _khorsheed_dsh_reader_reader_polish_result$schema(),
1944
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
861
1945
  },
862
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":215,"column":3},
1946
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":416,"column":3},
863
1947
  },
864
- {
865
- id: '@khorsheed/dsh-reader#reader/pruneTags',
1948
+ 'reader/pruneTags': {
866
1949
  service: 'readerRemote',
867
- namespace: 'reader',
868
- method: 'pruneTags',
1950
+ description: 'Drop tags nothing references any more.',
869
1951
  invocation: { kind: 'direct' },
870
1952
  parameters: [
871
1953
  ],
@@ -874,25 +1956,31 @@ export const TYPERT_REMOTE = {
874
1956
  typeSymbol: '@khorsheed/dsh-reader#reader/pruneTags:result',
875
1957
  create: _khorsheed_dsh_reader_reader_pruneTags_result$schema,
876
1958
  schema: _khorsheed_dsh_reader_reader_pruneTags_result$schema(),
1959
+ jsonSchema: {"type":"object","properties":{"removed":{"type":"number"}},"required":["removed"],"additionalProperties":true},
877
1960
  },
878
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":262,"column":3},
1961
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":269,"column":3},
879
1962
  },
880
- {
881
- id: '@khorsheed/dsh-reader#reader/quoteToSideChat',
1963
+ 'reader/quoteToSideChat': {
882
1964
  service: 'readerRemote',
883
- namespace: 'reader',
884
- method: 'quoteToSideChat',
1965
+ description: 'Forward a ref block to the side-chat service when one is composed.',
885
1966
  invocation: { kind: 'direct' },
886
1967
  parameters: [
887
1968
  {
888
1969
  name: 'request',
889
- wire: 'request',
890
1970
  source: 'json',
891
1971
  codec: {
892
1972
  mode: 'strict',
893
1973
  typeSymbol: '@khorsheed/dsh-reader#reader/quoteToSideChat:request',
894
1974
  create: _khorsheed_dsh_reader_reader_quoteToSideChat_parameter_0$schema,
895
1975
  schema: _khorsheed_dsh_reader_reader_quoteToSideChat_parameter_0$schema(),
1976
+ jsonSchema: {"type":"object","properties":{"contextKey":{"type":"string"},"label":{"type":"string"},"text":{"type":"string"}},"required":["contextKey","label","text"],"additionalProperties":true},
1977
+ },
1978
+ strictCodec: {
1979
+ mode: 'strict',
1980
+ typeSymbol: '@khorsheed/dsh-reader#reader/quoteToSideChat:request',
1981
+ create: _khorsheed_dsh_reader_reader_quoteToSideChat_parameter_0_strict$schema,
1982
+ schema: _khorsheed_dsh_reader_reader_quoteToSideChat_parameter_0_strict$schema(),
1983
+ jsonSchema: {"type":"object","properties":{"contextKey":{"type":"string"},"label":{"type":"string"},"text":{"type":"string"}},"required":["contextKey","label","text"],"additionalProperties":false},
896
1984
  },
897
1985
  },
898
1986
  ],
@@ -901,25 +1989,64 @@ export const TYPERT_REMOTE = {
901
1989
  typeSymbol: '@khorsheed/dsh-reader#reader/quoteToSideChat:result',
902
1990
  create: _khorsheed_dsh_reader_reader_quoteToSideChat_result$schema,
903
1991
  schema: _khorsheed_dsh_reader_reader_quoteToSideChat_result$schema(),
1992
+ jsonSchema: {"type":"string","enum":["unavailable","ok"]},
1993
+ },
1994
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":298,"column":3},
1995
+ },
1996
+ 'reader/recordDiscussion': {
1997
+ service: 'readerRemote',
1998
+ description: 'Remember that a conversation discussed this article.',
1999
+ invocation: { kind: 'direct' },
2000
+ parameters: [
2001
+ {
2002
+ name: 'request',
2003
+ source: 'json',
2004
+ codec: {
2005
+ mode: 'strict',
2006
+ typeSymbol: '@khorsheed/dsh-reader#reader/recordDiscussion:request',
2007
+ create: _khorsheed_dsh_reader_reader_recordDiscussion_parameter_0$schema,
2008
+ schema: _khorsheed_dsh_reader_reader_recordDiscussion_parameter_0$schema(),
2009
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"},"source":{"type":"string"},"sessionId":{"type":"string"},"sessionTitle":{"type":"string"}},"required":["entryId","title","sessionId"],"additionalProperties":true},
2010
+ },
2011
+ strictCodec: {
2012
+ mode: 'strict',
2013
+ typeSymbol: '@khorsheed/dsh-reader#reader/recordDiscussion:request',
2014
+ create: _khorsheed_dsh_reader_reader_recordDiscussion_parameter_0_strict$schema,
2015
+ schema: _khorsheed_dsh_reader_reader_recordDiscussion_parameter_0_strict$schema(),
2016
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"},"source":{"type":"string"},"sessionId":{"type":"string"},"sessionTitle":{"type":"string"}},"required":["entryId","title","sessionId"],"additionalProperties":false},
2017
+ },
2018
+ },
2019
+ ],
2020
+ result: {
2021
+ mode: 'strict',
2022
+ typeSymbol: '@khorsheed/dsh-reader#reader/recordDiscussion:result',
2023
+ create: _khorsheed_dsh_reader_reader_recordDiscussion_result$schema,
2024
+ schema: _khorsheed_dsh_reader_reader_recordDiscussion_result$schema(),
2025
+ jsonSchema: {"type":"string","enum":["ok","empty"]},
904
2026
  },
905
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":291,"column":3},
2027
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":340,"column":3},
906
2028
  },
907
- {
908
- id: '@khorsheed/dsh-reader#reader/recordRead',
2029
+ 'reader/recordRead': {
909
2030
  service: 'readerRemote',
910
- namespace: 'reader',
911
- method: 'recordRead',
2031
+ description: 'Record that the reader opened one entry (the recent page\'s write half).',
912
2032
  invocation: { kind: 'direct' },
913
2033
  parameters: [
914
2034
  {
915
2035
  name: 'request',
916
- wire: 'request',
917
2036
  source: 'json',
918
2037
  codec: {
919
2038
  mode: 'strict',
920
2039
  typeSymbol: '@khorsheed/dsh-reader#reader/recordRead:request',
921
2040
  create: _khorsheed_dsh_reader_reader_recordRead_parameter_0$schema,
922
2041
  schema: _khorsheed_dsh_reader_reader_recordRead_parameter_0$schema(),
2042
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"sourceId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"}},"required":["entryId","sourceId","title"],"additionalProperties":true},
2043
+ },
2044
+ strictCodec: {
2045
+ mode: 'strict',
2046
+ typeSymbol: '@khorsheed/dsh-reader#reader/recordRead:request',
2047
+ create: _khorsheed_dsh_reader_reader_recordRead_parameter_0_strict$schema,
2048
+ schema: _khorsheed_dsh_reader_reader_recordRead_parameter_0_strict$schema(),
2049
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"sourceId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"}},"required":["entryId","sourceId","title"],"additionalProperties":false},
923
2050
  },
924
2051
  },
925
2052
  ],
@@ -928,25 +2055,31 @@ export const TYPERT_REMOTE = {
928
2055
  typeSymbol: '@khorsheed/dsh-reader#reader/recordRead:result',
929
2056
  create: _khorsheed_dsh_reader_reader_recordRead_result$schema,
930
2057
  schema: _khorsheed_dsh_reader_reader_recordRead_result$schema(),
2058
+ jsonSchema: {"type":"object","properties":{"entries":{"type":"number"}},"required":["entries"],"additionalProperties":true},
931
2059
  },
932
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":268,"column":3},
2060
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":275,"column":3},
933
2061
  },
934
- {
935
- id: '@khorsheed/dsh-reader#reader/refresh',
2062
+ 'reader/refresh': {
936
2063
  service: 'readerRemote',
937
- namespace: 'reader',
938
- method: 'refresh',
2064
+ description: 'Fetch the named sources (or every enabled one) now.',
939
2065
  invocation: { kind: 'direct' },
940
2066
  parameters: [
941
2067
  {
942
2068
  name: 'request',
943
- wire: 'request',
944
2069
  source: 'json',
945
2070
  codec: {
946
2071
  mode: 'strict',
947
2072
  typeSymbol: '@khorsheed/dsh-reader#reader/refresh:request',
948
2073
  create: _khorsheed_dsh_reader_reader_refresh_parameter_0$schema,
949
2074
  schema: _khorsheed_dsh_reader_reader_refresh_parameter_0$schema(),
2075
+ jsonSchema: {"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}}},"required":[],"additionalProperties":true},
2076
+ },
2077
+ strictCodec: {
2078
+ mode: 'strict',
2079
+ typeSymbol: '@khorsheed/dsh-reader#reader/refresh:request',
2080
+ create: _khorsheed_dsh_reader_reader_refresh_parameter_0_strict$schema,
2081
+ schema: _khorsheed_dsh_reader_reader_refresh_parameter_0_strict$schema(),
2082
+ jsonSchema: {"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}}},"required":[],"additionalProperties":false},
950
2083
  },
951
2084
  },
952
2085
  ],
@@ -955,25 +2088,31 @@ export const TYPERT_REMOTE = {
955
2088
  typeSymbol: '@khorsheed/dsh-reader#reader/refresh:result',
956
2089
  create: _khorsheed_dsh_reader_reader_refresh_result$schema,
957
2090
  schema: _khorsheed_dsh_reader_reader_refresh_result$schema(),
2091
+ jsonSchema: {"type":"object","properties":{"results":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"status":{"type":"string","enum":["unavailable","ok","fetch-failed","truncated"]},"message":{"type":"string"}},"required":["id","status"],"additionalProperties":true}}},"required":["results"],"additionalProperties":true},
958
2092
  },
959
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":96,"column":9},
2093
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":103,"column":9},
960
2094
  },
961
- {
962
- id: '@khorsheed/dsh-reader#reader/rememberSentences',
2095
+ 'reader/rememberSentences': {
963
2096
  service: 'readerRemote',
964
- namespace: 'reader',
965
- method: 'rememberSentences',
2097
+ description: 'Persist what one translation run learned (and refresh what it reused), in one batch.',
966
2098
  invocation: { kind: 'direct' },
967
2099
  parameters: [
968
2100
  {
969
2101
  name: 'request',
970
- wire: 'request',
971
2102
  source: 'json',
972
2103
  codec: {
973
2104
  mode: 'strict',
974
2105
  typeSymbol: '@khorsheed/dsh-reader#reader/rememberSentences:request',
975
2106
  create: _khorsheed_dsh_reader_reader_rememberSentences_parameter_0$schema,
976
2107
  schema: _khorsheed_dsh_reader_reader_rememberSentences_parameter_0$schema(),
2108
+ jsonSchema: {"type":"object","properties":{"pair":{"type":"string"},"entries":{"type":"array","items":{"type":"object","properties":{"hash":{"type":"string","description":"The client's `translationHash(source)`, stored opaquely."},"source":{"type":"string"},"target":{"type":"string"}},"required":["hash","source","target"],"additionalProperties":true}},"recalled":{"type":"array","items":{"type":"object","properties":{"hash":{"type":"string","description":"The client's `translationHash(source)`, stored opaquely."},"source":{"type":"string"},"target":{"type":"string"}},"required":["hash","source","target"],"additionalProperties":true}},"entryId":{"type":"string"},"bodyHash":{"type":"string"}},"required":["pair","entries"],"additionalProperties":true},
2109
+ },
2110
+ strictCodec: {
2111
+ mode: 'strict',
2112
+ typeSymbol: '@khorsheed/dsh-reader#reader/rememberSentences:request',
2113
+ create: _khorsheed_dsh_reader_reader_rememberSentences_parameter_0_strict$schema,
2114
+ schema: _khorsheed_dsh_reader_reader_rememberSentences_parameter_0_strict$schema(),
2115
+ jsonSchema: {"type":"object","properties":{"pair":{"type":"string"},"entries":{"type":"array","items":{"type":"object","properties":{"hash":{"type":"string","description":"The client's `translationHash(source)`, stored opaquely."},"source":{"type":"string"},"target":{"type":"string"}},"required":["hash","source","target"],"additionalProperties":false}},"recalled":{"type":"array","items":{"type":"object","properties":{"hash":{"type":"string","description":"The client's `translationHash(source)`, stored opaquely."},"source":{"type":"string"},"target":{"type":"string"}},"required":["hash","source","target"],"additionalProperties":false}},"entryId":{"type":"string"},"bodyHash":{"type":"string"}},"required":["pair","entries"],"additionalProperties":false},
977
2116
  },
978
2117
  },
979
2118
  ],
@@ -982,25 +2121,31 @@ export const TYPERT_REMOTE = {
982
2121
  typeSymbol: '@khorsheed/dsh-reader#reader/rememberSentences:result',
983
2122
  create: _khorsheed_dsh_reader_reader_rememberSentences_result$schema,
984
2123
  schema: _khorsheed_dsh_reader_reader_rememberSentences_result$schema(),
2124
+ jsonSchema: {"type":"object","properties":{"stored":{"type":"number"}},"required":["stored"],"additionalProperties":true},
985
2125
  },
986
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":191,"column":3},
2126
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":198,"column":3},
987
2127
  },
988
- {
989
- id: '@khorsheed/dsh-reader#reader/removeSource',
2128
+ 'reader/removeSource': {
990
2129
  service: 'readerRemote',
991
- namespace: 'reader',
992
- method: 'removeSource',
2130
+ description: 'Drop a source; its entries\' translations go with it (their bodies stay for the budget).',
993
2131
  invocation: { kind: 'direct' },
994
2132
  parameters: [
995
2133
  {
996
2134
  name: 'request',
997
- wire: 'request',
998
2135
  source: 'json',
999
2136
  codec: {
1000
2137
  mode: 'strict',
1001
2138
  typeSymbol: '@khorsheed/dsh-reader#reader/removeSource:request',
1002
2139
  create: _khorsheed_dsh_reader_reader_removeSource_parameter_0$schema,
1003
2140
  schema: _khorsheed_dsh_reader_reader_removeSource_parameter_0$schema(),
2141
+ jsonSchema: {"type":"object","properties":{"id":{"type":"string"},"entryIds":{"type":"array","items":{"type":"string"}}},"required":["id"],"additionalProperties":true},
2142
+ },
2143
+ strictCodec: {
2144
+ mode: 'strict',
2145
+ typeSymbol: '@khorsheed/dsh-reader#reader/removeSource:request',
2146
+ create: _khorsheed_dsh_reader_reader_removeSource_parameter_0_strict$schema,
2147
+ schema: _khorsheed_dsh_reader_reader_removeSource_parameter_0_strict$schema(),
2148
+ jsonSchema: {"type":"object","properties":{"id":{"type":"string"},"entryIds":{"type":"array","items":{"type":"string"}}},"required":["id"],"additionalProperties":false},
1004
2149
  },
1005
2150
  },
1006
2151
  ],
@@ -1009,25 +2154,31 @@ export const TYPERT_REMOTE = {
1009
2154
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderMutationOutcome',
1010
2155
  create: _khorsheed_dsh_reader_reader_removeSource_result$schema,
1011
2156
  schema: _khorsheed_dsh_reader_reader_removeSource_result$schema(),
2157
+ jsonSchema: {"type":"string","enum":["not-found","unavailable","duplicate","ok","invalid-url","invalid-time"]},
1012
2158
  },
1013
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":90,"column":3},
2159
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":97,"column":3},
1014
2160
  },
1015
- {
1016
- id: '@khorsheed/dsh-reader#reader/renameTag',
2161
+ 'reader/renameTag': {
1017
2162
  service: 'readerRemote',
1018
- namespace: 'reader',
1019
- method: 'renameTag',
2163
+ description: 'Rename a tag without touching the entries that carry it.',
1020
2164
  invocation: { kind: 'direct' },
1021
2165
  parameters: [
1022
2166
  {
1023
2167
  name: 'request',
1024
- wire: 'request',
1025
2168
  source: 'json',
1026
2169
  codec: {
1027
2170
  mode: 'strict',
1028
2171
  typeSymbol: '@khorsheed/dsh-reader#reader/renameTag:request',
1029
2172
  create: _khorsheed_dsh_reader_reader_renameTag_parameter_0$schema,
1030
2173
  schema: _khorsheed_dsh_reader_reader_renameTag_parameter_0$schema(),
2174
+ jsonSchema: {"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":true},
2175
+ },
2176
+ strictCodec: {
2177
+ mode: 'strict',
2178
+ typeSymbol: '@khorsheed/dsh-reader#reader/renameTag:request',
2179
+ create: _khorsheed_dsh_reader_reader_renameTag_parameter_0_strict$schema,
2180
+ schema: _khorsheed_dsh_reader_reader_renameTag_parameter_0_strict$schema(),
2181
+ jsonSchema: {"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},
1031
2182
  },
1032
2183
  },
1033
2184
  ],
@@ -1036,25 +2187,30 @@ export const TYPERT_REMOTE = {
1036
2187
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderAnnotationOutcome',
1037
2188
  create: _khorsheed_dsh_reader_reader_renameTag_result$schema,
1038
2189
  schema: _khorsheed_dsh_reader_reader_renameTag_result$schema(),
2190
+ jsonSchema: {"type":"string","enum":["not-found","unavailable","duplicate","ok","empty","invalid"]},
1039
2191
  },
1040
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":227,"column":3},
2192
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":234,"column":3},
1041
2193
  },
1042
- {
1043
- id: '@khorsheed/dsh-reader#reader/setCachePolicy',
2194
+ 'reader/setCachePolicy': {
1044
2195
  service: 'readerRemote',
1045
- namespace: 'reader',
1046
- method: 'setCachePolicy',
1047
2196
  invocation: { kind: 'direct' },
1048
2197
  parameters: [
1049
2198
  {
1050
2199
  name: 'request',
1051
- wire: 'request',
1052
2200
  source: 'json',
1053
2201
  codec: {
1054
2202
  mode: 'strict',
1055
2203
  typeSymbol: '@khorsheed/dsh-reader#reader/setCachePolicy:request',
1056
2204
  create: _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0$schema,
1057
2205
  schema: _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0$schema(),
2206
+ jsonSchema: {"type":"object","properties":{"ttlHours":{"type":"number"},"maxEntries":{"type":"number"},"translationBudgetChars":{"type":"number"}},"required":["ttlHours"],"additionalProperties":true},
2207
+ },
2208
+ strictCodec: {
2209
+ mode: 'strict',
2210
+ typeSymbol: '@khorsheed/dsh-reader#reader/setCachePolicy:request',
2211
+ create: _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0_strict$schema,
2212
+ schema: _khorsheed_dsh_reader_reader_setCachePolicy_parameter_0_strict$schema(),
2213
+ jsonSchema: {"type":"object","properties":{"ttlHours":{"type":"number"},"maxEntries":{"type":"number"},"translationBudgetChars":{"type":"number"}},"required":["ttlHours"],"additionalProperties":false},
1058
2214
  },
1059
2215
  },
1060
2216
  ],
@@ -1063,25 +2219,163 @@ export const TYPERT_REMOTE = {
1063
2219
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderAnnotationOutcome',
1064
2220
  create: _khorsheed_dsh_reader_reader_setCachePolicy_result$schema,
1065
2221
  schema: _khorsheed_dsh_reader_reader_setCachePolicy_result$schema(),
2222
+ jsonSchema: {"type":"string","enum":["not-found","unavailable","duplicate","ok","empty","invalid"]},
2223
+ },
2224
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":263,"column":3},
2225
+ },
2226
+ 'reader/setPolishOff': {
2227
+ service: 'readerRemote',
2228
+ description: 'Show one paragraph\'s machine translation instead of the 润色 (or back).',
2229
+ invocation: { kind: 'direct' },
2230
+ parameters: [
2231
+ {
2232
+ name: 'request',
2233
+ source: 'json',
2234
+ codec: {
2235
+ mode: 'strict',
2236
+ typeSymbol: '@khorsheed/dsh-reader#reader/setPolishOff:request',
2237
+ create: _khorsheed_dsh_reader_reader_setPolishOff_parameter_0$schema,
2238
+ schema: _khorsheed_dsh_reader_reader_setPolishOff_parameter_0$schema(),
2239
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"paragraph":{"type":"number"},"off":{"type":"boolean"}},"required":["entryId","paragraph","off"],"additionalProperties":true},
2240
+ },
2241
+ strictCodec: {
2242
+ mode: 'strict',
2243
+ typeSymbol: '@khorsheed/dsh-reader#reader/setPolishOff:request',
2244
+ create: _khorsheed_dsh_reader_reader_setPolishOff_parameter_0_strict$schema,
2245
+ schema: _khorsheed_dsh_reader_reader_setPolishOff_parameter_0_strict$schema(),
2246
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"paragraph":{"type":"number"},"off":{"type":"boolean"}},"required":["entryId","paragraph","off"],"additionalProperties":false},
2247
+ },
2248
+ },
2249
+ ],
2250
+ result: {
2251
+ mode: 'strict',
2252
+ typeSymbol: '@khorsheed/dsh-reader#reader/setPolishOff:result',
2253
+ create: _khorsheed_dsh_reader_reader_setPolishOff_result$schema,
2254
+ schema: _khorsheed_dsh_reader_reader_setPolishOff_result$schema(),
2255
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
2256
+ },
2257
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":422,"column":3},
2258
+ },
2259
+ 'reader/snapshotEntry': {
2260
+ service: 'readerRemote',
2261
+ description: 'Hand the host the article\'s original text, block by block, for the model to read.',
2262
+ invocation: { kind: 'direct' },
2263
+ parameters: [
2264
+ {
2265
+ name: 'request',
2266
+ source: 'json',
2267
+ codec: {
2268
+ mode: 'strict',
2269
+ typeSymbol: '@khorsheed/dsh-reader#reader/snapshotEntry:request',
2270
+ create: _khorsheed_dsh_reader_reader_snapshotEntry_parameter_0$schema,
2271
+ schema: _khorsheed_dsh_reader_reader_snapshotEntry_parameter_0$schema(),
2272
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"},"source":{"type":"string"},"paragraphs":{"type":"array","items":{"type":"string"}}},"required":["entryId","title","paragraphs"],"additionalProperties":true},
2273
+ },
2274
+ strictCodec: {
2275
+ mode: 'strict',
2276
+ typeSymbol: '@khorsheed/dsh-reader#reader/snapshotEntry:request',
2277
+ create: _khorsheed_dsh_reader_reader_snapshotEntry_parameter_0_strict$schema,
2278
+ schema: _khorsheed_dsh_reader_reader_snapshotEntry_parameter_0_strict$schema(),
2279
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"},"source":{"type":"string"},"paragraphs":{"type":"array","items":{"type":"string"}}},"required":["entryId","title","paragraphs"],"additionalProperties":false},
2280
+ },
2281
+ },
2282
+ ],
2283
+ result: {
2284
+ mode: 'strict',
2285
+ typeSymbol: '@khorsheed/dsh-reader#reader/snapshotEntry:result',
2286
+ create: _khorsheed_dsh_reader_reader_snapshotEntry_result$schema,
2287
+ schema: _khorsheed_dsh_reader_reader_snapshotEntry_result$schema(),
2288
+ jsonSchema: {"type":"string","enum":["ok","empty"]},
2289
+ },
2290
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":428,"column":3},
2291
+ },
2292
+ 'reader/speakerNames': {
2293
+ service: 'readerRemote',
2294
+ description: 'The reader\'s names for a transcript\'s speakers, by index.',
2295
+ invocation: { kind: 'direct' },
2296
+ parameters: [
2297
+ {
2298
+ name: 'request',
2299
+ source: 'json',
2300
+ codec: {
2301
+ mode: 'strict',
2302
+ typeSymbol: '@khorsheed/dsh-reader#reader/speakerNames:request',
2303
+ create: _khorsheed_dsh_reader_reader_speakerNames_parameter_0$schema,
2304
+ schema: _khorsheed_dsh_reader_reader_speakerNames_parameter_0$schema(),
2305
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":true},
2306
+ },
2307
+ strictCodec: {
2308
+ mode: 'strict',
2309
+ typeSymbol: '@khorsheed/dsh-reader#reader/speakerNames:request',
2310
+ create: _khorsheed_dsh_reader_reader_speakerNames_parameter_0_strict$schema,
2311
+ schema: _khorsheed_dsh_reader_reader_speakerNames_parameter_0_strict$schema(),
2312
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"}},"required":["entryId"],"additionalProperties":false},
2313
+ },
2314
+ },
2315
+ ],
2316
+ result: {
2317
+ mode: 'strict',
2318
+ typeSymbol: '@khorsheed/dsh-reader#reader/speakerNames:result',
2319
+ create: _khorsheed_dsh_reader_reader_speakerNames_result$schema,
2320
+ schema: _khorsheed_dsh_reader_reader_speakerNames_result$schema(),
2321
+ jsonSchemaError: 'typert tool schema: selected dictionaries require string keys and unconstrained JSON values',
2322
+ },
2323
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":392,"column":3},
2324
+ },
2325
+ 'reader/startLocalTranscript': {
2326
+ service: 'readerRemote',
2327
+ description: 'Start (or rejoin) local transcription of an entry without captions. Answers `unavailable` without the transcription plugin and `needs-models` until the first model download is confirmed.',
2328
+ invocation: { kind: 'direct' },
2329
+ parameters: [
2330
+ {
2331
+ name: 'request',
2332
+ source: 'json',
2333
+ codec: {
2334
+ mode: 'strict',
2335
+ typeSymbol: '@khorsheed/dsh-reader#reader/startLocalTranscript:request',
2336
+ create: _khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0$schema,
2337
+ schema: _khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0$schema(),
2338
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"media":{"type":"object","properties":{"kind":{"type":"string","enum":["video","audio"]},"provider":{"type":"string","enum":["youtube","bilibili","xiaoyuzhou","enclosure"]},"ref":{"type":"string","description":"The platform's id (YouTube video id, Bilibili BV id) or the audio URL."},"durationSec":{"type":"number"},"thumbnail":{"type":"string"}},"required":["kind","provider","ref"],"additionalProperties":true},"title":{"type":"string"},"confirmModels":{"type":"boolean"}},"required":["entryId","url","media"],"additionalProperties":true},
2339
+ },
2340
+ strictCodec: {
2341
+ mode: 'strict',
2342
+ typeSymbol: '@khorsheed/dsh-reader#reader/startLocalTranscript:request',
2343
+ create: _khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0_strict$schema,
2344
+ schema: _khorsheed_dsh_reader_reader_startLocalTranscript_parameter_0_strict$schema(),
2345
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"media":{"type":"object","properties":{"kind":{"type":"string","enum":["video","audio"]},"provider":{"type":"string","enum":["youtube","bilibili","xiaoyuzhou","enclosure"]},"ref":{"type":"string","description":"The platform's id (YouTube video id, Bilibili BV id) or the audio URL."},"durationSec":{"type":"number"},"thumbnail":{"type":"string"}},"required":["kind","provider","ref"],"additionalProperties":false},"title":{"type":"string"},"confirmModels":{"type":"boolean"}},"required":["entryId","url","media"],"additionalProperties":false},
2346
+ },
2347
+ },
2348
+ ],
2349
+ result: {
2350
+ mode: 'strict',
2351
+ typeSymbol: '@khorsheed/dsh-reader/types#LocalTranscriptStatus',
2352
+ create: _khorsheed_dsh_reader_reader_startLocalTranscript_result$schema,
2353
+ schema: _khorsheed_dsh_reader_reader_startLocalTranscript_result$schema(),
2354
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"state":{"type":"string","enum":["failed","unavailable","done","idle","queued","fetching","needs-models","transcribing","speakers"]},"progress":{"type":"number","description":"0–1 across fetching the audio and transcribing it."},"ahead":{"type":"number","description":"Jobs ahead in the engine's queue."},"bytes":{"type":"number","description":"Bytes of speech models still to download (`needs-models`)."},"html":{"type":"string","description":"The transcript so far (or in full, once `done`)."},"language":{"type":"string","description":"The language the transcript is in, once known."},"speakers":{"type":"number","description":"How many voices the transcript has, once the speakers pass settled it."},"error":{"type":"string"}},"required":["entryId","state"],"additionalProperties":true},
1066
2355
  },
1067
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":256,"column":3},
2356
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":380,"column":3},
1068
2357
  },
1069
- {
1070
- id: '@khorsheed/dsh-reader#reader/storeEntryBody',
2358
+ 'reader/storeEntryBody': {
1071
2359
  service: 'readerRemote',
1072
- namespace: 'reader',
1073
- method: 'storeEntryBody',
2360
+ description: 'Cache the markup the browser extracted for one entry.',
1074
2361
  invocation: { kind: 'direct' },
1075
2362
  parameters: [
1076
2363
  {
1077
2364
  name: 'request',
1078
- wire: 'request',
1079
2365
  source: 'json',
1080
2366
  codec: {
1081
2367
  mode: 'strict',
1082
2368
  typeSymbol: '@khorsheed/dsh-reader#reader/storeEntryBody:request',
1083
2369
  create: _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0$schema,
1084
2370
  schema: _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0$schema(),
2371
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"html":{"type":"string"},"truncated":{"type":"boolean"},"scriptFigures":{"type":"number"},"bodyHash":{"type":"string"},"title":{"type":"string","description":"The article's own title, as extracted — the saved link's card upgrade."},"excerpt":{"type":"string","description":"A short excerpt (abstract / first paragraph), with the title."}},"required":["entryId","url","html"],"additionalProperties":true},
2372
+ },
2373
+ strictCodec: {
2374
+ mode: 'strict',
2375
+ typeSymbol: '@khorsheed/dsh-reader#reader/storeEntryBody:request',
2376
+ create: _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0_strict$schema,
2377
+ schema: _khorsheed_dsh_reader_reader_storeEntryBody_parameter_0_strict$schema(),
2378
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"url":{"type":"string"},"html":{"type":"string"},"truncated":{"type":"boolean"},"scriptFigures":{"type":"number"},"bodyHash":{"type":"string"},"title":{"type":"string","description":"The article's own title, as extracted — the saved link's card upgrade."},"excerpt":{"type":"string","description":"A short excerpt (abstract / first paragraph), with the title."}},"required":["entryId","url","html"],"additionalProperties":false},
1085
2379
  },
1086
2380
  },
1087
2381
  ],
@@ -1090,25 +2384,31 @@ export const TYPERT_REMOTE = {
1090
2384
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderEntryBodyView',
1091
2385
  create: _khorsheed_dsh_reader_reader_storeEntryBody_result$schema,
1092
2386
  schema: _khorsheed_dsh_reader_reader_storeEntryBody_result$schema(),
2387
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"cached":{"type":"boolean","description":"True when this body is a cached fetch rather than the feed's own payload."},"fresh":{"type":"boolean","description":"False when the cache's deadline has passed: the view offers the fetch."},"fromFeed":{"type":"boolean","description":"True when the feed's payload already carries full text for this entry."},"html":{"type":"string"},"fetchedAt":{"type":"string"},"truncated":{"type":"boolean"},"scriptFigures":{"type":"number","description":"Figures this page draws with scripts — the detail view says so."},"rendered":{"type":"boolean","description":"True when this body came from a rendered fetch (the「重新抓取」route reads it)."},"error":{"type":"string","description":"Why a fetch could not produce a body, when one was attempted."}},"required":["entryId","cached","fresh","fromFeed"],"additionalProperties":true},
1093
2388
  },
1094
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":139,"column":3},
2389
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":146,"column":3},
1095
2390
  },
1096
- {
1097
- id: '@khorsheed/dsh-reader#reader/tagEntry',
2391
+ 'reader/tagEntry': {
1098
2392
  service: 'readerRemote',
1099
- namespace: 'reader',
1100
- method: 'tagEntry',
2393
+ description: 'Add or remove one tag on one entry.',
1101
2394
  invocation: { kind: 'direct' },
1102
2395
  parameters: [
1103
2396
  {
1104
2397
  name: 'request',
1105
- wire: 'request',
1106
2398
  source: 'json',
1107
2399
  codec: {
1108
2400
  mode: 'strict',
1109
2401
  typeSymbol: '@khorsheed/dsh-reader#reader/tagEntry:request',
1110
2402
  create: _khorsheed_dsh_reader_reader_tagEntry_parameter_0$schema,
1111
2403
  schema: _khorsheed_dsh_reader_reader_tagEntry_parameter_0$schema(),
2404
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"tagId":{"type":"string"},"on":{"type":"boolean"}},"required":["entryId","tagId","on"],"additionalProperties":true},
2405
+ },
2406
+ strictCodec: {
2407
+ mode: 'strict',
2408
+ typeSymbol: '@khorsheed/dsh-reader#reader/tagEntry:request',
2409
+ create: _khorsheed_dsh_reader_reader_tagEntry_parameter_0_strict$schema,
2410
+ schema: _khorsheed_dsh_reader_reader_tagEntry_parameter_0_strict$schema(),
2411
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"tagId":{"type":"string"},"on":{"type":"boolean"}},"required":["entryId","tagId","on"],"additionalProperties":false},
1112
2412
  },
1113
2413
  },
1114
2414
  ],
@@ -1117,25 +2417,64 @@ export const TYPERT_REMOTE = {
1117
2417
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderAnnotationOutcome',
1118
2418
  create: _khorsheed_dsh_reader_reader_tagEntry_result$schema,
1119
2419
  schema: _khorsheed_dsh_reader_reader_tagEntry_result$schema(),
2420
+ jsonSchema: {"type":"string","enum":["not-found","unavailable","duplicate","ok","empty","invalid"]},
2421
+ },
2422
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":246,"column":3},
2423
+ },
2424
+ 'reader/updateNote': {
2425
+ service: 'readerRemote',
2426
+ description: 'Change or clear one note\'s comment.',
2427
+ invocation: { kind: 'direct' },
2428
+ parameters: [
2429
+ {
2430
+ name: 'request',
2431
+ source: 'json',
2432
+ codec: {
2433
+ mode: 'strict',
2434
+ typeSymbol: '@khorsheed/dsh-reader#reader/updateNote:request',
2435
+ create: _khorsheed_dsh_reader_reader_updateNote_parameter_0$schema,
2436
+ schema: _khorsheed_dsh_reader_reader_updateNote_parameter_0$schema(),
2437
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"},"comment":{"type":"string"}},"required":["entryId","noteId","comment"],"additionalProperties":true},
2438
+ },
2439
+ strictCodec: {
2440
+ mode: 'strict',
2441
+ typeSymbol: '@khorsheed/dsh-reader#reader/updateNote:request',
2442
+ create: _khorsheed_dsh_reader_reader_updateNote_parameter_0_strict$schema,
2443
+ schema: _khorsheed_dsh_reader_reader_updateNote_parameter_0_strict$schema(),
2444
+ jsonSchema: {"type":"object","properties":{"entryId":{"type":"string"},"noteId":{"type":"string"},"comment":{"type":"string"}},"required":["entryId","noteId","comment"],"additionalProperties":false},
2445
+ },
2446
+ },
2447
+ ],
2448
+ result: {
2449
+ mode: 'strict',
2450
+ typeSymbol: '@khorsheed/dsh-reader/types#ReaderNoteOutcome',
2451
+ create: _khorsheed_dsh_reader_reader_updateNote_result$schema,
2452
+ schema: _khorsheed_dsh_reader_reader_updateNote_result$schema(),
2453
+ jsonSchema: {"type":"string","enum":["not-found","ok","empty","full"]},
1120
2454
  },
1121
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":239,"column":3},
2455
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":328,"column":3},
1122
2456
  },
1123
- {
1124
- id: '@khorsheed/dsh-reader#reader/updateSource',
2457
+ 'reader/updateSource': {
1125
2458
  service: 'readerRemote',
1126
- namespace: 'reader',
1127
- method: 'updateSource',
2459
+ description: 'Change a source\'s label/enabled flag, or the global refresh time.',
1128
2460
  invocation: { kind: 'direct' },
1129
2461
  parameters: [
1130
2462
  {
1131
2463
  name: 'request',
1132
- wire: 'request',
1133
2464
  source: 'json',
1134
2465
  codec: {
1135
2466
  mode: 'strict',
1136
2467
  typeSymbol: '@khorsheed/dsh-reader#reader/updateSource:request',
1137
2468
  create: _khorsheed_dsh_reader_reader_updateSource_parameter_0$schema,
1138
2469
  schema: _khorsheed_dsh_reader_reader_updateSource_parameter_0$schema(),
2470
+ jsonSchema: {"type":"object","properties":{"id":{"type":"string"},"enabled":{"type":"boolean"},"label":{"type":"string"},"url":{"type":"string"},"timeOfDay":{"type":"string"}},"required":["id"],"additionalProperties":true},
2471
+ },
2472
+ strictCodec: {
2473
+ mode: 'strict',
2474
+ typeSymbol: '@khorsheed/dsh-reader#reader/updateSource:request',
2475
+ create: _khorsheed_dsh_reader_reader_updateSource_parameter_0_strict$schema,
2476
+ schema: _khorsheed_dsh_reader_reader_updateSource_parameter_0_strict$schema(),
2477
+ jsonSchema: {"type":"object","properties":{"id":{"type":"string"},"enabled":{"type":"boolean"},"label":{"type":"string"},"url":{"type":"string"},"timeOfDay":{"type":"string"}},"required":["id"],"additionalProperties":false},
1139
2478
  },
1140
2479
  },
1141
2480
  ],
@@ -1144,10 +2483,11 @@ export const TYPERT_REMOTE = {
1144
2483
  typeSymbol: '@khorsheed/dsh-reader/types#ReaderMutationOutcome',
1145
2484
  create: _khorsheed_dsh_reader_reader_updateSource_result$schema,
1146
2485
  schema: _khorsheed_dsh_reader_reader_updateSource_result$schema(),
2486
+ jsonSchema: {"type":"string","enum":["not-found","unavailable","duplicate","ok","invalid-url","invalid-time"]},
1147
2487
  },
1148
- sourceLocation: {"file":"packages/dsh-reader/src/remote.ts","line":78,"column":3},
2488
+ sourceLocation: {"file":"packages/reader/src/remote.ts","line":85,"column":3},
1149
2489
  },
1150
- ],
1151
- }
2490
+ },
2491
+ }, z)
1152
2492
 
1153
2493
  export default TYPERT_REMOTE