carrick 0.3.133 → 0.3.134
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/contract.d.ts +6 -0
- package/dist/contract.js.map +1 -1
- package/dist/hook/post-edit.d.ts +10 -5
- package/dist/hook/post-edit.js +80 -23
- package/dist/hook/post-edit.js.map +1 -1
- package/dist/hook/refresh.d.ts +23 -3
- package/dist/hook/refresh.js +48 -6
- package/dist/hook/refresh.js.map +1 -1
- package/dist/hook/reuse.d.ts +7 -21
- package/dist/hook/reuse.js +23 -36
- package/dist/hook/reuse.js.map +1 -1
- package/dist/hook/session-start.js +15 -2
- package/dist/hook/session-start.js.map +1 -1
- package/dist/hook/stop.js.map +1 -1
- package/dist/init/agents-section.js +1 -1
- package/dist/init/agents-section.js.map +1 -1
- package/dist/init/doctor.js +4 -0
- package/dist/init/doctor.js.map +1 -1
- package/dist/init/hosted.d.ts +1 -0
- package/dist/init/hosted.js +4 -1
- package/dist/init/hosted.js.map +1 -1
- package/dist/init/remove.js +7 -1
- package/dist/init/remove.js.map +1 -1
- package/dist/init/repo-copies.js +3 -1
- package/dist/init/repo-copies.js.map +1 -1
- package/dist/init/run.d.ts +1 -1
- package/dist/init/run.js +10 -2
- package/dist/init/run.js.map +1 -1
- package/dist/init/task-skills.d.ts +22 -1
- package/dist/init/task-skills.js +65 -1
- package/dist/init/task-skills.js.map +1 -1
- package/dist/render.d.ts +41 -16
- package/dist/render.js +91 -102
- package/dist/render.js.map +1 -1
- package/package.json +10 -9
- package/plugin/.claude-plugin/plugin.json +1 -1
- package/sidecar/dist/src/capture/anchors.js +18 -1
- package/sidecar/dist/src/capture/api.d.ts +17 -4
- package/sidecar/dist/src/capture/check-workspace.js +1 -1
- package/sidecar/dist/src/capture/check.d.ts +44 -0
- package/sidecar/dist/src/capture/check.js +112 -10
- package/sidecar/dist/src/capture/installed-package.d.ts +5 -0
- package/sidecar/dist/src/capture/installed-package.js +64 -6
- package/sidecar/dist/src/capture/paths-rewrite.js +3 -3
- package/sidecar/dist/src/capture/result-label.d.ts +42 -0
- package/sidecar/dist/src/capture/result-label.js +91 -0
- package/sidecar/dist/src/capture/self-check.js +13 -2
- package/sidecar/dist/src/index.js +116 -4
- package/sidecar/dist/src/infer-cache.d.ts +125 -0
- package/sidecar/dist/src/infer-cache.js +244 -0
- package/sidecar/dist/src/library-claims.js +42 -4
- package/sidecar/dist/src/node-index.d.ts +53 -0
- package/sidecar/dist/src/node-index.js +100 -0
- package/sidecar/dist/src/project-loader.d.ts +11 -0
- package/sidecar/dist/src/project-loader.js +15 -0
- package/sidecar/dist/src/result-candidates.d.ts +28 -0
- package/sidecar/dist/src/result-candidates.js +209 -0
- package/sidecar/dist/src/type-inferrer.d.ts +27 -0
- package/sidecar/dist/src/type-inferrer.js +175 -43
- package/sidecar/dist/src/types.d.ts +52 -0
- package/sidecar/dist/src/unwidened.js +10 -1
- package/sidecar/dist/src/validators.d.ts +919 -197
- package/sidecar/dist/src/validators.js +32 -0
- package/templates/skills/carrick-reuse.md +11 -0
|
@@ -83,6 +83,15 @@ export const SymbolRequestSchema = z.object({
|
|
|
83
83
|
// ============================================================================
|
|
84
84
|
// Infer Request Item Schema
|
|
85
85
|
// ============================================================================
|
|
86
|
+
/**
|
|
87
|
+
* The library store's label for which part of a call's result holds the
|
|
88
|
+
* response body (carrick#2818). Exactly one key.
|
|
89
|
+
*/
|
|
90
|
+
export const ResultLabelSchema = z.union([
|
|
91
|
+
z.object({ whole: z.literal(true) }).strict(),
|
|
92
|
+
z.object({ member: z.tuple([z.string().min(1)]) }).strict(),
|
|
93
|
+
z.object({ parse: z.string().min(1) }).strict(),
|
|
94
|
+
]);
|
|
86
95
|
export const InferRequestItemSchema = z.object({
|
|
87
96
|
file_path: z.string().min(1, 'File path cannot be empty'),
|
|
88
97
|
line_number: z.number().int().positive('Line number must be positive'),
|
|
@@ -95,6 +104,8 @@ export const InferRequestItemSchema = z.object({
|
|
|
95
104
|
param_name: z.string().optional(),
|
|
96
105
|
// The body-carrying member a `request_config` item asks about.
|
|
97
106
|
member: z.string().optional(),
|
|
107
|
+
// The library store's label for the call's result (carrick#2818).
|
|
108
|
+
result: ResultLabelSchema.optional(),
|
|
98
109
|
});
|
|
99
110
|
/**
|
|
100
111
|
* Per-item locator validation for infer requests.
|
|
@@ -189,6 +200,7 @@ const CaptureAnchorRequestSchema = z.discriminatedUnion('kind', [
|
|
|
189
200
|
// the request.
|
|
190
201
|
param_name: z.string().optional(),
|
|
191
202
|
unwrap: z.enum(['awaited', 'none']).optional(),
|
|
203
|
+
result: ResultLabelSchema.optional(),
|
|
192
204
|
}),
|
|
193
205
|
z.object({
|
|
194
206
|
kind: z.literal('literal'),
|
|
@@ -409,6 +421,12 @@ const RequestAtSchema = z
|
|
|
409
421
|
body: z.array(z.string().min(1)).optional(),
|
|
410
422
|
})
|
|
411
423
|
.strict();
|
|
424
|
+
/** Exactly one of the whole return, one member name, or a parse method (carrick#2817). */
|
|
425
|
+
const ResultShapeSchema = z.union([
|
|
426
|
+
z.object({ whole: z.literal(true) }).strict(),
|
|
427
|
+
z.object({ member: z.tuple([z.string().min(1)]) }).strict(),
|
|
428
|
+
z.object({ parse: z.string().min(1) }).strict(),
|
|
429
|
+
]);
|
|
412
430
|
const ClaimOnSchema = z.enum(['export', 'instance', 'both']);
|
|
413
431
|
const MemberPathSchema = z.array(z.string().min(1));
|
|
414
432
|
const KeyLabelsSchema = z.record(z.string().min(1), z.enum(['name', 'not_name']));
|
|
@@ -436,6 +454,7 @@ const LibraryClaimSchema = z.discriminatedUnion('kind', [
|
|
|
436
454
|
key_labels: KeyLabelsSchema.optional(),
|
|
437
455
|
name_scope: NameScopeSchema.optional(),
|
|
438
456
|
picker: z.string().optional(),
|
|
457
|
+
result: ResultShapeSchema.optional(),
|
|
439
458
|
})
|
|
440
459
|
.strict(),
|
|
441
460
|
z
|
|
@@ -479,6 +498,19 @@ const LibraryClaimSchema = z.discriminatedUnion('kind', [
|
|
|
479
498
|
runs: RunsSlotSchema.optional(),
|
|
480
499
|
yields: YieldsSchema.optional(),
|
|
481
500
|
request: RequestAtSchema.optional(),
|
|
501
|
+
result: ResultShapeSchema.optional(),
|
|
502
|
+
})
|
|
503
|
+
.strict(),
|
|
504
|
+
z
|
|
505
|
+
.object({
|
|
506
|
+
kind: z.literal('result'),
|
|
507
|
+
form: z.enum(['make', 'op']),
|
|
508
|
+
member: z.string().min(1).nullable(),
|
|
509
|
+
path: MemberPathSchema.optional(),
|
|
510
|
+
on: ClaimOnSchema.optional(),
|
|
511
|
+
of: z.string().min(1).optional(),
|
|
512
|
+
picker: z.string().optional(),
|
|
513
|
+
result: ResultShapeSchema,
|
|
482
514
|
})
|
|
483
515
|
.strict(),
|
|
484
516
|
z
|
|
@@ -26,6 +26,17 @@ An entry is either a `name` with a `file` for a function the index holds, or a
|
|
|
26
26
|
the other in an entry, never both. A `name` that matches more than one
|
|
27
27
|
definition comes back with its candidates on that entry's `error`.
|
|
28
28
|
|
|
29
|
+
Functions you added in this task are not in the index yet, so give each one a
|
|
30
|
+
`description` entry: one plain sentence about what it does, written from the
|
|
31
|
+
code you wrote. Do not look for the names in a file list; you wrote them.
|
|
32
|
+
|
|
33
|
+
Two limits decide what an empty answer means. The index was taken at the
|
|
34
|
+
commit the answer states, on the default branch, so anything added on this
|
|
35
|
+
branch is compared against that. And the comparison is on what each function is
|
|
36
|
+
described as doing, not on its source: the index holds no body hash.
|
|
37
|
+
|
|
38
|
+
When you are done, tell the user in one line what Carrick found.
|
|
39
|
+
|
|
29
40
|
The two kinds are scored on different scales, and each result states the floor
|
|
30
41
|
it was ranked against. `vector_basis` says what the cosines are over. On
|
|
31
42
|
`intent` the vector is the intent sentence alone, and a copy somebody renamed
|