@animalabs/agent-framework 0.22.4 → 0.23.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 (234) hide show
  1. package/README.md +105 -3
  2. package/dist/src/agent.d.ts +36 -10
  3. package/dist/src/agent.d.ts.map +1 -1
  4. package/dist/src/agent.js +76 -32
  5. package/dist/src/agent.js.map +1 -1
  6. package/dist/src/code-execution/index.d.ts +1 -1
  7. package/dist/src/code-execution/index.d.ts.map +1 -1
  8. package/dist/src/code-execution/index.js.map +1 -1
  9. package/dist/src/code-execution/py-runner.d.ts +34 -2
  10. package/dist/src/code-execution/py-runner.d.ts.map +1 -1
  11. package/dist/src/code-execution/py-runner.js +72 -16
  12. package/dist/src/code-execution/py-runner.js.map +1 -1
  13. package/dist/src/code-execution/runtime-py.d.ts +3 -2
  14. package/dist/src/code-execution/runtime-py.d.ts.map +1 -1
  15. package/dist/src/code-execution/runtime-py.js +47 -7
  16. package/dist/src/code-execution/runtime-py.js.map +1 -1
  17. package/dist/src/code-execution/tool-definition.d.ts +12 -7
  18. package/dist/src/code-execution/tool-definition.d.ts.map +1 -1
  19. package/dist/src/code-execution/tool-definition.js +59 -11
  20. package/dist/src/code-execution/tool-definition.js.map +1 -1
  21. package/dist/src/config-checks.d.ts +2 -2
  22. package/dist/src/config-checks.d.ts.map +1 -1
  23. package/dist/src/config-checks.js +6 -2
  24. package/dist/src/config-checks.js.map +1 -1
  25. package/dist/src/framework.d.ts +744 -120
  26. package/dist/src/framework.d.ts.map +1 -1
  27. package/dist/src/framework.js +3546 -906
  28. package/dist/src/framework.js.map +1 -1
  29. package/dist/src/gate/event-gate.d.ts.map +1 -1
  30. package/dist/src/gate/event-gate.js +13 -6
  31. package/dist/src/gate/event-gate.js.map +1 -1
  32. package/dist/src/held-writes.d.ts +16 -0
  33. package/dist/src/held-writes.d.ts.map +1 -0
  34. package/dist/src/held-writes.js +56 -0
  35. package/dist/src/held-writes.js.map +1 -0
  36. package/dist/src/index.d.ts +7 -3
  37. package/dist/src/index.d.ts.map +1 -1
  38. package/dist/src/index.js +8 -4
  39. package/dist/src/index.js.map +1 -1
  40. package/dist/src/mcpl/capability-grant.d.ts +4 -0
  41. package/dist/src/mcpl/capability-grant.d.ts.map +1 -1
  42. package/dist/src/mcpl/capability-grant.js +1 -1
  43. package/dist/src/mcpl/capability-grant.js.map +1 -1
  44. package/dist/src/mcpl/channel-registry.d.ts +95 -18
  45. package/dist/src/mcpl/channel-registry.d.ts.map +1 -1
  46. package/dist/src/mcpl/channel-registry.js +578 -150
  47. package/dist/src/mcpl/channel-registry.js.map +1 -1
  48. package/dist/src/mcpl/convert-block.d.ts +2 -2
  49. package/dist/src/mcpl/convert-block.d.ts.map +1 -1
  50. package/dist/src/mcpl/convert-block.js +6 -7
  51. package/dist/src/mcpl/convert-block.js.map +1 -1
  52. package/dist/src/mcpl/index.d.ts +5 -1
  53. package/dist/src/mcpl/index.d.ts.map +1 -1
  54. package/dist/src/mcpl/index.js +3 -1
  55. package/dist/src/mcpl/index.js.map +1 -1
  56. package/dist/src/mcpl/inference-router.d.ts +4 -2
  57. package/dist/src/mcpl/inference-router.d.ts.map +1 -1
  58. package/dist/src/mcpl/inference-router.js +6 -7
  59. package/dist/src/mcpl/inference-router.js.map +1 -1
  60. package/dist/src/mcpl/log-value.d.ts +7 -0
  61. package/dist/src/mcpl/log-value.d.ts.map +1 -1
  62. package/dist/src/mcpl/log-value.js +9 -0
  63. package/dist/src/mcpl/log-value.js.map +1 -1
  64. package/dist/src/mcpl/modern-connection.d.ts +227 -0
  65. package/dist/src/mcpl/modern-connection.d.ts.map +1 -0
  66. package/dist/src/mcpl/modern-connection.js +1088 -0
  67. package/dist/src/mcpl/modern-connection.js.map +1 -0
  68. package/dist/src/mcpl/prefix-rule.d.ts +18 -0
  69. package/dist/src/mcpl/prefix-rule.d.ts.map +1 -0
  70. package/dist/src/mcpl/prefix-rule.js +25 -0
  71. package/dist/src/mcpl/prefix-rule.js.map +1 -0
  72. package/dist/src/mcpl/protocol-family.d.ts +179 -0
  73. package/dist/src/mcpl/protocol-family.d.ts.map +1 -0
  74. package/dist/src/mcpl/protocol-family.js +697 -0
  75. package/dist/src/mcpl/protocol-family.js.map +1 -0
  76. package/dist/src/mcpl/push-coalescer.d.ts +38 -19
  77. package/dist/src/mcpl/push-coalescer.d.ts.map +1 -1
  78. package/dist/src/mcpl/push-coalescer.js +52 -23
  79. package/dist/src/mcpl/push-coalescer.js.map +1 -1
  80. package/dist/src/mcpl/reference-fetcher.d.ts +66 -15
  81. package/dist/src/mcpl/reference-fetcher.d.ts.map +1 -1
  82. package/dist/src/mcpl/reference-fetcher.js +243 -76
  83. package/dist/src/mcpl/reference-fetcher.js.map +1 -1
  84. package/dist/src/mcpl/references.d.ts +63 -18
  85. package/dist/src/mcpl/references.d.ts.map +1 -1
  86. package/dist/src/mcpl/references.js +117 -32
  87. package/dist/src/mcpl/references.js.map +1 -1
  88. package/dist/src/mcpl/server-connection.d.ts +326 -30
  89. package/dist/src/mcpl/server-connection.d.ts.map +1 -1
  90. package/dist/src/mcpl/server-connection.js +995 -212
  91. package/dist/src/mcpl/server-connection.js.map +1 -1
  92. package/dist/src/mcpl/server-registry.d.ts +25 -5
  93. package/dist/src/mcpl/server-registry.d.ts.map +1 -1
  94. package/dist/src/mcpl/server-registry.js +51 -12
  95. package/dist/src/mcpl/server-registry.js.map +1 -1
  96. package/dist/src/mcpl/tool-result-normalize.d.ts +54 -0
  97. package/dist/src/mcpl/tool-result-normalize.d.ts.map +1 -0
  98. package/dist/src/mcpl/tool-result-normalize.js +232 -0
  99. package/dist/src/mcpl/tool-result-normalize.js.map +1 -0
  100. package/dist/src/mcpl/transport.d.ts +56 -13
  101. package/dist/src/mcpl/transport.d.ts.map +1 -1
  102. package/dist/src/mcpl/transport.js +206 -70
  103. package/dist/src/mcpl/transport.js.map +1 -1
  104. package/dist/src/mcpl/types.d.ts +66 -20
  105. package/dist/src/mcpl/types.d.ts.map +1 -1
  106. package/dist/src/mcpl/types.js.map +1 -1
  107. package/dist/src/mcpl/visible-content.d.ts +2 -1
  108. package/dist/src/mcpl/visible-content.d.ts.map +1 -1
  109. package/dist/src/mcpl/visible-content.js +2 -1
  110. package/dist/src/mcpl/visible-content.js.map +1 -1
  111. package/dist/src/module-registry.d.ts +16 -6
  112. package/dist/src/module-registry.d.ts.map +1 -1
  113. package/dist/src/module-registry.js +65 -6
  114. package/dist/src/module-registry.js.map +1 -1
  115. package/dist/src/modules/api/index.d.ts +1 -1
  116. package/dist/src/modules/api/index.d.ts.map +1 -1
  117. package/dist/src/modules/api/index.js +3 -2
  118. package/dist/src/modules/api/index.js.map +1 -1
  119. package/dist/src/modules/discord/discord-js-client.d.ts +42 -2
  120. package/dist/src/modules/discord/discord-js-client.d.ts.map +1 -1
  121. package/dist/src/modules/discord/discord-js-client.js +268 -65
  122. package/dist/src/modules/discord/discord-js-client.js.map +1 -1
  123. package/dist/src/modules/discord/index.d.ts +27 -5
  124. package/dist/src/modules/discord/index.d.ts.map +1 -1
  125. package/dist/src/modules/discord/index.js +366 -76
  126. package/dist/src/modules/discord/index.js.map +1 -1
  127. package/dist/src/modules/discord/refusal.d.ts +14 -0
  128. package/dist/src/modules/discord/refusal.d.ts.map +1 -0
  129. package/dist/src/modules/discord/refusal.js +14 -0
  130. package/dist/src/modules/discord/refusal.js.map +1 -0
  131. package/dist/src/modules/discord/types.d.ts +17 -7
  132. package/dist/src/modules/discord/types.d.ts.map +1 -1
  133. package/dist/src/modules/health/index.d.ts.map +1 -1
  134. package/dist/src/modules/health/index.js +6 -2
  135. package/dist/src/modules/health/index.js.map +1 -1
  136. package/dist/src/modules/index.d.ts +1 -1
  137. package/dist/src/modules/index.d.ts.map +1 -1
  138. package/dist/src/modules/index.js +1 -1
  139. package/dist/src/modules/index.js.map +1 -1
  140. package/dist/src/modules/workspace/disk-agreement.d.ts +25 -2
  141. package/dist/src/modules/workspace/disk-agreement.d.ts.map +1 -1
  142. package/dist/src/modules/workspace/disk-agreement.js +45 -5
  143. package/dist/src/modules/workspace/disk-agreement.js.map +1 -1
  144. package/dist/src/modules/workspace/effects.d.ts +2 -1
  145. package/dist/src/modules/workspace/effects.d.ts.map +1 -1
  146. package/dist/src/modules/workspace/effects.js +19 -9
  147. package/dist/src/modules/workspace/effects.js.map +1 -1
  148. package/dist/src/modules/workspace/index.d.ts +214 -42
  149. package/dist/src/modules/workspace/index.d.ts.map +1 -1
  150. package/dist/src/modules/workspace/index.js +667 -113
  151. package/dist/src/modules/workspace/index.js.map +1 -1
  152. package/dist/src/modules/workspace/observe.d.ts +240 -8
  153. package/dist/src/modules/workspace/observe.d.ts.map +1 -1
  154. package/dist/src/modules/workspace/observe.js +554 -24
  155. package/dist/src/modules/workspace/observe.js.map +1 -1
  156. package/dist/src/modules/workspace/types.d.ts +10 -1
  157. package/dist/src/modules/workspace/types.d.ts.map +1 -1
  158. package/dist/src/modules/workspace/types.js.map +1 -1
  159. package/dist/src/modules/workspace/watcher.d.ts +42 -0
  160. package/dist/src/modules/workspace/watcher.d.ts.map +1 -1
  161. package/dist/src/modules/workspace/watcher.js +130 -25
  162. package/dist/src/modules/workspace/watcher.js.map +1 -1
  163. package/dist/src/silent-heartbeat.d.ts +112 -39
  164. package/dist/src/silent-heartbeat.d.ts.map +1 -1
  165. package/dist/src/silent-heartbeat.js +100 -29
  166. package/dist/src/silent-heartbeat.js.map +1 -1
  167. package/dist/src/tool-args.d.ts +40 -0
  168. package/dist/src/tool-args.d.ts.map +1 -0
  169. package/dist/src/tool-args.js +207 -0
  170. package/dist/src/tool-args.js.map +1 -0
  171. package/dist/src/tool-presentation.d.ts.map +1 -1
  172. package/dist/src/tool-presentation.js +9 -2
  173. package/dist/src/tool-presentation.js.map +1 -1
  174. package/dist/src/types/agent.d.ts +27 -17
  175. package/dist/src/types/agent.d.ts.map +1 -1
  176. package/dist/src/types/events.d.ts +8 -0
  177. package/dist/src/types/events.d.ts.map +1 -1
  178. package/dist/src/types/framework.d.ts +17 -2
  179. package/dist/src/types/framework.d.ts.map +1 -1
  180. package/dist/src/types/module.d.ts +54 -10
  181. package/dist/src/types/module.d.ts.map +1 -1
  182. package/dist/src/types/trace.d.ts +2 -2
  183. package/dist/src/types/trace.d.ts.map +1 -1
  184. package/package.json +3 -4
  185. package/src/agent.ts +99 -36
  186. package/src/code-execution/index.ts +1 -0
  187. package/src/code-execution/py-runner.ts +104 -17
  188. package/src/code-execution/runtime-py.ts +47 -7
  189. package/src/code-execution/tool-definition.ts +65 -11
  190. package/src/config-checks.ts +4 -2
  191. package/src/framework.ts +3633 -956
  192. package/src/gate/event-gate.ts +14 -6
  193. package/src/held-writes.ts +59 -0
  194. package/src/index.ts +19 -4
  195. package/src/mcpl/capability-grant.ts +1 -1
  196. package/src/mcpl/channel-registry.ts +613 -160
  197. package/src/mcpl/convert-block.ts +15 -7
  198. package/src/mcpl/index.ts +14 -1
  199. package/src/mcpl/inference-router.ts +8 -7
  200. package/src/mcpl/log-value.ts +10 -0
  201. package/src/mcpl/modern-connection.ts +1182 -0
  202. package/src/mcpl/prefix-rule.ts +32 -0
  203. package/src/mcpl/protocol-family.ts +691 -0
  204. package/src/mcpl/push-coalescer.ts +67 -29
  205. package/src/mcpl/reference-fetcher.ts +288 -82
  206. package/src/mcpl/references.ts +123 -33
  207. package/src/mcpl/server-connection.ts +1050 -221
  208. package/src/mcpl/server-registry.ts +50 -12
  209. package/src/mcpl/tool-result-normalize.ts +294 -0
  210. package/src/mcpl/transport.ts +204 -62
  211. package/src/mcpl/types.ts +67 -20
  212. package/src/mcpl/visible-content.ts +2 -1
  213. package/src/module-registry.ts +68 -13
  214. package/src/modules/api/index.ts +3 -2
  215. package/src/modules/discord/discord-js-client.ts +288 -72
  216. package/src/modules/discord/index.ts +380 -77
  217. package/src/modules/discord/refusal.ts +13 -0
  218. package/src/modules/discord/types.ts +17 -9
  219. package/src/modules/health/index.ts +6 -2
  220. package/src/modules/index.ts +1 -1
  221. package/src/modules/workspace/disk-agreement.ts +46 -5
  222. package/src/modules/workspace/effects.ts +18 -7
  223. package/src/modules/workspace/index.ts +722 -124
  224. package/src/modules/workspace/observe.ts +591 -22
  225. package/src/modules/workspace/types.ts +10 -1
  226. package/src/modules/workspace/watcher.ts +126 -25
  227. package/src/silent-heartbeat.ts +184 -59
  228. package/src/tool-args.ts +213 -0
  229. package/src/tool-presentation.ts +9 -2
  230. package/src/types/agent.ts +27 -17
  231. package/src/types/events.ts +8 -0
  232. package/src/types/framework.ts +17 -2
  233. package/src/types/module.ts +55 -10
  234. package/src/types/trace.ts +2 -2
