carrick 0.3.107 → 0.3.109

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 (40) hide show
  1. package/package.json +9 -10
  2. package/plugin/.claude-plugin/plugin.json +1 -1
  3. package/sidecar/dist/src/capture/api.d.ts +15 -0
  4. package/sidecar/dist/src/capture/check-classify.d.ts +9 -0
  5. package/sidecar/dist/src/capture/check-classify.js +20 -0
  6. package/sidecar/dist/src/capture/check-deep.js +2 -1
  7. package/sidecar/dist/src/capture/check-fields.d.ts +24 -0
  8. package/sidecar/dist/src/capture/check-fields.js +54 -36
  9. package/sidecar/dist/src/capture/check-union.d.ts +40 -0
  10. package/sidecar/dist/src/capture/check-union.js +92 -0
  11. package/sidecar/dist/src/capture/check-workspace.d.ts +1 -0
  12. package/sidecar/dist/src/capture/check-workspace.js +13 -2
  13. package/sidecar/dist/src/capture/check.js +5 -0
  14. package/sidecar/dist/src/capture/compiler-options.d.ts +39 -0
  15. package/sidecar/dist/src/capture/compiler-options.js +100 -0
  16. package/sidecar/dist/src/capture/deno-project.js +3 -2
  17. package/sidecar/dist/src/capture/index.d.ts +1 -0
  18. package/sidecar/dist/src/capture/index.js +90 -48
  19. package/sidecar/dist/src/capture/installed-package.js +3 -2
  20. package/sidecar/dist/src/capture/self-check.js +3 -2
  21. package/sidecar/dist/src/definition-resolver.d.ts +5 -8
  22. package/sidecar/dist/src/definition-resolver.js +8 -9
  23. package/sidecar/dist/src/index.js +124 -11
  24. package/sidecar/dist/src/infer-timing.d.ts +54 -0
  25. package/sidecar/dist/src/infer-timing.js +124 -0
  26. package/sidecar/dist/src/print-type.d.ts +48 -0
  27. package/sidecar/dist/src/print-type.js +71 -0
  28. package/sidecar/dist/src/printed-names.js +2 -1
  29. package/sidecar/dist/src/program-files.d.ts +44 -0
  30. package/sidecar/dist/src/program-files.js +64 -0
  31. package/sidecar/dist/src/project-loader.d.ts +5 -0
  32. package/sidecar/dist/src/project-loader.js +14 -5
  33. package/sidecar/dist/src/retype.d.ts +4 -2
  34. package/sidecar/dist/src/retype.js +16 -5
  35. package/sidecar/dist/src/type-inferrer.d.ts +157 -1
  36. package/sidecar/dist/src/type-inferrer.js +444 -20
  37. package/sidecar/dist/src/types.d.ts +104 -2
  38. package/sidecar/dist/src/validators.d.ts +166 -80
  39. package/sidecar/dist/src/validators.js +13 -0
  40. package/templates/skills/carrick-reuse.md +6 -5
@@ -176,6 +176,10 @@ const CaptureAnchorRequestSchema = z.discriminatedUnion('kind', [
176
176
  span_end: z.number().int().nonnegative().optional(),
177
177
  line_number: z.number().int().positive().optional(),
178
178
  expression_text: z.string().optional(),
179
+ // Any string, the empty one included: a name no parameter has is the
180
+ // capture's to demote, and refusing it here would fail every anchor of
181
+ // the request.
182
+ param_name: z.string().optional(),
179
183
  unwrap: z.enum(['awaited', 'none']).optional(),
180
184
  }),
181
185
  z.object({
@@ -236,6 +240,13 @@ export const HealthRequestSchema = BaseRequestSchema.extend({
236
240
  export const ShutdownRequestSchema = BaseRequestSchema.extend({
237
241
  action: z.literal('shutdown'),
238
242
  });
243
+ export const ListProgramFilesRequestSchema = BaseRequestSchema.extend({
244
+ action: z.literal('list_program_files'),
245
+ });
246
+ export const AddProgramFilesRequestSchema = BaseRequestSchema.extend({
247
+ action: z.literal('add_program_files'),
248
+ files: z.array(z.string().min(1, 'File path cannot be empty')),
249
+ });
239
250
  export const ResolveDefinitionsRequestSchema = BaseRequestSchema.extend({
240
251
  action: z.literal('resolve_definitions'),
241
252
  stub_dir: z.string().min(1, 'Stub dir cannot be empty'),
@@ -440,6 +451,8 @@ export const SidecarRequestSchema = z.discriminatedUnion('action', [
440
451
  ListLibrarySurfaceRequestSchema,
441
452
  HealthRequestSchema,
442
453
  ShutdownRequestSchema,
454
+ ListProgramFilesRequestSchema,
455
+ AddProgramFilesRequestSchema,
443
456
  ]);
444
457
  /**
445
458
  * Validates and parses incoming JSON into a typed SidecarRequest
@@ -44,11 +44,12 @@ find_similar({{SCOPE}})
44
44
  Call again with `offset: <next_offset>` for as long as the response carries
45
45
  `has_more`, and class what every page returned.
46
46
 
47
- Where the project is larger than one pass, the response carries `error` in place
48
- of clusters and names the two routes under the ceiling: a `service`, or a higher
49
- `min_lines`. Take the route the response names and run it again. Where
50
- `truncated` is present the audit is partial, and its `scanned_functions` of `of`
51
- says by how much.
47
+ Where the project is larger than one pass, the response carries `window`: the
48
+ functions it compared, in path order, each against every function after them.
49
+ Call again with `scan_from: <next_scan_from>` until a response carries no
50
+ `next_scan_from`; the windows together compare every pair once. `path` narrows
51
+ an audit to one directory. Where `truncated` is present the audit is partial,
52
+ and its `scanned_functions` of `of` says by how much.
52
53
 
53
54
  ## Class every row
54
55