@c4a/context 0.6.19 → 0.7.0

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 (120) hide show
  1. package/README.md +1 -1
  2. package/README.zh-CN.md +1 -1
  3. package/codeIndexPlan.d.ts +34 -0
  4. package/docs/README.md +7 -0
  5. package/docs/README.zh-CN.md +5 -0
  6. package/docs/guides/code-indexer-skill-authoring.md +124 -0
  7. package/docs/guides/indexer-provider-and-customization.md +140 -0
  8. package/docs/guides/markdown-indexer-skill-authoring.md +118 -0
  9. package/docs/reference/code-extractors.md +2 -2
  10. package/docs/reference/indexer-provider-protocol.md +819 -0
  11. package/docs/reference/project-api.md +2 -2
  12. package/index.d.ts +47 -1
  13. package/index.js +28239 -3952
  14. package/indexerAgentStepProtocol.d.ts +9391 -0
  15. package/indexerArtifactDependencies.d.ts +689 -0
  16. package/indexerArtifactPolicy.d.ts +335 -0
  17. package/indexerArtifactResult.d.ts +2010 -0
  18. package/indexerAuditFacts.d.ts +66 -0
  19. package/indexerAuditOverrideReadiness.d.ts +27 -0
  20. package/indexerAuditProtocol.d.ts +238 -0
  21. package/indexerAuditRevision.d.ts +726 -0
  22. package/indexerAuditRevisionActions.d.ts +236 -0
  23. package/indexerAuthoringFixture.d.ts +152 -0
  24. package/indexerBaseQuestionAmendment.d.ts +2403 -0
  25. package/indexerBenchmark.d.ts +1062 -0
  26. package/indexerCandidateCompile.d.ts +801 -0
  27. package/indexerCapabilityGroupEvidence.d.ts +129 -0
  28. package/indexerCatalogFallback.d.ts +1262 -0
  29. package/indexerCollectionMapping.d.ts +75 -0
  30. package/indexerContentLayers.d.ts +137 -0
  31. package/indexerControlledInvocation.d.ts +512 -0
  32. package/indexerControlledProgram.d.ts +12535 -0
  33. package/indexerCoreExports.d.ts +21 -0
  34. package/indexerCustomizationDraft.d.ts +13800 -0
  35. package/indexerCustomizationLadder.d.ts +103 -0
  36. package/indexerDependencyView.d.ts +1610 -0
  37. package/indexerEvidenceAdapterResult.d.ts +504 -0
  38. package/indexerExampleDecision.d.ts +1606 -0
  39. package/indexerExampleIdentity.d.ts +132 -0
  40. package/indexerExampleIdentityAudit.d.ts +70 -0
  41. package/indexerExampleLinkageAudit.d.ts +80 -0
  42. package/indexerGeneratedAuthoringAudit.d.ts +208 -0
  43. package/indexerIncrementalImpact.d.ts +221 -0
  44. package/indexerInventoryDisposition.d.ts +443 -0
  45. package/indexerLayerComposition.d.ts +1652 -0
  46. package/indexerLayoutChange.d.ts +329 -0
  47. package/indexerLayoutProposalSet.d.ts +447 -0
  48. package/indexerLayoutResolver.d.ts +342 -0
  49. package/indexerLayoutTransition.d.ts +247 -0
  50. package/indexerLifecycle.d.ts +53 -0
  51. package/indexerMainLifecycle.d.ts +258 -0
  52. package/indexerMainRunLedger.d.ts +888 -0
  53. package/indexerMainRunProtocol.d.ts +6471 -0
  54. package/indexerMainWorkset.d.ts +2141 -0
  55. package/indexerMaterialAnswer.d.ts +738 -0
  56. package/indexerMaterialAnswerActualization.d.ts +91 -0
  57. package/indexerMaterialAnswerExecutionPlan.d.ts +2887 -0
  58. package/indexerMaterialAnswerFlow.d.ts +63 -0
  59. package/indexerMaterialAnswerLayout.d.ts +76 -0
  60. package/indexerMaterialAnswerReview.d.ts +217 -0
  61. package/indexerMaterialAnswerReviewRoute.d.ts +6145 -0
  62. package/indexerMaterialAnswerRunLedger.d.ts +918 -0
  63. package/indexerMaterialAnswerRunProtocol.d.ts +1253 -0
  64. package/indexerMaterialGapLedger.d.ts +3111 -0
  65. package/indexerMaterialQuestionExclusion.d.ts +129 -0
  66. package/indexerMaterialQuestionWorkset.d.ts +508 -0
  67. package/indexerNavigationArtifactGraph.d.ts +5 -0
  68. package/indexerNavigationArtifactPlan.d.ts +39 -0
  69. package/indexerOverlayQuestionAmendment.d.ts +2551 -0
  70. package/indexerOverlayQuestionApplyProposal.d.ts +4697 -0
  71. package/indexerOverlayTrust.d.ts +1425 -0
  72. package/indexerParserCoordinate.d.ts +222 -0
  73. package/indexerParserFactView.d.ts +503 -0
  74. package/indexerPartitionConvergence.d.ts +496 -0
  75. package/indexerPartitionPlan.d.ts +919 -0
  76. package/indexerPartitionStrategyResolution.d.ts +594 -0
  77. package/indexerPhysicalArtifactAudit.d.ts +247 -0
  78. package/indexerPhysicalArtifactManifest.d.ts +449 -0
  79. package/indexerPlannedMaterialAnswer.d.ts +116 -0
  80. package/indexerPostAuthorComposition.d.ts +2000 -0
  81. package/indexerPostAuthorRunLedger.d.ts +1972 -0
  82. package/indexerPrimaryProjection.d.ts +262 -0
  83. package/indexerProfileContract.d.ts +3034 -0
  84. package/indexerProfileMetricAudit.d.ts +218 -0
  85. package/indexerProgramExecutionAuthorization.d.ts +227 -0
  86. package/indexerProgramRunProtocol.d.ts +7642 -0
  87. package/indexerProjectProposal.d.ts +2807 -0
  88. package/indexerProjectedArtifactFanOutAudit.d.ts +159 -0
  89. package/indexerProjectedArtifactPlan.d.ts +217 -0
  90. package/indexerProtocolCommon.d.ts +29 -0
  91. package/indexerProvider.d.ts +2573 -0
  92. package/indexerProviderComposition.d.ts +1357 -0
  93. package/indexerProviderContractReferences.d.ts +13 -0
  94. package/indexerProviderProfileResolution.d.ts +20 -0
  95. package/indexerProviderResolution.d.ts +752 -0
  96. package/indexerProviderResolutionAction.d.ts +678 -0
  97. package/indexerProviderRouting.d.ts +3909 -0
  98. package/indexerProviderSelectionProposal.d.ts +3311 -0
  99. package/indexerQuestionAuthority.d.ts +419 -0
  100. package/indexerReaderTargetInventory.d.ts +161 -0
  101. package/indexerReferenceOnlyAudit.d.ts +90 -0
  102. package/indexerRegistry.d.ts +3019 -0
  103. package/indexerRequirementComparison.d.ts +44 -0
  104. package/indexerRequirementConfirmation.d.ts +1193 -0
  105. package/indexerRequirementLifecycle.d.ts +3314 -0
  106. package/indexerRestrictedSelector.d.ts +63 -0
  107. package/indexerResultReconciliation.d.ts +6844 -0
  108. package/indexerResultReconciliationRun.d.ts +15 -0
  109. package/indexerRunEnvelope.d.ts +384 -0
  110. package/indexerRunProtocolCommon.d.ts +21 -0
  111. package/indexerSharedArtifactFingerprint.d.ts +33 -0
  112. package/indexerStructuredDeclaration.d.ts +513 -0
  113. package/indexerSubjectCatalog.d.ts +230 -0
  114. package/indexerSubjectIdentity.d.ts +19 -0
  115. package/indexerSubjectKeyAuthority.d.ts +785 -0
  116. package/indexerTemplateRendering.d.ts +485 -0
  117. package/indexerToolSnapshot.d.ts +431 -0
  118. package/indexerWorksetRead.d.ts +287 -0
  119. package/package.json +1 -1
  120. package/phases.d.ts +1 -1
