@collective-intelligence/extensions-sdk 0.1.26 → 0.1.28

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.
@@ -124,27 +124,6 @@ export declare const entityCapability: ReadValue<Readonly<{
124
124
  syncIntervalSeconds?: number | null;
125
125
  updateMode?: "full" | "partial";
126
126
  }> & import("../index.js").JsonObject>;
127
- export declare const relationCapability: ReadValue<Readonly<{
128
- extraPropsMode?: "ignore" | "import" | "inline";
129
- fieldMap?: readonly C.KnowledgeConnectorFieldMapRule[];
130
- fqn: string;
131
- outboundStrategy?: "local_first" | "remote_first";
132
- predefinedBindingExtras?: readonly C.KnowledgeConnectorBindingExtraConfig[];
133
- predefinedBindingKey?: string;
134
- predefinedBindingMode?: "external" | "managed";
135
- predefinedBindingParentEntityKey?: string;
136
- predefinedBindingRelationImportMode?: "child_binding" | "relation_only";
137
- predefinedBindingRemoteCollectionId?: string;
138
- predefinedBindingRemoteCollectionName?: string;
139
- predefinedBindingSourceEntityKey?: string;
140
- predefinedBindingTargetEntityKey?: string;
141
- predefinedSchedules?: readonly C.KnowledgePredefinedSchedule[];
142
- supportedSyncModes?: readonly ("delta" | "full")[];
143
- supportsInbound?: boolean;
144
- supportsOutbound?: boolean;
145
- syncIntervalSeconds?: number | null;
146
- updateMode?: "full" | "partial";
147
- }> & import("../index.js").JsonObject>;
148
127
  export declare const discoveryDefaults: ReadValue<Readonly<{
149
128
  extraPropsMode: "ignore" | "import" | "inline";
150
129
  outboundStrategy: "local_first" | "remote_first";
@@ -1,5 +1,5 @@
1
- import type { ClassDeclaredComponent, ConnectionImplementation, DeclaredComponent, DocumentsConnectorImplementation, ErasedWorkflowFieldImplementation, EventListenerImplementation, FieldTransformerImplementation, KnowledgeConnectorImplementation, KnowledgeConnectorOAuthImplementation, KnowledgeEntityAdapterImplementation, KnowledgeRelationAdapterImplementation, MetadataComponentManifest, NotificationChannelImplementation, PackageSchemaRuntimeSidecar, ToolImplementationConstructor, ToolSettingsOptionsImplementation, WorkflowNodeImplementationConstructor } from "../components/authoring-core.js";
2
- import type { ConnectionDeclaration, DocumentsConnectorDeclaration, DatasetParserDeclaration, ExternalDatasetProviderDeclaration, ManagedDatasetProviderDeclaration, EmailProviderDeclaration, EventListenerDeclaration, KnowledgeConnectorDeclaration, KnowledgeConnectorOAuthDeclaration, KnowledgeEntityAdapterDeclaration, KnowledgeRelationAdapterDeclaration, OrganizationSsoDeclaration, OutboundMessagingProviderDeclaration } from "../components/connectors.js";
1
+ import type { ClassDeclaredComponent, ConnectionImplementation, DeclaredComponent, DocumentsConnectorImplementation, ErasedWorkflowFieldImplementation, EventListenerImplementation, FieldTransformerImplementation, KnowledgeConnectorImplementation, KnowledgeConnectorOAuthImplementation, KnowledgeEntityAdapterImplementation, MetadataComponentManifest, NotificationChannelImplementation, PackageSchemaRuntimeSidecar, ToolImplementationConstructor, ToolSettingsOptionsImplementation, WorkflowNodeImplementationConstructor } from "../components/authoring-core.js";
2
+ import type { ConnectionDeclaration, DocumentsConnectorDeclaration, DatasetParserDeclaration, ExternalDatasetProviderDeclaration, ManagedDatasetProviderDeclaration, EmailProviderDeclaration, EventListenerDeclaration, KnowledgeConnectorDeclaration, KnowledgeConnectorOAuthDeclaration, KnowledgeEntityAdapterDeclaration, OrganizationSsoDeclaration, OutboundMessagingProviderDeclaration } from "../components/connectors.js";
3
3
  import type { DatasetParserImplementation } from "../components/dataset-parser.js";
4
4
  import type { ExternalDatasetProviderImplementation, ManagedDatasetProviderImplementation } from "../components/datasets.js";
5
5
  import type { EmailProviderImplementation, OrganizationSsoImplementation, OutboundMessagingProviderImplementation } from "../components/executable-authoring.js";
@@ -8,7 +8,7 @@ import type { WorkflowFieldDeclaration, WorkflowNodeDeclaration } from "../compo
8
8
  import type { HostedContributionDeclaration } from "../hosted/contributions.js";
9
9
  import type { PackageManifest } from "./manifest.js";
10
10
  import type { PackageVariablesDeclaration } from "./variables.js";
11
- export type DeclaredPackageComponent = ClassDeclaredComponent<DatasetParserDeclaration, new () => DatasetParserImplementation> | ClassDeclaredComponent<ExternalDatasetProviderDeclaration, new () => ExternalDatasetProviderImplementation> | ClassDeclaredComponent<ManagedDatasetProviderDeclaration, new () => ManagedDatasetProviderImplementation> | ClassDeclaredComponent<OrganizationSsoDeclaration, new () => OrganizationSsoImplementation> | ClassDeclaredComponent<EmailProviderDeclaration, new () => EmailProviderImplementation> | ClassDeclaredComponent<OutboundMessagingProviderDeclaration, new () => OutboundMessagingProviderImplementation> | ClassDeclaredComponent<ToolDeclaration, ToolImplementationConstructor> | ClassDeclaredComponent<ConnectionDeclaration, new () => ConnectionImplementation<unknown>> | ClassDeclaredComponent<DocumentsConnectorDeclaration, new () => DocumentsConnectorImplementation> | ClassDeclaredComponent<KnowledgeConnectorDeclaration, new () => KnowledgeConnectorImplementation> | ClassDeclaredComponent<KnowledgeConnectorOAuthDeclaration, new () => KnowledgeConnectorOAuthImplementation> | ClassDeclaredComponent<WorkflowNodeDeclaration, WorkflowNodeImplementationConstructor> | ClassDeclaredComponent<WorkflowFieldDeclaration, new () => ErasedWorkflowFieldImplementation> | ClassDeclaredComponent<EventListenerDeclaration, new () => EventListenerImplementation> | ClassDeclaredComponent<KnowledgeEntityAdapterDeclaration, new () => KnowledgeEntityAdapterImplementation> | ClassDeclaredComponent<KnowledgeRelationAdapterDeclaration, new () => KnowledgeRelationAdapterImplementation> | ClassDeclaredComponent<FieldTransformerDeclaration, new () => FieldTransformerImplementation> | ClassDeclaredComponent<NotificationChannelDeclaration, new () => NotificationChannelImplementation> | ClassDeclaredComponent<ToolSettingsOptionsDeclaration, new () => ToolSettingsOptionsImplementation> | DeclaredComponent<MetadataComponentManifest>;
11
+ export type DeclaredPackageComponent = ClassDeclaredComponent<DatasetParserDeclaration, new () => DatasetParserImplementation> | ClassDeclaredComponent<ExternalDatasetProviderDeclaration, new () => ExternalDatasetProviderImplementation> | ClassDeclaredComponent<ManagedDatasetProviderDeclaration, new () => ManagedDatasetProviderImplementation> | ClassDeclaredComponent<OrganizationSsoDeclaration, new () => OrganizationSsoImplementation> | ClassDeclaredComponent<EmailProviderDeclaration, new () => EmailProviderImplementation> | ClassDeclaredComponent<OutboundMessagingProviderDeclaration, new () => OutboundMessagingProviderImplementation> | ClassDeclaredComponent<ToolDeclaration, ToolImplementationConstructor> | ClassDeclaredComponent<ConnectionDeclaration, new () => ConnectionImplementation<unknown>> | ClassDeclaredComponent<DocumentsConnectorDeclaration, new () => DocumentsConnectorImplementation> | ClassDeclaredComponent<KnowledgeConnectorDeclaration, new () => KnowledgeConnectorImplementation> | ClassDeclaredComponent<KnowledgeConnectorOAuthDeclaration, new () => KnowledgeConnectorOAuthImplementation> | ClassDeclaredComponent<WorkflowNodeDeclaration, WorkflowNodeImplementationConstructor> | ClassDeclaredComponent<WorkflowFieldDeclaration, new () => ErasedWorkflowFieldImplementation> | ClassDeclaredComponent<EventListenerDeclaration, new () => EventListenerImplementation> | ClassDeclaredComponent<KnowledgeEntityAdapterDeclaration, new () => KnowledgeEntityAdapterImplementation> | ClassDeclaredComponent<FieldTransformerDeclaration, new () => FieldTransformerImplementation> | ClassDeclaredComponent<NotificationChannelDeclaration, new () => NotificationChannelImplementation> | ClassDeclaredComponent<ToolSettingsOptionsDeclaration, new () => ToolSettingsOptionsImplementation> | DeclaredComponent<MetadataComponentManifest>;
12
12
  /** Backwards-compatible name for the discriminated package component union. */
13
13
  export type PackageComponent = DeclaredPackageComponent;
14
14
  export type DeclaredPackageManifest = PackageManifest;
@@ -1,4 +1,10 @@
1
1
  import type * as I from "../components/connector-instances.js";
2
2
  import type { ReadValue } from "./readers.js";
3
+ import type { VaryingDefinition } from "./variables.js";
4
+ export declare const connection: ReadValue<(VaryingDefinition<{
5
+ setupKey: string;
6
+ }> & import("../index.js").JsonObject) | ({
7
+ connectionInstanceFqn: string;
8
+ } & import("../index.js").JsonObject)>;
3
9
  export declare const knowledgeConnectorInstance: ReadValue<I.KnowledgeConnectorInstanceDeclaration>;
4
10
  export declare const datasetConnectorInstance: ReadValue<I.DatasetConnectorInstanceDeclaration>;
@@ -124,6 +124,12 @@ export declare const lifecycle: ReadValue<Readonly<{
124
124
  deployMode: import("../index.js").LifecycleDeployMode;
125
125
  readonly: boolean;
126
126
  }> & import("../index.js").JsonObject>;
127
+ /**
128
+ * Refuses a key retired with Record Relations by name. The object reader keeps
129
+ * unknown keys, so the retired key is refused here; only stored-release reads
130
+ * drop it.
131
+ */
132
+ export declare const withoutRetiredRelationKey: <A extends object>(read: ReadValue<A>, key: string) => ReadValue<A>;
127
133
  export declare const autocompleteConfiguration: ReadValue<Readonly<{
128
134
  autocompleteFields: readonly K.KnowledgeAutocompleteFieldReference[];
129
135
  defaultAutocompleteFields: readonly K.KnowledgeAutocompleteFieldReference[];
@@ -8,7 +8,7 @@ export declare const policyBody: ReadValue<Readonly<{
8
8
  }> & import("../index.js").JsonObject>;
9
9
  /** Only an allow filter policy on entities may hold a field write rule. */
10
10
  export declare const fieldWriteRule: <A extends Pick<KnowledgePolicyDeclaration, "effect" | "policyBody" | "policyType" | "targetKind">>(policy: A, path: string) => A;
11
- /** Only a policy on one entity schema may follow its relation fields. */
11
+ /** Only a policy on one entity schema may follow its Reference Fields. */
12
12
  export declare const relationScopeRule: <A extends Pick<KnowledgePolicyDeclaration, "policyBody" | "targetKind">>(policy: A, path: string) => A;
13
13
  export declare const policyFields: {
14
14
  effect: ReadValue<"allow" | "deny">;
@@ -19,5 +19,5 @@ export declare const policyFields: {
19
19
  }> & import("../index.js").JsonObject>;
20
20
  policyType: ReadValue<"filter" | "gate">;
21
21
  targetFqn: ReadValue<string>;
22
- targetKind: ReadValue<"entity_domain" | "entity_schema" | "relation_domain" | "relation_schema">;
22
+ targetKind: ReadValue<"entity_domain" | "entity_schema">;
23
23
  };
@@ -4,6 +4,7 @@ import type * as Cat from "../components/catalog.js";
4
4
  import type { ConnectionInstanceDeclaration } from "../components/connection-instances.js";
5
5
  import type * as C from "../components/connectors.js";
6
6
  import type * as D from "../components/declaration.js";
7
+ import type * as Dc from "../components/document-collections.js";
7
8
  import type * as Ext from "../components/external-application.js";
8
9
  import type * as K from "../components/knowledge.js";
9
10
  import type * as Og from "../components/organization-group.js";
@@ -124,6 +125,7 @@ export declare const primitives: {
124
125
  requirements: import("../index.js").PackageSchemaProjection;
125
126
  semanticRoles: readonly import("../index.js").DatasetTableTemplateSemanticRole[];
126
127
  }> & JsonObject>;
128
+ documentCollection: ReadValue<Dc.DocumentCollectionDeclaration>;
127
129
  documentsConnector: ReadValue<Readonly<{
128
130
  description?: string;
129
131
  displayName: string;
@@ -163,7 +165,6 @@ export declare const primitives: {
163
165
  domainFqn: string;
164
166
  domainName: string;
165
167
  entitySchemaFqns: readonly string[];
166
- relationSchemaFqns: readonly string[];
167
168
  }> & JsonObject>;
168
169
  emailProvider: ReadValue<Readonly<{
169
170
  description?: string;
@@ -272,14 +273,15 @@ export declare const primitives: {
272
273
  contributions?: readonly C.KnowledgeConnectorContribution[];
273
274
  defaultOutboundStrategy?: "local_first" | "remote_first";
274
275
  defaultUpdateMode?: "full" | "partial";
276
+ deltaOverlapSeconds?: number;
275
277
  discoveryDefaults?: C.KnowledgeConnectorDiscoveryDefaults;
276
278
  entityIdentityMode?: "adapter" | "item_metadata";
277
279
  entitySchemaCapabilities?: readonly C.KnowledgeEntitySchemaCapability[];
278
280
  isSingleton?: boolean;
279
281
  outboundCapability?: "declared_and_enablable" | "none";
282
+ pullPageSize?: number;
280
283
  remoteDeletion?: C.KnowledgeConnectorRemoteDeletion;
281
284
  recommendedImportSchedules?: readonly C.KnowledgePredefinedSchedule[];
282
- relationSchemaCapabilities?: readonly C.KnowledgeRelationSchemaCapability[];
283
285
  remoteReference?: C.KnowledgeConnectorRemoteReference;
284
286
  settings?: import("../index.js").PortableFormDefinition;
285
287
  supportedBindingModes?: readonly ("external" | "managed")[];
@@ -321,45 +323,12 @@ export declare const primitives: {
321
323
  version: string;
322
324
  }> & Readonly<{
323
325
  effect: "allow" | "deny";
324
- targetKind: "entity_domain" | "entity_schema" | "relation_domain" | "relation_schema";
326
+ targetKind: "entity_domain" | "entity_schema";
325
327
  policyBody: K.KnowledgePolicyBody;
326
328
  policyType: "filter" | "gate";
327
329
  priority?: number;
328
330
  targetFqn: string;
329
331
  }> & JsonObject;
330
- knowledgeRelationAdapter: ReadValue<Readonly<{
331
- description?: string;
332
- displayName: string;
333
- fqn: string;
334
- icon?: string;
335
- kind: "knowledgeRelationAdapter";
336
- tags?: readonly string[];
337
- version: string;
338
- }> & Readonly<{
339
- connectorFqn: string;
340
- relationSchemaFqn: string;
341
- }> & JsonObject>;
342
- knowledgeRelationSchema: ReadValue<Readonly<{
343
- description?: string;
344
- displayName: string;
345
- fqn: string;
346
- icon?: string;
347
- kind: "knowledgeRelationSchema";
348
- tags?: readonly string[];
349
- version: string;
350
- }> & Readonly<{
351
- catalogTags?: Cat.CatalogTags;
352
- domainFqn: string;
353
- lifecycle?: import("../index.js").LifecycleOptions;
354
- localMutationPolicy?: "always" | "connector_backed" | "never";
355
- managedProjection?: K.KnowledgeManagedProjection;
356
- fieldLocalization?: Readonly<Record<string, K.KnowledgeFieldLocalization>>;
357
- fieldPresentation?: Readonly<Record<string, K.KnowledgeFieldPresentation>>;
358
- fieldSemantics?: Readonly<Record<string, K.KnowledgeFieldSemantics>>;
359
- schema: import("../index.js").PackageSchemaProjection;
360
- sourceSchemaFqn: string;
361
- targetSchemaFqn: string;
362
- }> & JsonObject>;
363
332
  managedDatasetProvider: ReadValue<Readonly<{
364
333
  description?: string;
365
334
  displayName: string;
@@ -6,6 +6,12 @@ import type { ExtensionReleaseManifest } from "./manifest.js";
6
6
  * a Studio App Template stored as `studioApp`.
7
7
  */
8
8
  export declare const storedPrimitiveKind: (stored: unknown) => string | undefined;
9
+ /**
10
+ * Returns one stored primitive declaration with the current spelling that
11
+ * {@link withCurrentPrimitiveKinds} gives each primitive of a stored release.
12
+ * A reader of a stored definition baseline calls it after the digest check.
13
+ */
14
+ export declare const withCurrentPrimitive: (primitive: JsonObject) => JsonObject;
9
15
  /**
10
16
  * Returns a stored release manifest whose retained primitive declarations use
11
17
  * the current spelling: current kind names, a Studio App Template in place of
@@ -13,7 +19,11 @@ export declare const storedPrimitiveKind: (stored: unknown) => string | undefine
13
19
  * `invokingApplicationFqns`, and Organization Group names in place of
14
20
  * Organization Team names. Historical Entity Relation Field cardinalities map
15
21
  * one/many to many_to_one/many_to_many; valid redundant scalar maxItems is
16
- * removed. Every other relation setting is retained. A reader that
22
+ * removed. Every other relation setting is retained. Components of a kind
23
+ * retired with Record Relations, the retired relation keys of current
24
+ * components, `relation` pipeline tasks and each step or pipeline left without
25
+ * a task are dropped; a retired nested policy form still fails the read. A
26
+ * reader that
17
27
  * executes the release archive compares the verbatim stored JSON with the
18
28
  * archive before it calls this function.
19
29
  */
@@ -8,7 +8,6 @@ export declare const SchemaConsumerProfiles: Readonly<{
8
8
  readonly connectorSettings: "interactive_form";
9
9
  readonly form: "interactive_form";
10
10
  readonly knowledgeEntity: "knowledge_record";
11
- readonly knowledgeRelation: "knowledge_record";
12
11
  readonly notificationCredential: "interactive_form";
13
12
  readonly studioComponentProps: "studio_props";
14
13
  readonly toolInput: "ai_function_input";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@collective-intelligence/extensions-sdk",
3
- "version": "0.1.26",
3
+ "version": "0.1.28",
4
4
  "description": "Framework-neutral authoring contracts for Collective Intelligence extension packages.",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -45,5 +45,5 @@
45
45
  "typescript": "7.0.2",
46
46
  "ultracite": "7.10.7"
47
47
  },
48
- "gitHead": "2c37d54a16c777f06382ff0e527c544f5ff38012"
48
+ "gitHead": "a2aa507323bc6d3ce0ef6d3e460f28573ef40dd8"
49
49
  }