@@ -40,6 +40,8 @@ import { type Fingerprint, type RootIdentity } from './disk-agreement.js';
40
40
  export interface MountView {
41
41
  /** Mount root as configured. */
42
42
  root: string;
43
+ /** The mount's name, which a tool puts before a path in the mount. */
44
+ name: string;
43
45
  /**
44
46
  * The root directory disk last agreed under, once the mount has evidence.
45
47
  * A root that resolves to any other directory is unavailable.
@@ -54,13 +56,39 @@ export interface MountView {
54
56
  * pass passes over them, named or not, as another mount's directory.
55
57
  */
56
58
  others: readonly string[];
59
+ /**
60
+ * The same mounts, each by its directory, its name and, where it has one,
61
+ * its real root (NestedMount), for a refusal that names the mount a path
62
+ * leads into: through a symlink this mount doesn't follow (linkWords), or
63
+ * through one it follows, or a root configured through one (nestedAtReal).
64
+ * Without it, no path is refused for where its links lead, and a link's
65
+ * refusal names no mount.
66
+ */
67
+ nested?: readonly NestedMount[];
57
68
  }
69
+ /**
70
+ * A mount nested in another: its directory in one of its spellings,
71
+ * mount-relative and `/`-separated, its name, and its real root, which
72
+ * every spelling shares. The real root is the root as realpath resolves it
73
+ * (the nearest existing directory's, where the root isn't made yet) once
74
+ * the module's start has read it, and the root as configured until then.
75
+ * There's none where it's this mount's own or holds it: the mount is nested
76
+ * by its configured path alone, since through its real root it would claim
77
+ * this mount's every path.
78
+ */
79
+ export type NestedMount = {
80
+ dir: string;
81
+ name: string;
82
+ real?: string;
83
+ };
58
84
  export type StatFingerprint = Omit<Fingerprint, 'hashedAt'>;