@@ -0,0 +1,262 @@
1
+ import { z } from "zod";
2
+ import { type IndexerJson, type IndexerRegistry } from "./indexerRegistry.js";
3
+ export declare const indexerPrimaryRegistryProjectionSchema: z.ZodObject<{
4
+ protocol: z.ZodLiteral<"context.indexer.primary-registry-projection/v1">;
5
+ indexer_id: z.ZodEffects<z.ZodString, string, string>;
6
+ operation: z.ZodLiteral<"main-index">;
7
+ requirement_bindings: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodType<IndexerJson, z.ZodTypeDef, IndexerJson>>, "many">;
8
+ read_scope: z.ZodRecord<z.ZodString, z.ZodType<IndexerJson, z.ZodTypeDef, IndexerJson>>;
9
+ profile: z.ZodObject<{
10
+ primary: z.ZodRecord<z.ZodString, z.ZodType<IndexerJson, z.ZodTypeDef, IndexerJson>>;
11
+ additional: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodType<IndexerJson, z.ZodTypeDef, IndexerJson>>, "many">;
12
+ }, "strict", z.ZodTypeAny, {
13
+ primary: Record<string, IndexerJson>;
14
+ additional: Record<string, IndexerJson>[];
15
+ }, {
16
+ primary: Record<string, IndexerJson>;
17
+ additional: Record<string, IndexerJson>[];
18
+ }>;
19
+ provider_layers: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodType<IndexerJson, z.ZodTypeDef, IndexerJson>>, "many">;
20
+ customization: z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodType<IndexerJson, z.ZodTypeDef, IndexerJson>>>;
21
+ projection_digest: z.ZodString;
22
+ }, "strict", z.ZodTypeAny, {
23
+ operation: "main-index";
24
+ protocol: "context.indexer.primary-registry-projection/v1";
25
+ requirement_bindings: Record<string, IndexerJson>[];
26
+ read_scope: Record<string, IndexerJson>;
27
+ profile: {
28
+ primary: Record<string, IndexerJson>;
29
+ additional: Record<string, IndexerJson>[];
30
+ };
31
+ customization: Record<string, IndexerJson> | null;
32
+ indexer_id: string;
33
+ provider_layers: Record<string, IndexerJson>[];
34
+ projection_digest: string;
35
+ }, {
36
+ operation: "main-index";
37
+ protocol: "context.indexer.primary-registry-projection/v1";
38
+ requirement_bindings: Record<string, IndexerJson>[];
39
+ read_scope: Record<string, IndexerJson>;
40
+ profile: {
41
+ primary: Record<string, IndexerJson>;
42
+ additional: Record<string, IndexerJson>[];
43
+ };
44
+ customization: Record<string, IndexerJson> | null;
45
+ indexer_id: string;
46
+ provider_layers: Record<string, IndexerJson>[];
47
+ projection_digest: string;
48
+ }>;
49
+ export type IndexerPrimaryRegistryProjection = z.infer<typeof indexerPrimaryRegistryProjectionSchema>;
50
+ type PrimaryRegistryProjectionPayload = Omit<IndexerPrimaryRegistryProjection, "projection_digest">;
51
+ export declare function indexerPrimaryRegistryProjectionDigest(value: PrimaryRegistryProjectionPayload): string;
52
+ export declare function buildIndexerPrimaryRegistryProjection(input: {
53
+ registry: IndexerRegistry;
54
+ indexer_id: string;
55
+ pre_authority_provider_ids?: readonly string[];
56
+ }): IndexerPrimaryRegistryProjection;
57
+ export declare function validateIndexerPrimaryRegistryProjection(input: {
58
+ projection: unknown;
59
+ registry: IndexerRegistry;
60
+ indexer_id: string;
61
+ pre_authority_provider_ids?: readonly string[];
62
+ }): IndexerPrimaryRegistryProjection;
63
+ declare const primaryResourceBindingSchema: z.ZodObject<{
64
+ layer_ref: z.ZodString;
65
+ phase: z.ZodEnum<["primary", "pre-authority"]>;
66
+ kind: z.ZodEffects<z.ZodString, string, string>;
67
+ ref: z.ZodString;
68
+ digest: z.ZodString;
69
+ }, "strict", z.ZodTypeAny, {
70
+ kind: string;
71
+ ref: string;
72
+ digest: string;
73
+ layer_ref: string;
74
+ phase: "primary" | "pre-authority";
75
+ }, {
76
+ kind: string;
77
+ ref: string;
78
+ digest: string;
79
+ layer_ref: string;
80
+ phase: "primary" | "pre-authority";
81
+ }>;
82
+ export declare const indexerPrimaryExecutionProjectionSchema: z.ZodEffects<z.ZodObject<{
83
+ protocol: z.ZodLiteral<"context.indexer.primary-execution-projection/v1">;
84
+ indexer_id: z.ZodEffects<z.ZodString, string, string>;
85
+ primary_registry_projection_digest: z.ZodString;
86
+ program_digest: z.ZodNullable<z.ZodString>;
87
+ instructions_digest: z.ZodString;
88
+ template_set_digest: z.ZodString;
89
+ config_digest: z.ZodString;
90
+ cli_contract_digest: z.ZodString;
91
+ profile_contract_digest: z.ZodString;
92
+ resources: z.ZodArray<z.ZodObject<{
93
+ layer_ref: z.ZodString;
94
+ phase: z.ZodEnum<["primary", "pre-authority"]>;
95
+ kind: z.ZodEffects<z.ZodString, string, string>;
96
+ ref: z.ZodString;
97
+ digest: z.ZodString;
98
+ }, "strict", z.ZodTypeAny, {
99
+ kind: string;
100
+ ref: string;
101
+ digest: string;
102
+ layer_ref: string;
103
+ phase: "primary" | "pre-authority";
104
+ }, {
105
+ kind: string;
106
+ ref: string;
107
+ digest: string;
108
+ layer_ref: string;
109
+ phase: "primary" | "pre-authority";
110
+ }>, "many">;
111
+ primary_resource_binding_digest: z.ZodString;
112
+ shared_artifact_fingerprint: z.ZodObject<{
113
+ protocol: z.ZodLiteral<"context.indexer.shared-artifact-fingerprint/v1">;
114
+ indexer_id: z.ZodEffects<z.ZodString, string, string>;
115
+ implementation_fingerprint: z.ZodString;
116
+ instructions_fingerprint: z.ZodString;
117
+ template_fingerprint: z.ZodString;
118
+ } & {
119
+ fingerprint_digest: z.ZodString;
120
+ }, "strict", z.ZodTypeAny, {
121
+ protocol: "context.indexer.shared-artifact-fingerprint/v1";
122
+ indexer_id: string;
123
+ implementation_fingerprint: string;
124
+ instructions_fingerprint: string;
125
+ template_fingerprint: string;
126
+ fingerprint_digest: string;
127
+ }, {
128
+ protocol: "context.indexer.shared-artifact-fingerprint/v1";
129
+ indexer_id: string;
130
+ implementation_fingerprint: string;
131
+ instructions_fingerprint: string;
132
+ template_fingerprint: string;
133
+ fingerprint_digest: string;
134
+ }>;
135
+ primary_execution_fingerprint: z.ZodString;
136
+ }, "strict", z.ZodTypeAny, {
137
+ protocol: "context.indexer.primary-execution-projection/v1";
138
+ indexer_id: string;
139
+ program_digest: string | null;
140
+ profile_contract_digest: string;
141
+ primary_registry_projection_digest: string;
142
+ primary_execution_fingerprint: string;
143
+ primary_resource_binding_digest: string;
144
+ instructions_digest: string;
145
+ template_set_digest: string;
146
+ config_digest: string;
147
+ cli_contract_digest: string;
148
+ resources: {
149
+ kind: string;
150
+ ref: string;
151
+ digest: string;
152
+ layer_ref: string;
153
+ phase: "primary" | "pre-authority";
154
+ }[];
155
+ shared_artifact_fingerprint: {
156
+ protocol: "context.indexer.shared-artifact-fingerprint/v1";
157
+ indexer_id: string;
158
+ implementation_fingerprint: string;
159
+ instructions_fingerprint: string;
160
+ template_fingerprint: string;
161
+ fingerprint_digest: string;
162
+ };
163
+ }, {
164
+ protocol: "context.indexer.primary-execution-projection/v1";
165
+ indexer_id: string;
166
+ program_digest: string | null;
167
+ profile_contract_digest: string;
168
+ primary_registry_projection_digest: string;
169
+ primary_execution_fingerprint: string;
170
+ primary_resource_binding_digest: string;
171
+ instructions_digest: string;
172
+ template_set_digest: string;
173
+ config_digest: string;
174
+ cli_contract_digest: string;
175
+ resources: {
176
+ kind: string;
177
+ ref: string;
178
+ digest: string;
179
+ layer_ref: string;
180
+ phase: "primary" | "pre-authority";
181
+ }[];
182
+ shared_artifact_fingerprint: {
183
+ protocol: "context.indexer.shared-artifact-fingerprint/v1";
184
+ indexer_id: string;
185
+ implementation_fingerprint: string;
186
+ instructions_fingerprint: string;
187
+ template_fingerprint: string;
188
+ fingerprint_digest: string;
189
+ };
190
+ }>, {
191
+ protocol: "context.indexer.primary-execution-projection/v1";
192
+ indexer_id: string;
193
+ program_digest: string | null;
194
+ profile_contract_digest: string;
195
+ primary_registry_projection_digest: string;
196
+ primary_execution_fingerprint: string;
197
+ primary_resource_binding_digest: string;
198
+ instructions_digest: string;
199
+ template_set_digest: string;
200
+ config_digest: string;
201
+ cli_contract_digest: string;
202
+ resources: {
203
+ kind: string;
204
+ ref: string;
205
+ digest: string;
206
+ layer_ref: string;
207
+ phase: "primary" | "pre-authority";
208
+ }[];
209
+ shared_artifact_fingerprint: {
210
+ protocol: "context.indexer.shared-artifact-fingerprint/v1";
211
+ indexer_id: string;
212
+ implementation_fingerprint: string;
213
+ instructions_fingerprint: string;
214
+ template_fingerprint: string;
215
+ fingerprint_digest: string;
216
+ };
217
+ }, {
218
+ protocol: "context.indexer.primary-execution-projection/v1";
219
+ indexer_id: string;
220
+ program_digest: string | null;
221
+ profile_contract_digest: string;
222
+ primary_registry_projection_digest: string;
223
+ primary_execution_fingerprint: string;
224
+ primary_resource_binding_digest: string;
225
+ instructions_digest: string;
226
+ template_set_digest: string;
227
+ config_digest: string;
228
+ cli_contract_digest: string;
229
+ resources: {
230
+ kind: string;
231
+ ref: string;
232
+ digest: string;
233
+ layer_ref: string;
234
+ phase: "primary" | "pre-authority";
235
+ }[];
236
+ shared_artifact_fingerprint: {
237
+ protocol: "context.indexer.shared-artifact-fingerprint/v1";
238
+ indexer_id: string;
239
+ implementation_fingerprint: string;
240
+ instructions_fingerprint: string;
241
+ template_fingerprint: string;
242
+ fingerprint_digest: string;
243
+ };
244
+ }>;
245
+ export type IndexerPrimaryExecutionProjection = z.infer<typeof indexerPrimaryExecutionProjectionSchema>;
246
+ type PrimaryResourceBinding = z.infer<typeof primaryResourceBindingSchema>;
247
+ type PrimaryExecutionProjectionPayload = Omit<IndexerPrimaryExecutionProjection, "primary_execution_fingerprint">;
248
+ export declare function indexerPrimaryResourceBindingDigest(resources: readonly PrimaryResourceBinding[]): string;
249
+ export declare function indexerPrimaryExecutionFingerprint(value: PrimaryExecutionProjectionPayload): string;
250
+ export declare function buildIndexerPrimaryExecutionProjection(input: {
251
+ indexer_id: string;
252
+ primary_registry_projection_digest: string;
253
+ program_digest: string | null;
254
+ instructions_digest: string;
255
+ template_set_digest: string;
256
+ config_digest: string;
257
+ cli_contract_digest: string;
258
+ profile_contract_digest: string;
259
+ resources: readonly PrimaryResourceBinding[];
260
+ }): IndexerPrimaryExecutionProjection;
261
+ export declare function validateIndexerPrimaryExecutionProjection(value: unknown): IndexerPrimaryExecutionProjection;
262
+ export {};