@semiont/core 0.5.20 → 0.5.22

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/testing.d.ts CHANGED
@@ -293,6 +293,20 @@ interface components {
293
293
  BeckonSparkleEvent: {
294
294
  annotationId: string;
295
295
  };
296
+ /** @description One edit to a linking annotation's body list: add or remove a body item, or replace an existing one. */
297
+ BindBodyOperation: {
298
+ /**
299
+ * @description The type of body operation
300
+ * @enum {string}
301
+ */
302
+ op: "add" | "remove" | "replace";
303
+ /** @description Body item for add operations */
304
+ item?: components["schemas"]["AnnotationBody"];
305
+ /** @description Previous body item for replace operations */
306
+ oldItem?: components["schemas"]["AnnotationBody"];
307
+ /** @description Replacement body item for replace operations */
308
+ newItem?: components["schemas"]["AnnotationBody"];
309
+ };
296
310
  /** @description Void success reply emitted on the bind:body-updated channel after bind:update-body has been applied, matched to the originating command by correlationId. */
297
311
  BindBodyUpdated: {
298
312
  /** @description Correlation id echoed from the originating bind:update-body command so busRequest can match the reply. */
@@ -319,20 +333,8 @@ interface components {
319
333
  annotationId: string;
320
334
  /** @description Branded ResourceId of the resource the annotation belongs to */
321
335
  resourceId: string;
322
- /** @description List of body mutation operations to apply */
323
- operations: {
324
- /**
325
- * @description The type of body operation
326
- * @enum {string}
327
- */
328
- op: "add" | "remove" | "replace";
329
- /** @description Body item for add operations */
330
- item?: components["schemas"]["AnnotationBody"];
331
- /** @description Previous body item for replace operations */
332
- oldItem?: components["schemas"]["AnnotationBody"];
333
- /** @description Replacement body item for replace operations */
334
- newItem?: components["schemas"]["AnnotationBody"];
335
- }[];
336
+ /** @description Ordered body-list edits to apply. */
337
+ operations: components["schemas"]["BindBodyOperation"][];
336
338
  };
337
339
  BodyOperationAdd: {
338
340
  /** @enum {string} */
@@ -669,8 +671,8 @@ interface components {
669
671
  placement: "local" | "codespace";
670
672
  /** @description owner/name GitHub slug — present for codespace placements, where the repo is the stack's identity */
671
673
  repo?: string;
672
- /** @description The KB's did:web identifier as recorded from its committed .semiont/config — the permanent identity stamped into its event log. Prefer this as a merge key: ports are reallocated across restarts; the did follows the KB. */
673
- did?: string;
674
+ /** @description The KB's did:web identifier, from its committed .semiont/config — "did:web:" + the [site] domain, verbatim. REQUIRED: a KB that declares no domain has no identity to publish, and the launcher refuses to start it rather than inventing or defaulting one. NOT unique within a document: a did names the knowledge base, not a running copy of it, so a local clone and a codespace of the same repo legitimately share one and both are published. host:port is the unique field (at most one entry per address), so consumers look up by ADDRESS and use the did to VERIFY that the copy they reached is the KB they meant — an address alone cannot say which KB is which, and an identity alone cannot say which copy. */
675
+ did: string;
674
676
  /** @description Human-readable site name from the KB's .semiont/config, for display */
675
677
  siteName?: string;
676
678
  /** @description The agent that owns this entry's lifecycle (the launcher writes "semiont-launcher"). Consumers treat managed entries as authoritative for themselves — upsert on appearance, remove on disappearance — and never touch entries they did not write. */
@@ -784,6 +786,15 @@ interface components {
784
786
  /** @description The gathered annotation context (unified GatheredContext, focus.kind:'annotation') */
785
787
  response: components["schemas"]["GatheredContext"];
786
788
  };
789
+ /** @description Optional configuration for an annotation-focus gather, which windows text around a mark. Distinct from the resource-focus options (depth / maxResources / includeContent / includeSummary), which traverse the resource graph. */
790
+ GatherAnnotationOptions: {
791
+ /** @description Whether to include source context in the gathered result */
792
+ includeSourceContext?: boolean;
793
+ /** @description Whether to include target context in the gathered result */
794
+ includeTargetContext?: boolean;
795
+ /** @description Characters of surrounding text context to include */
796
+ contextWindow?: number;
797
+ };
787
798
  /** @description Request payload sent on the gather:requested bus channel to gather context for an annotation. */
788
799
  GatherAnnotationRequest: {
789
800
  /** @description Client-generated correlation ID to thread the response back to the originating request */
@@ -792,15 +803,7 @@ interface components {
792
803
  annotationId: string;
793
804
  /** @description Branded ResourceId of the resource the annotation belongs to */
794
805
  resourceId: string;
795
- /** @description Optional gathering configuration */
796
- options?: {
797
- /** @description Whether to include source context in the gathered result */
798
- includeSourceContext?: boolean;
799
- /** @description Whether to include target context in the gathered result */
800
- includeTargetContext?: boolean;
801
- /** @description Characters of surrounding text context to include */
802
- contextWindow?: number;
803
- };
806
+ options?: components["schemas"]["GatherAnnotationOptions"];
804
807
  };
805
808
  /** @description Progress payload emitted on the gather:annotation-progress SSE channel during LLM context gathering. */
806
809
  GatherProgress: {
@@ -1400,12 +1403,8 @@ interface components {
1400
1403
  MatchSearchResult: {
1401
1404
  correlationId: string;
1402
1405
  referenceId: string;
1403
- response: (components["schemas"]["ResourceDescriptor"] & {
1404
- /** @description Relevance score */
1405
- score?: number;
1406
- /** @description Human-readable reason for the match */
1407
- matchReason?: string;
1408
- })[];
1406
+ /** @description The scored candidates, best first. */
1407
+ response: components["schemas"]["ScoredResource"][];
1409
1408
  };
1410
1409
  MediaTokenRequest: {
1411
1410
  /** @description The resource ID to generate a media token for */
@@ -1607,6 +1606,13 @@ interface components {
1607
1606
  contentChecksum: string;
1608
1607
  contentByteSize?: number;
1609
1608
  };
1609
+ /** @description A resource returned by a search, carrying its relevance score and the reason it matched. */
1610
+ ScoredResource: components["schemas"]["ResourceDescriptor"] & {
1611
+ /** @description Relevance score assigned by the matcher; higher is a better candidate. */
1612
+ score?: number;
1613
+ /** @description Human-readable reason for the match. */
1614
+ matchReason?: string;
1615
+ };
1610
1616
  /** @description Selection data for user-initiated annotations. Captures the text range and optional selector information from a user's highlight in the UI. */
1611
1617
  SelectionData: {
1612
1618
  /** @description The exact selected text */
@@ -1673,6 +1679,8 @@ interface components {
1673
1679
  projectName?: string;
1674
1680
  /** @description Current git branch of the knowledge base repository */
1675
1681
  gitBranch?: string;
1682
+ /** @description The knowledge base's did:web identity — 'did:web:' + the committed [site] domain, byte-identical to the string the launcher publishes in its discovery document. REQUIRED: a KB that declares no domain does not run (the launcher refuses to start it, and the backend refuses to boot), so a response without this field means the caller reached something that bypassed both. Identifies WHICH knowledge base this is; it does NOT identify which running copy — one KB reachable at two addresses (a local clone and a codespace of one repo) reports the same did at both. Use it to verify what you connected to, not to select among discovered entries. */
1683
+ did: string;
1676
1684
  };
1677
1685
  /** @description A persisted domain event with metadata. Flat shape — event fields and metadata are peers. */
1678
1686
  StoredEventResponse: {
@@ -2075,6 +2083,23 @@ type StoredEvent<T extends EventBase = PersistedEvent> = T & {
2075
2083
  signature?: EventSignature;
2076
2084
  };
2077
2085
 
2086
+ /**
2087
+ * Viewport-space rectangle of a clicked annotation element — runtime-only
2088
+ * view geometry riding UI events (never wire vocabulary; deliberately not in
2089
+ * the OpenAPI schemas). Structurally satisfied by a DOM `DOMRect`, spelled
2090
+ * out here because this package compiles without the DOM lib.
2091
+ */
2092
+ interface AnchorRect {
2093
+ x: number;
2094
+ y: number;
2095
+ width: number;
2096
+ height: number;
2097
+ top: number;
2098
+ right: number;
2099
+ bottom: number;
2100
+ left: number;
2101
+ }
2102
+
2078
2103
  /**
2079
2104
  * Bus Protocol
2080
2105
  *
@@ -2118,22 +2143,6 @@ type BindUpdateBodyCommand = components['schemas']['BindUpdateBodyCommand'] & {
2118
2143
  * - Commands/reads/results/UI: OpenAPI schema refs — plain strings
2119
2144
  * - void: UI-only signals with no payload
2120
2145
  */
2121
- /**
2122
- * Viewport-space rectangle of a clicked annotation element — runtime-only
2123
- * view geometry riding UI events (never wire vocabulary; deliberately not in
2124
- * the OpenAPI schemas). Structurally satisfied by a DOM `DOMRect`, spelled
2125
- * out here because this package compiles without the DOM lib.
2126
- */
2127
- interface AnchorRect {
2128
- x: number;
2129
- y: number;
2130
- width: number;
2131
- height: number;
2132
- top: number;
2133
- right: number;
2134
- bottom: number;
2135
- left: number;
2136
- }
2137
2146
  type EventMap = {
2138
2147
  'yield:created': StoredEvent<EventOfType<'yield:created'>>;
2139
2148
  'yield:cloned': StoredEvent<EventOfType<'yield:cloned'>>;