@mjasnikovs/pi-task 0.40.11 → 0.40.12

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.
@@ -24,6 +24,14 @@ export declare const MAX_CHUNK_BYTES: number;
24
24
  /**
25
25
  * Where a declaration starts. Splitting here keeps a signature and its body in
26
26
  * one chunk, which is what makes a retrieved chunk quotable as evidence.
27
+ *
28
+ * The modifiers are SEQUENTIAL, not alternatives. Written as `export|declare`
29
+ * they excluded `export declare function` — which is what `tsc --declaration`
30
+ * emits for every exported function in a module: 6,935 such lines in a
31
+ * 4,000-file sample, 3,479 of them functions, and not one started a chunk.
32
+ * `undici-types/fetch.d.ts` put `export declare function fetch(` inside a chunk
33
+ * headed `export type RequestInfo`, so nothing could retrieve the chunk that
34
+ * defines `fetch`.
27
35
  */
28
36
  export declare const DECL_SPLIT_RE: RegExp;
29
37
  /** Where a README section starts. */
@@ -24,8 +24,16 @@ export const MAX_CHUNK_BYTES = 8 * 1024;
24
24
  /**
25
25
  * Where a declaration starts. Splitting here keeps a signature and its body in
26
26
  * one chunk, which is what makes a retrieved chunk quotable as evidence.
27
+ *
28
+ * The modifiers are SEQUENTIAL, not alternatives. Written as `export|declare`
29
+ * they excluded `export declare function` — which is what `tsc --declaration`
30
+ * emits for every exported function in a module: 6,935 such lines in a
31
+ * 4,000-file sample, 3,479 of them functions, and not one started a chunk.
32
+ * `undici-types/fetch.d.ts` put `export declare function fetch(` inside a chunk
33
+ * headed `export type RequestInfo`, so nothing could retrieve the chunk that
34
+ * defines `fetch`.
27
35
  */
28
- export const DECL_SPLIT_RE = /^(?:export\s+|declare\s+)?(?:default\s+)?(?:async\s+)?(?:function|class|interface|type|namespace|module|const|let|var|enum)\s+/m;
36
+ export const DECL_SPLIT_RE = /^(?:export\s+)?(?:declare\s+)?(?:default\s+)?(?:abstract\s+)?(?:async\s+)?(?:function|class|interface|type|namespace|module|const|let|var|enum)\s+/m;
29
37
  /** Where a README section starts. */
30
38
  export const README_SPLIT_RE = /^#{1,2} /m;
31
39
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mjasnikovs/pi-task",
3
- "version": "0.40.11",
3
+ "version": "0.40.12",
4
4
  "description": "Deterministic task planning and spec-orchestration for local models — crash-safe /task pipelines with verify/enforce gates, a real-time remote web view, and web/docs/fetch/worker subagent tools.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",