@kortexya/reasoninglayer 1.0.1 → 1.1.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.
package/dist/index.d.ts CHANGED
@@ -109,7 +109,7 @@ type JsonValue$1 = string | number | boolean | null | JsonValue$1[] | object;
109
109
  * This is the single source of truth for the version constant.
110
110
  * The `scripts/release.sh` script updates this value alongside `package.json`.
111
111
  */
112
- declare const SDK_VERSION = "1.0.1";
112
+ declare const SDK_VERSION = "1.1.0";
113
113
  /**
114
114
  * Authentication mode for the SDK.
115
115
  *
@@ -605,6 +605,12 @@ interface AddPendingReviewResponse {
605
605
  }
606
606
  /** Request to add a rule (a term with antecedents). */
607
607
  interface AddRuleRequest$1 {
608
+ /**
609
+ * Optional engine-side aggregator declared on the rule head.
610
+ * When present, the rule's head term receives an `"aggregator"` feature
611
+ * containing a serialized `RuleAggregator` descriptor.
612
+ */
613
+ aggregator?: null | RuleAggregatorDto;
608
614
  /**
609
615
  * Antecedent terms (body of the rule)
610
616
  * These go into the `when` feature
@@ -801,6 +807,51 @@ interface AlignmentStatsDto {
801
807
  */
802
808
  entities_unaligned: number;
803
809
  }
810
+ /** Request body for `POST /api/v1/operations/anti-unify`. */
811
+ interface AntiUnifyRequest$1 {
812
+ /**
813
+ * First Ψ-term id; must already be registered in the tenant's
814
+ * term store.
815
+ * @format uuid
816
+ */
817
+ term1_id: string;
818
+ /**
819
+ * Second Ψ-term id; must already be registered in the tenant's
820
+ * term store.
821
+ * @format uuid
822
+ */
823
+ term2_id: string;
824
+ }
825
+ /**
826
+ * Response from anti-unification.
827
+ *
828
+ * The engine creates the LGG term inside the tenant's term store and
829
+ * returns its id; the full enriched [`TermDto`] is included so
830
+ * callers can inspect features and free variables in a single
831
+ * round-trip.
832
+ */
833
+ interface AntiUnifyResponse$1 {
834
+ /**
835
+ * Computation time in milliseconds (engine + lock acquisition).
836
+ * @format int64
837
+ * @min 0
838
+ */
839
+ computation_time_ms: number;
840
+ /** Full enriched view of the LGG term (sort, features, references). */
841
+ lgg: TermDto$1;
842
+ /**
843
+ * Id of the newly-created LGG term.
844
+ * @format uuid
845
+ */
846
+ lgg_term_id: string;
847
+ }
848
+ interface AppendRequest$1 {
849
+ data_versions?: Record<string, string>;
850
+ extra?: Record<string, any>;
851
+ request_hash: string;
852
+ request_path: string;
853
+ response_hash: string;
854
+ }
804
855
  /** Request to append residuations during unification */