59
85
  /**
60
- * Opened with every read or write of a workspace path, where the platform has
61
- * it: for a regular file it changes nothing, and a FIFO or other special file
62
- * swapped in at the path neither blocks the open nor passes the regular-file
63
- * check that follows.
86
+ * Opened with every open of a workspace path that may already be there, a
87
+ * read, a write in place or a directory's sync, where the platform has it:
88
+ * for a regular file or a directory it changes nothing, and a FIFO or other
89
+ * special file swapped in at the path neither blocks the open nor passes the
90
+ * check of its kind that follows. A create needs none: O_CREAT | O_EXCL fails
91
+ * at once on anything already at the path.
64
92
  */
65
93
  export declare const NONBLOCK: number;
66
94
  export type Observation = {
@@ -111,6 +139,208 @@ export declare function contained(rootReal: string, candidate: string): boolean;
111
139
  export declare function parentOf(relativePath: string): string;
112
140
  /** The last component of a mount-relative path. */
113
141
  export declare function nameOf(relativePath: string): string;
142
+ /**
143
+ * What linkOnTheWay found on a path's way beneath the mount's root: a
144
+ * symlink (`link`, mount-relative), or a directory there the walk couldn't
145
+ * ask (`unsure`, with the errno it got).
146
+ */
147
+ export type LinkFound = {
148
+ link: string;
149
+ } | {
150
+ unsure: string;
151
+ code: string;
152
+ };
153
+ /**
154
+ * On a mount that doesn't follow symlinks, what is on the way to a
155
+ * mount-relative path: the first directory, from beneath the mount's root
156
+ * down to the path itself (or, `through` 'parents', down to its parent), that
157
+ * is a symlink, or one the walk couldn't ask. Null when there is none, or
158
+ * when the mount follows symlinks. The path is
159
+ * walked as the lookups that follow resolve it, with `.` and `..` taken out,
160
+ * so a `..` after a name that isn't there hides nothing beyond it, and the
161
+ * root, which is the configured path whatever it resolves to, is never on the
162
+ * way, even where the path names it on its way back into the mount. Each
163
+ * directory is asked only whether it is a link, by readlink, from the root
164
+ * down. EINVAL means it isn't, and the walk goes on. Nothing there, a file in
165
+ * the way, or a directory this user can't search (ENOENT, ENOTDIR, EACCES)
166
+ * ends it with nothing found, since nothing beneath is reached through a link
167
+ * and the caller's own lookup meets the same answer. Any other answer, EPERM
168
+ * included, leaves it unsure of what's beneath, and the path is refused for
169
+ * that.
170
+ */
171
+ export declare function linkOnTheWay(view: Pick<MountView, 'root' | 'followSymlinks'>, rel: string, through?: 'path' | 'parents'): Promise<LinkFound | null>;
172
+ /**
173
+ * On a mount that doesn't follow symlinks, what refuses the mount-relative
174
+ * `rel`, which realpath resolved to `real` (or, `through` 'parents', whose
175
+ * parent it resolved to `real`): the first symlink on its way, or a
176
+ * directory there the walk couldn't ask. Null when the mount follows
177
+ * symlinks, or there's none. Where `real` is the root's canonical path joined
178
+ * with what was resolved (`rel`, or with `through` 'parents', its parent),
179
+ * nothing beneath the root resolved through a link, and nothing more is
180
+ * asked: that is every path through ordinary directories, at no cost
181
+ * per path. Otherwise each directory is asked in turn (linkOnTheWay), since a
182
+ * name spelled otherwise than disk spells it, on a file system that ignores
183
+ * case or Unicode normalization, also resolves to another string, and isn't
184
+ * a link.
185
+ */
186
+ export declare function linkRefusal(view: Pick<MountView, 'root' | 'followSymlinks'>, rootReal: string, rel: string, real: string, through?: 'path' | 'parents'): Promise<LinkFound | null>;
187
+ /**
188
+ * Where a symlink the walk found leads, for its refusal: to a path inside
189
+ * the mount (mount-relative, and whether it's a directory), outside the
190
+ * mount, or nowhere it can be resolved to. One realpath and one stat, made
191
+ * only when refusing.
192
+ */
193
+ export type LinkLeads = {
194
+ kind: 'inside';
195
+ target: string;
196
+ directory: boolean;
197
+ } | {
198
+ kind: 'outside';
199
+ } | {
200
+ kind: 'nowhere';
201
+ };
202
+ export declare function linkLeads(root: string, rootReal: string, link: string): Promise<LinkLeads>;
203
+ /**
204
+ * The nested mount whose directory holds `target` (mount-relative), the
205
+ * innermost where nested mounts nest, as #460 picks one; undefined when none
206
+ * does.
207
+ */
208
+ export declare function nestedHolder(target: string, nested: readonly {
209
+ dir: string;
210
+ name: string;
211
+ }[]): {
212
+ dir: string;
213
+ name: string;
214
+ } | undefined;
215
+ /**
216
+ * Why a path is refused for what linkOnTheWay found, given where a link
217
+ * leads (linkLeads). For a link, the link is the subject, with where it
218
+ * leads: for a link inside the mount, its target, and for a link to a
219
+ * directory there, the setting the mount's host can change (the link stands
220
+ * among the path's directories, so following a link to a file can't make the
221
+ * path beneath it exist); for one leading outside the mount, that it does;
222
+ * for one that can't be resolved, nothing more. A target in a nested mount's
223
+ * directory (`nested`) is that mount's: the refusal names the mount and the
224
+ * path to use there in place of the link, and offers no setting, since
225
+ * following the link would only reach into another mount's directory. For a
226
+ * directory the walk couldn't ask, which one, and the answer it got. Paths
227
+ * are spelled as the tools take them, from the mount's name.
228
+ */
229
+ export declare function linkWords(name: string, found: LinkFound, leads: LinkLeads | null, nested?: readonly {
230
+ dir: string;
231
+ name: string;
232
+ }[]): string;
233
+ /** Why a path is refused for what linkOnTheWay found (linkWords, with where the link leads). */
234
+ export declare function linkReason(view: Pick<MountView, 'root' | 'name' | 'nested'>, rootReal: string, found: LinkFound): Promise<string>;
235
+ /**
236
+ * The nested mount whose root holds `real`, a canonical path, the innermost,
237
+ * with the path to use there; undefined when none does. A path the lexical
238
+ * checks pass (inOtherMount, the tools' holderOf) reaches another mount's
239
+ * directory this way through a symlink the mount follows, so each check that
240
+ * resolves a path canonically asks this too.
241
+ */
242
+ export declare function nestedAtReal(real: string, nested?: readonly NestedMount[]): {
243
+ name: string;
244
+ use: string;
245
+ } | undefined;
246
+ /**
247
+ * Why a mount-relative path that resolves into a nested mount's directory is
248
+ * refused (nestedAtReal): what it leads into, and the path to use in its
249
+ * place. Spelled as the tools take paths, from the mount's name.
250
+ */
251
+ export declare function leadsInto(name: string, rel: string, holder: {
252
+ name: string;
253
+ use: string;
254
+ }): string;
255
+ /**
256
+ * Names compared more loosely, through upper case and back, which also folds
257
+ * `ß` with `ss`, `ſ` with `s` and `ς` with `σ`, as a disk that folds fully
258
+ * does. It also folds dotless `ı` with `i`, which a disk may keep apart;
259
+ * the same-file check keeps that from naming another file.
260
+ */
261
+ export declare const foldedLoosely: (name: string) => string;
262
+ /** What the workspace holds of a mount, as the spelling step reads it (diskSpelling). */
263
+ export interface WorkspaceEntries {
264
+ /**
265
+ * Whether the workspace holds an entry at exactly this path, or records an
266
+ * intent there, such as a deletion disk hasn't been given yet.
267
+ */
268
+ has(path: string): boolean;
269
+ /** The paths of the entries under `prefix`, a directory's path and `/`, or `''` for every entry. */
270
+ under(prefix: string): string[];
271
+ /**
272
+ * The nested mount whose directory holds this path, by the nested-mount
273
+ * checks' own reading of it, or undefined where the path is the mount's
274
+ * own.
275
+ */
276
+ holder(path: string): string | undefined;
277
+ /** Whether the mount's root folds case (foldsCase). */
278
+ rootFoldsCase: boolean;
279
+ }
280
+ /**
281
+ * Whether `dir` folds case, told without writing: by looking up flipped a
282
+ * name it lists whose flipped spelling it doesn't list too (a name with no
283
+ * letter to flip is its own flipped spelling, and two hard links that differ
284
+ * only in case are one file on any disk). Where no name it lists tells, or
285
+ * it can't be listed, the directory holding it is asked instead, where both
286
+ * are on one device, each as a link to it leads: its own name looked up
287
+ * flipped there, or, for a name with no letter to flip, that directory's own
288
+ * folding. A directory on a device of its own is taken to tell case apart. A
289
+ * directory not there yet folds as the one it would be made in. Where
290
+ * nothing tells, it's taken to tell case apart.
291
+ */
292
+ export declare function foldsCase(dir: string): Promise<boolean>;
293
+ /**
294
+ * A name in simple case folding, letter by letter: each letter as the lower
295
+ * case of its upper case, so `Σ` and a word's last `ς` are both `σ`, `ſ` is
296
+ * `s` and `µ` is `μ`. A letter whose upper case is more than one letter
297
+ * takes its own lower case instead, as the Greek `ᾈ` takes `ᾀ` and `ß` stays
298
+ * `ß`. A letter whose lower case is more than one letter too, as `İ`'s is,
299
+ * stays as it is, and so does dotless `ı`, whose upper case `I` lowers to
300
+ * `i`, which case folding keeps apart from it. Unicode normalization is left
301
+ * alone, and so are letters only a fuller folding joins, such as `ß` with
302
+ * `ss`: no listing shows two such names to be one file, and a disk that
303
+ * folds case needn't join them.
304
+ */
305
+ export declare const lowered: (name: string) => string;
306
+ /**
307
+ * `relativePath` as disk spells it. On a disk that folds names, as macOS's
308
+ * does by default (case and Unicode normalization), `SRC/a.ts` reaches
309
+ * `src/a.ts`, and whatever names what it finds from the spelling it was
310
+ * given takes the file in a second time, under a name disk doesn't list. So
311
+ * each segment, from the mount's root down, takes the name its directory
312
+ * lists for it (listedName). The walk goes on beneath a segment only if it's
313
+ * a directory, a symlink not included, so nothing past a link is read. It
314
+ * passes over an empty or `.` segment, which names the directory reached,
315
+ * and goes back up at `..`, to the directory it came from. At the mount's
316
+ * root a `..` stops it, keeping the rest as given: a path can climb above
317
+ * the root and come back in, as `../proj/x` does for a root named `proj`, and
318
+ * walking that would list the directory above the root. An absolute path
319
+ * keeps its spelling too: it names a place from the filesystem's root, not
320
+ * the mount's, so walking it from the mount's root would respell it against
321
+ * other directories, and the path returned could lead outside the mount.
322
+ *
323
+ * Given the workspace's `entries`, an entry not yet on disk spells its path
324
+ * as its file will. A path the workspace holds an entry at exactly keeps its
325
+ * spelling whole, and so does a last segment where the workspace holds an
326
+ * entry at exactly that path once its directories have taken disk's
327
+ * spelling, so an entry that disk lists in another spelling, or in a
328
+ * directory disk lists in another, stays reachable by its own path. `has`
329
+ * counts a path the workspace records an intent at, such as a deletion disk
330
+ * hasn't been given yet, so that's reached by its own path too. And where
331
+ * the directory reached folds case, each segment disk has nothing for takes
332
+ * the name of an entry it equals in simple case folding (entryName), as the
333
+ * disk will once that entry is written: a second draft spelled in another
334
+ * case is the first one. None of this applies where disk's spelling puts the
335
+ * path in a nested mount's directory, by the nested-mount checks' own
336
+ * reading (`holder`): there the path keeps disk's spelling, so they refuse
337
+ * at least what they refuse without the entries. The root's folding is read
338
+ * at start (`rootFoldsCase`), and a directory beneath it is taken to fold as
339
+ * the directory holding it did when its name was looked up with its case
340
+ * flipped, or, for a name with no letter to flip, as the nearest directory
341
+ * above that told, so the step reads nothing more of disk for this.
342
+ */
343
+ export declare function diskSpelling(root: string, relativePath: string, entries?: WorkspaceEntries): Promise<string>;
114
344
  export type DirCheck = {
115
345
  kind: 'checked';
116
346
  dir: CheckedDir;
@@ -196,10 +426,12 @@ export declare function checkDir(view: MountView, rootReal: string, rel: string,
196
426
  * which nothing can exist. Either proves it only while every directory the
197
427
  * walk went through, the root included, is still the one its path names
198
428
  * afterwards: a root or parent replaced during the walk would otherwise lend
199
- * its replacement's absence to the original's path. Symlinked directories
200
- * inside the mount are followed as parents; any other symlink proves
201
- * nothing. Returns the directory whose entries prove it, or why absence
202
- * couldn't be shown.
429
+ * its replacement's absence to the original's path. On a mount that follows
430
+ * symlinks, symlinked directories inside the mount are followed as parents;
431
+ * on one that doesn't, a symlinked directory on the way proves nothing, and
432
+ * the reason says so (linkReason). Any other symlink proves nothing.
433
+ * Returns the directory whose entries prove it, or why absence couldn't be
434
+ * shown.
203
435
  */
204
436
  export declare function confirmAbsent(view: MountView, rootReal: string, rel: string, target?: 'entry' | 'beneath'): Promise<{
205
437
  by: string;
@@ -1 +1 @@
1
- {"version":3,"file":"observe.d.ts","sourceRoot":"","sources":["../../../../src/modules/workspace/observe.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAMH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD,OAAO,EAAoB,KAAK,WAAW,EAAE,KAAK,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAE5F,MAAM,WAAW,SAAS;IACxB,gCAAgC;IAChC,IAAI,EAAE,MAAM,CAAC;IACb;;;OAGG;IACH,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,cAAc,EAAE,OAAO,CAAC;IACxB,4CAA4C;IAC5C,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB;;;OAGG;IACH,MAAM,EAAE,SAAS,MAAM,EAAE,CAAC;CAC3B;AAED,MAAM,MAAM,eAAe,GAAG,IAAI,CAAC,WAAW,EAAE,UAAU,CAAC,CAAC;AAE5D;;;;;GAKG;AACH,eAAO,MAAM,QAAQ,QAA0E,CAAC;AAEhG,M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