805
856
  interface AppendResiduationsRequest$1 {
806
857
  session_id: string;
@@ -1131,6 +1182,30 @@ interface AttestationDto$1 {
1131
1182
  /** Human-readable verification description */
1132
1183
  verification_details: string;
1133
1184
  }
1185
+ /**
1186
+ * One immutable, hash-chained audit record.
1187
+ *
1188
+ * Field order matters for hashing: serialisation is via `serde_json`
1189
+ * with sorted keys, so insertion order is irrelevant — only the field
1190
+ * *names* drive the canonical JSON layout.
1191
+ */
1192
+ interface AuditRecord$1 {
1193
+ actor?: null | UserId;
1194
+ data_versions: Record<string, string>;
1195
+ extra: Record<string, object>;
1196
+ git_revision: string;
1197
+ id: AuditRecordId;
1198
+ prev_hash: string;
1199
+ record_hash: string;
1200
+ request_hash: string;
1201
+ request_path: string;
1202
+ response_hash: string;
1203
+ tenant_id: TenantId;
1204
+ /** @format date-time */
1205
+ timestamp: string;
1206
+ }
1207
+ /** @format uuid */
1208
+ type AuditRecordId = string;
1134
1209
  /** An augmentation target identified by calibration. */
1135
1210
  interface AugmentationTargetDto$1 {
1136
1211
  /** Specific feature (if feature-level target). */
@@ -1155,6 +1230,24 @@ interface AugmentationTargetDto$1 {
1155
1230
  /** Sort name. */
1156
1231
  sort_name: string;
1157
1232
  }
1233
+ /** Trace entry for a single fired knowledge axiom. */
1234
+ interface AxiomFiringDto {
1235
+ /**
1236
+ * Combined antecedent truth (product t-norm over antecedent gates).
1237
+ * @format double
1238
+ */
1239
+ antecedent_truth: number;
1240
+ /**
1241
+ * Reichenbach satisfaction `1 − a + a · c`.
1242
+ * @format double
1243
+ */
1244
+ reichenbach_satisfaction: number;
1245
+ /**
1246
+ * The rule that fired.
1247
+ * @format uuid
1248
+ */
1249
+ rule_id: string;
1250
+ }
1158
1251
  /** Request to backtrack to a marker or most recent choice point */
1159
1252
  interface BacktrackRequest {
1160
1253
  /**
@@ -1241,6 +1334,17 @@ interface BackwardChainRequest$1 {
1241
1334
  * Internally converted to Ψ-term constraints for TRUE HOMOICONICITY.
1242
1335
  */
1243
1336
  constraints?: ConstraintInputDto$1[];
1337
+ /**
1338
+ * When true, the response's `referenced_terms` field is populated
1339
+ * with the full TermDto for every term transitively referenced by
1340
+ * any solution's bindings. Lets the caller read complex bound
1341
+ * values (lists of nested Ψ-terms etc.) in one request instead of
1342
+ * chasing references via getTerm.
1343
+ *
1344
+ * Default: false (existing behaviour preserved).
1345
+ * @default false
1346
+ */
1347
+ expand_bindings?: boolean;
1244
1348
  /**
1245
1349
  * The goal to prove (as a term).
1246
1350
  * Either `goal` or `goal_id` must be provided, but not both.
@@ -1307,6 +1411,17 @@ interface BackwardChainResponse$1 {
1307
1411
  * @min 0
1308
1412
  */
1309
1413
  query_time_ms: number;
1414
+ /**
1415
+ * Populated when the request had `expand_bindings: true`.
1416
+ * Maps UUID-as-string → TermDto for every term transitively
1417
+ * referenced by the solutions' bindings. Capped at
1418
+ * MAX_EXPAND_TERMS to prevent runaway responses.
1419
+ *
1420
+ * Keys are stringified UUIDs because JSON object keys must be
1421
+ * strings; this also matches the existing `referenced_terms`
1422
+ * shape on `TermDto` for consistency.
1423
+ */
1424
+ referenced_terms?: object | null;
1310
1425
  /** Solutions found */
1311
1426
  solutions: SolutionDto$1[];
1312
1427
  }
@@ -1675,6 +1790,32 @@ interface BoundConstraintDto$1 {
1675
1790
  /** Target feature name that will be constrained */
1676
1791
  target: string;
1677
1792
  }
1793
+ /** Request: diff two MVCC branches of the tenant's term store. */
1794
+ interface BranchDiffRequest {
1795
+ /** Source branch (the "before"). */
1796
+ branch_a: string;
1797
+ /** Target branch (the "after"). */
1798
+ branch_b: string;
1799
+ /**
1800
+ * Cap the number of changed terms to render.
1801
+ * @format int32
1802
+ * @min 0
1803
+ */
1804
+ limit?: number;
1805
+ }
1806
+ interface BranchDiffResponse {
1807
+ /** @min 0 */
1808
+ added_count: number;
1809
+ /** @min 0 */
1810
+ changed_count: number;
1811
+ /**
1812
+ * `VisualizationGraph` with each node carrying
1813
+ * `properties.diff = "added" | "removed" | "changed"`.
1814
+ */
1815
+ graph: VisualizationGraphDto$1;
1816
+ /** @min 0 */
1817
+ removed_count: number;
1818
+ }
1678
1819
  /** Request to broadcast a message to all agents. */
1679
1820
  interface BroadcastMessageRequest$1 {
1680
1821
  /** Message content (arbitrary JSON) */
@@ -2052,6 +2193,16 @@ interface CandidateMatchDto$1 {
2052
2193
  */
2053
2194
  term_id: string;
2054
2195
  }
2196
+ interface CaptureSnapshotRequest$1 {
2197
+ /** @format date-time */
2198
+ captured_after?: string | null;
2199
+ /**
2200
+ * @format int32
2201
+ * @min 0
2202
+ */
2203
+ max_entries?: number | null;
2204
+ request_path_pattern: string;
2205
+ }
2055
2206
  /** Request to check if one variable is a causal ancestor of another */
2056
2207
  interface CausalAncestorRequest$1 {
2057
2208
  /** The potential ancestor variable */
@@ -3155,6 +3306,44 @@ interface CopyTermResponse {
3155
3306
  copy_mode: CopyModeDto$1;
3156
3307
  original_term_id: string;
3157
3308
  }
3309
+ /**
3310
+ * One coreference group — a target Ψ-term that appears as the value
3311
+ * of multiple `(term, feature)` source-pairs in the rendered subgraph.
3312
+ */
3313
+ interface CoreferenceGroupDto {
3314
+ /**
3315
+ * Distinguishes Aït-Kaci's strict coreference (Reference-typed
3316
+ * feature pointing at the same Ψ-term across positions) from
3317
+ * looser shared-value clustering (multiple terms ground to the
3318
+ * same scalar/typed value). The strict variant satisfies the
3319
+ * OSF identity ↤ relation; the loose variant is a useful
3320
+ * dataviz signal but not strictly a variable in the OSF sense.
3321
+ */
3322
+ kind?: string;
3323
+ /** All `(term, feature_name)` pairs that hold this reference. */
3324
+ references: CoreferenceSourceDto[];
3325
+ /**
3326
+ * Visual tag (e.g. "X1", "X2") for this group — clients can label
3327
+ * both ends of an identity edge with this string to mirror
3328
+ * Aït-Kaci's `t1 ⊓ X = t2 ⊓ X` notation.
3329
+ */
3330
+ tag: string;
3331
+ /**
3332
+ * The shared target term id (the same Ψ-term every source points at).
3333
+ * @format uuid
3334
+ */
3335
+ target_term_id: string;
3336
+ }
3337
+ /** One `(term, feature)` pair contributing to a coreference group. */
3338
+ interface CoreferenceSourceDto {
3339
+ /** The feature name on that term whose value is the shared target. */
3340
+ feature_name: string;
3341
+ /**
3342
+ * The Ψ-term that owns the feature.
3343
+ * @format uuid
3344
+ */
3345
+ term_id: string;
3346
+ }
3158
3347
  /** Request to correct an entity before approval */
3159
3348
  interface CorrectEntityRequest$1 {
3160
3349
  /** Corrected features */
@@ -3503,6 +3692,13 @@ interface CreateSortRequest$1 {
3503
3692
  name?: string;
3504
3693
  /** Parent sort IDs */
3505
3694
  parents?: string[];
3695
+ /**
3696
+ * Existential witnesses — proof obligations a term must discharge to
3697
+ * belong to this sort. Each entry is a JSON `ExistentialWitness`
3698
+ * (variables, constraints, certainty). When witness validation
3699
+ * cannot conclude immediately the term is residuated.
3700
+ */
3701
+ witnesses?: object[];
3506
3702
  }
3507
3703
  /** Request to create a new computation space */
3508
3704
  interface CreateSpaceRequest$1 {
@@ -3528,6 +3724,16 @@ interface CreateStoreTermRequest$1 {
3528
3724
  interface CreateTermRequest$1 {
3529
3725
  /** Features map */
3530
3726
  features: Record<string, ValueDto$1>;
3727
+ /**
3728
+ * Optional client-supplied TermId. When present, the term is created
3729
+ * with that id; if a term with that id already exists in the tenant,
3730
+ * the handler returns 200 with the existing term instead of 409 —
3731
+ * re-runs of an idempotent seed script become safe.
3732
+ *
3733
+ * When absent, the server allocates a fresh UUID.
3734
+ * @format uuid
3735
+ */
3736
+ id?: string | null;
3531
3737
  /**
3532
3738
  * Owner ID
3533
3739
  * @format uuid
@@ -3941,6 +4147,59 @@ interface DereferenceResponse$1 {
3941
4147
  is_bound: boolean;
3942
4148
  original_id: string;
3943
4149
  }
4150
+ /**
4151
+ * Request for the forward-chain derivation visualization.
4152
+ *
4153
+ * Runs the homoiconic forward chainer with provenance enabled, then
4154
+ * emits a meta-hypergraph: one node per Ψ-term (input fact, rule, or
4155
+ * derived fact); one hyperedge per rule application grouping
4156
+ * (rule, antecedents..., produced_fact). Aggregate contributors are
4157
+ * included on the same hyperedge when present.
4158
+ */
4159
+ interface DerivationVisualizationRequest {
4160
+ /**
4161
+ * Restrict the rendered subgraph to the ancestors of these
4162
+ * terms (transitive provenance closure). When empty, the full
4163
+ * derivation lattice is returned.
4164
+ */
4165
+ focus_term_ids?: string[];
4166
+ /**
4167
+ * Whether to include aggregate-contributor edges on each step.
4168
+ * Defaults to true.
4169
+ */
4170
+ include_aggregates?: boolean;
4171
+ /**
4172
+ * Cap on chainer iterations. Defaults to 100.
4173
+ * @format int32
4174
+ * @min 0
4175
+ */
4176
+ max_iterations?: number;
4177
+ }
4178
+ /** Response for derivation-lattice visualization. */
4179
+ interface DerivationVisualizationResponse {
4180
+ /**
4181
+ * Number of derived (non-input) facts in the trace.
4182
+ * @min 0
4183
+ */
4184
+ derived_count: number;
4185
+ /**
4186
+ * Whether the chainer reached a fixpoint (true) or hit
4187
+ * max_iterations (false).
4188
+ */
4189
+ fixpoint_reached: boolean;
4190
+ /** The derivation graph (meta-hypergraph over Ψ-terms). */
4191
+ graph: VisualizationGraphDto$1;
4192
+ /**
4193
+ * Number of forward-chainer iterations the trace covers.
4194
+ * @min 0
4195
+ */
4196
+ iterations: number;
4197
+ /**
4198
+ * Number of distinct rule applications recorded.
4199
+ * @min 0
4200
+ */
4201
+ rule_application_count: number;
4202
+ }
3944
4203
  /** Request for derived inference (Phase 4). */
3945
4204
  interface DerivedInferenceRequest$1 {
3946
4205
  /** Pairs of feature vectors for inference. */
@@ -4780,6 +5039,25 @@ interface DriveDto$1 {
4780
5039
  /** Drive type (curiosity, competence, social, autonomy) */
4781
5040
  drive_type: string;
4782
5041
  }
5042
+ /** Loss weighting (paper eq. 4) — `data_weight + knowledge_weight = 1.0`. */
5043
+ interface DualWeightedLossDto {
5044
+ /**
5045
+ * Weight on the data-axiom satisfaction.
5046
+ * @format double
5047
+ */
5048
+ data_weight: number;
5049
+ /**
5050
+ * Weight on the knowledge-axiom satisfaction.
5051
+ * @format double
5052
+ */
5053
+ knowledge_weight: number;
5054
+ /**
5055
+ * `p` parameter for the `pMeanError` aggregator.
5056
+ * @format int32
5057
+ * @min 0
5058
+ */
5059
+ p_aggregator: number;
5060
+ }
4783
5061
  /** Request for dynamic sort addition (Phase 6). */
4784
5062
  interface DynamicAddSortRequest$1 {
4785
5063
  /** Feature names associated with this sort. */
@@ -5010,7 +5288,7 @@ interface E2ETrainingResponse$1 {
5010
5288
  triggered: boolean;
5011
5289
  }
5012
5290
  /** Edge type in the graph */
5013
- type EdgeTypeDto$1 = "subtype" | "multiple_inheritance" | "glb_path" | "lub_path" | "constraint_dependency" | "propagation" | "feature" | "coreference" | "trigger_dependency" | "relation_source" | "relation_target" | {
5291
+ type EdgeTypeDto$1 = "subtype" | "multiple_inheritance" | "glb_path" | "lub_path" | "constraint_dependency" | "propagation" | "feature" | "coreference" | "trigger_dependency" | "relation_source" | "relation_target" | "identity" | "derivation" | {
5014
5292
  custom: string;
5015
5293
  };
5016
5294
  /** FuzzyNumber shape for effect prediction response */
@@ -5331,6 +5609,24 @@ interface EpisodeStatsResponse$1 {
5331
5609
  */
5332
5610
  total_episodes: number;
5333
5611
  }
5612
+ /** Per-epoch training metrics. */
5613
+ interface EpochMetricsDto {
5614
+ /**
5615
+ * `pMeanError` over the data-axiom satisfactions (`K_D`).
5616
+ * @format double
5617
+ */
5618
+ data_satisfaction: number;
5619
+ /**
5620
+ * `pMeanError` over the knowledge-axiom satisfactions (`K_K`).
5621
+ * @format double
5622
+ */
5623
+ knowledge_satisfaction: number;
5624
+ /**
5625
+ * Dual-weighted loss `1 − ( w_D · K_D + w_K · K_K )`.
5626
+ * @format double
5627
+ */
5628
+ total_loss: number;
5629
+ }
5334
5630
  /** An equivalence class of sorts */
5335
5631
  interface EquivalenceClass {
5336
5632
  /**
@@ -6321,6 +6617,14 @@ interface FindBySortRequest$1 {
6321
6617
  * returned. Omit or pass an empty map to disable filtering.
6322
6618
  */
6323
6619
  filter?: object | null;
6620
+ /**
6621
+ * Optional cap on the number of returned terms. When set, the handler
6622
+ * truncates the post-filter result list to this many terms. Useful for
6623
+ * UI explain/combo paths that scan tens of evidence rows but never
6624
+ * need the full thousands. Omit (or 0) for no cap.
6625
+ * @min 0
6626
+ */
6627
+ limit?: number | null;
6324
6628
  /**
6325
6629
  * Sort ID to search for (takes precedence over sort_name)
6326
6630
  * @format uuid
@@ -6701,6 +7005,33 @@ type FunctionValueDto$1 = {
6701
7005
  } | {
6702
7006
  type: "Uninstantiated";
6703
7007
  };
7008
+ /**
7009
+ * Request: render the LIFE-function definitions in the tenant's
7010
+ * term store.
7011
+ */
7012
+ interface FunctionsVisualizationRequest {
7013
+ /**
7014
+ * Maximum number of functions to render.
7015
+ * @format int32
7016
+ * @min 0
7017
+ */
7018
+ limit?: number;
7019
+ /** Optional: restrict to functions matching this name prefix. */
7020
+ name_prefix?: string | null;
7021
+ }
7022
+ interface FunctionsVisualizationResponse {
7023
+ /**
7024
+ * Number of functions surfaced.
7025
+ * @min 0
7026
+ */
7027
+ function_count: number;
7028
+ /**
7029
+ * Function definitions as a Ψ-term hyperedge graph: each
7030
+ * function becomes a hyperedge whose corners are head + body
7031
+ * + each equation, color-distinguished by role.
7032
+ */
7033
+ graph: VisualizationGraphDto$1;
7034
+ }
6704
7035
  /** Request for fuzzy merge operation */
6705
7036
  interface FuzzyMergeRequest$1 {
6706
7037
  /**
@@ -7875,6 +8206,64 @@ interface GoalSummaryDto$1 {
7875
8206
  */
7876
8207
  min_degree?: number | null;
7877
8208
  }
8209
+ /**
8210
+ * Request: render the graded-poset structure of the tenant's sort
8211
+ * hierarchy. Each sort becomes a poset element; dimension = depth
8212
+ * from root (Top); coverings = parent→child relationships.
8213
+ *
8214
+ * Surfaces the boundary B(σ) and coboundary C(σ) sets per element
8215
+ * as `properties.boundary` / `properties.coboundary` strings, plus
8216
+ * emits 4-adjacency edges (lower / upper N↑/N↓) when requested.
8217
+ */
8218
+ interface GradedPosetRequest {
8219
+ /**
8220
+ * Include lower 4-adjacency edges (N↓): pairs (σ₁, σ₂) ∈ B(σ)
8221
+ * that share an element in B(σ₁) ∩ B(σ₂).
8222
+ */
8223
+ include_lower_adjacencies?: boolean;
8224
+ /** Include upper 4-adjacency edges (N↑). */
8225
+ include_upper_adjacencies?: boolean;
8226
+ /**
8227
+ * Maximum sort elements to return (0 = unlimited). Default 500.
8228
+ * 4-adjacency on a 20k-sort hierarchy emits ~300k edges, which
8229
+ * is too much for in-browser layout — paginate to keep the UI
8230
+ * responsive.
8231
+ * @min 0
8232
+ */
8233
+ limit?: number;
8234
+ /**
8235
+ * Skip this many sort elements (paired with `limit`).
8236
+ * @min 0
8237
+ */
8238
+ offset?: number;
8239
+ }
8240
+ interface GradedPosetResponse {
8241
+ /** @min 0 */
8242
+ covering_count: number;
8243
+ /** @min 0 */
8244
+ element_count: number;
8245
+ /**
8246
+ * Poset rendering. Elements at dimension `n` get
8247
+ * `level=n`. Coverings are subtype edges; 4-adjacency edges
8248
+ * carry `edge_type=Custom("LowerAdjacency"|"UpperAdjacency")`.
8249
+ */
8250
+ graph: VisualizationGraphDto$1;
8251
+ /** @min 0 */
8252
+ limit?: number;
8253
+ /**
8254
+ * Maximum dimension in the poset.
8255
+ * @min 0
8256
+ */
8257
+ max_dimension: number;
8258
+ /** @min 0 */
8259
+ offset?: number;
8260
+ /**
8261
+ * Pagination: total elements available before offset/limit
8262
+ * applied. Drives "load next page" controls.
8263
+ * @min 0
8264
+ */
8265
+ total_count?: number;
8266
+ }
7878
8267
  /** An edge connecting two nodes */
7879
8268
  interface GraphEdgeDto$1 {
7880
8269
  /** Color of the edge (hex string) */
@@ -7976,6 +8365,7 @@ interface GroundTruthEntry$1 {
7976
8365
  */
7977
8366
  term_id: string;
7978
8367
  }
8368
+ type GroundTruthStatus$1 = "Pending" | "Validated" | "Refuted" | "Unknown";
7979
8369
  /** Statistics for entity grounding (linking to external ontologies) */
7980
8370
  interface GroundingStatsDto$1 {
7981
8371
  /**
@@ -8094,7 +8484,7 @@ interface HyperedgeDto$1 {
8094
8484
  source_term_id?: string | null;
8095
8485
  }
8096
8486
  /** Hyperedge type */
8097
- type HyperedgeTypeDto$1 = "term_features" | "constraint_variables" | "unification_result" | {
8487
+ type HyperedgeTypeDto$1 = "term_features" | "constraint_variables" | "unification_result" | "coreference_group" | "derivation_step" | "aggregate" | "negation" | "entailment" | "bound_constraint" | "multiple_inheritance" | "refraction" | "fuzzy_belt" | "meta_rule" | "learned_rule" | {
8098
8488
  custom: string;
8099
8489
  };
8100
8490
  /** Request for OSF term hypergraph visualization */
@@ -8103,7 +8493,21 @@ interface HypergraphRequest$1 {
8103
8493
  generate_dot?: boolean;
8104
8494
  /** Whether to include hyperedges */
8105
8495
  include_hyperedges?: boolean;
8106
- /** Whether to include relation Psi-terms as intermediate hypergraph nodes */
8496
+ /**
8497
+ * When `true`, run the tagged forward chainer (probabilistic
8498
+ * semiring) on the visible subgraph and emit a per-term certainty
8499
+ * tag in the response's `provenance_tags`. Default false because
8500
+ * the chainer is O((n+m)·k) on rule count.
8501
+ */
8502
+ include_provenance?: boolean;
8503
+ /**
8504
+ * Whether to include relation Psi-terms as intermediate hypergraph nodes.
8505
+ * Defaults to `true` — relation Ψ-terms (terms with source + target +
8506
+ * relation_type) are a first-class part of the term graph, and omitting
8507
+ * them by default leaves cross-entity links invisible to clients that
8508
+ * don't know they have to ask. Pass `false` to skip the scan when only
8509
+ * the per-term feature decomposition is needed.
8510
+ */
8107
8511
  include_relations?: boolean;
8108
8512
  /**
8109
8513
  * Maximum depth to traverse
@@ -8126,10 +8530,31 @@ interface HypergraphRequest$1 {
8126
8530
  interface HypergraphResponse$1 {
8127
8531
  /** S-connected components (if s_threshold > 0) */
8128
8532
  components?: ComponentDto$1[];
8533
+ /**
8534
+ * Coreference groups: when multiple `(term, feature)` pairs point at
8535
+ * the same target Ψ-term via Reference values, those references
8536
+ * share an OSF-style tag (X). Aït-Kaci's Ψ-terms are graphs, not
8537
+ * trees — a renderer that draws each Reference as an independent
8538
+ * edge loses the identity. Each group is shipped with an auto-
8539
+ * generated visual tag so the client can label both endpoints.
8540
+ */
8541
+ coreferences?: CoreferenceGroupDto[];
8129
8542
  /** Degree distribution */
8130
8543
  degree_distribution: DegreeDistributionDto$1;
8131
8544
  /** The visualization graph */
8132
8545
  graph: VisualizationGraphDto$1;
8546
+ /**
8547
+ * Provenance / certainty tag per visible Ψ-term, in `[0.0, 1.0]`.
8548
+ *
8549
+ * Encoded by the OSFKB `ProvenanceSemiring` — see
8550
+ * `crates/domain/src/types/provenance_semiring.rs`. Values are
8551
+ * best-effort: an asserted (root) fact yields `1.0`; a forward-
8552
+ * chained fact yields the tagged-FC certainty if the request
8553
+ * asks for it (`include_provenance: true`); otherwise defaults
8554
+ * to `1.0`. Renderers are expected to map this to polygon fill
8555
+ * opacity so audit-ability is visually obvious.
8556
+ */
8557
+ provenance_tags?: Record<string, number>;
8133
8558
  /** Statistics */
8134
8559
  stats: HypergraphStats$1;
8135
8560
  }
@@ -8828,6 +9253,13 @@ interface IngestionStatsDto$1 {
8828
9253
  /** Token usage from LLM API calls during this ingestion */
8829
9254
  token_usage?: TokenUsageDto$1;
8830
9255
  }
9256
+ /** Inline Ψ-term feature payload for a single prediction. */
9257
+ interface InlineInferenceTermDto {
9258
+ /** Per-antecedent flat feature vectors. */
9259
+ antecedent_features: Record<string, number[]>;
9260
+ /** Temporal feature sequence for the conclusion gate. */
9261
+ temporal_features: TemporalSequenceDto;
9262
+ }
8831
9263
  /** Outcome of an integrated cognitive cycle. */
8832
9264
  interface IntegratedCycleOutcomeDto$1 {
8833
9265
  /** Actions executed */
@@ -9211,6 +9643,15 @@ type KbChangeDto$1 = {
9211
9643
  term2: string;
9212
9644
  type: "Coreference";
9213
9645
  };
9646
+ /** One labelled training Ψ-term. */
9647
+ interface LabelledTermDto {
9648
+ /** Per-antecedent flat feature vectors. */
9649
+ antecedent_features: Record<string, number[]>;
9650
+ /** Ground-truth label for the conclusion sort. */
9651
+ label: MortalityLabelDto;
9652
+ /** Temporal feature sequence for the conclusion gate. */
9653
+ temporal_features: TemporalSequenceDto;
9654
+ }
9214
9655
  /** Statistics about the lattice */
9215
9656
  interface LatticeStats$1 {
9216
9657
  /**
@@ -9244,6 +9685,89 @@ interface LatticeStats$1 {
9244
9685
  */
9245
9686
  total_sorts: number;
9246
9687
  }
9688
+ /**
9689
+ * Request for the viewport-tile lattice endpoint. Designed for
9690
+ * million-scale rendering: the server pre-computes a stable global
9691
+ * layout for the tenant once (per hierarchy snapshot), and clients
9692
+ * fetch only the nodes whose (x, y) fall inside their viewport.
9693
+ *
9694
+ * The layout is deterministic: y = BFS level × level_spacing,
9695
+ * x = hash(sort_id) % width within that level. Not paper-faithful,
9696
+ * but produces stable coordinates that don't require a real force
9697
+ * layout — usable on tenants where 1M nodes can't be laid out
9698
+ * online.
9699
+ */
9700
+ interface LatticeTileRequest {
9701
+ /**
9702
+ * When true, emit one synthetic Feature node per declared
9703
+ * feature on each sort, with an edge from the sort to the
9704
+ * feature. Lets clients render the "starburst" galaxy view
9705
+ * where each sort is a center surrounded by feature spokes.
9706
+ * Default false to preserve the millions-scale wire budget.
9707
+ */
9708
+ include_features?: boolean;
9709
+ /**
9710
+ * Max features per sort when `include_features` is true.
9711
+ * Bounds bandwidth on densely-typed tenants (some sorts
9712
+ * declare 80+ features). Default 32.
9713
+ * @min 0
9714
+ */
9715
+ max_features_per_sort?: number;
9716
+ /**
9717
+ * Hard cap on emitted nodes — when the viewport contains more
9718
+ * than this, the client should zoom in. Default 5000.
9719
+ * @min 0
9720
+ */
9721
+ max_nodes?: number;
9722
+ /** @format double */
9723
+ max_x: number;
9724
+ /** @format double */
9725
+ max_y: number;
9726
+ /**
9727
+ * Viewport bounds in lattice coordinate space. Nodes outside
9728
+ * these bounds are not emitted.
9729
+ * @format double
9730
+ */
9731
+ min_x: number;
9732
+ /** @format double */
9733
+ min_y: number;
9734
+ /**
9735
+ * Optional zoom level (0 = whole graph, increasing = closer).
9736
+ * At lower zooms we emit fewer edges (top-K by node degree)
9737
+ * to keep responses tractable. Default 1.0.
9738
+ * @format double
9739
+ */
9740
+ zoom?: number;
9741
+ }
9742
+ interface LatticeTileResponse {
9743
+ /** @min 0 */
9744
+ emitted_count: number;
9745
+ /**
9746
+ * Subgraph of the lattice within the viewport. Each node has
9747
+ * `position.x`, `position.y` set so the client can place it
9748
+ * directly without running a layout.
9749
+ */
9750
+ graph: VisualizationGraphDto$1;
9751
+ /** @format double */
9752
+ layout_max_x: number;
9753
+ /** @format double */
9754
+ layout_max_y: number;
9755
+ /**
9756
+ * Bounds of the full layout (so clients can compute "where am I?").
9757
+ * @format double
9758
+ */
9759
+ layout_min_x: number;
9760
+ /** @format double */
9761
+ layout_min_y: number;
9762
+ /** Was the response truncated by max_nodes? */
9763
+ truncated: boolean;
9764
+ /**
9765
+ * Total nodes that fell in the viewport before max_nodes
9766
+ * truncation — drives "zoom in to see all" affordance.
9767
+ * @min 0
9768
+ */
9769
+ viewport_count: number;
9770
+ }
9247
9771
  /** Request for lattice (sort hierarchy) visualization */
9248
9772
  interface LatticeVisualizationRequest$1 {
9249
9773
  /** Whether to generate DOT output */
@@ -9254,12 +9778,24 @@ interface LatticeVisualizationRequest$1 {
9254
9778
  layout_algorithm?: LayoutAlgorithmDto$1;
9255
9779
  /** Layout direction preference */
9256
9780
  layout_direction?: LayoutDirectionDto$1;
9781
+ /**
9782
+ * Maximum sort elements to return (0 = unlimited). Default 500
9783
+ * keeps heavy-hierarchy responses (20k+ sorts) tractable.
9784
+ * Paginate by stepping `offset` if the full set is needed.
9785
+ * @min 0
9786
+ */
9787
+ limit?: number;
9257
9788
  /**
9258
9789
  * Maximum depth to traverse (default: unlimited)
9259
9790
  * @format int32
9260
9791
  * @min 0
9261
9792
  */
9262
9793
  max_depth?: number | null;
9794
+ /**
9795
+ * Skip this many sort elements (paired with `limit`).
9796
+ * @min 0
9797
+ */
9798
+ offset?: number;
9263
9799
  /**
9264
9800
  * Optional root sort ID to start from
9265
9801
  * @format uuid
@@ -9270,8 +9806,24 @@ interface LatticeVisualizationRequest$1 {
9270
9806
  interface LatticeVisualizationResponse$1 {
9271
9807
  /** The visualization graph */
9272
9808
  graph: VisualizationGraphDto$1;
9809
+ /**
9810
+ * Pagination: limit used (0 = unlimited).
9811
+ * @min 0
9812
+ */
9813
+ limit?: number;
9814
+ /**
9815
+ * Pagination: offset used in this response.
9816
+ * @min 0
9817
+ */
9818
+ offset?: number;
9273
9819
  /** Statistics about the lattice */
9274
9820
  stats: LatticeStats$1;
9821
+ /**
9822
+ * Pagination: total sorts available before offset/limit applied.
9823
+ * Clients can use this to drive a "load next page" UI.
9824
+ * @min 0
9825
+ */
9826
+ total_count?: number;
9275
9827
  }
9276
9828
  /** Per-layer verification result. */
9277
9829
  interface LayerResultDto$1 {
@@ -10758,6 +11310,8 @@ interface MonadicFixpointResponse$1 {
10758
11310
  */
10759
11311
  max_depth: number;
10760
11312
  }
11313
+ /** Conclusion-side ground-truth label. */
11314
+ type MortalityLabelDto = "positive" | "negative";
10761
11315
  /** Full motivation state DTO combining drives, deficits, and curiosity. */
10762
11316
  interface MotivationStateDto$1 {
10763
11317
  /** Curiosity targets sorted by exploration priority */
@@ -10964,7 +11518,7 @@ interface NlQueryResultItem$1 {
10964
11518
  sort_name: string;
10965
11519
  }
10966
11520
  /** Node type in the graph */
10967
- type NodeTypeDto$1 = "sort" | "synthetic_sort" | "root_sort" | "bottom_sort" | "constraint" | "fd_variable" | "term" | "feature" | "reference" | "residuated_term" | "trigger" | "relation" | {
11521
+ type NodeTypeDto$1 = "sort" | "synthetic_sort" | "root_sort" | "bottom_sort" | "constraint" | "fd_variable" | "term" | "feature" | "reference" | "residuated_term" | "trigger" | "relation" | "rule" | {
10968
11522
  custom: string;
10969
11523
  };
10970
11524
  /** Number format options */
@@ -11155,6 +11709,85 @@ interface OntologyRagStatsDto$1 {
11155
11709
  /** @min 0 */
11156
11710
  terms_unified: number;
11157
11711
  }
11712
+ /**
11713
+ * Top-level orchestrator configuration DTO.
11714
+ *
11715
+ * Mirrors
11716
+ * [`OrchestratorConfig`](osfkb_application::services::osf_neural_predicate_orchestrator::OrchestratorConfig)
11717
+ * with API-friendly enum encodings.
11718
+ */
11719
+ interface OrchestratorConfigDto {
11720
+ /** Antecedent-sort gate bindings. */
11721
+ antecedent_bindings: SortGateBindingDto[];
11722
+ /** Conclusion-sort gate binding (typically `Temporal`). */
11723
+ conclusion_binding: SortGateBindingDto;
11724
+ /** Knowledge-axiom rule ids registered in the tenant's homoiconic KB. */
11725
+ knowledge_axioms: string[];
11726
+ /** Loss weighting and `pMean` aggregator hyperparameters. */
11727
+ loss: DualWeightedLossDto;
11728
+ /** Training-loop hyperparameters. */
11729
+ training: TrainingHyperparametersDto;
11730
+ }
11731
+ /** Request body for `POST /api/v1/inference/orchestrator/configure`. */
11732
+ interface OrchestratorConfigureRequest {
11733
+ /** The orchestrator configuration to register for the calling tenant. */
11734
+ config: OrchestratorConfigDto;
11735
+ }
11736
+ /** Response for the configure endpoint. */
11737
+ interface OrchestratorConfigureResponse {
11738
+ /**
11739
+ * UUID for retrieving and using this config in subsequent train/predict
11740
+ * calls.
11741
+ * @format uuid
11742
+ */
11743
+ config_id: string;
11744
+ }
11745
+ /** Request body for `POST /api/v1/inference/orchestrator/predict`. */
11746
+ type OrchestratorPredictRequest = PredictTermDto & {
11747
+ /**
11748
+ * Identifier returned by the configure endpoint.
11749
+ * @format uuid
11750
+ */
11751
+ config_id: string;
11752
+ };
11753
+ /** Response for the predict endpoint. */
11754
+ interface OrchestratorPredictResponse {
11755
+ /** Per-axiom firing trace. */
11756
+ axiom_trace: AxiomFiringDto[];
11757
+ /**
11758
+ * Conclusion-sort truth value τ(x ⊑ conclusion_sort).
11759
+ * @format double
11760
+ */
11761
+ conclusion_probability: number;
11762
+ /**
11763
+ * Final fused confidence via noisy-OR over fired knowledge axioms.
11764
+ * @format double
11765
+ */
11766
+ fused_confidence: number;
11767
+ }
11768
+ /** Request body for `POST /api/v1/inference/orchestrator/train`. */
11769
+ interface OrchestratorTrainRequest {
11770
+ /**
11771
+ * Identifier returned by the configure endpoint.
11772
+ * @format uuid
11773
+ */
11774
+ config_id: string;
11775
+ /**
11776
+ * One or more labelled training Ψ-terms to consume in this call. Each
11777
+ * call performs a single training epoch.
11778
+ */
11779
+ labelled_terms: LabelledTermDto[];
11780
+ }
11781
+ /** Response for the train endpoint. */
11782
+ interface OrchestratorTrainResponse {
11783
+ /**
11784
+ * Whether training stopped early (always `false` when only one epoch is
11785
+ * run per call; reserved for future multi-epoch extensions).
11786
+ */
11787
+ early_stopped: boolean;
11788
+ /** One entry per training epoch executed in this call. */
11789
+ epochs: EpochMetricsDto[];
11790
+ }
11158
11791
  /**
11159
11792
  * Request for pure OSF search
11160
11793
  *
@@ -11806,6 +12439,37 @@ interface PredictPreferencesRequest$1 {
11806
12439
  interface PredictPreferencesResponse$1 {
11807
12440
  predictions: PreferencePrediction$1[];
11808
12441
  }
12442
+ /**
12443
+ * Inference Ψ-term — either inline features or a reference to a persisted
12444
+ * term id (reserved for future use; currently inline-only).
12445
+ */
12446
+ type PredictTermDto = InlineInferenceTermDto;
12447
+ interface PredictionEntry$1 {
12448
+ /**
12449
+ * Verdict at capture time. Always `Pending` for newly captured
12450
+ * snapshots.
12451
+ */
12452
+ captured_status: GroundTruthStatus$1;
12453
+ id: PredictionEntryId;
12454
+ request_hash: string;
12455
+ /**
12456
+ * Domain-shaped opaque payload (e.g. `{"drug": "...", "disease": "...", "score": 0.87}`).
12457
+ * The engine does NOT interpret this — only the consumer's
12458
+ * `GroundTruthProviderPort` does.
12459
+ */
12460
+ response_summary: object;
12461
+ /** Back-pointer into the audit ledger this prediction was captured from. */
12462
+ source_record_id: AuditRecordId;
12463
+ /** @format date-time */
12464
+ validated_at?: string | null;
12465
+ /**
12466
+ * Verdict after the most recent `validate()` call. `None` until
12467
+ * validation has run.
12468
+ */
12469
+ validated_status?: null | GroundTruthStatus$1;
12470
+ }
12471
+ /** @format uuid */
12472
+ type PredictionEntryId = string;
11809
12473
  /** Prediction error DTO. */
11810
12474
  interface PredictionErrorDto$1 {
11811
12475
  /** Actual outcome */
@@ -11825,6 +12489,16 @@ interface PredictionErrorDto$1 {
11825
12489
  /** Predicted outcome */
11826
12490
  predicted: string;
11827
12491
  }
12492
+ interface PredictionSnapshot$1 {
12493
+ /** @format date-time */
12494
+ captured_at: string;
12495
+ entries: PredictionEntry$1[];
12496
+ filter: SnapshotFilter$1;
12497
+ id: PredictionSnapshotId;
12498
+ tenant_id: TenantId;
12499
+ }
12500
+ /** @format uuid */
12501
+ type PredictionSnapshotId = string;
11828
12502
  /** A user preference. */
11829
12503
  interface PreferenceDto$1 {
11830
12504
  /**
@@ -13584,6 +14258,25 @@ interface RowUnifyResponse$1 {
13584
14258
  /** Unified row type (if successful) */
13585
14259
  unified?: null | RowTypeDto$1;
13586
14260
  }
14261
+ /**
14262
+ * Rule aggregator descriptor for engine-side aggregation on rule heads.
14263
+ *
14264
+ * When present, the engine aggregates multiple proofs of the same rule
14265
+ * that share the same `group_by` feature values, applying `op` to the
14266
+ * `target` feature. This eliminates run-to-run variance from proof-order
14267
+ * sensitivity and makes `max_solutions` cap unique groups, not raw proofs.
14268
+ */
14269
+ interface RuleAggregatorDto {
14270
+ /**
14271
+ * Feature names that define the aggregation group key.
14272
+ * Proofs with identical values for all `group_by` features are merged.
14273
+ */
14274
+ group_by: string[];
14275
+ /** Aggregation operator: "sum", "max", "min", "count", or "first". */
14276
+ op: string;
14277
+ /** Feature name whose value is aggregated within each group. */
14278
+ target: string;
14279
+ }
13587
14280
  /** A rule clause (OSF clause) */
13588
14281
  interface RuleClauseDto$1 {
13589
14282
  /** Constraints on variables in this clause */
@@ -14214,6 +14907,21 @@ interface SingleCopyRequest$1 {
14214
14907
  copy_mode: CopyModeDto$1;
14215
14908
  term_id: string;
14216
14909
  }
14910
+ interface SnapshotFilter$1 {
14911
+ /** @format date-time */
14912
+ captured_after?: string | null;
14913
+ /**
14914
+ * @format int32
14915
+ * @min 0
14916
+ */
14917
+ max_entries?: number | null;
14918
+ /**
14919
+ * Glob-style pattern matched against `AuditRecord::request_path`.
14920
+ * Required — without it the snapshot would capture the entire
14921
+ * ledger, which is rarely useful.
14922
+ */
14923
+ request_path_pattern: string;
14924
+ }
14217
14925
  /** Request for soft unification (Phase 2). */
14218
14926
  interface SoftUnifyRequest$1 {
14219
14927
  /**
@@ -14507,6 +15215,21 @@ interface SortDto$1 {
14507
15215
  */
14508
15216
  tenant_id: string;
14509
15217
  }
15218
+ /** Binding between a sort and the gate that scores its subsumption. */
15219
+ interface SortGateBindingDto {
15220
+ /**
15221
+ * Architecture flavour (selects which port the orchestrator dispatches
15222
+ * to).
15223
+ */
15224
+ architecture: SubsumptionArchitectureDto;
15225
+ /**
15226
+ * Sort whose subsumption truth the gate scores.
15227
+ * @format uuid
15228
+ */
15229
+ sort_id: string;
15230
+ /** Optional weak anchor (only meaningful for `ResiduationMlp`). */
15231
+ weak_anchor?: null | ThresholdAnchorDto;
15232
+ }
14510
15233
  /** Basic sort information */
14511
15234
  interface SortInfoDto$1 {
14512
15235
  id: string;
@@ -14537,6 +15260,71 @@ interface SortListResponse$1 {
14537
15260
  */
14538
15261
  total?: number;
14539
15262
  }
15263
+ /**
15264
+ * Request for the focus-based "neighborhood" view of the sort
15265
+ * hierarchy. Designed to scale to tenants with millions of sorts —
15266
+ * instead of trying to display the entire lattice, the client picks
15267
+ * a focus sort and asks for its N-hop neighborhood, capped at
15268
+ * `max_nodes` so the wire payload and renderer load are bounded.
15269
+ *
15270
+ * Edges to nodes outside the returned set are kept (so accumulating
15271
+ * successive neighborhoods stitches the global graph) but with the
15272
+ * off-set endpoint represented by its UUID-derived id.
15273
+ */
15274
+ interface SortNeighborhoodRequest {
15275
+ /**
15276
+ * Maximum hop distance (BFS depth). Default 2.
15277
+ * @format int32
15278
+ * @min 0
15279
+ */
15280
+ hops?: number;
15281
+ /**
15282
+ * Whether to include both ancestors (parents) AND descendants
15283
+ * (children). Default true.
15284
+ */
15285
+ include_ancestors?: boolean;
15286
+ include_descendants?: boolean;
15287
+ /**
15288
+ * When true, also emit 4-adjacency siblings of the focus
15289
+ * (sorts sharing a common parent or child). Default false.
15290
+ */
15291
+ include_siblings?: boolean;
15292
+ /**
15293
+ * Hard cap on returned nodes. When BFS exceeds this, the
15294
+ * expansion stops and the closest `max_nodes` are emitted.
15295
+ * Default 5000 — keeps the client renderer responsive.
15296
+ * @min 0
15297
+ */
15298
+ max_nodes?: number;
15299
+ /**
15300
+ * Focus sort. The neighborhood is centred here.
15301
+ * @format uuid
15302
+ */
15303
+ sort_id: string;
15304
+ }
15305
+ interface SortNeighborhoodResponse {
15306
+ /**
15307
+ * Number of nodes actually returned.
15308
+ * @min 0
15309
+ */
15310
+ emitted_count: number;
15311
+ /**
15312
+ * Subgraph centred on the focus sort. The focus node has
15313
+ * `properties.role = "focus"`; ancestors carry `role = "ancestor"`,
15314
+ * descendants `role = "descendant"`, siblings `role = "sibling"`.
15315
+ * `level` on each node is the signed hop distance from focus
15316
+ * (positive = descendant, negative = ancestor).
15317
+ */
15318
+ graph: VisualizationGraphDto$1;
15319
+ /**
15320
+ * Total number of sorts within `hops` of focus before
15321
+ * truncation — clients can use this to surface "showing N of M".
15322
+ * @min 0
15323
+ */
15324
+ reachable_count: number;
15325
+ /** Was the BFS truncated by `max_nodes`? */
15326
+ truncated: boolean;
15327
+ }
14540
15328
  /** API representation of sort origin/provenance */
14541
15329
  type SortOriginDto$1 = {
14542
15330
  /** @format uuid */
@@ -15240,6 +16028,53 @@ interface SubstringRequest$1 {
15240
16028
  interface SubstringResponse {
15241
16029
  result: string;
15242
16030
  }
16031
+ /**
16032
+ * Architecture choice for a single sort-subsumption gate.
16033
+ *
16034
+ * Tagged on a `kind` discriminator to keep the OpenAPI schema flat.
16035
+ */
16036
+ type SubsumptionArchitectureDto = {
16037
+ /**
16038
+ * Hidden layer width.
16039
+ * @min 0
16040
+ */
16041
+ hidden_dim: number;
16042
+ /**
16043
+ * Input feature dimension.
16044
+ * @min 0
16045
+ */
16046
+ input_dim: number;
16047
+ kind: "residuation_mlp";
16048
+ } | {
16049
+ /**
16050
+ * Hidden state width per LSTM direction.
16051
+ * @min 0
16052
+ */
16053
+ hidden_dim: number;
16054
+ /**
16055
+ * Per-timestep feature dimension.
16056
+ * @min 0
16057
+ */
16058
+ input_dim: number;
16059
+ kind: "temporal";
16060
+ /**
16061
+ * Number of stacked BiLSTM layers.
16062
+ * @min 0
16063
+ */
16064
+ n_lstm_layers: number;
16065
+ };
16066
+ interface SummaryResponse$1 {
16067
+ /**
16068
+ * @format int64
16069
+ * @min 0
16070
+ */
16071
+ n_records: number;
16072
+ per_actor: Record<string, number>;
16073
+ per_request_path: Record<string, number>;
16074
+ tenant_id: string;
16075
+ ts_first?: string | null;
16076
+ ts_last?: string | null;
16077
+ }
15243
16078
  /** Information about a suspended (incomplete) query */
15244
16079
  interface SuspendedQueryDto$1 {
15245
16080
  /**
@@ -15539,6 +16374,23 @@ interface TemporalPlanResponse$1 {
15539
16374
  /** Selected term IDs in temporal order */
15540
16375
  selected_term_ids: string[];
15541
16376
  }
16377
+ /** Variable-length temporal feature sequence in row-major form. */
16378
+ interface TemporalSequenceDto {
16379
+ /** Row-major buffer of length `seq_len * input_dim`. */
16380
+ data: number[];
16381
+ /**
16382
+ * Per-timestep feature dimension.
16383
+ * @min 0
16384
+ */
16385
+ input_dim: number;
16386
+ /**
16387
+ * Number of timesteps.
16388
+ * @min 0
16389
+ */
16390
+ seq_len: number;
16391
+ }
16392
+ /** @format uuid */
16393
+ type TenantId = string;
15542
16394
  /** Information about a single tenant in the system. */
15543
16395
  interface TenantInfo {
15544
16396
  /**
@@ -15617,6 +16469,23 @@ type TermInputDto$1 = {
15617
16469
  features?: Record<string, FeatureInputValueDto$1>;
15618
16470
  sort_name: string;
15619
16471
  };
16472
+ /**
16473
+ * Request for paginated raw term listing. Parallel to the lattice
16474
+ * pagination endpoint but for Ψ-terms — gives clients a default-fast
16475
+ * "show me terms" view that bypasses the in-memory term store.
16476
+ */
16477
+ interface TermListRequest {
16478
+ /**
16479
+ * Page size. Default 500.
16480
+ * @min 0
16481
+ */
16482
+ limit?: number;
16483
+ /**
16484
+ * Page offset.
16485
+ * @min 0
16486
+ */
16487
+ offset?: number;
16488
+ }
15620
16489
  /** Response for term list operations */
15621
16490
  interface TermListResponse$1 {
15622
16491
  /**
@@ -15649,7 +16518,7 @@ interface TermResponse$1 {
15649
16518
  witness_proofs?: WitnessProofDto$1[];
15650
16519
  }
15651
16520
  /** Term completion state (Hassan's LIFE semantics) */
15652
- type TermState$1 = "complete" | "residuated" | "no_witnesses";
16521
+ type TermState$1 = "complete" | "residuated" | "failed" | "no_witnesses";
15653
16522
  /** Response with term store session info */
15654
16523
  interface TermStoreSessionResponse$1 {
15655
16524
  session_id: string;
@@ -15665,6 +16534,29 @@ interface TermTranslationDto {
15665
16534
  copied_id: string;
15666
16535
  original_id: string;
15667
16536
  }
16537
+ /** Threshold-based weak anchor for an antecedent gate. */
16538
+ interface ThresholdAnchorDto {
16539
+ /**
16540
+ * Index into the gate's input feature vector that the threshold reads.
16541
+ * @min 0
16542
+ */
16543
+ feature_index: number;
16544
+ /**
16545
+ * Synthetic samples drawn for pre-anchoring.
16546
+ * @min 0
16547
+ */
16548
+ samples: number;
16549
+ /**
16550
+ * Pre-anchoring training steps.
16551
+ * @min 0
16552
+ */
16553
+ steps: number;
16554
+ /**
16555
+ * Threshold value; samples ≥ threshold are anchor-labelled `true`.
16556
+ * @format double
16557
+ */
16558
+ threshold: number;
16559
+ }
15668
16560
  /** Token usage from LLM API calls during ingestion */
15669
16561
  interface TokenUsageDto$1 {
15670
16562
  /**
@@ -15792,6 +16684,35 @@ interface TrainingExampleDto$1 {
15792
16684
  /** Data source (real, synthetic, negative). */
15793
16685
  source: string;
15794
16686
  }
16687
+ /** Training-loop hyperparameters. */
16688
+ interface TrainingHyperparametersDto {
16689
+ /**
16690
+ * Mini-batch size.
16691
+ * @min 0
16692
+ */
16693
+ batch_size: number;
16694
+ /**
16695
+ * Early-stopping patience.
16696
+ * @min 0
16697
+ */
16698
+ early_stopping_patience: number;
16699
+ /**
16700
+ * Total training epochs.
16701
+ * @min 0
16702
+ */
16703
+ epochs: number;
16704
+ /**
16705
+ * AdamW learning rate.
16706
+ * @format double
16707
+ */
16708
+ learning_rate: number;
16709
+ /**
16710
+ * PRNG seed for deterministic batch construction.
16711
+ * @format int64
16712
+ * @min 0
16713
+ */
16714
+ seed?: number;
16715
+ }
15795
16716
  /** Response for training trigger endpoints. */
15796
16717
  interface TrainingTriggerResponse$1 {
15797
16718
  /** Error message if training failed to trigger. */
@@ -16328,6 +17249,8 @@ interface UpdateVisibilityRequest$1 {
16328
17249
  /** New visibility level */
16329
17250
  visibility: VisibilityDto$1;
16330
17251
  }
17252
+ /** @format uuid */
17253
+ type UserId = string;
16331
17254
  /**
16332
17255
  * Request for witness-validated term creation
16333
17256
  *
@@ -16413,6 +17336,37 @@ interface ValidatedUnifyResponse$1 {
16413
17336
  /** Witnesses satisfied during unification */
16414
17337
  witnesses_satisfied: WitnessInstantiationDto$1[];
16415
17338
  }
17339
+ interface ValidationReportDto$1 {
17340
+ completed_at: string;
17341
+ /**
17342
+ * @format int64
17343
+ * @min 0
17344
+ */
17345
+ n_pending: number;
17346
+ /**
17347
+ * @format int64
17348
+ * @min 0
17349
+ */
17350
+ n_refuted: number;
17351
+ /**
17352
+ * @format int64
17353
+ * @min 0
17354
+ */
17355
+ n_total: number;
17356
+ /**
17357
+ * @format int64
17358
+ * @min 0
17359
+ */
17360
+ n_unknown: number;
17361
+ /**
17362
+ * @format int64
17363
+ * @min 0
17364
+ */
17365
+ n_validated: number;
17366
+ snapshot_id: string;
17367
+ /** @format double */
17368
+ validation_rate?: number | null;
17369
+ }
16416
17370
  /** DTO for validation rules (client-side validation from FeatureDescriptor constraints) */
16417
17371
  interface ValidationRuleDto$1 {
16418
17372
  /** Feature/field name this rule applies to */
@@ -16677,6 +17631,12 @@ interface VerifyFaithfulnessResponse$1 {
16677
17631
  */
16678
17632
  score: number;
16679
17633
  }
17634
+ interface VerifyResponse$1 {
17635
+ /** @min 0 */
17636
+ n_violations: number;
17637
+ ok: boolean;
17638
+ violations: any[];
17639
+ }
16680
17640
  /**
16681
17641
  * Request for OSF-aware round-trip faithfulness verification.
16682
17642
  *
@@ -18705,7 +19665,7 @@ declare class Terms<SecurityDataType = unknown> {
18705
19665
  * - `"residuated"` — some witnesses are suspended (missing information)
18706
19666
  * - `"no_witnesses"` — the sort has no witness requirements
18707
19667
  */
18708
- type TermState = 'complete' | 'residuated' | 'no_witnesses';
19668
+ type TermState = 'complete' | 'residuated' | 'failed' | 'no_witnesses';
18709
19669
  /**
18710
19670
  * Proof that a term satisfies a type witness.
18711
19671
  *
@@ -19741,6 +20701,16 @@ declare class Inference<SecurityDataType = unknown> {
19741
20701
  * @secure
19742
20702
  */
19743
20703
  clearFacts: (tenantId: string, params?: RequestParams) => Promise<HttpResponse<ClearFactsResponse$1, any>>;
20704
+ /**
20705
+ * @description In OSF/LIFE terms, an orchestrator wires neural sort-subsumption gates (`τ(x ⊑ S) ∈ [0, 1]`) for a conclusion sort and a set of antecedent sorts. Knowledge axioms reference homoiconic rule Ψ-terms registered in the tenant's KB. The first call lazily instantiates the underlying Candle-backed gates; subsequent calls within the same tenant share gate state. # Authorization Requires `X-Tenant-Id` header.
20706
+ *
20707
+ * @tags inference
20708
+ * @name ConfigureOrchestrator
20709
+ * @summary Register an OSF Neural-Predicate Orchestrator configuration for the calling tenant.
20710
+ * @request POST:/api/v1/inference/orchestrator/configure
20711
+ * @secure
20712
+ */
20713
+ configureOrchestrator: (data: OrchestratorConfigureRequest, params?: RequestParams) => Promise<HttpResponse<OrchestratorConfigureResponse, void>>;
19744
20714
  /**
19745
20715
  * @description # TRUE HOMOICONICITY Goals are first-class Ψ-terms that can be created, persisted, and reused. This endpoint creates a goal from clauses and optional constraints, persists it to PostgreSQL, and returns the goal ID for later use. # Authorization Requires X-Tenant-Id header.
19746
20716
  *
@@ -19844,6 +20814,26 @@ declare class Inference<SecurityDataType = unknown> {
19844
20814
  * @secure
19845
20815
  */
19846
20816
  nafProve: (data: NafProveRequest$1, params?: RequestParams) => Promise<HttpResponse<BackwardChainResponse$1, any>>;
20817
+ /**
20818
+ * @description In OSF/LIFE terms, the orchestrator forwards the Ψ-term through the conclusion gate to read `τ(x ⊑ conclusion_sort)`, then for each knowledge axiom evaluates its antecedent gates and combines them with the conclusion truth via Reichenbach (`1 − a + a · c`). The fused confidence aggregates per-axiom modus-ponens witness strength via noisy-OR. # Authorization Requires `X-Tenant-Id` header.
20819
+ *
20820
+ * @tags inference
20821
+ * @name PredictWithOrchestrator
20822
+ * @summary Score a single Ψ-term: conclusion subsumption probability + per-axiom firing trace + noisy-OR fused confidence.
20823
+ * @request POST:/api/v1/inference/orchestrator/predict
20824
+ * @secure
20825
+ */
20826
+ predictWithOrchestrator: (data: OrchestratorPredictRequest, params?: RequestParams) => Promise<HttpResponse<OrchestratorPredictResponse, void>>;
20827
+ /**
20828
+ * @description In OSF/LIFE terms, the orchestrator pushes the conclusion gate and each antecedent gate toward the dual-weighted satisfaction objective `1 − ( w_D · K_D + w_K · K_K )` (paper eq. 4). Each call performs exactly one epoch over the supplied batch — the response carries the per-epoch metrics for that single epoch (multi-epoch aggregation is the caller's responsibility). # Authorization Requires `X-Tenant-Id` header.
20829
+ *
20830
+ * @tags inference
20831
+ * @name TrainOrchestrator
20832
+ * @summary Run one training epoch over a labelled Ψ-term batch.
20833
+ * @request POST:/api/v1/inference/orchestrator/train
20834
+ * @secure
20835
+ */
20836
+ trainOrchestrator: (data: OrchestratorTrainRequest, params?: RequestParams) => Promise<HttpResponse<OrchestratorTrainResponse, void>>;
19847
20837
  }
19848
20838
 
19849
20839
  /**
@@ -19990,6 +20980,16 @@ interface BackwardChainRequest {
19990
20980
  timeoutMs?: number | null;
19991
20981
  /** Additional constraints (deprecated — prefer ConstrainedVariable in goal). */
19992
20982
  constraints?: ConstraintInputDto[];
20983
+ /**
20984
+ * When true, the response's `referencedTerms` field is populated with the
20985
+ * full {@link TermDto} for every term transitively referenced by any
20986
+ * solution's bindings. Lets the caller read complex bound values
20987
+ * (lists of nested Ψ-terms etc.) in one request instead of chasing
20988
+ * references via {@link TermsResource.get}.
20989
+ *
20990
+ * @defaultValue `false`
20991
+ */
20992
+ expandBindings?: boolean;
19993
20993
  }
19994
20994
  /** Response from backward chaining inference. */
19995
20995
  interface BackwardChainResponse {
@@ -19999,6 +20999,13 @@ interface BackwardChainResponse {
19999
20999
  queryTimeMs: number;
20000
21000
  /** Goal ID if the goal was saved (when save_goal=true). */
20001
21001
  goalId?: string | null;
21002
+ /**
21003
+ * Populated when the request had `expandBindings: true`. Maps UUID →
21004
+ * {@link TermDto} for every term transitively referenced by the solutions'
21005
+ * bindings. Capped at the backend's MAX_EXPAND_TERMS to prevent runaway
21006
+ * responses.
21007
+ */
21008
+ referencedTerms?: Record<string, TermDto>;
20002
21009
  }
20003
21010
  /**
20004
21011
  * Request for forward chaining inference.
@@ -20719,6 +21726,12 @@ declare class InferenceClient {
20719
21726
  *
20720
21727
  * The `timeout_ms` field on the request is a wall-clock timeout for the search.
20721
21728
  * When it fires, the backend returns whatever solutions have been found so far.
21729
+ *
21730
+ * Pass `expandBindings: true` to receive the full {@link TermDto} of every
21731
+ * Ψ-term transitively referenced by a solution's bindings in the
21732
+ * `referencedTerms` sidecar map of the response. Lets the caller read complex
21733
+ * bound values (lists of nested Ψ-terms etc.) without follow-up
21734
+ * `terms.get(uuid)` calls.
20722
21735
  */
20723
21736
  backwardChain(request: Omit<BackwardChainRequest, 'goal'> & {
20724
21737
  goal?: TermInputArg | null;
@@ -23723,7 +24736,7 @@ type ResiduationStateFilter = 'pending' | 'suspended' | 'ready' | 'completed' |
23723
24736
  * @remarks
23724
24737
  * Can be a predefined node type or a custom type name.
23725
24738
  */
23726
- type NodeTypeDto = 'sort' | 'synthetic_sort' | 'root_sort' | 'bottom_sort' | 'constraint' | 'fd_variable' | 'term' | 'feature' | 'reference' | 'residuated_term' | 'trigger' | 'relation' | {
24739
+ type NodeTypeDto = 'sort' | 'synthetic_sort' | 'root_sort' | 'bottom_sort' | 'constraint' | 'fd_variable' | 'term' | 'feature' | 'reference' | 'residuated_term' | 'trigger' | 'relation' | 'rule' | {
23727
24740
  custom: string;
23728
24741
  };
23729
24742
  /**
@@ -23732,7 +24745,7 @@ type NodeTypeDto = 'sort' | 'synthetic_sort' | 'root_sort' | 'bottom_sort' | 'co
23732
24745
  * @remarks
23733
24746
  * Can be a predefined edge type or a custom type name.
23734
24747
  */
23735
- type EdgeTypeDto = 'subtype' | 'multiple_inheritance' | 'glb_path' | 'lub_path' | 'constraint_dependency' | 'propagation' | 'feature' | 'coreference' | 'trigger_dependency' | 'relation_source' | 'relation_target' | {
24748
+ type EdgeTypeDto = 'subtype' | 'multiple_inheritance' | 'glb_path' | 'lub_path' | 'constraint_dependency' | 'propagation' | 'feature' | 'coreference' | 'trigger_dependency' | 'relation_source' | 'relation_target' | 'identity' | 'derivation' | {
23736
24749
  custom: string;
23737
24750
  };
23738
24751
  /**
@@ -23741,7 +24754,7 @@ type EdgeTypeDto = 'subtype' | 'multiple_inheritance' | 'glb_path' | 'lub_path'
23741
24754
  * @remarks
23742
24755
  * Can be a predefined hyperedge type or a custom type name.
23743
24756
  */
23744
- type HyperedgeTypeDto = 'term_features' | 'constraint_variables' | 'unification_result' | {
24757
+ type HyperedgeTypeDto = 'term_features' | 'constraint_variables' | 'unification_result' | 'coreference_group' | 'derivation_step' | 'aggregate' | 'negation' | 'entailment' | 'bound_constraint' | 'multiple_inheritance' | 'refraction' | 'fuzzy_belt' | 'meta_rule' | 'learned_rule' | {
23745
24758
  custom: string;
23746
24759
  };
23747
24760
  /**
@@ -28684,6 +29697,16 @@ declare class ReviewsClient {
28684
29697
  declare class Visualization<SecurityDataType = unknown> {
28685
29698
  http: HttpClient<SecurityDataType>;
28686
29699
  constructor(http: HttpClient<SecurityDataType>);
29700
+ /**
29701
+ * @description Note: when MVCC branching isn't materialized as named branches in the user's store, this endpoint surfaces an empty diff. The shape is preserved so clients can rely on it without conditional code.
29702
+ *
29703
+ * @tags visualization
29704
+ * @name GetBranchDiffVisualization
29705
+ * @summary Render the diff between two MVCC branches of the tenant's term store. Each visible Ψ-term carries `properties.diff` ∈ `{added, removed, changed}` so the renderer can color-distinguish.
29706
+ * @request POST:/api/v1/visualization/branch-diff
29707
+ * @secure
29708
+ */
29709
+ getBranchDiffVisualization: (data: BranchDiffRequest, params?: RequestParams) => Promise<HttpResponse<BranchDiffResponse, any>>;
28687
29710
  /**
28688
29711
  * No description
28689
29712
  *
@@ -28694,6 +29717,46 @@ declare class Visualization<SecurityDataType = unknown> {
28694
29717
  * @secure
28695
29718
  */
28696
29719
  getConstraintGraph: (data: ConstraintGraphRequest$1, params?: RequestParams) => Promise<HttpResponse<ConstraintGraphResponse$1, any>>;
29720
+ /**
29721
+ * @description Each event is a JSON-encoded `DerivationStepEvent` with shape: ```json { "iteration": 3, "rule_id": "uuid", "antecedents": ["uuid",...], "derived_fact": "uuid" } ``` Sent once per record produced during the chainer pass. The client can animate each polygon emerging as its premise edges arrive.
29722
+ *
29723
+ * @tags visualization
29724
+ * @name GetDerivationStream
29725
+ * @summary SSE channel that streams the forward-chainer's derivation steps as they fire, instead of blocking until the full trace is assembled.
29726
+ * @request GET:/api/v1/visualization/derivation/stream
29727
+ * @secure
29728
+ */
29729
+ getDerivationStream: (params?: RequestParams) => Promise<HttpResponse<void, any>>;
29730
+ /**
29731
+ * @description Runs the homoiconic forward chainer with provenance enabled and emits a [`VisualizationGraph`] in which: - **Nodes** are Ψ-terms (each one is either an asserted fact, a rule, or a derived fact). Rules surface as `NodeType::Rule`. - **Edges** are `EdgeType::Derivation`, oriented antecedent → rule-application → produced-fact, mirroring the proof DAG. - **Hyperedges** are `HyperedgeType::DerivationStep` — one per rule application, grouping the rule with all its antecedents plus the produced fact. Rendering each step as a polygon makes "this fact came from these premises via this rule" visually atomic — exactly the idea behind Aït-Kaci & Sasaki's proof-tree diagrams in OSF/LIFE papers.
29732
+ *
29733
+ * @tags visualization
29734
+ * @name GetDerivationVisualization
29735
+ * @summary Get the forward-chain derivation lattice as a meta-hypergraph.
29736
+ * @request POST:/api/v1/visualization/derivation
29737
+ * @secure
29738
+ */
29739
+ getDerivationVisualization: (data: DerivationVisualizationRequest, params?: RequestParams) => Promise<HttpResponse<DerivationVisualizationResponse, any>>;
29740
+ /**
29741
+ * No description
29742
+ *
29743
+ * @tags visualization
29744
+ * @name GetFunctionsVisualization
29745
+ * @summary Render the LIFE-style function definitions in the tenant's term store. A LIFE function is itself a Ψ-term (homoiconic) — typically a term whose sort is `function` (or a subtype) carrying features `head`, `body`, optional `equations`. This handler scans the store for terms matching that signature and emits one TermFeatures-style hyperedge per function so each is visually atomic.
29746
+ * @request POST:/api/v1/visualization/functions
29747
+ * @secure
29748
+ */
29749
+ getFunctionsVisualization: (data: FunctionsVisualizationRequest, params?: RequestParams) => Promise<HttpResponse<FunctionsVisualizationResponse, any>>;
29750
+ /**
29751
+ * No description
29752
+ *
29753
+ * @tags visualization
29754
+ * @name GetGradedPosetVisualization
29755
+ * @summary Render the graded-poset projection of the tenant's sort hierarchy per "Weisfeiler & Lehman Go Categorical" (Choi, Kim, Yun 2026): - elements = sorts - dimension(σ) = topological depth from the lattice top - coverings = parent → child (subtype) - 4-adjacency edges when requested
29756
+ * @request POST:/api/v1/visualization/graded-poset
29757
+ * @secure
29758
+ */
29759
+ getGradedPosetVisualization: (data: GradedPosetRequest, params?: RequestParams) => Promise<HttpResponse<GradedPosetResponse, any>>;
28697
29760
  /**
28698
29761
  * No description
28699
29762
  *
@@ -28714,6 +29777,16 @@ declare class Visualization<SecurityDataType = unknown> {
28714
29777
  * @secure
28715
29778
  */
28716
29779
  getLatticeDot: (params?: RequestParams) => Promise<HttpResponse<void, any>>;
29780
+ /**
29781
+ * @description The layout is computed once per tenant (per hierarchy snapshot) and cached. Coordinates are stable across requests, so the client can pan/zoom by submitting different bboxes and the same node always lands at the same screen position.
29782
+ *
29783
+ * @tags visualization
29784
+ * @name GetLatticeTile
29785
+ * @summary Render only the lattice nodes that fall inside the client's viewport, using a stable pre-computed deterministic layout. This scales to millions of sorts because the per-request work is O(K) where K is the number of nodes inside the viewport, not O(N).
29786
+ * @request POST:/api/v1/visualization/lattice-tile
29787
+ * @secure
29788
+ */
29789
+ getLatticeTile: (data: LatticeTileRequest, params?: RequestParams) => Promise<HttpResponse<LatticeTileResponse, any>>;
28717
29790
  /**
28718
29791
  * @description Returns a graph representation of the sort hierarchy with nodes for each sort and edges for subtype relationships. Supports filtering by root sort and depth.
28719
29792
  *
@@ -28734,6 +29807,26 @@ declare class Visualization<SecurityDataType = unknown> {
28734
29807
  * @secure
28735
29808
  */
28736
29809
  getResiduationState: (data: ResiduationStateRequest$1, params?: RequestParams) => Promise<HttpResponse<ResiduationStateResponse$1, any>>;
29810
+ /**
29811
+ * @description BFS expands ancestors and/or descendants from the focus, emitting each visited sort with its signed hop distance as `level`. When the visit count would exceed `max_nodes`, the BFS halts and the `truncated` flag is set; the closest sorts are kept.
29812
+ *
29813
+ * @tags visualization
29814
+ * @name GetSortNeighborhood
29815
+ * @summary Render an N-hop neighborhood around a focus sort, capped at `max_nodes`. Designed for tenants with millions of sorts — the client never sees the full lattice; it browses by picking a focus and walking outward.
29816
+ * @request POST:/api/v1/visualization/sort-neighborhood
29817
+ * @secure
29818
+ */
29819
+ getSortNeighborhood: (data: SortNeighborhoodRequest, params?: RequestParams) => Promise<HttpResponse<SortNeighborhoodResponse, any>>;
29820
+ /**
29821
+ * No description
29822
+ *
29823
+ * @tags visualization
29824
+ * @name GetTermListVisualization
29825
+ * @summary Paginated raw list of Ψ-terms for visualization. Mirrors the `lattice` endpoint but for terms — at 9M terms in the drug-discovery tenant the first page returns sub-second without loading the in-memory term store.
29826
+ * @request POST:/api/v1/visualization/term-list
29827
+ * @secure
29828
+ */
29829
+ getTermListVisualization: (data: TermListRequest, params?: RequestParams) => Promise<HttpResponse<TermListResponse$1, any>>;
28737
29830
  /**
28738
29831
  * No description
28739
29832
  *
@@ -28754,6 +29847,16 @@ declare class Visualization<SecurityDataType = unknown> {
28754
29847
  * @secure
28755
29848
  */
28756
29849
  getTriggerDependencies: (data: TriggerDependencyRequest$1, params?: RequestParams) => Promise<HttpResponse<TriggerDependencyResponse$1, any>>;
29850
+ /**
29851
+ * @description **Unify (`⊔`)**: computes the meet on the Ψ-term lattice — the most-specific term that subsumes both operands. Variables in either operand bind to the corresponding sub-term in the other. **Anti-unify (`⊓`)**: computes the join — the least-general generalization (LGG) that subsumes both operands, introducing fresh variables where they disagree. This is the operation Aït-Kaci & Sasaki used for ILP rule synthesis. The handler runs the operation in a sandbox (trail-undone after snapshot) so the tenant's term store is not mutated by a visualization request. Returns operand1, operand2, and the result as polygons in one `VisualizationGraph`, with `properties.role` distinguishing each.
29852
+ *
29853
+ * @tags visualization
29854
+ * @name GetUnifyTermsVisualization
29855
+ * @summary Render the unification (or anti-unification) of two Ψ-terms.
29856
+ * @request POST:/api/v1/visualization/unify-terms
29857
+ * @secure
29858
+ */
29859
+ getUnifyTermsVisualization: (data: UnifyTermsRequest$1, params?: RequestParams) => Promise<HttpResponse<UnifyTermsResponse$1, any>>;
28757
29860
  /**
28758
29861
  * No description
28759
29862
  *
@@ -41392,6 +42495,442 @@ declare class UiClient {
41392
42495
  catalog(): Promise<UICatalogResponse>;
41393
42496
  }
41394
42497
 
42498
+ declare class Compliance<SecurityDataType = unknown> {
42499
+ http: HttpClient<SecurityDataType>;
42500
+ constructor(http: HttpClient<SecurityDataType>);
42501
+ /**
42502
+ * No description
42503
+ *
42504
+ * @tags compliance
42505
+ * @name Append
42506
+ * @summary `POST /api/v1/compliance/audit/append`
42507
+ * @request POST:/api/v1/compliance/audit/append
42508
+ * @secure
42509
+ */
42510
+ append: (data: AppendRequest$1, params?: RequestParams) => Promise<HttpResponse<AuditRecord$1, any>>;
42511
+ /**
42512
+ * No description
42513
+ *
42514
+ * @tags compliance
42515
+ * @name CaptureSnapshot
42516
+ * @summary `POST /api/v1/predictions/snapshot`
42517
+ * @request POST:/api/v1/predictions/snapshot
42518
+ * @secure
42519
+ */
42520
+ captureSnapshot: (data: CaptureSnapshotRequest$1, params?: RequestParams) => Promise<HttpResponse<PredictionSnapshot$1, any>>;
42521
+ /**
42522
+ * No description
42523
+ *
42524
+ * @tags compliance
42525
+ * @name GetSnapshot
42526
+ * @summary `GET /api/v1/predictions/snapshot/{id}`
42527
+ * @request GET:/api/v1/predictions/snapshot/{id}
42528
+ * @secure
42529
+ */
42530
+ getSnapshot: (id: string, params?: RequestParams) => Promise<HttpResponse<PredictionSnapshot$1, any>>;
42531
+ /**
42532
+ * No description
42533
+ *
42534
+ * @tags compliance
42535
+ * @name List
42536
+ * @summary `GET /api/v1/compliance/audit/list`
42537
+ * @request GET:/api/v1/compliance/audit/list
42538
+ * @secure
42539
+ */
42540
+ list: (query?: {
42541
+ /**
42542
+ * @format int32
42543
+ * @min 0
42544
+ */
42545
+ limit?: number | null;
42546
+ request_path_pattern?: string | null;
42547
+ }, params?: RequestParams) => Promise<HttpResponse<AuditRecord$1[], any>>;
42548
+ /**
42549
+ * No description
42550
+ *
42551
+ * @tags compliance
42552
+ * @name Summary
42553
+ * @summary `GET /api/v1/compliance/audit/summary`
42554
+ * @request GET:/api/v1/compliance/audit/summary
42555
+ * @secure
42556
+ */
42557
+ summary: (params?: RequestParams) => Promise<HttpResponse<SummaryResponse$1, any>>;
42558
+ /**
42559
+ * @description Runs validation with a built-in stub provider that returns `Pending` for every entry. Real consumers wire their own `GroundTruthProviderPort` implementation and call `PredictionLedgerPort::validate` from a service.
42560
+ *
42561
+ * @tags compliance
42562
+ * @name ValidateStub
42563
+ * @summary `POST /api/v1/predictions/snapshot/{id}/validate-stub`
42564
+ * @request POST:/api/v1/predictions/snapshot/{id}/validate-stub
42565
+ * @secure
42566
+ */
42567
+ validateStub: (id: string, params?: RequestParams) => Promise<HttpResponse<ValidationReportDto$1, any>>;
42568
+ /**
42569
+ * No description
42570
+ *
42571
+ * @tags compliance
42572
+ * @name Verify
42573
+ * @summary `GET /api/v1/compliance/audit/verify`
42574
+ * @request GET:/api/v1/compliance/audit/verify
42575
+ * @secure
42576
+ */
42577
+ verify: (params?: RequestParams) => Promise<HttpResponse<VerifyResponse$1, void>>;
42578
+ }
42579
+
42580
+ /**
42581
+ * Hash-chained audit ledger and prediction-snapshot validation —
42582
+ * `/api/v1/compliance/*` and `/api/v1/predictions/*`.
42583
+ *
42584
+ * Every API call (or any explicitly logged event) becomes an append-
42585
+ * only `AuditRecord` whose `record_hash` chains into the previous
42586
+ * record's `prev_hash`. Snapshots freeze a slice of the ledger
42587
+ * matching a request-path glob and let an external validator
42588
+ * mark each prediction `Validated` / `Refuted` / `Unknown`.
42589
+ *
42590
+ * @module
42591
+ */
42592
+ /** Verdict of a prediction snapshot entry against ground truth. */
42593
+ type GroundTruthStatus = 'Pending' | 'Validated' | 'Refuted' | 'Unknown';
42594
+ /**
42595
+ * Body for `POST /api/v1/compliance/audit/append` — record one event
42596
+ * in the tenant's audit ledger.
42597
+ */
42598
+ interface AppendRequest {
42599
+ /** Hash of the request body (caller chooses the hashing scheme). */
42600
+ requestHash: string;
42601
+ /** Path of the request being audited (e.g. `/api/v1/inference/backward-chain`). */
42602
+ requestPath: string;
42603
+ /** Hash of the response body. */
42604
+ responseHash: string;
42605
+ /** Optional map of input-data versions in effect at request time. */
42606
+ dataVersions?: Record<string, string>;
42607
+ /** Optional bag of caller-defined metadata. */
42608
+ extra?: Record<string, unknown>;
42609
+ }
42610
+ /** A single record in the tenant's hash-chained audit ledger. */
42611
+ interface AuditRecord {
42612
+ /** Stable id of this record. */
42613
+ id: string;
42614
+ /** Tenant the record belongs to. */
42615
+ tenantId: string;
42616
+ /** Optional actor (user id) who triggered the request. */
42617
+ actor?: string | null;
42618
+ /** ISO-8601 timestamp at which the record was appended. */
42619
+ timestamp: string;
42620
+ /** Path of the audited request. */
42621
+ requestPath: string;
42622
+ /** Hash of the audited request body. */
42623
+ requestHash: string;
42624
+ /** Hash of the audited response body. */
42625
+ responseHash: string;
42626
+ /** Hash of the previous record (forms the chain). */
42627
+ prevHash: string;
42628
+ /** Hash of this record (computed from all other fields). */
42629
+ recordHash: string;
42630
+ /** Git revision of the engine that wrote this record. */
42631
+ gitRevision: string;
42632
+ /** Map of input-data versions in effect when the record was written. */
42633
+ dataVersions: Record<string, string>;
42634
+ /** Caller-defined metadata. */
42635
+ extra: Record<string, unknown>;
42636
+ }
42637
+ /** Filter for `GET /api/v1/compliance/audit/list`. */
42638
+ interface ListAuditOptions {
42639
+ /** Limit on the number of records returned. */
42640
+ limit?: number;
42641
+ /** Glob-style filter on `requestPath`. */
42642
+ requestPathPattern?: string;
42643
+ }
42644
+ /**
42645
+ * Response of `GET /api/v1/compliance/audit/summary` — top-line
42646
+ * counts over the tenant's full ledger.
42647
+ */
42648
+ interface SummaryResponse {
42649
+ /** Number of records in the ledger. */
42650
+ nRecords: number;
42651
+ /** Counts grouped by actor id. */
42652
+ perActor: Record<string, number>;
42653
+ /** Counts grouped by request path. */
42654
+ perRequestPath: Record<string, number>;
42655
+ /** Tenant id (echoed back). */
42656
+ tenantId: string;
42657
+ /** ISO-8601 timestamp of the first record in the ledger. */
42658
+ tsFirst?: string;
42659
+ /** ISO-8601 timestamp of the last record. */
42660
+ tsLast?: string;
42661
+ }
42662
+ /**
42663
+ * Response of `GET /api/v1/compliance/audit/verify` — re-walks the
42664
+ * hash chain and reports any breaks.
42665
+ */
42666
+ interface VerifyResponse {
42667
+ /** True iff the chain is intact. */
42668
+ ok: boolean;
42669
+ /** Number of detected violations. */
42670
+ nViolations: number;
42671
+ /** Raw violation entries (engine-defined shape). */
42672
+ violations: unknown[];
42673
+ }
42674
+ /**
42675
+ * Filter description that is persisted on each snapshot — mirrors the
42676
+ * `CaptureSnapshotRequest` minus the request-side optionality
42677
+ * (capture always records the resolved filter that was applied).
42678
+ */
42679
+ interface SnapshotFilter {
42680
+ /** Glob-style pattern on `AuditRecord.requestPath`. */
42681
+ requestPathPattern: string;
42682
+ /** Lower bound on `AuditRecord.timestamp`. */
42683
+ capturedAfter?: string | null;
42684
+ /** Optional cap on the number of entries. */
42685
+ maxEntries?: number | null;
42686
+ }
42687
+ /** Body of `POST /api/v1/predictions/snapshot`. */
42688
+ interface CaptureSnapshotRequest {
42689
+ /** Glob-style pattern that selects which audit records to freeze. */
42690
+ requestPathPattern: string;
42691
+ /** Lower bound on `AuditRecord.timestamp` (ISO-8601). */
42692
+ capturedAfter?: string;
42693
+ /** Cap on the number of frozen entries. */
42694
+ maxEntries?: number;
42695
+ }
42696
+ /** A single prediction frozen into a snapshot, awaiting validation. */
42697
+ interface PredictionEntry {
42698
+ /** Stable id of this entry within the snapshot. */
42699
+ id: string;
42700
+ /** Hash of the audited request body that produced the prediction. */
42701
+ requestHash: string;
42702
+ /** Domain-shaped opaque payload — the engine never interprets it. */
42703
+ responseSummary: unknown;
42704
+ /** Back-pointer to the audit record this entry was derived from. */
42705
+ sourceRecordId: string;
42706
+ /** Verdict at capture time — always `Pending`. */
42707
+ capturedStatus: GroundTruthStatus;
42708
+ /** Verdict after the most recent validation pass; `null` until run. */
42709
+ validatedStatus?: GroundTruthStatus | null;
42710
+ /** ISO-8601 timestamp of the most recent validation pass. */
42711
+ validatedAt?: string | null;
42712
+ }
42713
+ /** A frozen slice of the audit ledger — the unit of validation. */
42714
+ interface PredictionSnapshot {
42715
+ /** Stable id of the snapshot. */
42716
+ id: string;
42717
+ /** Tenant the snapshot belongs to. */
42718
+ tenantId: string;
42719
+ /** ISO-8601 timestamp at which the snapshot was captured. */
42720
+ capturedAt: string;
42721
+ /** Filter that defined which audit records made it in. */
42722
+ filter: SnapshotFilter;
42723
+ /** Prediction entries the snapshot froze. */
42724
+ entries: PredictionEntry[];
42725
+ }
42726
+ /** Result of a `validate-stub` pass over a snapshot. */
42727
+ interface ValidationReportDto {
42728
+ /** Snapshot the report applies to. */
42729
+ snapshotId: string;
42730
+ /** ISO-8601 timestamp of the validation pass. */
42731
+ completedAt: string;
42732
+ /** Total entries considered. */
42733
+ nTotal: number;
42734
+ /** Entries verdict-`Pending`. */
42735
+ nPending: number;
42736
+ /** Entries verdict-`Validated`. */
42737
+ nValidated: number;
42738
+ /** Entries verdict-`Refuted`. */
42739
+ nRefuted: number;
42740
+ /** Entries whose ground truth couldn't be resolved. */
42741
+ nUnknown: number;
42742
+ /** Validated / non-pending ratio (null when no non-pending entries). */
42743
+ validationRate?: number | null;
42744
+ }
42745
+
42746
+ type compliance_AppendRequest = AppendRequest;
42747
+ type compliance_AuditRecord = AuditRecord;
42748
+ type compliance_CaptureSnapshotRequest = CaptureSnapshotRequest;
42749
+ type compliance_GroundTruthStatus = GroundTruthStatus;
42750
+ type compliance_ListAuditOptions = ListAuditOptions;
42751
+ type compliance_PredictionEntry = PredictionEntry;
42752
+ type compliance_PredictionSnapshot = PredictionSnapshot;
42753
+ type compliance_SnapshotFilter = SnapshotFilter;
42754
+ type compliance_SummaryResponse = SummaryResponse;
42755
+ type compliance_ValidationReportDto = ValidationReportDto;
42756
+ type compliance_VerifyResponse = VerifyResponse;
42757
+ declare namespace compliance {
42758
+ export type { compliance_AppendRequest as AppendRequest, compliance_AuditRecord as AuditRecord, compliance_CaptureSnapshotRequest as CaptureSnapshotRequest, compliance_GroundTruthStatus as GroundTruthStatus, compliance_ListAuditOptions as ListAuditOptions, compliance_PredictionEntry as PredictionEntry, compliance_PredictionSnapshot as PredictionSnapshot, compliance_SnapshotFilter as SnapshotFilter, compliance_SummaryResponse as SummaryResponse, compliance_ValidationReportDto as ValidationReportDto, compliance_VerifyResponse as VerifyResponse };
42759
+ }
42760
+
42761
+ /**
42762
+ * Resource client for the hash-chained audit ledger and prediction-
42763
+ * snapshot validation pipeline (`/api/v1/compliance/*` and
42764
+ * `/api/v1/predictions/*`).
42765
+ *
42766
+ * @remarks
42767
+ * Two cooperating mechanisms:
42768
+ *
42769
+ * - **Audit ledger** — every API call (or anything explicitly
42770
+ * appended via {@link append}) becomes an immutable
42771
+ * `AuditRecord` whose `recordHash` chains into the previous
42772
+ * record's `prevHash`. {@link verify} re-walks the chain and
42773
+ * reports breaks; {@link summary} returns top-line counts.
42774
+ *
42775
+ * - **Prediction snapshots** — {@link captureSnapshot} freezes a
42776
+ * slice of the ledger matching a request-path glob, producing a
42777
+ * `PredictionSnapshot` with one `PredictionEntry` per audited
42778
+ * prediction. Each entry starts `Pending`; an external validator
42779
+ * (against ground truth) flips them to `Validated` / `Refuted` /
42780
+ * `Unknown` and {@link validateStub} surfaces a ratio report.
42781
+ *
42782
+ * Delegates to the generated `Compliance` route class for type-safe
42783
+ * HTTP calls.
42784
+ */
42785
+ declare class ComplianceClient {
42786
+ /** @internal */
42787
+ private readonly api;
42788
+ /** @internal */
42789
+ constructor(api: Compliance);
42790
+ /**
42791
+ * Append one record to the tenant's audit ledger.
42792
+ *
42793
+ * @param request - Hashes + path + optional metadata.
42794
+ * @returns The freshly appended record (with `recordHash` /
42795
+ * `prevHash` populated by the engine).
42796
+ */
42797
+ append(request: AppendRequest): Promise<AuditRecord>;
42798
+ /**
42799
+ * List audit records for this tenant, optionally filtered.
42800
+ *
42801
+ * @param options - Limit / glob filter on `requestPath`.
42802
+ */
42803
+ list(options?: ListAuditOptions): Promise<AuditRecord[]>;
42804
+ /**
42805
+ * Top-line counts over the tenant's full ledger — useful for
42806
+ * dashboards and quick health checks.
42807
+ */
42808
+ summary(): Promise<SummaryResponse>;
42809
+ /**
42810
+ * Re-walk the hash chain end-to-end and report any breaks.
42811
+ *
42812
+ * @returns `ok: true` when the chain is intact. `violations` is
42813
+ * an engine-defined opaque list when it isn't.
42814
+ */
42815
+ verify(): Promise<VerifyResponse>;
42816
+ /**
42817
+ * Capture a frozen slice of the audit ledger for later validation.
42818
+ *
42819
+ * @param request - Glob-style path filter + optional time / count
42820
+ * bounds.
42821
+ * @returns The freshly persisted snapshot, including every
42822
+ * captured `PredictionEntry`.
42823
+ *
42824
+ * @remarks
42825
+ * The `requestPathPattern` is mandatory. Without it the snapshot
42826
+ * would freeze the entire ledger, which is rarely useful.
42827
+ */
42828
+ captureSnapshot(request: CaptureSnapshotRequest): Promise<PredictionSnapshot>;
42829
+ /**
42830
+ * Fetch a previously-captured snapshot by id.
42831
+ */
42832
+ getSnapshot(id: string): Promise<PredictionSnapshot>;
42833
+ /**
42834
+ * Run the stub validator over a snapshot and return a
42835
+ * pending/validated/refuted/unknown report.
42836
+ *
42837
+ * @param id - Snapshot id.
42838
+ *
42839
+ * @remarks
42840
+ * "Stub" is the in-engine validator that defers the actual
42841
+ * ground-truth resolution to a `GroundTruthProviderPort` registered
42842
+ * on the backend. Without a registered provider every entry stays
42843
+ * `Pending`.
42844
+ */
42845
+ validateStub(id: string): Promise<ValidationReportDto>;
42846
+ }
42847
+
42848
+ declare class Operations<SecurityDataType = unknown> {
42849
+ http: HttpClient<SecurityDataType>;
42850
+ constructor(http: HttpClient<SecurityDataType>);
42851
+ /**
42852
+ * @description `POST /api/v1/operations/anti-unify` Accepts two Ψ-term ids and returns the LGG term computed by the engine's [`AntiUnificationEngine`](osfkb_domain::operations::ilp::AntiUnificationEngine). The LGG is persisted in the tenant's term store; the response carries both its id and an enriched view (sort name + display name + referenced-term summaries).
42853
+ *
42854
+ * @tags operations
42855
+ * @name AntiUnify
42856
+ * @summary Anti-unify two Ψ-terms (Least General Generalisation).
42857
+ * @request POST:/api/v1/operations/anti-unify
42858
+ */
42859
+ antiUnify: (data: AntiUnifyRequest$1, params?: RequestParams) => Promise<HttpResponse<AntiUnifyResponse$1, void>>;
42860
+ }
42861
+
42862
+ /**
42863
+ * Anti-unify two Ψ-terms — request body for
42864
+ * `POST /api/v1/operations/anti-unify`.
42865
+ *
42866
+ * The two referenced terms must already exist in the tenant's term
42867
+ * store. The engine computes their Least General Generalisation (LGG)
42868
+ * using `osfkb_domain::operations::ilp::AntiUnificationEngine` and
42869
+ * persists the resulting Ψ-term.
42870
+ */
42871
+ interface AntiUnifyRequest {
42872
+ /** First Ψ-term id (must already be registered in the tenant). */
42873
+ term1Id: string;
42874
+ /** Second Ψ-term id (must already be registered in the tenant). */
42875
+ term2Id: string;
42876
+ }
42877
+ /**
42878
+ * Result of an anti-unification call.
42879
+ *
42880
+ * Carries the newly-created LGG term's id plus an enriched view
42881
+ * (sort name, display name, referenced-term summaries) so callers
42882
+ * don't need a follow-up `getTerm` round-trip.
42883
+ */
42884
+ interface AntiUnifyResponse {
42885
+ /** Id of the newly-created LGG term. */
42886
+ lggTermId: string;
42887
+ /** Enriched view of the LGG term. */
42888
+ lgg: TermDto;
42889
+ /** Engine + lock-acquisition time, in milliseconds. */
42890
+ computationTimeMs: number;
42891
+ }
42892
+
42893
+ type operations_AntiUnifyRequest = AntiUnifyRequest;
42894
+ type operations_AntiUnifyResponse = AntiUnifyResponse;
42895
+ declare namespace operations {
42896
+ export type { operations_AntiUnifyRequest as AntiUnifyRequest, operations_AntiUnifyResponse as AntiUnifyResponse };
42897
+ }
42898
+
42899
+ /**
42900
+ * Resource client for low-level term-graph operations.
42901
+ *
42902
+ * @remarks
42903
+ * Currently exposes anti-unification — the Inductive Logic
42904
+ * Programming building block that computes the Least General
42905
+ * Generalisation (LGG) of two Ψ-terms. More operations may surface
42906
+ * here over time; the namespace is reserved for engine-internal
42907
+ * primitives that are useful to expose as standalone calls rather
42908
+ * than as part of a larger pipeline.
42909
+ *
42910
+ * Delegates to the generated `Operations` route class for type-safe
42911
+ * HTTP calls.
42912
+ */
42913
+ declare class OperationsClient {
42914
+ /** @internal */
42915
+ private readonly api;
42916
+ /** @internal */
42917
+ constructor(api: Operations);
42918
+ /**
42919
+ * Compute the anti-unification (Least General Generalisation) of
42920
+ * two Ψ-terms.
42921
+ *
42922
+ * @param request - The two term ids to generalise.
42923
+ * @returns The newly-created LGG term + enriched view + timing.
42924
+ *
42925
+ * @remarks
42926
+ * Both ids must already be registered in the tenant's term store.
42927
+ * The LGG is persisted; subsequent calls with the same operands
42928
+ * still produce a fresh LGG term (idempotency is not guaranteed at
42929
+ * this layer — wrap in your own cache if you need it).
42930
+ */
42931
+ antiUnify(request: AntiUnifyRequest): Promise<AntiUnifyResponse>;
42932
+ }
42933
+
41395
42934
  /** Core knowledge base operations — types, records, rules, functions, constraints, and queries. */
41396
42935
  interface CoreGroup {
41397
42936
  readonly types: SortsClient;
@@ -41578,6 +43117,10 @@ declare class ReasoningLayerClient {
41578
43117
  readonly rlTraining: RlTrainingClient;
41579
43118
  /** Sort-driven UI descriptor operations (describe, action, catalog). */
41580
43119
  readonly ui: UiClient;
43120
+ /** Hash-chained audit ledger and prediction-snapshot validation. */
43121
+ readonly compliance: ComplianceClient;
43122
+ /** Low-level term-graph operations (anti-unification / LGG). */
43123
+ readonly operations: OperationsClient;
41581
43124
  private _core?;
41582
43125
  private _ai?;
41583
43126
  private _reasoning?;
@@ -42683,4 +44226,4 @@ declare function toUntaggedFeatures(features: PlainFeatureMap): Record<string, F
42683
44226
  */
42684
44227
  declare function toTermInputDto(input: PsiTermInput | TermInputDto): TermInputDto;
42685
44228
 
42686
- export { ANY_ROLE, actionReviews as ActionReviews, type AddFactRequest, type AddFactResponse, type AddRuleRequest, type AddRuleResponse, admin as Admin, type AiGroup, analysis as Analysis, type AnalysisGroup, ApiError, type ApiResponse, type AuthConfig, AuthenticationError, type BackwardChainRequest, type BackwardChainResponse, BadRequestError, type BulkAddTermsRequest, type BulkAddTermsResponse, type BulkCreateSortsRequest, type BulkCreateSortsResponse, cdl as CDL, causal as Causal, type ClearTermsResponse, type ClientConfig, cognitive as Cognitive, collections as Collections, communities as Communities, type ConstrainedPlainVar, ConstraintViolationError, constraints as Constraints, control as Control, conversation as Conversation, type ConversationMessageRequest, type ConversationMessageResponse, type ConversationSummaryDto, type ConversationTurnsResponse, type CoreGroup, type CreateResearchSessionRequest, type CreateResearchSessionResponse, type CreateSortRequest, type CreateTermRequest, type DataGroup, discovery as Discovery, type ErrorResponse$1 as ErrorResponse, execution as Execution, extract as Extract, type FeatureInputValueDto, type FeatureValueDto, ForbiddenError, type ForwardChainRequest, type ForwardChainResponse, functions as Functions, fuzzy as Fuzzy, FuzzyShape, type FuzzyShapeDto, generation as Generation, type GlbRequest, type GlbResponse, health as Health, homoiconic as Homoiconic, ilp as ILP, imageExtraction as ImageExtraction, inference as Inference, type IngestPaperRequest, type IngestPaperResponse, ingestion as Ingestion, IngestionFailedError, IngestionSession, type IngestionSyncOptions, type Interceptor, InternalServerError, type JsonValue$1 as JsonValue, LP, type ListConversationsResponse, type LubRequest, type LubResponse, namespaces as Namespaces, NetworkError, neuroSymbolic as NeuroSymbolic, NotFoundError, ontology as Ontology, optimize as Optimize, type OsfSearchRequest, type OsfSearchResponse, osfql as Osfql, type OsfqlRequest, type OsfqlResponse, type OsfqlValue, oversight as Oversight, type PaginationParams, type PaperMetadataDto, type PaperSource, type PlainFeatureMap, type PlainFeatureValue, plainValues as PlainValues, preferences as Preferences, proofEngine as ProofEngine, type PsiTermDto, type PsiTermInput, query as Query, rag as RAG, RateLimitError, type RateLimitInfo, reasoning as Reasoning, type ReasoningGroup, ReasoningLayerClient, ReasoningLayerError, type RequestOptions, research as Research, type ResearchContradictionsResponse, type ResearchCycleResponse, type ResearchFindingsResponse, type ResearchGapsResponse, type ResearchReportResponse, type ResearchSessionResponse, reviews as Reviews, row as Row, SDK_VERSION, scenarios as Scenarios, scheduling as Scheduling, type SearchPapersRequest, type SearchPapersResponse, SortBuilder, type SortDto, type SortInfoDto, sorts as Sorts, sources as Sources, spaces as Spaces, statistical as Statistical, synthetic as Synthetic, type SystemGroup, type TermDto, type TermInputArg, type TermInputDto, type TermListResponse, type TermPatternDto, type TermResponse, terms as Terms, TimeoutError, type TurnDto, type UpdateTermRequest, utilities as Utilities, ValidationError, Value, type ValueDto, values as Values, type VerifyClaimRequest, type VerifyClaimResponse, visualization as Visualization, WebSocketClient, WebSocketConnection, webhookActions as WebhookActions, type WorkflowGroup, allen, constrained, discriminateFeatureValue, guard, isConstrainedPlainVar, isPsiTermInput, isTaggedValueDto, isUuid, psi, toTaggedFeatures, toTaggedValue, toTermInputDto, toUntaggedFeatures, toUntaggedValue };
44229
+ export { ANY_ROLE, actionReviews as ActionReviews, type AddFactRequest, type AddFactResponse, type AddRuleRequest, type AddRuleResponse, admin as Admin, type AiGroup, analysis as Analysis, type AnalysisGroup, ApiError, type ApiResponse, type AuthConfig, AuthenticationError, type BackwardChainRequest, type BackwardChainResponse, BadRequestError, type BulkAddTermsRequest, type BulkAddTermsResponse, type BulkCreateSortsRequest, type BulkCreateSortsResponse, cdl as CDL, causal as Causal, type ClearTermsResponse, type ClientConfig, cognitive as Cognitive, collections as Collections, communities as Communities, compliance as Compliance, type ConstrainedPlainVar, ConstraintViolationError, constraints as Constraints, control as Control, conversation as Conversation, type ConversationMessageRequest, type ConversationMessageResponse, type ConversationSummaryDto, type ConversationTurnsResponse, type CoreGroup, type CreateResearchSessionRequest, type CreateResearchSessionResponse, type CreateSortRequest, type CreateTermRequest, type DataGroup, discovery as Discovery, type ErrorResponse$1 as ErrorResponse, execution as Execution, extract as Extract, type FeatureInputValueDto, type FeatureValueDto, ForbiddenError, type ForwardChainRequest, type ForwardChainResponse, functions as Functions, fuzzy as Fuzzy, FuzzyShape, type FuzzyShapeDto, generation as Generation, type GlbRequest, type GlbResponse, health as Health, homoiconic as Homoiconic, ilp as ILP, imageExtraction as ImageExtraction, inference as Inference, type IngestPaperRequest, type IngestPaperResponse, ingestion as Ingestion, IngestionFailedError, IngestionSession, type IngestionSyncOptions, type Interceptor, InternalServerError, type JsonValue$1 as JsonValue, LP, type ListConversationsResponse, type LubRequest, type LubResponse, namespaces as Namespaces, NetworkError, neuroSymbolic as NeuroSymbolic, NotFoundError, ontology as Ontology, operations as Operations, optimize as Optimize, type OsfSearchRequest, type OsfSearchResponse, osfql as Osfql, type OsfqlRequest, type OsfqlResponse, type OsfqlValue, oversight as Oversight, type PaginationParams, type PaperMetadataDto, type PaperSource, type PlainFeatureMap, type PlainFeatureValue, plainValues as PlainValues, preferences as Preferences, proofEngine as ProofEngine, type PsiTermDto, type PsiTermInput, query as Query, rag as RAG, RateLimitError, type RateLimitInfo, reasoning as Reasoning, type ReasoningGroup, ReasoningLayerClient, ReasoningLayerError, type RequestOptions, research as Research, type ResearchContradictionsResponse, type ResearchCycleResponse, type ResearchFindingsResponse, type ResearchGapsResponse, type ResearchReportResponse, type ResearchSessionResponse, reviews as Reviews, row as Row, SDK_VERSION, scenarios as Scenarios, scheduling as Scheduling, type SearchPapersRequest, type SearchPapersResponse, SortBuilder, type SortDto, type SortInfoDto, sorts as Sorts, sources as Sources, spaces as Spaces, statistical as Statistical, synthetic as Synthetic, type SystemGroup, type TermDto, type TermInputArg, type TermInputDto, type TermListResponse, type TermPatternDto, type TermResponse, terms as Terms, TimeoutError, type TurnDto, type UpdateTermRequest, utilities as Utilities, ValidationError, Value, type ValueDto, values as Values, type VerifyClaimRequest, type VerifyClaimResponse, visualization as Visualization, WebSocketClient, WebSocketConnection, webhookActions as WebhookActions, type WorkflowGroup, allen, constrained, discriminateFeatureValue, guard, isConstrainedPlainVar, isPsiTermInput, isTaggedValueDto, isUuid, psi, toTaggedFeatures, toTaggedValue, toTermInputDto, toUntaggedFeatures, toUntaggedValue };