@kortexya/reasoninglayer 1.4.0 → 1.5.1

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.cts 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.4.0";
112
+ declare const SDK_VERSION = "1.5.1";
113
113
  /**
114
114
  * Authentication mode for the SDK.
115
115
  *
@@ -281,6 +281,44 @@ declare class HttpClient<SecurityDataType = unknown> {
281
281
  request: <T = any, E = any>({ body, secure, path, type, query, format, baseUrl, cancelToken, ...params }: FullRequestParams) => Promise<HttpResponse<T, E>>;
282
282
  }
283
283
 
284
+ /** A validation rule over a single parameter (externally tagged). */
285
+ type ActionParamRuleDto = {
286
+ /** String parameter, when present, must be non-empty. */
287
+ non_empty_string: {
288
+ param: string;
289
+ };
290
+ } | {
291
+ /** Integer parameter, when present, in `[min, max]`. */
292
+ int_range: {
293
+ /** @format int64 */
294
+ max: number;
295
+ /** @format int64 */
296
+ min: number;
297
+ param: string;
298
+ };
299
+ } | {
300
+ /** Real parameter, when present, in `[min, max]`. */
301
+ real_range: {
302
+ /** @format double */
303
+ max: number;
304
+ /** @format double */
305
+ min: number;
306
+ param: string;
307
+ };
308
+ } | {
309
+ /** String parameter, when present, must be one of `allowed`. */
310
+ one_of: {
311
+ allowed: string[];
312
+ param: string;
313
+ };
314
+ };
315
+ /** One action parameter projected from an [`ActionInputSpec`]. */
316
+ interface ActionParameterDto {
317
+ /** Parameter (input feature) name. */
318
+ name: string;
319
+ /** Whether the input is required. */
320
+ required: boolean;
321
+ }
284
322
  /** Reason why an action requires review */
285
323
  type ActionReviewReasonDto$1 = "requires_approval" | "high_risk" | "external_side_effect" | "low_confidence" | "first_use" | {
286
324
  /** Custom reason */
@@ -328,6 +366,49 @@ interface ActionReviewSummaryDto$1 {
328
366
  */
329
367
  total_pending: number;
330
368
  }
369
+ /** A declarative side-effect fired after the action applies. */
370
+ interface ActionSideEffectDto {
371
+ /** Notification body. */
372
+ body: string;
373
+ /** Delivery channel: `webhook`, `email`, `in_app`, or `browser_push`. */
374
+ channel: string;
375
+ /** Recipient/target (webhook URL or recipient address). */
376
+ target: string;
377
+ /** Notification title. */
378
+ title: string;
379
+ }
380
+ /** A typed, validated, RBAC-bound action schema. */
381
+ interface ActionTypeDefDto {
382
+ /** Action type name (the action sort). */
383
+ name: string;
384
+ /** Typed parameters. */
385
+ params?: ParamSpecDto[];
386
+ /** Roles required to apply this action (empty ⇒ unrestricted). */
387
+ required_roles?: string[];
388
+ /** Validation rules over parameters. */
389
+ rules?: ActionParamRuleDto[];
390
+ /** Side-effects to dispatch once the action applies. */
391
+ side_effects?: ActionSideEffectDto[];
392
+ }
393
+ /** One projected action type. */
394
+ interface ActionTypeDto {
395
+ /** Action sort name (Palantir action-type apiName). */
396
+ apiName: string;
397
+ /** Human-facing name (the action sort name). */
398
+ displayName: string;
399
+ /** Parameters — required inputs first, then optional. */
400
+ parameters: ActionParameterDto[];
401
+ }
402
+ /** Response for `GET /api/v1/ontology/action-types`. */
403
+ interface ActionTypeListResponse$1 {
404
+ /** The projected action types. */
405
+ actionTypes: ActionTypeDto[];
406
+ /**
407
+ * Number of action types returned.
408
+ * @min 0
409
+ */
410
+ count: number;
411
+ }
331
412
  /** Activation level DTO. */
332
413
  interface ActivationDto$1 {
333
414
  /**
@@ -774,6 +855,55 @@ interface AgentSubVerdictDto$1 {
774
855
  /** Per-agent verdict: "safe", "unsafe", "partial", or "residuated" */
775
856
  verdict: string;
776
857
  }
858
+ /** Request to align a domain ontology to an upper ontology. */
859
+ interface AlignOntologyRequest$1 {
860
+ /** Domain ontology to align, as OWL/RDF-XML. */
861
+ domain_owl: string;
862
+ /** Upper ontologies to align against. Defaults to `["BFO"]` when empty. */
863
+ targets?: string[];
864
+ }
865
+ /** Response from an ontology-alignment run. */
866
+ interface AlignOntologyResponse$1 {
867
+ /** Surfaced ⊥-conflicts among proposed candidates. */
868
+ conflicts: AlignmentConflictDto$1[];
869
+ /**
870
+ * Number of domain sorts considered.
871
+ * @min 0
872
+ */
873
+ domain_sorts: number;
874
+ /** The MAPPING artifact as Turtle (`skos:*` + `kortexya:confidence`). */
875
+ mapping_ttl: string;
876
+ /** Confirmed SKOS correspondences. */
877
+ matches: AlignmentMatchDto$1[];
878
+ /**
879
+ * Number of upper-ontology target sorts indexed.
880
+ * @min 0
881
+ */
882
+ target_sorts: number;
883
+ }
884
+ /**
885
+ * Two upper-ontology candidates a domain class cannot map to simultaneously
886
+ * (their lattice meet is ⊥ — e.g. disjoint BFO branches).
887
+ */
888
+ interface AlignmentConflictDto$1 {
889
+ /** Domain sort name whose candidates conflict. */
890
+ domain_sort: string;
891
+ /** The kept (higher-scored) candidate CURIE. */
892
+ target_a: string;
893
+ /** The rejected, incompatible candidate CURIE. */
894
+ target_b: string;
895
+ }
896
+ /** A confirmed SKOS correspondence from a domain class to an upper-ontology class. */
897
+ interface AlignmentMatchDto$1 {
898
+ /** Domain sort name. */
899
+ domain_sort: string;
900
+ /** SKOS relation: `exactMatch` / `broadMatch` / `narrowMatch` / `closeMatch`. */
901
+ match_type: string;
902
+ /** Upper-ontology class CURIE (e.g. the BFO IRI's CURIE form). */
903
+ target_curie: string;
904
+ /** Upper-ontology class label. */
905
+ target_label: string;
906
+ }
777
907
  /** Statistics for source text alignment quality */
778
908
  interface AlignmentStatsDto {
779
909
  /**
@@ -866,6 +996,43 @@ interface AppendResiduationsResponse$1 {
866
996
  /** @min 0 */
867
997
  total_residuations: number;
868
998
  }
999
+ /** Request body for `POST /api/v1/actions/apply`. */
1000
+ interface ApplyActionRequest$1 {
1001
+ /** The action schema to apply. */
1002
+ action: ActionTypeDefDto;
1003
+ /** Roles held by the caller (checked against `action.required_roles`). */
1004
+ caller_roles?: string[];
1005
+ /** Multi-term edits to commit atomically when the action is `Ready`. */
1006
+ edits?: TermEditDto[];
1007
+ /** Bound input features (`feature → JSON value`). */
1008
+ inputs?: Record<string, any>;
1009
+ }
1010
+ /** Outcome of applying an action (the `outcome` field discriminates). */
1011
+ type ApplyActionResponse$1 = {
1012
+ outcome: "applied";
1013
+ /**
1014
+ * Number of side-effects delivered successfully.
1015
+ * @min 0
1016
+ */
1017
+ side_effects_dispatched: number;
1018
+ /**
1019
+ * Number of side-effects whose delivery failed (apply still succeeded).
1020
+ * @min 0
1021
+ */
1022
+ side_effects_failed: number;
1023
+ } | {
1024
+ /** Names of the unbound required parameters. */
1025
+ missing: string[];
1026
+ outcome: "suspended";
1027
+ } | {
1028
+ outcome: "rejected";
1029
+ /** Human-readable reason. */
1030
+ reason: string;
1031
+ } | {
1032
+ outcome: "rolled_back";
1033
+ /** Human-readable cause. */
1034
+ reason: string;
1035
+ };
869
1036
  /** Request to apply arguments to a curried function */
870
1037
  interface ApplyCurriedRequest$1 {
871
1038
  arguments: PositionalArgumentDto$1[];
@@ -1155,6 +1322,14 @@ interface AssignmentDto {
1155
1322
  * Every cell in the input grid is classified as exactly one of these.
1156
1323
  */
1157
1324
  type AssignmentStatusDto = "confirmed_true" | "confirmed_false" | "free";
1325
+ /** Request body for `POST /api/v1/feasibility/sessions/{session_id}/assumptions`. */
1326
+ interface AssumptionRequest$1 {
1327
+ /**
1328
+ * The flat decision-variable index to assume `true`.
1329
+ * @min 0
1330
+ */
1331
+ var: number;
1332
+ }
1158
1333
  /** Attention target DTO. */
1159
1334
  type AttentionTargetDto$1 = {
1160
1335
  /** @format uuid */
@@ -1649,6 +1824,28 @@ interface BeliefDto$1 {
1649
1824
  }
1650
1825
  /** Binary operator for expressions */
1651
1826
  type BinaryOperatorDto$1 = "Add" | "Subtract" | "Multiply" | "Divide";
1827
+ /** Request to bind a sort to a SQL table. */
1828
+ interface BindSortRequest$1 {
1829
+ /** Column mappings: feature name to column spec. */
1830
+ columns: ColumnMappingDto$1[];
1831
+ /** Primary key column names. */
1832
+ key_columns?: string[];
1833
+ /** Sort name to bind. */
1834
+ sort_name: string;
1835
+ /** External source identifier. */
1836
+ source_id: string;
1837
+ /** SQL table name. */
1838
+ table_name: string;
1839
+ }
1840
+ /** Response from binding a sort to a SQL table. */
1841
+ interface BindSortResponse$1 {
1842
+ /** Whether the binding was successful. */
1843
+ bound: boolean;
1844
+ /** Sort name that was bound. */
1845
+ sort_name: string;
1846
+ /** SQL table the sort is bound to. */
1847
+ table_name: string;
1848
+ }
1652
1849
  /** Request to bind a term in the session */
1653
1850
  interface BindTermRequest$1 {
1654
1851
  features?: FeatureBindingDto$1[];
@@ -1722,6 +1919,22 @@ interface BindingDto$1 {
1722
1919
  */
1723
1920
  variable_term_id: string;
1724
1921
  }
1922
+ /** Summary of a single sort-table binding. */
1923
+ interface BindingSummaryDto$1 {
1924
+ /**
1925
+ * Number of bound features/columns.
1926
+ * @min 0
1927
+ */
1928
+ feature_count: number;
1929
+ /** Primary key column names. */
1930
+ key_columns: string[];
1931
+ /** Sort ID (UUID string). */
1932
+ sort_id: string;
1933
+ /** External source identifier. */
1934
+ source_id: string;
1935
+ /** SQL table name. */
1936
+ table_name: string;
1937
+ }
1725
1938
  /** Response with current bindings */
1726
1939
  interface BindingsResponse$1 {
1727
1940
  bindings: TermBindingDto$1[];
@@ -1748,6 +1961,64 @@ type BitwiseResponse = {
1748
1961
  reason: string;
1749
1962
  status: "fail";
1750
1963
  };
1964
+ /**
1965
+ * A boolean-valued expression for the [`TypedConstraintDto::Arithmetic`] escape
1966
+ * hatch (mirrors the domain `BoolExpr`). Tagged by `type`. `not`/`implies`/
1967
+ * `iff`/`xor` are convenience nodes; an empty `and` is true, an empty `or` is
1968
+ * false.
1969
+ */
1970
+ type BoolExprDto = {
1971
+ type: "lit";
1972
+ /** The polarity. */
1973
+ value: boolean;
1974
+ /**
1975
+ * The flat decision-variable index.
1976
+ * @min 0
1977
+ */
1978
+ var: number;
1979
+ } | {
1980
+ type: "const";
1981
+ /** The truth value. */
1982
+ value: boolean;
1983
+ } | {
1984
+ /** The negated expression. */
1985
+ expr: BoolExprDto;
1986
+ type: "not";
1987
+ } | {
1988
+ /** The conjuncts. */
1989
+ exprs: BoolExprDto[];
1990
+ type: "and";
1991
+ } | {
1992
+ /** The disjuncts. */
1993
+ exprs: BoolExprDto[];
1994
+ type: "or";
1995
+ } | {
1996
+ /** Antecedent. */
1997
+ left: BoolExprDto;
1998
+ /** Consequent. */
1999
+ right: BoolExprDto;
2000
+ type: "implies";
2001
+ } | {
2002
+ /** Left operand. */
2003
+ left: BoolExprDto;
2004
+ /** Right operand. */
2005
+ right: BoolExprDto;
2006
+ type: "iff";
2007
+ } | {
2008
+ /** Left operand. */
2009
+ left: BoolExprDto;
2010
+ /** Right operand. */
2011
+ right: BoolExprDto;
2012
+ type: "xor";
2013
+ } | {
2014
+ /** Left-hand linear expression. */
2015
+ left: LinExprDto;
2016
+ /** The relational operator. */
2017
+ op: RelOpDto$1;
2018
+ /** Right-hand linear expression. */
2019
+ right: LinExprDto;
2020
+ type: "compare";
2021
+ };
1751
2022
  /**
1752
2023
  * API representation of an OSF Bound Constraint
1753
2024
  *
@@ -2506,6 +2777,70 @@ interface ClarificationQuestionDto$1 {
2506
2777
  question: string;
2507
2778
  type: string;
2508
2779
  }
2780
+ /** Per-cell trichotomy, partitioned by class (flat cell indices). */
2781
+ interface ClassificationDto {
2782
+ /** Cells in no valid completion — gray these out. */
2783
+ confirmed_false: number[];
2784
+ /** Cells in every valid completion — forced/highlighted. */
2785
+ confirmed_true: number[];
2786
+ /** Cells that are a free choice. */
2787
+ sometimes: number[];
2788
+ }
2789
+ interface ClassificationLevelDto$1 {
2790
+ /**
2791
+ * @format int32
2792
+ * @min 0
2793
+ */
2794
+ level: number;
2795
+ name: string;
2796
+ }
2797
+ /**
2798
+ * Request body for `POST /api/v1/solver/classify`. Same fields as
2799
+ * `SolveProblemRequest` plus an optional list of variable names whose
2800
+ * classification is requested; omitting it classifies every binary
2801
+ * variable.
2802
+ */
2803
+ interface ClassifyProblemRequest$1 {
2804
+ constraints?: LinearConstraint$2[];
2805
+ /** @format double */
2806
+ gap_tolerance?: number | null;
2807
+ /**
2808
+ * Backend-selection hint. `Auto` (default) routes CP-SAT for fully
2809
+ * discrete problems and HiGHS for any continuous variable.
2810
+ */
2811
+ hint?: SolverHint$1;
2812
+ objective?: null | Objective$1;
2813
+ /**
2814
+ * @format int64
2815
+ * @min 0
2816
+ */
2817
+ time_limit_ms?: number | null;
2818
+ variables: VariableSpec$1[];
2819
+ /**
2820
+ * Variables to classify. Omit (or send empty) to classify every
2821
+ * binary variable.
2822
+ */
2823
+ variables_of_interest?: any[] | null;
2824
+ }
2825
+ /** Response body for `POST /api/v1/solver/classify`. */
2826
+ interface ClassifyProblemResponse$1 {
2827
+ /**
2828
+ * Variable-name → baseline solve value. Useful for displaying a
2829
+ * concrete witness alongside the classification.
2830
+ */
2831
+ baseline_values: Record<string, number>;
2832
+ /**
2833
+ * Variable-name → classification. Empty when baseline is
2834
+ * infeasible.
2835
+ */
2836
+ classifications: Record<string, VariableClassification$1>;
2837
+ message?: string | null;
2838
+ /** @format double */
2839
+ solve_time_ms: number;
2840
+ solver: string;
2841
+ /** Status reported by the solver. */
2842
+ status: SolutionStatus$1;
2843
+ }
2509
2844
  /** Request for safety classification (Phase 5). */
2510
2845
  interface ClassifySafetyRequest$1 {
2511
2846
  /** Text to classify for safety violations. */
@@ -2674,6 +3009,21 @@ interface CollectionResponse {
2674
3009
  /** Collection DTO */
2675
3010
  collection: CollectionDto$1;
2676
3011
  }
3012
+ /** Mapping between an OSF feature and a SQL column. */
3013
+ interface ColumnMappingDto$1 {
3014
+ /** SQL column name. */
3015
+ column: string;
3016
+ /** OSF feature name. */
3017
+ feature: string;
3018
+ /** Whether the column is nullable. */
3019
+ nullable?: boolean;
3020
+ /**
3021
+ * SQL type (e.g., "VARCHAR(255)", "INTEGER"). Omit or leave empty to have
3022
+ * the server introspect the real type from the registered source's live
3023
+ * schema (falls back to TEXT if the source isn't connected).
3024
+ */
3025
+ sql_type?: string;
3026
+ }
2677
3027
  /**
2678
3028
  * Request body for `POST /api/v1/flow-networks/{id}/commit` —
2679
3029
  * structural mutations applied in a single atomic step.
@@ -3211,6 +3561,8 @@ type ConstraintInputDto$1 = {
3211
3561
  relation: string;
3212
3562
  type: "Allen";
3213
3563
  };
3564
+ /** Comparison sense of a linear constraint. */
3565
+ type ConstraintSense$1 = "leq" | "geq" | "eq";
3214
3566
  /**
3215
3567
  * Session status information
3216
3568
  *
@@ -3771,6 +4123,66 @@ interface CreateStoreTermRequest$1 {
3771
4123
  features?: Record<string, object>;
3772
4124
  sort_id: string;
3773
4125
  }
4126
+ /**
4127
+ * Request to explicitly provision a new tenant.
4128
+ *
4129
+ * Until now tenants came into existence only implicitly, on first write. This
4130
+ * makes provisioning explicit: it materialises the tenant's inference state and
4131
+ * per-tenant sort hierarchy up front, and optionally seeds initial sorts. The
4132
+ * seeded sorts are real lattice insertions (not placeholders) — full
4133
+ * Marketplace-pack seeding is layered on later via the pack installer.
4134
+ */
4135
+ interface CreateTenantRequest$1 {
4136
+ /**
4137
+ * Optional owner user UUID for the tenant's initial state. Generated when omitted.
4138
+ * @format uuid
4139
+ */
4140
+ owner_user_id?: string | null;
4141
+ /** Optional sort names to seed into the new tenant's hierarchy as top-level sorts. */
4142
+ seed_sorts?: string[];
4143
+ /**
4144
+ * Optional explicit tenant UUID. A fresh UUID is generated when omitted.
4145
+ * @format uuid
4146
+ */
4147
+ tenant_id?: string | null;
4148
+ }
4149
+ /** Response for the create-tenant operation. */
4150
+ interface CreateTenantResponse$1 {
4151
+ /** `true` if the tenant was newly created; `false` if it already existed (idempotent). */
4152
+ created: boolean;
4153
+ /**
4154
+ * Number of seed sorts successfully inserted into the tenant hierarchy.
4155
+ * @min 0
4156
+ */
4157
+ seeded_sorts: number;
4158
+ /** The provisioned tenant UUID (echoes the request or the generated value). */
4159
+ tenant_id: string;
4160
+ }
4161
+ /** Request to create a term within a specific collection */
4162
+ interface CreateTermInCollectionRequest$1 {
4163
+ /**
4164
+ * Collection ID to add the term to
4165
+ * @format uuid
4166
+ */
4167
+ collection_id: string;
4168
+ /** Term features */
4169
+ features: Record<string, ValueDto$1>;
4170
+ /**
4171
+ * Namespace ID
4172
+ * @format uuid
4173
+ */
4174
+ namespace_id: string;
4175
+ /**
4176
+ * Sort ID for the term
4177
+ * @format uuid
4178
+ */
4179
+ sort_id: string;
4180
+ /**
4181
+ * Tenant ID
4182
+ * @format uuid
4183
+ */
4184
+ tenant_id: string;
4185
+ }
3774
4186
  /**
3775
4187
  * Request to create a term
3776
4188
  *
@@ -5535,6 +5947,11 @@ interface EmbeddingVerificationResponse$1 {
5535
5947
  /** Volume-specificity verification result. */
5536
5948
  specificity?: null | SpecificityDto$1;
5537
5949
  }
5950
+ /** Response to ending a session. */
5951
+ interface EndSchedulingResponse$1 {
5952
+ /** Whether a live session was removed. */
5953
+ ended: boolean;
5954
+ }
5538
5955
  /** Enriched health response with component statuses and build info */
5539
5956
  interface EnrichedHealthResponse$1 {
5540
5957
  /** Build info DTO */
@@ -6218,6 +6635,19 @@ interface ExternalActionSummaryDto$1 {
6218
6635
  /** Webhook URL */
6219
6636
  webhook_url: string;
6220
6637
  }
6638
+ /**
6639
+ * SKOS external-ontology alignment surfaced on a [`SortDto`] — e.g. a BFO/CCO
6640
+ * correspondence attached by the upper-ontology aligner. This makes each
6641
+ * alignment a live, queryable property of the sort, not a separate export.
6642
+ */
6643
+ interface ExternalMatchDto$1 {
6644
+ /** SKOS mapping relation: `exactMatch` | `closeMatch` | `broadMatch` | `narrowMatch`. */
6645
+ match_type: string;
6646
+ /** CURIE of the aligned external concept (e.g. `obo:BFO_0000023`). */
6647
+ ontology_id: string;
6648
+ /** How the match was discovered: `grounding` | `manual` | `import` | `inferred`. */
6649
+ source: string;
6650
+ }
6221
6651
  /**
6222
6652
  * Request to extract named entities from text using the tenant's sort hierarchy as labels.
6223
6653
  *
@@ -6583,10 +7013,16 @@ type FeatureConstraintDto = {
6583
7013
  interface FeatureDescriptorDto$1 {
6584
7014
  /** Custom OWL annotations for this feature (e.g., isIdentifier, unit, enumValues) */
6585
7015
  annotations?: Record<string, string>;
6586
- /** Optional constraint on the feature value */
7016
+ /**
7017
+ * Optional constraint on the feature value. Defaults to `None`
7018
+ * when absent so callers needn't send an explicit null.
7019
+ */
6587
7020
  constraint?: null | ConstraintDto$1;
6588
7021
  /**
6589
- * Expected sort for the feature value (for nested PSI-terms)
7022
+ * Expected sort for the feature value (for nested PSI-terms).
7023
+ * Optional — omit for a primitive/un-typed feature. Defaults to
7024
+ * `None` when absent from the request body so a minimal
7025
+ * `{"name", "required"}` descriptor deserializes.
6590
7026
  * @format uuid
6591
7027
  */
6592
7028
  expected_sort?: string | null;
@@ -6615,6 +7051,9 @@ interface FeatureDescriptorDto$1 {
6615
7051
  type FeatureInputValueDto$1 = {
6616
7052
  /** @format uuid */
6617
7053
  term_id: string;
7054
+ } | {
7055
+ /** @format uuid */
7056
+ sort_ref: string;
6618
7057
  } | {
6619
7058
  name: string;
6620
7059
  } | {
@@ -7108,6 +7547,15 @@ interface ForwardChainResponse$1 {
7108
7547
  */
7109
7548
  total_facts: number;
7110
7549
  }
7550
+ /** One migration item a human should review. */
7551
+ interface FoundryReviewItemDto$1 {
7552
+ /** What kind of item (`property_type`, `action_type`). */
7553
+ kind: string;
7554
+ /** The item's apiName. */
7555
+ name: string;
7556
+ /** Why it needs review. */
7557
+ reason: string;
7558
+ }
7111
7559
  /** Function body - what to compute */
7112
7560
  type FunctionBodyDto$1 = {
7113
7561
  type: "Value";
@@ -7129,6 +7577,57 @@ interface FunctionClauseDto$1 {
7129
7577
  guard?: null | GuardDto;
7130
7578
  parameters: PatternDto$1[];
7131
7579
  }
7580
+ /**
7581
+ * Typed signature summary for a single registered function.
7582
+ *
7583
+ * This is the OSF/LIFE realisation of a Palantir "Function Type" entry: a
7584
+ * function is a Ψ-term in the function sub-lattice, and its signature is the
7585
+ * arity plus the number of pattern-matched clauses (LIFE-style bidirectional
7586
+ * evaluation). Returned by the `GET /api/v1/functions` discovery endpoint so a
7587
+ * client (or the Studio Functions page) can enumerate callable functions
7588
+ * without evaluating them.
7589
+ */
7590
+ interface FunctionSummaryDto$1 {
7591
+ /**
7592
+ * Number of named arguments the function accepts.
7593
+ * @min 0
7594
+ */
7595
+ arity: number;
7596
+ /**
7597
+ * Number of pattern-matched clauses (tried in order during evaluation).
7598
+ * @min 0
7599
+ */
7600
+ clauses_count: number;
7601
+ /** Function name (the key used by `POST /functions/evaluate`). */
7602
+ name: string;
7603
+ }
7604
+ /** One projected function type. */
7605
+ interface FunctionTypeDto {
7606
+ /** Function name (Palantir function-type apiName). */
7607
+ apiName: string;
7608
+ /**
7609
+ * Number of named-feature parameters (the function's arity).
7610
+ * @min 0
7611
+ */
7612
+ arity: number;
7613
+ /**
7614
+ * Number of defining clauses (homoiconic rules) backing the function.
7615
+ * @min 0
7616
+ */
7617
+ clausesCount: number;
7618
+ /** Human-facing name (the function name). */
7619
+ displayName: string;
7620
+ }
7621
+ /** Response for `GET /api/v1/ontology/function-types`. */
7622
+ interface FunctionTypeListResponse$1 {
7623
+ /**
7624
+ * Number of function types returned.
7625
+ * @min 0
7626
+ */
7627
+ count: number;
7628
+ /** The projected function types, ordered by apiName. */
7629
+ functionTypes: FunctionTypeDto[];
7630
+ }
7132
7631
  /** Value type for literals */
7133
7632
  type FunctionValueDto$1 = {
7134
7633
  type: "Integer";
@@ -7595,6 +8094,16 @@ interface GFlowNetTrainResponse$1 {
7595
8094
  /** Whether training was triggered. */
7596
8095
  triggered: boolean;
7597
8096
  }
8097
+ interface GateRequest$1 {
8098
+ clearance: string;
8099
+ marking: string;
8100
+ }
8101
+ interface GateResponse$1 {
8102
+ clearance: string;
8103
+ decision: string;
8104
+ dominates: boolean;
8105
+ marking: string;
8106
+ }
7598
8107
  /**
7599
8108
  * GeneralConstraintDto
7600
8109
  * General constraint: Arithmetic, Basic {constraint_type, value}, Conjunction {constraints}, or Disjunction {constraints}
@@ -7848,6 +8357,27 @@ interface GenerationReportDto$1 {
7848
8357
  */
7849
8358
  validation_failures: number;
7850
8359
  }
8360
+ /**
8361
+ * Request body for `POST /api/v1/feasibility/sessions`. The
8362
+ * `choice_points` define the flat decision-variable layout (a binary choice ⇒
8363
+ * one boolean; an `n`-way choice ⇒ `n` one-hot vars + an implied exactly-one);
8364
+ * `constraints` are posted over those variables.
8365
+ */
8366
+ interface GenericModelRequest$1 {
8367
+ /** The decisions to explore, in order. Each must have `alternative_count ≥ 2`. */
8368
+ choice_points: ChoicePointDto$1[];
8369
+ /** The typed constraints over the flat decision variables. */
8370
+ constraints?: TypedConstraintDto[];
8371
+ /**
8372
+ * Optional linear objective to **maximize** (`Σ weight·var` over the true
8373
+ * decision variables), as `(var, weight)` terms. Empty ⇒ pure-feasibility
8374
+ * mode (the trichotomy over all feasible completions). Non-empty ⇒ optimize
8375
+ * mode: the trichotomy is taken over the **maximum-weight** completions and
8376
+ * the responses carry `total_score` (the optimum). A var absent from the
8377
+ * list has weight `0`; duplicate vars sum.
8378
+ */
8379
+ objective?: LinTermDto[];
8380
+ }
7851
8381
  /** Request to get agent state. */
7852
8382
  interface GetAgentStateRequest$1 {
7853
8383
  /**
@@ -8056,6 +8586,16 @@ interface GetResiduationsResponse$1 {
8056
8586
  residuations: ResiduationDetailDto$1[];
8057
8587
  term_id: string;
8058
8588
  }
8589
+ /** Response listing all rules for a tenant. */
8590
+ interface GetRulesResponse$1 {
8591
+ /**
8592
+ * Total count.
8593
+ * @min 0
8594
+ */
8595
+ count: number;
8596
+ /** The rules. */
8597
+ rules: RuleEntryDto$1[];
8598
+ }
8059
8599
  /** Response for GET /api/v1/scenarios/:id — retrieve a stored scenario. */
8060
8600
  interface GetScenarioResponse$1 {
8061
8601
  /** Agent TermId (if an agent was created). */
@@ -8508,6 +9048,28 @@ interface GroundTruthEntry$1 {
8508
9048
  term_id: string;
8509
9049
  }
8510
9050
  type GroundTruthStatus$1 = "Pending" | "Validated" | "Refuted" | "Unknown";
9051
+ /** Response from grounded NL schema generation. */
9052
+ interface GroundedSchemaResponse$1 {
9053
+ /**
9054
+ * Number of inference tools.
9055
+ * @min 0
9056
+ */
9057
+ inference_tools: number;
9058
+ /** Human-readable ontology summary. */
9059
+ ontology_summary: string;
9060
+ /**
9061
+ * Number of query tools generated.
9062
+ * @min 0
9063
+ */
9064
+ query_tools: number;
9065
+ /** System prompt for LLM grounding. */
9066
+ system_prompt: string;
9067
+ /**
9068
+ * Number of write tools generated.
9069
+ * @min 0
9070
+ */
9071
+ write_tools: number;
9072
+ }
8511
9073
  /** Statistics for entity grounding (linking to external ontologies) */
8512
9074
  interface GroundingStatsDto$1 {
8513
9075
  /**
@@ -8827,6 +9389,43 @@ interface ImpliesResponse$1 {
8827
9389
  /** True if implication holds (antecedent fails OR consequent succeeds) */
8828
9390
  result: boolean;
8829
9391
  }
9392
+ /** Request to import a Foundry ontology export (Q1.8). */
9393
+ interface ImportFoundryRequest$1 {
9394
+ /** The Foundry ontology export, as JSON. */
9395
+ foundry_json: string;
9396
+ }
9397
+ /** Response from a Foundry import: what was created + a mapped/review-needed report. */
9398
+ interface ImportFoundryResponse$1 {
9399
+ /**
9400
+ * Interface types mapped to (super) sorts.
9401
+ * @min 0
9402
+ */
9403
+ mapped_interface_types: number;
9404
+ /**
9405
+ * Link types mapped to referring features.
9406
+ * @min 0
9407
+ */
9408
+ mapped_links: number;
9409
+ /**
9410
+ * Object types mapped to sorts.
9411
+ * @min 0
9412
+ */
9413
+ mapped_object_types: number;
9414
+ /**
9415
+ * Properties mapped to features.
9416
+ * @min 0
9417
+ */
9418
+ mapped_properties: number;
9419
+ /**
9420
+ * Number of relations discovered from link types.
9421
+ * @min 0
9422
+ */
9423
+ relations_discovered: number;
9424
+ /** Items imported with a caveat or skipped — need human review. */
9425
+ review_needed: FoundryReviewItemDto$1[];
9426
+ /** Names of sorts created (object + interface types). */
9427
+ sorts_created: string[];
9428
+ }
8830
9429
  /** Request to import a module */
8831
9430
  interface ImportModuleRequest$1 {
8832
9431
  /** Optional alias for the import */
@@ -8843,6 +9442,23 @@ interface ImportModuleResponse$1 {
8843
9442
  importer_module: string;
8844
9443
  success: boolean;
8845
9444
  }
9445
+ /** Request to import an OWL/RDF ontology into the sort hierarchy. */
9446
+ interface ImportOwlRequest$1 {
9447
+ /** OWL/RDF XML content to import. */
9448
+ rdf_xml: string;
9449
+ }
9450
+ /** Response from an OWL ontology import. */
9451
+ interface ImportOwlResponse$1 {
9452
+ /** Names of reified sorts created (many-to-many with attributes). */
9453
+ reified_sorts_created: string[];
9454
+ /**
9455
+ * Number of relations discovered from OWL object properties.
9456
+ * @min 0
9457
+ */
9458
+ relations_discovered: number;
9459
+ /** Names of sorts created from OWL classes. */
9460
+ sorts_created: string[];
9461
+ }
8846
9462
  /** A message in the inbox. */
8847
9463
  interface InboxMessageDto {
8848
9464
  /** Message content (arbitrary JSON) */
@@ -9610,6 +10226,29 @@ interface IntentionDto$1 {
9610
10226
  */
9611
10227
  status?: string;
9612
10228
  }
10229
+ /** One projected interface type — a non-maximal sort. */
10230
+ interface InterfaceTypeDto {
10231
+ /** Sort name (Palantir interface-type apiName). */
10232
+ apiName: string;
10233
+ /** Sort description, if any. */
10234
+ description?: string | null;
10235
+ /** Human-facing name (the sort name). */
10236
+ displayName: string;
10237
+ /** apiNames of supersorts that are themselves interfaces (extended interfaces). */
10238
+ extendsInterfaceTypes: string[];
10239
+ /** The appropriate scalar features that form the inherited contract. */
10240
+ properties: PropertyDto[];
10241
+ }
10242
+ /** Response for `GET /api/v1/ontology/interface-types`. */
10243
+ interface InterfaceTypeListResponse$1 {
10244
+ /**
10245
+ * Number of interface types returned.
10246
+ * @min 0
10247
+ */
10248
+ count: number;
10249
+ /** The projected interface types. */
10250
+ interfaceTypes: InterfaceTypeDto[];
10251
+ }
9613
10252
  interface InterventionObservationRequest$1 {
9614
10253
  /** Variables that changed after intervention */
9615
10254
  changed_variables: string[];
@@ -10352,6 +10991,73 @@ interface LeastSortsResponse {
10352
10991
  /** @format uuid */
10353
10992
  tenant_id: string;
10354
10993
  }
10994
+ /**
10995
+ * An integer-valued linear expression `constant + Σ coeff·var` over boolean
10996
+ * cells (each cell contributes its coefficient when set).
10997
+ */
10998
+ interface LinExprDto {
10999
+ /**
11000
+ * The constant addend.
11001
+ * @format int64
11002
+ */
11003
+ constant?: number;
11004
+ /** The `coeff·var` terms. */
11005
+ terms?: LinTermDto[];
11006
+ }
11007
+ /** One term `coeff · var` of a [`LinExprDto`]. */
11008
+ interface LinTermDto {
11009
+ /**
11010
+ * The integer coefficient.
11011
+ * @format int64
11012
+ */
11013
+ coeff: number;
11014
+ /**
11015
+ * The flat decision-variable index.
11016
+ * @min 0
11017
+ */
11018
+ var: number;
11019
+ }
11020
+ /**
11021
+ * A linear constraint `Σ coef_i · x_i (sense) rhs`. Variables not
11022
+ * referenced in `coefficients` are treated as if their coefficient is
11023
+ * zero.
11024
+ */
11025
+ interface LinearConstraint$2 {
11026
+ /** Variable-name → coefficient. */
11027
+ coefficients: Record<string, number>;
11028
+ /** Optional caller-supplied label, returned in error reports. */
11029
+ name?: string | null;
11030
+ /**
11031
+ * Right-hand side.
11032
+ * @format double
11033
+ */
11034
+ rhs: number;
11035
+ /** Comparison sense. */
11036
+ sense: ConstraintSense$1;
11037
+ }
11038
+ /** One projected link type — a referring feature from one sort to another. */
11039
+ interface LinkTypeDto {
11040
+ /** Qualified apiName `"<sort>.<feature>"`. */
11041
+ apiName: string;
11042
+ /** Cardinality — `ONE`, because OSF features are functional. */
11043
+ cardinality: string;
11044
+ /** The feature name. */
11045
+ displayName: string;
11046
+ /** The target object type (the feature's value sort). */
11047
+ linkedObjectTypeApiName: string;
11048
+ /** The source object type (the sort declaring the feature). */
11049
+ objectTypeApiName: string;
11050
+ }
11051
+ /** Response for `GET /api/v1/ontology/link-types`. */
11052
+ interface LinkTypeListResponse$1 {
11053
+ /**
11054
+ * Number of link types returned.
11055
+ * @min 0
11056
+ */
11057
+ count: number;
11058
+ /** The projected link types. */
11059
+ linkTypes: LinkTypeDto[];
11060
+ }
10355
11061
  /** Response for listing pending action reviews */
10356
11062
  interface ListActionReviewsResponse$1 {
10357
11063
  /** Whether there are more pages */
@@ -10374,6 +11080,11 @@ interface ListActionReviewsResponse$1 {
10374
11080
  */
10375
11081
  total: number;
10376
11082
  }
11083
+ /** Response listing all sort-table bindings. */
11084
+ interface ListBindingsResponse$1 {
11085
+ /** Active sort-table bindings. */
11086
+ bindings: BindingSummaryDto$1[];
11087
+ }
10377
11088
  /** Request to list available functions */
10378
11089
  interface ListEvalFunctionsRequest$1 {
10379
11090
  /** Optional category filter */
@@ -10398,6 +11109,16 @@ interface ListExternalActionsResponse$1 {
10398
11109
  */
10399
11110
  total: number;
10400
11111
  }
11112
+ /** Response from listing all functions registered for a tenant. */
11113
+ interface ListFunctionsResponse$1 {
11114
+ /** All functions registered for the requesting tenant, sorted by name. */
11115
+ functions: FunctionSummaryDto$1[];
11116
+ /**
11117
+ * Total count (equals `functions.len()`), surfaced for convenience.
11118
+ * @min 0
11119
+ */
11120
+ total: number;
11121
+ }
10401
11122
  /**
10402
11123
  * Response for listing saved goals.
10403
11124
  *
@@ -10438,6 +11159,9 @@ interface ListIngestionSessionsResponse$1 {
10438
11159
  */
10439
11160
  total: number;
10440
11161
  }
11162
+ interface ListLevelsResponse$1 {
11163
+ levels: ClassificationLevelDto$1[];
11164
+ }
10441
11165
  /** Response for listing patterns. */
10442
11166
  interface ListPatternsResponse$1 {
10443
11167
  /**
@@ -10526,6 +11250,16 @@ interface ListTenantsResponse$1 {
10526
11250
  /** All tenants that have data in the system */
10527
11251
  tenants: TenantInfo[];
10528
11252
  }
11253
+ /** A single literal `var = value` for a [`TypedConstraintDto::Forbid`] clause. */
11254
+ interface LitDto {
11255
+ /** The required polarity (`true` ⇒ the var is set, `false` ⇒ unset). */
11256
+ value: boolean;
11257
+ /**
11258
+ * The flat decision-variable index.
11259
+ * @min 0
11260
+ */
11261
+ var: number;
11262
+ }
10529
11263
  /**
10530
11264
  * A literal for NAF queries - a term with optional negation.
10531
11265
  *
@@ -10605,34 +11339,21 @@ interface MarkdownDocumentDto$1 {
10605
11339
  /** Optional metadata about the document */
10606
11340
  metadata?: null | DocumentMetadataDto$1;
10607
11341
  }
10608
- /** A matched entity from pure OSF search */
11342
+ /** An entity matched while resolving a stage. */
10609
11343
  interface MatchedEntityDto$1 {
10610
11344
  /**
10611
- * Community this entity belongs to
10612
- * @format uuid
10613
- */
10614
- community_id: string;
10615
- /** Key features as strings */
10616
- features: Record<string, string>;
10617
- /**
10618
- * Match degree (0.0-1.0)
11345
+ * Match confidence in [0, 1].
10619
11346
  * @format double
10620
11347
  */
10621
- match_degree: number;
10622
- /** Why this entity matched */
10623
- match_reason?: string | null;
10624
- /** Human-readable name (if available) */
10625
- name?: string | null;
10626
- /**
10627
- * Sort ID
10628
- * @format uuid
10629
- */
10630
- sort_id: string;
10631
- /**
10632
- * Term ID
10633
- * @format uuid
10634
- */
10635
- term_id: string;
11348
+ confidence: number;
11349
+ /** Why it matched (e.g. "exact", "fuzzy_glb", "salience"). */
11350
+ match_reason: string;
11351
+ /** Display label of the entity. */
11352
+ name: string;
11353
+ /** Sort name the entity belongs to. */
11354
+ sort_name: string;
11355
+ /** Optional TermId (string form). */
11356
+ term_id?: string | null;
10636
11357
  }
10637
11358
  /**
10638
11359
  * Snapshot of the per-tenant Phase 2 materialization sentinel for the
@@ -10724,6 +11445,59 @@ interface MaterializationSummaryDto$1 {
10724
11445
  */
10725
11446
  webhook_actions_created: number;
10726
11447
  }
11448
+ /**
11449
+ * Request body for `POST /api/v1/scenarios/materialize`.
11450
+ *
11451
+ * Materializes an already-generated scenario (e.g. the `scenario` payload from
11452
+ * `POST /api/v1/ontology/generate`) into the caller's knowledge base, exactly
11453
+ * as reviewed — sorts, belief instances, rules, goal, and the ontology-declared
11454
+ * engine pipeline. Unlike `create_scenario`, this does **not** call the LLM, so
11455
+ * the materialized graph is byte-for-byte what the client reviewed.
11456
+ */
11457
+ interface MaterializeScenarioRequest$1 {
11458
+ /** The domain `GeneratedScenario` JSON to materialize verbatim. */
11459
+ scenario: any;
11460
+ }
11461
+ /** Response for `POST /api/v1/scenarios/materialize`. */
11462
+ interface MaterializeScenarioResponse$1 {
11463
+ /**
11464
+ * Number of belief (instance) Ψ-terms created.
11465
+ * @min 0
11466
+ */
11467
+ beliefs_created: number;
11468
+ /**
11469
+ * Number of generic constraint terms created.
11470
+ * @min 0
11471
+ */
11472
+ constraints_created: number;
11473
+ /**
11474
+ * Number of ontology-declared `pipeline_stage` control-plane terms created.
11475
+ * @min 0
11476
+ */
11477
+ pipeline_stages_created: number;
11478
+ /**
11479
+ * Number of OSF relation edges (`Value::Reference` features) linking instances.
11480
+ * @min 0
11481
+ */
11482
+ relations_created: number;
11483
+ /**
11484
+ * Number of rule Ψ-terms created.
11485
+ * @min 0
11486
+ */
11487
+ rules_created: number;
11488
+ /**
11489
+ * Number of ontology-declared `llm_sensor_point` control-plane terms created.
11490
+ * @min 0
11491
+ */
11492
+ sensor_points_created: number;
11493
+ /**
11494
+ * Number of sorts created or reused.
11495
+ * @min 0
11496
+ */
11497
+ sorts_created: number;
11498
+ /** Non-fatal materialization warnings. */
11499
+ warnings: string[];
11500
+ }
10727
11501
  /** Request for math function */
10728
11502
  interface MathFunctionRequest$1 {
10729
11503
  /** Arguments (some may be uninstantiated for bidirectional solving) */
@@ -10973,6 +11747,81 @@ interface MetaSortsResponse$1 {
10973
11747
  * @format uuid
10974
11748
  */
10975
11749
  equality_constraint: string;
11750
+ /**
11751
+ * FD all-different constraint over a list of variables
11752
+ * @format uuid
11753
+ */
11754
+ fd_all_different_constraint: string;
11755
+ /**
11756
+ * FD arithmetic constraint
11757
+ * @format uuid
11758
+ */
11759
+ fd_arithmetic_constraint: string;
11760
+ /**
11761
+ * FD circuit (Hamiltonian) constraint
11762
+ * @format uuid
11763
+ */
11764
+ fd_circuit_constraint: string;
11765
+ /**
11766
+ * Parent sort for all CLP(FD) constraints
11767
+ * @format uuid
11768
+ */
11769
+ fd_constraint: string;
11770
+ /**
11771
+ * FD cumulative scheduling constraint
11772
+ * @format uuid
11773
+ */
11774
+ fd_cumulative_constraint: string;
11775
+ /**
11776
+ * FD disjunctive (no-overlap) constraint
11777
+ * @format uuid
11778
+ */
11779
+ fd_disjunctive_constraint: string;
11780
+ /**
11781
+ * FD domain constraint: variable ∈ [min, max]
11782
+ * @format uuid
11783
+ */
11784
+ fd_domain_constraint: string;
11785
+ /**
11786
+ * FD element constraint: list[index] = value
11787
+ * @format uuid
11788
+ */
11789
+ fd_element_constraint: string;
11790
+ /**
11791
+ * FD global-cardinality constraint
11792
+ * @format uuid
11793
+ */
11794
+ fd_global_cardinality_constraint: string;
11795
+ /**
11796
+ * FD in-set constraint: variable ∈ {values}
11797
+ * @format uuid
11798
+ */
11799
+ fd_in_constraint: string;
11800
+ /**
11801
+ * FD labeling: solve collected FD constraints
11802
+ * @format uuid
11803
+ */
11804
+ fd_labeling_constraint: string;
11805
+ /**
11806
+ * FD lex-chain constraint
11807
+ * @format uuid
11808
+ */
11809
+ fd_lex_chain_constraint: string;
11810
+ /**
11811
+ * FD reified constraint
11812
+ * @format uuid
11813
+ */
11814
+ fd_reified_constraint: string;
11815
+ /**
11816
+ * FD scalar-product constraint: Σ aᵢ·xᵢ ⋚ target
11817
+ * @format uuid
11818
+ */
11819
+ fd_scalar_product_constraint: string;
11820
+ /**
11821
+ * FD sum constraint: Σ vars ⋚ target
11822
+ * @format uuid
11823
+ */
11824
+ fd_sum_constraint: string;
10976
11825
  /**
10977
11826
  * Feature constraint (X.f .= Y)
10978
11827
  * @format uuid
@@ -10983,6 +11832,41 @@ interface MetaSortsResponse$1 {
10983
11832
  * @format uuid
10984
11833
  */
10985
11834
  findall_constraint: string;
11835
+ /**
11836
+ * Edge-classification (Dulmage-Mendelsohn) objective
11837
+ * @format uuid
11838
+ */
11839
+ flow_classify_edges_constraint: string;
11840
+ /**
11841
+ * Parent sort for all CLP(Flow) constraints
11842
+ * @format uuid
11843
+ */
11844
+ flow_constraint: string;
11845
+ /**
11846
+ * Flow-edge constraint: declares a capacitated directed edge
11847
+ * @format uuid
11848
+ */
11849
+ flow_edge_constraint: string;
11850
+ /**
11851
+ * Max-flow objective: bind `flow_value` to the source→sink flow
11852
+ * @format uuid
11853
+ */
11854
+ flow_max_constraint: string;
11855
+ /**
11856
+ * Min-cost-max-flow objective: bind flow value and total cost
11857
+ * @format uuid
11858
+ */
11859
+ flow_min_cost_max_flow_constraint: string;
11860
+ /**
11861
+ * Min-cut objective: bind cut value, edges, and partitions
11862
+ * @format uuid
11863
+ */
11864
+ flow_min_cut_constraint: string;
11865
+ /**
11866
+ * Flow-solve trigger: drains the flow store and runs the algorithm
11867
+ * @format uuid
11868
+ */
11869
+ flow_solve_constraint: string;
10986
11870
  /**
10987
11871
  * Forall constraint (universal quantification)
10988
11872
  * @format uuid
@@ -11627,7 +12511,7 @@ interface NeuroSymbolicStatusResponse$1 {
11627
12511
  status?: object | null;
11628
12512
  }
11629
12513
  /** Translation mode for NL queries */
11630
- type NlQueryMode$1 = "llm" | "constraint" | "cognitive" | "triz";
12514
+ type NlQueryMode$1 = "llm" | "constraint" | "cognitive" | "triz" | "grounded_sql";
11631
12515
  /** Natural language query request */
11632
12516
  interface NlQueryRequest$1 {
11633
12517
  /** Optional: confirm a TRIZ session (triggers invention pipeline) */
@@ -11683,7 +12567,14 @@ interface NlQueryResponse$1 {
11683
12567
  results: NlQueryResultItem$1[];
11684
12568
  /** Structured problem from TRIZ session (for user confirmation) */
11685
12569
  structured_problem?: any;
11686
- /** Whether the query was successful */
12570
+ /**
12571
+ * Whether the pipeline ran end-to-end without error.
12572
+ *
12573
+ * This is **not** a "found-results" flag — an empty `results` array
12574
+ * is a perfectly valid outcome for a query that ran fine but had
12575
+ * no matches in the term store. Use `results.is_empty()` to test
12576
+ * for empty matches, and check `error` for actual failures.
12577
+ */
11687
12578
  success: boolean;
11688
12579
  /** Tool call info (constraint mode) */
11689
12580
  tool_call?: null | ToolCallInfo$1;
@@ -11737,6 +12628,43 @@ type NumberValueDto$1 = {
11737
12628
  /** @format double */
11738
12629
  value: number;
11739
12630
  };
12631
+ /** One projected object type. */
12632
+ interface ObjectTypeDto {
12633
+ /** Sort name (Palantir object-type apiName). */
12634
+ apiName: string;
12635
+ /** Sort description, if any. */
12636
+ description?: string | null;
12637
+ /** Human-facing name (the sort name). */
12638
+ displayName: string;
12639
+ /** apiNames of the supersorts this sort refines (the interfaces it implements). */
12640
+ implementsInterfaceTypes: string[];
12641
+ /** Primary key — Ψ-terms are identified by their `TermId`. */
12642
+ primaryKey: string[];
12643
+ /** Appropriate scalar features projected as properties. */
12644
+ properties: PropertyDto[];
12645
+ /** Lifecycle status — always `ACTIVE` for a live sort. */
12646
+ status: string;
12647
+ }
12648
+ /** Response for `GET /api/v1/ontology/object-types`. */
12649
+ interface ObjectTypeListResponse$1 {
12650
+ /**
12651
+ * Number of object types returned.
12652
+ * @min 0
12653
+ */
12654
+ count: number;
12655
+ /** The projected object types. */
12656
+ objectTypes: ObjectTypeDto[];
12657
+ }
12658
+ /** Linear objective. Omit to run feasibility-only. */
12659
+ interface Objective$1 {
12660
+ coefficients?: Record<string, number>;
12661
+ /** @format double */
12662
+ constant?: number;
12663
+ /** Direction of the objective function. */
12664
+ sense: ObjectiveSense$1;
12665
+ }
12666
+ /** Direction of the objective function. */
12667
+ type ObjectiveSense$1 = "minimize" | "maximize";
11740
12668
  interface ObserveMultiRequest$1 {
11741
12669
  /** Map of variable name to value */
11742
12670
  observations: Record<string, number>;
@@ -12144,6 +13072,15 @@ interface OversightAlertDto$1 {
12144
13072
  */
12145
13073
  step_index: number;
12146
13074
  }
13075
+ /** A typed action parameter (named feature with an appropriateness type). */
13076
+ interface ParamSpecDto {
13077
+ /** Feature name. */
13078
+ name: string;
13079
+ /** Appropriateness type: `integer`, `real`, `string`, `boolean`, or `any`. */
13080
+ param_type: string;
13081
+ /** Whether the input must be bound for the action to be `Ready`. */
13082
+ required?: boolean;
13083
+ }
12147
13084
  /** Metadata extracted from a parsed document */
12148
13085
  interface ParsedDocumentMetadataDto$1 {
12149
13086
  /** Document author */
@@ -12845,6 +13782,20 @@ interface ProofTraceDto$1 {
12845
13782
  /** Suggested fixes from the proof engine */
12846
13783
  suggestions: FixSuggestionDto$1[];
12847
13784
  }
13785
+ /**
13786
+ * A projected property — one appropriate *scalar* feature of a sort.
13787
+ *
13788
+ * Referring features (whose value is another sort) are projected as
13789
+ * [`link_types`] instead, so they never appear here.
13790
+ */
13791
+ interface PropertyDto {
13792
+ /** The feature name (Palantir property apiName). */
13793
+ apiName: string;
13794
+ /** The declared value-type hint, or `"string"` when unspecified. */
13795
+ dataType: string;
13796
+ /** Whether the feature is required by the sort's appropriateness conditions. */
13797
+ required: boolean;
13798
+ }
12848
13799
  /** A single provenance entry mapping a citation to a source fact. */
12849
13800
  interface ProvenanceDto {
12850
13801
  /** Human-readable description of the source. */
@@ -13106,6 +14057,18 @@ interface ReExtractResponse {
13106
14057
  */
13107
14058
  pending_review_count: number;
13108
14059
  }
14060
+ interface ReadableTermDto$1 {
14061
+ id: string;
14062
+ marking: string;
14063
+ }
14064
+ interface ReadableTermsResponse$1 {
14065
+ clearance: string;
14066
+ readable: ReadableTermDto$1[];
14067
+ /** @min 0 */
14068
+ readable_count: number;
14069
+ /** @min 0 */
14070
+ withheld_count: number;
14071
+ }
13109
14072
  /** Response payload for `POST /api/v1/admin/derived-facts/rebuild/{tenant_id}`. */
13110
14073
  interface RebuildDerivedFactsResponse {
13111
14074
  /**
@@ -13649,7 +14612,7 @@ interface ResiduationGoalDto$1 {
13649
14612
  result_target?: string | null;
13650
14613
  }
13651
14614
  /** Kind of residuation to visualize */
13652
- type ResiduationKind$1 = "inference" | "fuzzy" | "extraction" | "all";
14615
+ type ResiduationKind$1 = "inference" | "fuzzy" | "extraction" | "naf_failure" | "all";
13653
14616
  /** Request for residuation check */
13654
14617
  interface ResiduationRequest$1 {
13655
14618
  /**
@@ -14511,6 +15474,23 @@ interface RuleDto$1 {
14511
15474
  id: string;
14512
15475
  is_fact: boolean;
14513
15476
  }
15477
+ /** A single rule entry with head, body, and optional certainty. */
15478
+ interface RuleEntryDto$1 {
15479
+ /** The body (antecedents) of the rule. */
15480
+ body: PsiTermDto$1[];
15481
+ /**
15482
+ * Optional certainty/confidence for the rule.
15483
+ * @format double
15484
+ */
15485
+ certainty?: number | null;
15486
+ /** The head (consequent) of the rule. */
15487
+ head: PsiTermDto$1;
15488
+ /**
15489
+ * Rule term ID.
15490
+ * @format uuid
15491
+ */
15492
+ rule_id: string;
15493
+ }
14514
15494
  /** Response with rule store info */
14515
15495
  interface RuleStoreResponse$1 {
14516
15496
  /** @min 0 */
@@ -14661,6 +15641,26 @@ interface ScenarioSummaryDto$1 {
14661
15641
  */
14662
15642
  sorts_created: number;
14663
15643
  }
15644
+ /**
15645
+ * Response to a pin: the cells whose class changed, plus the full updated
15646
+ * classification for convenience.
15647
+ */
15648
+ interface SchedulingDeltaResponse$1 {
15649
+ /** The full classification after the pin. */
15650
+ classification: ClassificationDto;
15651
+ /** Cells that became `confirmed_false` on this pin. */
15652
+ newly_confirmed_false: number[];
15653
+ /** Cells that became `confirmed_true` on this pin (incl. the pinned cell). */
15654
+ newly_confirmed_true: number[];
15655
+ /**
15656
+ * In optimize mode, the optimum `Σ weight·var` after this assumption;
15657
+ * absent for pure-feasibility models. The optimum can drop as pins shrink
15658
+ * the optimal set, so always trust `classification` (the full state) for
15659
+ * repaint — the optimize delta can also un-confirm cells.
15660
+ * @format int64
15661
+ */
15662
+ total_score?: number | null;
15663
+ }
14664
15664
  /**
14665
15665
  * A scheduling feasibility request.
14666
15666
  *
@@ -14752,6 +15752,20 @@ interface SchedulingOptimizeResponse$1 {
14752
15752
  */
14753
15753
  total_score: number;
14754
15754
  }
15755
+ /** Response carrying a session id and its current classification. */
15756
+ interface SchedulingSessionResponse$1 {
15757
+ /** The current per-cell trichotomy. */
15758
+ classification: ClassificationDto;
15759
+ /** Opaque session id. */
15760
+ session_id: string;
15761
+ /**
15762
+ * In optimize mode (the request carried an `objective`), the optimum
15763
+ * `Σ weight·var` over the optimal completions at the current pins; absent
15764
+ * for pure-feasibility models.
15765
+ * @format int64
15766
+ */
15767
+ total_score?: number | null;
15768
+ }
14755
15769
  /** Top-level request status. */
14756
15770
  type SchedulingStatusDto = "feasible" | "infeasible";
14757
15771
  /** Request to search communities */
@@ -15222,6 +16236,8 @@ interface SolutionDto$1 {
15222
16236
  /** The substitution that satisfies the query */
15223
16237
  substitution: HomoiconicSubstitutionDto$1;
15224
16238
  }
16239
+ /** Status reported by the solver. */
16240
+ type SolutionStatus$1 = "optimal" | "feasible" | "infeasible" | "unbounded" | "unknown";
15225
16241
  /** Request to solve a constraint problem */
15226
16242
  interface SolveConstraintRequest$1 {
15227
16243
  constraints: ArithmeticConstraintDto$1[];
@@ -15263,6 +16279,66 @@ interface SolveFlowNetworkResponse$1 {
15263
16279
  */
15264
16280
  total_flow?: number | null;
15265
16281
  }
16282
+ /** Request body for `POST /api/v1/solver/solve`. */
16283
+ interface SolveProblemRequest$1 {
16284
+ constraints?: LinearConstraint$2[];
16285
+ /**
16286
+ * Relative MIP gap tolerance (e.g. `0.01` for 1 %). `0.0` means
16287
+ * "solve to proven optimum".
16288
+ * @format double
16289
+ */
16290
+ gap_tolerance?: number | null;
16291
+ /**
16292
+ * Backend-selection hint. `Auto` (default) routes CP-SAT for fully
16293
+ * discrete problems and HiGHS for any continuous variable.
16294
+ */
16295
+ hint?: SolverHint$1;
16296
+ objective?: null | Objective$1;
16297
+ /**
16298
+ * Wall-clock limit per solve, in milliseconds. Defaults server-side
16299
+ * to 30 000.
16300
+ * @format int64
16301
+ * @min 0
16302
+ */
16303
+ time_limit_ms?: number | null;
16304
+ variables: VariableSpec$1[];
16305
+ }
16306
+ /** Response body for `POST /api/v1/solver/solve`. */
16307
+ interface SolveProblemResponse$1 {
16308
+ /** Optional diagnostic message (e.g. when status is `Unknown`). */
16309
+ message?: string | null;
16310
+ /** @format double */
16311
+ objective_value?: number | null;
16312
+ /**
16313
+ * Wall-clock solve time inside the solver service, in milliseconds.
16314
+ * @format double
16315
+ */
16316
+ solve_time_ms: number;
16317
+ /** `"cp_sat"` or `"highs"`. */
16318
+ solver: string;
16319
+ /** Status reported by the solver. */
16320
+ status: SolutionStatus$1;
16321
+ /** Variable-name → optimal value. Empty for infeasible/unbounded. */
16322
+ values: Record<string, number>;
16323
+ }
16324
+ /**
16325
+ * Response body for `GET /api/v1/solver/health`. Typed so the OpenAPI
16326
+ * audit (`openapi_audit::should_have_no_untyped_response_bodies`)
16327
+ * stays green — a liveness probe still gets a schema-described shape
16328
+ * rather than an opaque `serde_json::Value`.
16329
+ */
16330
+ interface SolverHealthResponse$1 {
16331
+ /**
16332
+ * Liveness marker — `"ok"` when the upstream solver service
16333
+ * responded with a 2xx to its `/health` endpoint.
16334
+ */
16335
+ status: string;
16336
+ }
16337
+ /**
16338
+ * Backend-selection hint. `Auto` (default) routes CP-SAT for fully
16339
+ * discrete problems and HiGHS for any continuous variable.
16340
+ */
16341
+ type SolverHint$1 = "auto" | "prefer_cp" | "prefer_lp";
15266
16342
  /** Response with ancestor sorts */
15267
16343
  interface SortAncestorsResponse {
15268
16344
  ancestors: SortInfoDto$1[];
@@ -15464,6 +16540,12 @@ interface SortDto$1 {
15464
16540
  bound_constraints?: BoundConstraintDto$1[];
15465
16541
  /** Human-readable description for semantic search */
15466
16542
  description?: string | null;
16543
+ /**
16544
+ * SKOS external-ontology alignments (e.g. BFO/CCO) attached to this sort.
16545
+ * Populated by the upper-ontology aligner; makes each correspondence a live,
16546
+ * queryable property of the sort rather than a separate static export.
16547
+ */
16548
+ external_matches?: ExternalMatchDto$1[];
15467
16549
  /** Feature declarations that define the sort's schema */
15468
16550
  feature_declarations?: FeatureDescriptorDto$1[];
15469
16551
  /**
@@ -16757,6 +17839,29 @@ interface TemporalPlanResponse$1 {
16757
17839
  /** Selected term IDs in temporal order */
16758
17840
  selected_term_ids: string[];
16759
17841
  }
17842
+ /**
17843
+ * A temporal rule over one agent's ordered slot timeline (mirrors the domain
17844
+ * `TemporalRule`). Tagged by `type`.
17845
+ */
17846
+ type TemporalRuleDto = {
17847
+ type: "no_consec";
17848
+ } | {
17849
+ /** Whether at most one slot may be worked per day. */
17850
+ max_1_shift_per_day: boolean;
17851
+ /**
17852
+ * Worked-slot (or worked-day) cap.
17853
+ * @min 0
17854
+ */
17855
+ max_days: number;
17856
+ type: "capacity";
17857
+ } | {
17858
+ /**
17859
+ * Maximum consecutive worked nights.
17860
+ * @min 0
17861
+ */
17862
+ k: number;
17863
+ type: "max_consecutive_nights";
17864
+ };
16760
17865
  /** Variable-length temporal feature sequence in row-major form. */
16761
17866
  interface TemporalSequenceDto {
16762
17867
  /** Row-major buffer of length `seq_len * input_dim`. */
@@ -16829,6 +17934,17 @@ interface TermDto$1 {
16829
17934
  */
16830
17935
  tenant_id: string;
16831
17936
  }
17937
+ /** One edit in the action's atomic multi-term batch. */
17938
+ type TermEditDto = {
17939
+ /** Create or overwrite a term (reuses the standard term-creation body). */
17940
+ put: CreateTermRequest$1;
17941
+ } | {
17942
+ /**
17943
+ * Remove an existing term by id.
17944
+ * @format uuid
17945
+ */
17946
+ remove: string;
17947
+ };
16832
17948
  /** Response for term existence check */
16833
17949
  interface TermExistsResponse {
16834
17950
  /** Whether the term exists */
@@ -17132,6 +18248,27 @@ interface TrajectoryStepDto$1 {
17132
18248
  /** Specific tool identifier (if different from action) */
17133
18249
  tool_used?: string | null;
17134
18250
  }
18251
+ /** Request to transpile an OSFQL query to SQL. */
18252
+ interface TranspileRequest$1 {
18253
+ /** SQL dialect: "postgres", "mysql", or "sqlite". */
18254
+ dialect?: string;
18255
+ /** OSFQL query to transpile. */
18256
+ osfql: string;
18257
+ }
18258
+ /** Response from OSFQL-to-SQL transpilation. */
18259
+ interface TranspileResponse$1 {
18260
+ /** Whether the entire plan is SQL-transpilable. */
18261
+ fully_transpilable: boolean;
18262
+ /**
18263
+ * Number of parameters in the generated SQL.
18264
+ * @min 0
18265
+ */
18266
+ param_count: number;
18267
+ /** Source ID the query targets. */
18268
+ source_id?: string | null;
18269
+ /** Generated SQL query. */
18270
+ sql: string;
18271
+ }
17135
18272
  /** Request for trigger dependency graph */
17136
18273
  interface TriggerDependencyRequest$1 {
17137
18274
  /** Whether to generate DOT output */
@@ -17213,6 +18350,63 @@ interface TrizRecordOutcomeResponse {
17213
18350
  */
17214
18351
  updated_confidence: number;
17215
18352
  }
18353
+ /**
18354
+ * One structured constraint over the flat decision variables (mirrors the
18355
+ * domain `TypedConstraint`). Tagged by `type`; variable ids are flat indices
18356
+ * the caller assigns (the choice-point layout defines the ranges).
18357
+ */
18358
+ type TypedConstraintDto = {
18359
+ /**
18360
+ * Optional upper bound (`null` = none).
18361
+ * @min 0
18362
+ */
18363
+ max?: number | null;
18364
+ /**
18365
+ * Lower bound (`0` = none).
18366
+ * @min 0
18367
+ */
18368
+ min: number;
18369
+ type: "global_cardinality";
18370
+ /** The variables summed. */
18371
+ vars: number[];
18372
+ } | {
18373
+ /** The literals of the clause. */
18374
+ lits: LitDto[];
18375
+ type: "forbid";
18376
+ } | {
18377
+ type: "pin";
18378
+ /**
18379
+ * The variable to fix `true`.
18380
+ * @min 0
18381
+ */
18382
+ var: number;
18383
+ } | {
18384
+ /** `available[L]` — `false` where the slot is structurally unavailable. */
18385
+ available: boolean[];
18386
+ /**
18387
+ * Days in the timeline.
18388
+ * @min 0
18389
+ */
18390
+ days: number;
18391
+ /** Temporal rules enforced over the timeline. */
18392
+ rules: TemporalRuleDto[];
18393
+ /**
18394
+ * Shifts per day.
18395
+ * @min 0
18396
+ */
18397
+ shifts: number;
18398
+ type: "regular";
18399
+ /** The agent's variables in slot order. */
18400
+ vars: number[];
18401
+ } | {
18402
+ type: "all_different";
18403
+ /** The mutually-exclusive variables. */
18404
+ vars: number[];
18405
+ } | {
18406
+ /** The boolean-valued expression asserted true. */
18407
+ expr: BoolExprDto;
18408
+ type: "arithmetic";
18409
+ };
17216
18410
  /** DTO for UIAction — all actions reference OSFQL execution */
17217
18411
  type UIActionDto$1 = {
17218
18412
  field_types: Record<string, string>;
@@ -17789,7 +18983,7 @@ type ValidationTypeDto$1 = {
17789
18983
  /**
17790
18984
  * ValueDto
17791
18985
  * Value in a term feature. Discriminated by 'type' field.
17792
- * Variants: String, Integer, Real, Boolean, Uninstantiated, Reference, List, FuzzyScalar, FuzzyNumber, Set.
18986
+ * Variants: String, Integer, Real, Boolean, Uninstantiated, Reference, SortId, List, FuzzyScalar, FuzzyNumber, Set.
17793
18987
  */
17794
18988
  type ValueDto$1 = {
17795
18989
  type: "String";
@@ -17811,9 +19005,19 @@ type ValueDto$1 = {
17811
19005
  type: "Reference";
17812
19006
  /** @format uuid */
17813
19007
  value: string;
19008
+ } | {
19009
+ type: "SortId";
19010
+ /** @format uuid */
19011
+ value: string;
17814
19012
  } | {
17815
19013
  type: "List";
17816
19014
  value: ValueDto$1[];
19015
+ } | {
19016
+ type: "Domain";
19017
+ value: ValueDto$1[];
19018
+ } | {
19019
+ type: "Choice";
19020
+ value: ValueDto$1[];
17817
19021
  } | {
17818
19022
  type: "FuzzyScalar";
17819
19023
  value: {
@@ -17871,6 +19075,17 @@ type ValuePatternDto$1 = {
17871
19075
  type: "bind";
17872
19076
  variable: string;
17873
19077
  };
19078
+ /**
19079
+ * Domain of a variable. CP-SAT handles `Integer` and `Binary`; HiGHS
19080
+ * handles all three. The solver service picks the backend based on the
19081
+ * `hint` field and the variable kinds present.
19082
+ */
19083
+ type VarKind$1 = "continuous" | "integer" | "binary";
19084
+ /**
19085
+ * Per-variable classification — the ILP analog of flow's edge
19086
+ * classification (Dulmage-Mendelsohn).
19087
+ */
19088
+ type VariableClassification$1 = "always_used" | "sometimes_used" | "never_used";
17874
19089
  /**
17875
19090
  * Feasibility of a single binary variable in the constraint space.
17876
19091
  *
@@ -17904,6 +19119,27 @@ interface VariableFeasibilityDto$1 {
17904
19119
  */
17905
19120
  verified?: boolean;
17906
19121
  }
19122
+ /**
19123
+ * A single decision variable. Names must be unique within a problem
19124
+ * and are echoed verbatim in the response `values` map.
19125
+ */
19126
+ interface VariableSpec$1 {
19127
+ /** Variable kind. Defaults to `Continuous`. */
19128
+ kind?: VarKind$1;
19129
+ /**
19130
+ * Lower bound. Use `f64::NEG_INFINITY` for unbounded below.
19131
+ * @format double
19132
+ */
19133
+ lower_bound?: number;
19134
+ /** Caller-chosen identifier. Must be unique. */
19135
+ name: string;
19136
+ /**
19137
+ * Upper bound. Use `f64::INFINITY` for unbounded above. Ignored
19138
+ * for `Binary` (forced to 1).
19139
+ * @format double
19140
+ */
19141
+ upper_bound?: number;
19142
+ }
17907
19143
  /** Result of verbalizing a single PsiTerm. */
17908
19144
  interface VerbalizationResultDto$1 {
17909
19145
  /**
@@ -20294,7 +21530,7 @@ declare namespace terms {
20294
21530
  }
20295
21531
 
20296
21532
  /** Translation mode for natural language queries. */
20297
- type NlQueryMode = 'llm' | 'constraint' | 'cognitive' | 'triz';
21533
+ type NlQueryMode = 'llm' | 'constraint' | 'cognitive' | 'triz' | 'grounded_sql';
20298
21534
  /** A result item from a natural language query. */
20299
21535
  interface NlQueryResultItem {
20300
21536
  /** Term ID. */
@@ -20349,20 +21585,16 @@ interface OsfSearchRequest {
20349
21585
  * A matched entity in a structured search result.
20350
21586
  */
20351
21587
  interface MatchedEntityDto {
20352
- /** Term ID. */
20353
- termId: string;
20354
- /** Sort ID. */
20355
- sortId: string;
20356
- /** Community this entity belongs to. */
20357
- communityId: string;
20358
- /** Human-readable name (if available). */
20359
- name?: string | null;
20360
- /** Key features as strings. */
20361
- features: Record<string, string>;
20362
- /** Match degree (0.0-1.0). */
20363
- matchDegree: number;
20364
- /** Why this entity matched. */
20365
- matchReason?: string | null;
21588
+ /** Match confidence in [0, 1]. */
21589
+ confidence: number;
21590
+ /** Why it matched (e.g. `"exact"`, `"fuzzy_glb"`, `"salience"`). */
21591
+ matchReason: string;
21592
+ /** Display label of the entity. */
21593
+ name: string;
21594
+ /** Sort name the entity belongs to. */
21595
+ sortName: string;
21596
+ /** Optional term ID (string form). */
21597
+ termId?: string | null;
20366
21598
  }
20367
21599
  /**
20368
21600
  * A discovered relation between entities in a structured search result.
@@ -21227,6 +22459,16 @@ declare class Inference<SecurityDataType = unknown> {
21227
22459
  * @secure
21228
22460
  */
21229
22461
  getMetaSorts: (params?: RequestParams) => Promise<HttpResponse<MetaSortsResponse$1, any>>;
22462
+ /**
22463
+ * @description # Authorization Requires X-Tenant-Id header.
22464
+ *
22465
+ * @tags inference
22466
+ * @name GetRules
22467
+ * @summary Get all rules (clauses with antecedents) for a tenant
22468
+ * @request GET:/api/v1/inference/rules/{tenant_id}
22469
+ * @secure
22470
+ */
22471
+ getRules: (tenantId: string, params?: RequestParams) => Promise<HttpResponse<GetRulesResponse$1, any>>;
21230
22472
  /**
21231
22473
  * @description # TRUE HOMOICONICITY Goals are Ψ-terms persisted to PostgreSQL. This endpoint returns all goals for the authenticated tenant with summary information. # Authorization Requires X-Tenant-Id header.
21232
22474
  *
@@ -21829,6 +23071,30 @@ interface ListGoalsResponse {
21829
23071
  /** List of saved goals. */
21830
23072
  goals: GoalSummaryDto[];
21831
23073
  }
23074
+ /**
23075
+ * A single stored rule (clause with antecedents).
23076
+ *
23077
+ * @remarks
23078
+ * Both `head` and `body` are homoiconic {@link PsiTermDto} values
23079
+ * (untagged feature-value representation).
23080
+ */
23081
+ interface RuleEntryDto {
23082
+ /** Rule term ID (UUID). */
23083
+ ruleId: string;
23084
+ /** The head (consequent) of the rule. */
23085
+ head: PsiTermDto;
23086
+ /** The body (antecedents) of the rule. */
23087
+ body: PsiTermDto[];
23088
+ /** Optional certainty/confidence for the rule. */
23089
+ certainty?: number | null;
23090
+ }
23091
+ /** Response listing all rules for a tenant. */
23092
+ interface GetRulesResponse {
23093
+ /** Total number of rules. */
23094
+ count: number;
23095
+ /** The rules (clauses with antecedents). */
23096
+ rules: RuleEntryDto[];
23097
+ }
21832
23098
  /**
21833
23099
  * Response listing the meta-sorts (built-in system sorts) for inference.
21834
23100
  *
@@ -22038,6 +23304,7 @@ type inference_ForwardChainResponse = ForwardChainResponse;
22038
23304
  type inference_FuzzyProveRequest = FuzzyProveRequest;
22039
23305
  type inference_FuzzyProveResponse = FuzzyProveResponse;
22040
23306
  type inference_GetFactsResponse = GetFactsResponse;
23307
+ type inference_GetRulesResponse = GetRulesResponse;
22041
23308
  type inference_GoalDto = GoalDto;
22042
23309
  type inference_GoalSummaryDto = GoalSummaryDto;
22043
23310
  type inference_GuardOp = GuardOp;
@@ -22049,12 +23316,13 @@ type inference_NafProveRequest = NafProveRequest;
22049
23316
  type inference_NafProveResponse = NafProveResponse;
22050
23317
  type inference_ProofDto = ProofDto;
22051
23318
  type inference_ProvenanceTagDto = ProvenanceTagDto;
23319
+ type inference_RuleEntryDto = RuleEntryDto;
22052
23320
  type inference_SolutionDto = SolutionDto;
22053
23321
  type inference_TaggedDerivedFact = TaggedDerivedFact;
22054
23322
  type inference_TaggedForwardChainRequest = TaggedForwardChainRequest;
22055
23323
  type inference_TaggedForwardChainResponse = TaggedForwardChainResponse;
22056
23324
  declare namespace inference {
22057
- export type { inference_AddFactRequest as AddFactRequest, inference_AddFactResponse as AddFactResponse, inference_AddRuleRequest as AddRuleRequest, inference_AddRuleResponse as AddRuleResponse, inference_AllenRelation as AllenRelation, inference_BackwardChainRequest as BackwardChainRequest, inference_BackwardChainResponse as BackwardChainResponse, inference_BayesianEffectDto as BayesianEffectDto, inference_BayesianPredictRequest as BayesianPredictRequest, inference_BayesianPredictResponse as BayesianPredictResponse, inference_BindingDto as BindingDto, inference_BulkAddFactsRequest as BulkAddFactsRequest, inference_BulkAddFactsResponse as BulkAddFactsResponse, inference_BulkAddRulesRequest as BulkAddRulesRequest, inference_BulkAddRulesResponse as BulkAddRulesResponse, inference_BulkFuzzyProveRequest as BulkFuzzyProveRequest, inference_BulkFuzzyProveResponse as BulkFuzzyProveResponse, inference_ClearFactsResponse as ClearFactsResponse, inference_ConstraintInputDto as ConstraintInputDto, inference_CreateGoalRequest as CreateGoalRequest, inference_CreateGoalResponse as CreateGoalResponse, inference_DeleteGoalResponse as DeleteGoalResponse, inference_FactConfidenceEntry as FactConfidenceEntry, inference_ForwardChainRequest as ForwardChainRequest, inference_ForwardChainResponse as ForwardChainResponse, inference_FuzzyProveRequest as FuzzyProveRequest, inference_FuzzyProveResponse as FuzzyProveResponse, inference_GetFactsResponse as GetFactsResponse, inference_GoalDto as GoalDto, inference_GoalSummaryDto as GoalSummaryDto, inference_GuardOp as GuardOp, inference_HomoiconicSubstitutionDto as HomoiconicSubstitutionDto, inference_ListGoalsResponse as ListGoalsResponse, inference_LiteralInputDto as LiteralInputDto, inference_MetaSortsResponse as MetaSortsResponse, inference_NafProveRequest as NafProveRequest, inference_NafProveResponse as NafProveResponse, inference_ProofDto as ProofDto, inference_ProvenanceTagDto as ProvenanceTagDto, inference_SolutionDto as SolutionDto, inference_TaggedDerivedFact as TaggedDerivedFact, inference_TaggedForwardChainRequest as TaggedForwardChainRequest, inference_TaggedForwardChainResponse as TaggedForwardChainResponse };
23325
+ export type { inference_AddFactRequest as AddFactRequest, inference_AddFactResponse as AddFactResponse, inference_AddRuleRequest as AddRuleRequest, inference_AddRuleResponse as AddRuleResponse, inference_AllenRelation as AllenRelation, inference_BackwardChainRequest as BackwardChainRequest, inference_BackwardChainResponse as BackwardChainResponse, inference_BayesianEffectDto as BayesianEffectDto, inference_BayesianPredictRequest as BayesianPredictRequest, inference_BayesianPredictResponse as BayesianPredictResponse, inference_BindingDto as BindingDto, inference_BulkAddFactsRequest as BulkAddFactsRequest, inference_BulkAddFactsResponse as BulkAddFactsResponse, inference_BulkAddRulesRequest as BulkAddRulesRequest, inference_BulkAddRulesResponse as BulkAddRulesResponse, inference_BulkFuzzyProveRequest as BulkFuzzyProveRequest, inference_BulkFuzzyProveResponse as BulkFuzzyProveResponse, inference_ClearFactsResponse as ClearFactsResponse, inference_ConstraintInputDto as ConstraintInputDto, inference_CreateGoalRequest as CreateGoalRequest, inference_CreateGoalResponse as CreateGoalResponse, inference_DeleteGoalResponse as DeleteGoalResponse, inference_FactConfidenceEntry as FactConfidenceEntry, inference_ForwardChainRequest as ForwardChainRequest, inference_ForwardChainResponse as ForwardChainResponse, inference_FuzzyProveRequest as FuzzyProveRequest, inference_FuzzyProveResponse as FuzzyProveResponse, inference_GetFactsResponse as GetFactsResponse, inference_GetRulesResponse as GetRulesResponse, inference_GoalDto as GoalDto, inference_GoalSummaryDto as GoalSummaryDto, inference_GuardOp as GuardOp, inference_HomoiconicSubstitutionDto as HomoiconicSubstitutionDto, inference_ListGoalsResponse as ListGoalsResponse, inference_LiteralInputDto as LiteralInputDto, inference_MetaSortsResponse as MetaSortsResponse, inference_NafProveRequest as NafProveRequest, inference_NafProveResponse as NafProveResponse, inference_ProofDto as ProofDto, inference_ProvenanceTagDto as ProvenanceTagDto, inference_RuleEntryDto as RuleEntryDto, inference_SolutionDto as SolutionDto, inference_TaggedDerivedFact as TaggedDerivedFact, inference_TaggedForwardChainRequest as TaggedForwardChainRequest, inference_TaggedForwardChainResponse as TaggedForwardChainResponse };
22058
23326
  }
22059
23327
 
22060
23328
  /**
@@ -22130,6 +23398,28 @@ declare class InferenceClient {
22130
23398
  * @returns Clear result with facts_cleared count.
22131
23399
  */
22132
23400
  clearFacts(): Promise<ClearFactsResponse>;
23401
+ /**
23402
+ * Get all stored rules (clauses with antecedents) for the tenant.
23403
+ *
23404
+ * @returns Rules with a total count. Each rule's `head` and `body` are {@link PsiTermDto} values.
23405
+ * @throws {ApiError} If the request fails.
23406
+ *
23407
+ * @remarks
23408
+ * The tenant is taken from the client's configured tenant ID (used for the
23409
+ * `{tenant_id}` path parameter), matching the sibling fact-retrieval methods.
23410
+ *
23411
+ * Responses use the homoiconic {@link PsiTermDto} representation.
23412
+ *
23413
+ * @example
23414
+ * ```typescript
23415
+ * const result = await client.inference.getRules();
23416
+ * console.log(result.count); // number of stored rules
23417
+ * for (const rule of result.rules) {
23418
+ * console.log(rule.head.display, '<-', rule.body.map((b) => b.display));
23419
+ * }
23420
+ * ```
23421
+ */
23422
+ getRules(): Promise<GetRulesResponse>;
22133
23423
  /**
22134
23424
  * Query for matching data by searching rules and facts backwards from a goal pattern.
22135
23425
  *
@@ -25135,7 +26425,7 @@ type GlbLubOperation = 'glb' | 'lub';
25135
26425
  /**
25136
26426
  * Kind of residuation to visualize.
25137
26427
  */
25138
- type ResiduationKind = 'inference' | 'fuzzy' | 'extraction' | 'all';
26428
+ type ResiduationKind = 'inference' | 'fuzzy' | 'extraction' | 'naf_failure' | 'all';
25139
26429
  /**
25140
26430
  * State filter for residuation visualization.
25141
26431
  */
@@ -26386,6 +27676,16 @@ declare class Collections<SecurityDataType = unknown> {
26386
27676
  * @secure
26387
27677
  */
26388
27678
  createCollection: (data: CreateCollectionRequest$1, params?: RequestParams) => Promise<HttpResponse<CollectionResponse, void>>;
27679
+ /**
27680
+ * @description The term is created through the standard term path (sort validation + reactive constraints apply), then assigned to the collection so `query_terms_in_collection` can resolve it. The tenant is taken from the `X-Tenant-Id` header; `collection_id` comes from the request body.
27681
+ *
27682
+ * @tags collections
27683
+ * @name CreateTermInCollection
27684
+ * @summary Create a term scoped to a collection.
27685
+ * @request POST:/api/v1/terms/in-collection
27686
+ * @secure
27687
+ */
27688
+ createTermInCollection: (data: CreateTermInCollectionRequest$1, params?: RequestParams) => Promise<HttpResponse<TermResponse$1, void>>;
26389
27689
  /**
26390
27690
  * No description
26391
27691
  *
@@ -26466,12 +27766,46 @@ declare class Collections<SecurityDataType = unknown> {
26466
27766
  * @secure
26467
27767
  */
26468
27768
  listCollections: (namespaceId: string, params?: RequestParams) => Promise<HttpResponse<CollectionListResponse, void>>;
27769
+ /**
27770
+ * @description `?include_children=true` widens the result to the namespace subtree. `?from=<ns>` performs a cross-namespace query: terms are returned only if the `from` namespace may access this namespace under the visibility rules.
27771
+ *
27772
+ * @tags collections
27773
+ * @name ListNamespaceTerms
27774
+ * @summary List terms scoped to a namespace.
27775
+ * @request GET:/api/v1/namespaces/{namespace_id}/terms
27776
+ * @secure
27777
+ */
27778
+ listNamespaceTerms: (namespaceId: string, query?: {
27779
+ /**
27780
+ * Querying namespace (visibility gate)
27781
+ * @format uuid
27782
+ */
27783
+ from?: string;
27784
+ /** Include descendant namespaces */
27785
+ include_children?: boolean;
27786
+ }, params?: RequestParams) => Promise<HttpResponse<TermListResponse$1, void>>;
27787
+ /**
27788
+ * No description
27789
+ *
27790
+ * @tags collections
27791
+ * @name ListVisibleNamespaceTerms
27792
+ * @summary List the terms visible within a namespace's own hierarchy (the namespace plus all descendant namespaces). A namespace can always see terms inside its own subtree.
27793
+ * @request GET:/api/v1/namespaces/{namespace_id}/visible-terms
27794
+ * @secure
27795
+ */
27796
+ listVisibleNamespaceTerms: (namespaceId: string, query?: {
27797
+ /**
27798
+ * Querying namespace
27799
+ * @format uuid
27800
+ */
27801
+ from?: string;
27802
+ }, params?: RequestParams) => Promise<HttpResponse<TermListResponse$1, void>>;
26469
27803
  /**
26470
27804
  * No description
26471
27805
  *
26472
27806
  * @tags collections
26473
27807
  * @name QueryTermsByCollectionPath
26474
- * @summary Query terms by collection path prefix (placeholder - needs term integration)
27808
+ * @summary Query terms in every collection whose path matches a prefix within a namespace (e.g. `/projects/alpha` matches `/projects/alpha` and its sub-paths). Member terms of all matching collections are hydrated.
26475
27809
  * @request POST:/api/v1/collections/query/by-path
26476
27810
  * @secure
26477
27811
  */
@@ -26481,7 +27815,7 @@ declare class Collections<SecurityDataType = unknown> {
26481
27815
  *
26482
27816
  * @tags collections
26483
27817
  * @name QueryTermsInCollection
26484
- * @summary Query terms in a collection (placeholder - needs term integration)
27818
+ * @summary Query terms scoped to a collection (optionally including descendant collections). Resolves the collection's member terms and hydrates each from the tenant term store.
26485
27819
  * @request POST:/api/v1/collections/query/in-collection
26486
27820
  * @secure
26487
27821
  */
@@ -26498,6 +27832,27 @@ declare class Collections<SecurityDataType = unknown> {
26498
27832
  updateCollection: (id: string, data: UpdateCollectionRequest$1, params?: RequestParams) => Promise<HttpResponse<void, void>>;
26499
27833
  }
26500
27834
 
27835
+ /**
27836
+ * Request to create a term scoped to a collection.
27837
+ *
27838
+ * @remarks
27839
+ * Features use the tagged {@link ValueDto} format (`{"type": "String", "value": "hello"}`).
27840
+ * Use `Value.*` builders to construct feature values. The term is created through the
27841
+ * standard term path (sort validation + reactive constraints apply) and then assigned
27842
+ * to the collection.
27843
+ */
27844
+ interface CreateTermInCollectionRequest {
27845
+ /** Collection UUID to add the term to. */
27846
+ collectionId: string;
27847
+ /** Namespace UUID. */
27848
+ namespaceId: string;
27849
+ /** Sort (type) UUID for the term. */
27850
+ sortId: string;
27851
+ /** Tenant UUID. */
27852
+ tenantId: string;
27853
+ /** Named features with tagged values. */
27854
+ features: Record<string, ValueDto>;
27855
+ }
26501
27856
  /**
26502
27857
  * Request to create a collection.
26503
27858
  */
@@ -26544,9 +27899,10 @@ interface CollectionDto {
26544
27899
 
26545
27900
  type collections_CollectionDto = CollectionDto;
26546
27901
  type collections_CreateCollectionRequest = CreateCollectionRequest;
27902
+ type collections_CreateTermInCollectionRequest = CreateTermInCollectionRequest;
26547
27903
  type collections_UpdateCollectionRequest = UpdateCollectionRequest;
26548
27904
  declare namespace collections {
26549
- export type { collections_CollectionDto as CollectionDto, collections_CreateCollectionRequest as CreateCollectionRequest, collections_UpdateCollectionRequest as UpdateCollectionRequest };
27905
+ export type { collections_CollectionDto as CollectionDto, collections_CreateCollectionRequest as CreateCollectionRequest, collections_CreateTermInCollectionRequest as CreateTermInCollectionRequest, collections_UpdateCollectionRequest as UpdateCollectionRequest };
26550
27906
  }
26551
27907
 
26552
27908
  /**
@@ -26632,6 +27988,69 @@ declare class CollectionsClient {
26632
27988
  * @returns Array of root collections.
26633
27989
  */
26634
27990
  getRootCollections(namespaceId: string): Promise<CollectionDto[]>;
27991
+ /**
27992
+ * Create a term scoped to a collection.
27993
+ *
27994
+ * @param request - Term creation parameters, including the target collection.
27995
+ * @returns The created term wrapped in a {@link TermResponse}, including its
27996
+ * validation state and any witness proofs or residuated witnesses.
27997
+ * @throws {ApiError} If the request fails.
27998
+ *
27999
+ * @remarks
28000
+ * The term is created through the standard term path (sort validation +
28001
+ * reactive constraints apply), then assigned to the collection so that
28002
+ * collection queries can resolve it. Features use the tagged `ValueDto`
28003
+ * format — use `Value.*` builders to construct feature values. The tenant is
28004
+ * taken from the `X-Tenant-Id` header; `collectionId` comes from the request.
28005
+ *
28006
+ * @example
28007
+ * ```typescript
28008
+ * const result = await client.collections.createTermInCollection({
28009
+ * collectionId: 'coll-uuid',
28010
+ * namespaceId: 'ns-uuid',
28011
+ * sortId: 'sort-uuid',
28012
+ * tenantId: 'tenant-uuid',
28013
+ * features: { name: Value.string('Alice') },
28014
+ * });
28015
+ * console.log(result.term.id);
28016
+ * ```
28017
+ */
28018
+ createTermInCollection(request: CreateTermInCollectionRequest): Promise<TermResponse>;
28019
+ /**
28020
+ * List terms scoped to a namespace.
28021
+ *
28022
+ * @param namespaceId - Namespace UUID.
28023
+ * @returns The matching terms with a total count.
28024
+ * @throws {ApiError} If the request fails.
28025
+ *
28026
+ * @remarks
28027
+ * Features in the returned terms use the tagged `ValueDto` format.
28028
+ *
28029
+ * @example
28030
+ * ```typescript
28031
+ * const { terms, count } = await client.collections.listNamespaceTerms('ns-uuid');
28032
+ * console.log(`${count} terms`);
28033
+ * ```
28034
+ */
28035
+ listNamespaceTerms(namespaceId: string): Promise<TermListResponse>;
28036
+ /**
28037
+ * List the terms visible within a namespace's own hierarchy.
28038
+ *
28039
+ * @param namespaceId - Namespace UUID.
28040
+ * @returns The matching terms with a total count.
28041
+ * @throws {ApiError} If the request fails.
28042
+ *
28043
+ * @remarks
28044
+ * Returns terms inside the namespace plus all descendant namespaces; a
28045
+ * namespace can always see terms inside its own subtree. Features in the
28046
+ * returned terms use the tagged `ValueDto` format.
28047
+ *
28048
+ * @example
28049
+ * ```typescript
28050
+ * const { terms } = await client.collections.listVisibleNamespaceTerms('ns-uuid');
28051
+ * ```
28052
+ */
28053
+ listVisibleNamespaceTerms(namespaceId: string): Promise<TermListResponse>;
26635
28054
  /**
26636
28055
  * Query terms by collection path prefix.
26637
28056
  *
@@ -34660,6 +36079,16 @@ declare class Scenarios<SecurityDataType = unknown> {
34660
36079
  * @secure
34661
36080
  */
34662
36081
  listScenarios: (params?: RequestParams) => Promise<HttpResponse<ListScenariosResponse$1, any>>;
36082
+ /**
36083
+ * @description Materializes an already-generated GeneratedScenario verbatim (no LLM call): sorts, belief instances, rules, goal, and the ontology-declared engine pipeline. Used by the studio's build wizard to persist exactly what was reviewed so it is immediately queryable in chat.
36084
+ *
36085
+ * @tags scenarios
36086
+ * @name MaterializeScenario
36087
+ * @summary Materialize a pre-generated scenario into the knowledge base
36088
+ * @request POST:/api/v1/scenarios/materialize
36089
+ * @secure
36090
+ */
36091
+ materializeScenario: (data: MaterializeScenarioRequest$1, params?: RequestParams) => Promise<HttpResponse<MaterializeScenarioResponse$1, void>>;
34663
36092
  /**
34664
36093
  * @description Adds new sorts, beliefs, rules, constraints, guard constraints, temporal constraints, and/or webhook actions to an existing scenario without re-creating everything from scratch.
34665
36094
  *
@@ -34845,6 +36274,38 @@ interface GetScenarioResponse {
34845
36274
  /** Number of webhook actions created during materialization. */
34846
36275
  webhookActionsCreated: number;
34847
36276
  }
36277
+ /**
36278
+ * Request to materialize an already-generated scenario verbatim (no LLM call).
36279
+ *
36280
+ * @remarks
36281
+ * Used to persist a pre-generated `GeneratedScenario` exactly as reviewed.
36282
+ * The `scenario` field is the opaque domain `GeneratedScenario` JSON object.
36283
+ */
36284
+ interface MaterializeScenarioRequest {
36285
+ /** The domain `GeneratedScenario` JSON to materialize verbatim. */
36286
+ scenario: unknown;
36287
+ }
36288
+ /**
36289
+ * Response from materializing a pre-generated scenario.
36290
+ */
36291
+ interface MaterializeScenarioResponse {
36292
+ /** Number of belief (instance) Psi-terms created. */
36293
+ beliefsCreated: number;
36294
+ /** Number of generic constraint terms created. */
36295
+ constraintsCreated: number;
36296
+ /** Number of ontology-declared `pipeline_stage` control-plane terms created. */
36297
+ pipelineStagesCreated: number;
36298
+ /** Number of OSF relation edges (`Value::Reference` features) linking instances. */
36299
+ relationsCreated: number;
36300
+ /** Number of rule Psi-terms created. */
36301
+ rulesCreated: number;
36302
+ /** Number of ontology-declared `llm_sensor_point` control-plane terms created. */
36303
+ sensorPointsCreated: number;
36304
+ /** Number of sorts created or reused. */
36305
+ sortsCreated: number;
36306
+ /** Non-fatal materialization warnings. */
36307
+ warnings: string[];
36308
+ }
34848
36309
  /**
34849
36310
  * Request to incrementally update a scenario.
34850
36311
  *
@@ -34978,6 +36439,8 @@ type scenarios_GetScenarioResponse = GetScenarioResponse;
34978
36439
  type scenarios_LayerResultSummaryDto = LayerResultSummaryDto;
34979
36440
  type scenarios_ListScenariosResponse = ListScenariosResponse;
34980
36441
  type scenarios_MaterializationSummaryDto = MaterializationSummaryDto;
36442
+ type scenarios_MaterializeScenarioRequest = MaterializeScenarioRequest;
36443
+ type scenarios_MaterializeScenarioResponse = MaterializeScenarioResponse;
34981
36444
  type scenarios_ScenarioSummaryDto = ScenarioSummaryDto;
34982
36445
  type scenarios_UpdateScenarioRequest = UpdateScenarioRequest;
34983
36446
  type scenarios_UpdateScenarioResponse = UpdateScenarioResponse;
@@ -34985,7 +36448,7 @@ type scenarios_VerificationStepDto = VerificationStepDto;
34985
36448
  type scenarios_VerifyScenarioRequest = VerifyScenarioRequest;
34986
36449
  type scenarios_VerifyScenarioResponse = VerifyScenarioResponse;
34987
36450
  declare namespace scenarios {
34988
- export type { scenarios_ClarificationQuestionDto as ClarificationQuestionDto, scenarios_CreateScenarioRequest as CreateScenarioRequest, scenarios_CreateScenarioResponse as CreateScenarioResponse, scenarios_CycleOutcomeSummaryDto as CycleOutcomeSummaryDto, scenarios_FormalVerdictDto as FormalVerdictDto, scenarios_GetScenarioResponse as GetScenarioResponse, scenarios_LayerResultSummaryDto as LayerResultSummaryDto, scenarios_ListScenariosResponse as ListScenariosResponse, scenarios_MaterializationSummaryDto as MaterializationSummaryDto, scenarios_ScenarioSummaryDto as ScenarioSummaryDto, scenarios_UpdateScenarioRequest as UpdateScenarioRequest, scenarios_UpdateScenarioResponse as UpdateScenarioResponse, scenarios_VerificationStepDto as VerificationStepDto, scenarios_VerifyScenarioRequest as VerifyScenarioRequest, scenarios_VerifyScenarioResponse as VerifyScenarioResponse };
36451
+ export type { scenarios_ClarificationQuestionDto as ClarificationQuestionDto, scenarios_CreateScenarioRequest as CreateScenarioRequest, scenarios_CreateScenarioResponse as CreateScenarioResponse, scenarios_CycleOutcomeSummaryDto as CycleOutcomeSummaryDto, scenarios_FormalVerdictDto as FormalVerdictDto, scenarios_GetScenarioResponse as GetScenarioResponse, scenarios_LayerResultSummaryDto as LayerResultSummaryDto, scenarios_ListScenariosResponse as ListScenariosResponse, scenarios_MaterializationSummaryDto as MaterializationSummaryDto, scenarios_MaterializeScenarioRequest as MaterializeScenarioRequest, scenarios_MaterializeScenarioResponse as MaterializeScenarioResponse, scenarios_ScenarioSummaryDto as ScenarioSummaryDto, scenarios_UpdateScenarioRequest as UpdateScenarioRequest, scenarios_UpdateScenarioResponse as UpdateScenarioResponse, scenarios_VerificationStepDto as VerificationStepDto, scenarios_VerifyScenarioRequest as VerifyScenarioRequest, scenarios_VerifyScenarioResponse as VerifyScenarioResponse };
34989
36452
  }
34990
36453
 
34991
36454
  /**
@@ -35008,6 +36471,29 @@ declare class ScenariosClient {
35008
36471
  * @returns Created scenario (may include interactive questions).
35009
36472
  */
35010
36473
  create(request: CreateScenarioRequest): Promise<CreateScenarioResponse>;
36474
+ /**
36475
+ * Materialize an already-generated scenario verbatim (no LLM call).
36476
+ *
36477
+ * @param req - The pre-generated `GeneratedScenario` JSON to materialize.
36478
+ * @returns Counts of materialized sorts, beliefs, rules, relations, control-plane terms, and any non-fatal warnings.
36479
+ * @throws {ApiError} If the request fails (e.g., malformed scenario JSON).
36480
+ *
36481
+ * @remarks
36482
+ * Materializes the scenario exactly as provided: sorts, belief instances, rules,
36483
+ * goal, and the ontology-declared engine pipeline. Used to persist exactly what
36484
+ * was reviewed so it is immediately queryable.
36485
+ *
36486
+ * The `scenario` field is the opaque domain `GeneratedScenario` JSON object;
36487
+ * no value-level serialization split applies. Response fields are normalized
36488
+ * from snake_case to camelCase.
36489
+ *
36490
+ * @example
36491
+ * ```typescript
36492
+ * const result = await client.scenarios.materializeScenario({ scenario: generated });
36493
+ * console.log(result.sortsCreated, result.beliefsCreated, result.rulesCreated);
36494
+ * ```
36495
+ */
36496
+ materializeScenario(req: MaterializeScenarioRequest): Promise<MaterializeScenarioResponse>;
35011
36497
  /**
35012
36498
  * List all scenarios.
35013
36499
  *
@@ -37364,6 +38850,16 @@ declare class Functions<SecurityDataType = unknown> {
37364
38850
  * @secure
37365
38851
  */
37366
38852
  evaluateFunction: (data: EvaluateFunctionRequest$1, params?: RequestParams) => Promise<HttpResponse<EvaluateFunctionResponse$1, void>>;
38853
+ /**
38854
+ * @description This is the discovery counterpart to `register_function`/`evaluate_function`: it projects the tenant's slice of the function sub-lattice into a list of typed signatures (name + arity + clause count) without evaluating anything. The tenant is taken from the authenticated principal (never a body field), honouring the tenancy-scoping invariant.
38855
+ *
38856
+ * @tags functions
38857
+ * @name ListFunctions
38858
+ * @summary Handler to list all functions registered for the authenticated tenant.
38859
+ * @request GET:/api/v1/functions
38860
+ * @secure
38861
+ */
38862
+ listFunctions: (params?: RequestParams) => Promise<HttpResponse<ListFunctionsResponse$1, any>>;
37367
38863
  /**
37368
38864
  * No description
37369
38865
  *
@@ -37566,6 +39062,30 @@ type EvaluateFunctionResponse = {
37566
39062
  resultType: 'Suspend';
37567
39063
  reason: string;
37568
39064
  };
39065
+ /**
39066
+ * Summary of a single registered function.
39067
+ *
39068
+ * @remarks
39069
+ * A typed signature (name + arity + clause count) projected from the tenant's
39070
+ * slice of the function sub-lattice. Returned by {@link ListFunctionsResponse}.
39071
+ */
39072
+ interface FunctionSummaryDto {
39073
+ /** Number of named arguments the function accepts. */
39074
+ arity: number;
39075
+ /** Number of pattern-matched clauses (tried in order during evaluation). */
39076
+ clausesCount: number;
39077
+ /** Function name (the key used by `POST /functions/evaluate`). */
39078
+ name: string;
39079
+ }
39080
+ /**
39081
+ * Response listing all functions registered for the authenticated tenant.
39082
+ */
39083
+ interface ListFunctionsResponse {
39084
+ /** All functions registered for the requesting tenant, sorted by name. */
39085
+ functions: FunctionSummaryDto[];
39086
+ /** Total count (equals `functions.length`), surfaced for convenience. */
39087
+ total: number;
39088
+ }
37569
39089
 
37570
39090
  type functions_BinaryOperatorDto = BinaryOperatorDto;
37571
39091
  type functions_EvaluateFunctionRequest = EvaluateFunctionRequest;
@@ -37574,12 +39094,14 @@ type functions_ExpressionDto = ExpressionDto;
37574
39094
  type functions_FunctionBodyDto = FunctionBodyDto;
37575
39095
  type functions_FunctionClauseDto = FunctionClauseDto;
37576
39096
  type functions_FunctionGuardDto = FunctionGuardDto;
39097
+ type functions_FunctionSummaryDto = FunctionSummaryDto;
37577
39098
  type functions_FunctionValueDto = FunctionValueDto;
39099
+ type functions_ListFunctionsResponse = ListFunctionsResponse;
37578
39100
  type functions_PatternDto = PatternDto;
37579
39101
  type functions_RegisterFunctionRequest = RegisterFunctionRequest;
37580
39102
  type functions_RegisterFunctionResponse = RegisterFunctionResponse;
37581
39103
  declare namespace functions {
37582
- export type { functions_BinaryOperatorDto as BinaryOperatorDto, functions_EvaluateFunctionRequest as EvaluateFunctionRequest, functions_EvaluateFunctionResponse as EvaluateFunctionResponse, functions_ExpressionDto as ExpressionDto, functions_FunctionBodyDto as FunctionBodyDto, functions_FunctionClauseDto as FunctionClauseDto, functions_FunctionGuardDto as FunctionGuardDto, functions_FunctionValueDto as FunctionValueDto, functions_PatternDto as PatternDto, functions_RegisterFunctionRequest as RegisterFunctionRequest, functions_RegisterFunctionResponse as RegisterFunctionResponse };
39104
+ export type { functions_BinaryOperatorDto as BinaryOperatorDto, functions_EvaluateFunctionRequest as EvaluateFunctionRequest, functions_EvaluateFunctionResponse as EvaluateFunctionResponse, functions_ExpressionDto as ExpressionDto, functions_FunctionBodyDto as FunctionBodyDto, functions_FunctionClauseDto as FunctionClauseDto, functions_FunctionGuardDto as FunctionGuardDto, functions_FunctionSummaryDto as FunctionSummaryDto, functions_FunctionValueDto as FunctionValueDto, functions_ListFunctionsResponse as ListFunctionsResponse, functions_PatternDto as PatternDto, functions_RegisterFunctionRequest as RegisterFunctionRequest, functions_RegisterFunctionResponse as RegisterFunctionResponse };
37583
39105
  }
37584
39106
 
37585
39107
  /**
@@ -37684,6 +39206,30 @@ declare class FunctionsClient {
37684
39206
  * ```
37685
39207
  */
37686
39208
  evaluateFunction(request: EvaluateFunctionRequest): Promise<EvaluateFunctionResponse>;
39209
+ /**
39210
+ * List all functions registered for the authenticated tenant.
39211
+ *
39212
+ * @returns The registered functions as typed signatures (name, arity, clause count) plus a total count.
39213
+ * @throws {ApiError} If the request fails.
39214
+ *
39215
+ * @remarks
39216
+ * This is the discovery counterpart to {@link registerFunction} / {@link evaluateFunction}:
39217
+ * it projects the tenant's slice of the function sub-lattice into a list of typed
39218
+ * signatures without evaluating anything. The tenant is taken from the authenticated
39219
+ * principal (never a body field).
39220
+ *
39221
+ * Returns response-only camelCase types; no value serialization is involved.
39222
+ *
39223
+ * @example
39224
+ * ```typescript
39225
+ * const result = await client.functions.listFunctions();
39226
+ * console.log(result.total); // number of registered functions
39227
+ * for (const fn of result.functions) {
39228
+ * console.log(`${fn.name}/${fn.arity} (${fn.clausesCount} clauses)`);
39229
+ * }
39230
+ * ```
39231
+ */
39232
+ listFunctions(): Promise<ListFunctionsResponse>;
37687
39233
  }
37688
39234
 
37689
39235
  declare class WebhookActions<SecurityDataType = unknown> {
@@ -39662,6 +41208,15 @@ declare class Admin<SecurityDataType = unknown> {
39662
41208
  * @request POST:/api/v1/admin/clear-tenant/{tenant_id}
39663
41209
  */
39664
41210
  clearTenantData: (tenantId: string, params?: RequestParams) => Promise<HttpResponse<ClearTenantResponse$1, void>>;
41211
+ /**
41212
+ * @description Explicitly creates a tenant's inference state and sort hierarchy, optionally seeding initial sorts. Idempotent. No X-Tenant-Id header required.
41213
+ *
41214
+ * @tags admin
41215
+ * @name CreateTenant
41216
+ * @summary Provision a new tenant
41217
+ * @request POST:/api/v1/admin/tenants
41218
+ */
41219
+ createTenant: (data: CreateTenantRequest$1, params?: RequestParams) => Promise<HttpResponse<CreateTenantResponse$1, any>>;
39665
41220
  /**
39666
41221
  * @description Returns all tenant IDs that have terms or ingestion sessions, with counts. No X-Tenant-Id header required. Works in both PostgreSQL and in-memory modes.
39667
41222
  *
@@ -39767,13 +41322,48 @@ interface ListTenantsResponse {
39767
41322
  /** All tenants that have data in the system. */
39768
41323
  tenants: TenantInfoDto[];
39769
41324
  }
41325
+ /**
41326
+ * Request to provision a new tenant.
41327
+ *
41328
+ * @remarks
41329
+ * Provisioning is explicit and idempotent: it materializes the tenant's
41330
+ * inference state and per-tenant sort hierarchy up front, and optionally
41331
+ * seeds initial top-level sorts. All fields are optional — omitted UUIDs
41332
+ * are generated server-side.
41333
+ */
41334
+ interface CreateTenantRequest {
41335
+ /** Optional owner user UUID for the tenant's initial state. Generated when omitted. */
41336
+ ownerUserId?: string | null;
41337
+ /** Optional sort names to seed into the new tenant's hierarchy as top-level sorts. */
41338
+ seedSorts?: string[];
41339
+ /** Optional explicit tenant UUID. A fresh UUID is generated when omitted. */
41340
+ tenantId?: string | null;
41341
+ }
41342
+ /**
41343
+ * Response for the create-tenant operation.
41344
+ *
41345
+ * @remarks
41346
+ * Reports whether the tenant was newly created (vs. already existed, since the
41347
+ * operation is idempotent), how many seed sorts were inserted, and the
41348
+ * provisioned tenant UUID.
41349
+ */
41350
+ interface CreateTenantResponse {
41351
+ /** `true` if the tenant was newly created; `false` if it already existed (idempotent). */
41352
+ created: boolean;
41353
+ /** Number of seed sorts successfully inserted into the tenant hierarchy. */
41354
+ seededSorts: number;
41355
+ /** The provisioned tenant UUID (echoes the request or the generated value). */
41356
+ tenantId: string;
41357
+ }
39770
41358
 
39771
41359
  type admin_ClearTenantResponse = ClearTenantResponse;
41360
+ type admin_CreateTenantRequest = CreateTenantRequest;
41361
+ type admin_CreateTenantResponse = CreateTenantResponse;
39772
41362
  type admin_FactoryResetResponse = FactoryResetResponse;
39773
41363
  type admin_ListTenantsResponse = ListTenantsResponse;
39774
41364
  type admin_TenantInfoDto = TenantInfoDto;
39775
41365
  declare namespace admin {
39776
- export type { admin_ClearTenantResponse as ClearTenantResponse, admin_FactoryResetResponse as FactoryResetResponse, admin_ListTenantsResponse as ListTenantsResponse, admin_TenantInfoDto as TenantInfoDto };
41366
+ export type { admin_ClearTenantResponse as ClearTenantResponse, admin_CreateTenantRequest as CreateTenantRequest, admin_CreateTenantResponse as CreateTenantResponse, admin_FactoryResetResponse as FactoryResetResponse, admin_ListTenantsResponse as ListTenantsResponse, admin_TenantInfoDto as TenantInfoDto };
39777
41367
  }
39778
41368
 
39779
41369
  /**
@@ -39853,6 +41443,31 @@ declare class AdminClient {
39853
41443
  * ```
39854
41444
  */
39855
41445
  listTenants(): Promise<ListTenantsResponse>;
41446
+ /**
41447
+ * Provision a new tenant.
41448
+ *
41449
+ * @param request - Tenant provisioning parameters. All fields are optional;
41450
+ * omitted UUIDs are generated server-side and seed sorts default to none.
41451
+ * @returns Whether the tenant was newly created, how many seed sorts were
41452
+ * inserted, and the provisioned tenant UUID.
41453
+ * @throws {ApiError} If the request fails.
41454
+ *
41455
+ * @remarks
41456
+ * Explicitly creates a tenant's inference state and sort hierarchy, optionally
41457
+ * seeding initial top-level sorts. Idempotent — provisioning an existing tenant
41458
+ * returns `created: false`. No `X-Tenant-Id` header is required.
41459
+ *
41460
+ * @example
41461
+ * ```typescript
41462
+ * const result = await client.admin.createTenant({
41463
+ * seedSorts: ['Person', 'Organization'],
41464
+ * });
41465
+ * console.log(result.tenantId); // generated UUID
41466
+ * console.log(result.created); // true
41467
+ * console.log(result.seededSorts); // 2
41468
+ * ```
41469
+ */
41470
+ createTenant(request: CreateTenantRequest): Promise<CreateTenantResponse>;
39856
41471
  }
39857
41472
 
39858
41473
  declare class ImageExtraction<SecurityDataType = unknown> {
@@ -40659,7 +42274,7 @@ interface VariableBounds {
40659
42274
  * };
40660
42275
  * ```
40661
42276
  */
40662
- interface LinearConstraint {
42277
+ interface LinearConstraint$1 {
40663
42278
  /** Coefficients per variable. Missing variables have coefficient 0. */
40664
42279
  coefficients: LinearExpression;
40665
42280
  /** Comparison operator: <=, >=, or =. */
@@ -40706,7 +42321,7 @@ interface LinearProgramDefinition {
40706
42321
  /** Objective function to maximize or minimize. */
40707
42322
  objective: ObjectiveFunction;
40708
42323
  /** Linear constraints. */
40709
- constraints: LinearConstraint[];
42324
+ constraints: LinearConstraint$1[];
40710
42325
  /** Variable bounds. Variables not listed are unbounded. */
40711
42326
  bounds?: Record<string, VariableBounds>;
40712
42327
  }
@@ -40815,7 +42430,7 @@ interface KBOptimizationConfig {
40815
42430
  /** Whether all variables must be non-negative (default: false). */
40816
42431
  nonNegative?: boolean;
40817
42432
  /** Additional explicit constraints to add beyond those discovered from the KB. */
40818
- additionalConstraints?: LinearConstraint[];
42433
+ additionalConstraints?: LinearConstraint$1[];
40819
42434
  }
40820
42435
  /**
40821
42436
  * Result of a KB-driven optimization, including the discovered problem.
@@ -40835,7 +42450,6 @@ type optimize_KBOptimizationConfig = KBOptimizationConfig;
40835
42450
  type optimize_KBOptimizationResult = KBOptimizationResult;
40836
42451
  type optimize_KBResourceConstraint = KBResourceConstraint;
40837
42452
  type optimize_KBVariableSpec = KBVariableSpec;
40838
- type optimize_LinearConstraint = LinearConstraint;
40839
42453
  type optimize_LinearExpression = LinearExpression;
40840
42454
  type optimize_LinearProgramDefinition = LinearProgramDefinition;
40841
42455
  type optimize_ObjectiveFunction = ObjectiveFunction;
@@ -40845,7 +42459,7 @@ type optimize_OptimizationResult = OptimizationResult;
40845
42459
  type optimize_SolveOptions = SolveOptions;
40846
42460
  type optimize_VariableBounds = VariableBounds;
40847
42461
  declare namespace optimize {
40848
- export type { optimize_ConstraintOperator as ConstraintOperator, optimize_InfeasibleResult as InfeasibleResult, optimize_KBOptimizationConfig as KBOptimizationConfig, optimize_KBOptimizationResult as KBOptimizationResult, optimize_KBResourceConstraint as KBResourceConstraint, optimize_KBVariableSpec as KBVariableSpec, optimize_LinearConstraint as LinearConstraint, optimize_LinearExpression as LinearExpression, optimize_LinearProgramDefinition as LinearProgramDefinition, optimize_ObjectiveFunction as ObjectiveFunction, optimize_OptimalResult as OptimalResult, optimize_OptimizationDirection as OptimizationDirection, optimize_OptimizationResult as OptimizationResult, optimize_SolveOptions as SolveOptions, optimize_VariableBounds as VariableBounds };
42462
+ export type { optimize_ConstraintOperator as ConstraintOperator, optimize_InfeasibleResult as InfeasibleResult, optimize_KBOptimizationConfig as KBOptimizationConfig, optimize_KBOptimizationResult as KBOptimizationResult, optimize_KBResourceConstraint as KBResourceConstraint, optimize_KBVariableSpec as KBVariableSpec, LinearConstraint$1 as LinearConstraint, optimize_LinearExpression as LinearExpression, optimize_LinearProgramDefinition as LinearProgramDefinition, optimize_ObjectiveFunction as ObjectiveFunction, optimize_OptimalResult as OptimalResult, optimize_OptimizationDirection as OptimizationDirection, optimize_OptimizationResult as OptimizationResult, optimize_SolveOptions as SolveOptions, optimize_VariableBounds as VariableBounds };
40849
42463
  }
40850
42464
 
40851
42465
  /**
@@ -42014,6 +43628,53 @@ interface ConversationTurnsResponse {
42014
43628
  conversationId: string;
42015
43629
  turns: TurnDto[];
42016
43630
  }
43631
+ /**
43632
+ * An entry in a session's focus stack — an entity ranked by ACT-R activation.
43633
+ */
43634
+ interface FocusEntryDto {
43635
+ /** Entity term ID (UUID string). */
43636
+ termId: string;
43637
+ /** Sort name of the entity. */
43638
+ sortName: string;
43639
+ /** Display label, if the entity has a name/label. */
43640
+ label?: string | null;
43641
+ /** Current ACT-R activation (salience). */
43642
+ activation: number;
43643
+ /** Rank (0 = most salient). */
43644
+ rank: number;
43645
+ }
43646
+ /**
43647
+ * A cross-turn coreference resolved within a session.
43648
+ */
43649
+ interface ResolvedCoreferenceDto {
43650
+ /** The referring-expression kind (from the LLM sensor). */
43651
+ expressionType: string;
43652
+ /** The resolved entity term ID, if any. */
43653
+ resolvedTermId?: string | null;
43654
+ /** The resolved entity's label, if any. */
43655
+ resolvedLabel?: string | null;
43656
+ /** Confidence (salience of the chosen candidate). */
43657
+ confidence: number;
43658
+ /** Whether the top two candidates were close (LLM tiebreaker advised). */
43659
+ ambiguous: boolean;
43660
+ }
43661
+ /**
43662
+ * Session memory snapshot for a conversation.
43663
+ *
43664
+ * @remarks
43665
+ * Inspects the session's focus stack (entities ranked by ACT-R activation) and
43666
+ * the cross-turn references resolved so far.
43667
+ */
43668
+ interface SessionGraphDto {
43669
+ /** Session ID (the conversation's UUID). */
43670
+ sessionId: string;
43671
+ /** Current turn number. */
43672
+ currentTurn: number;
43673
+ /** Entities ranked by current activation (most salient first). */
43674
+ focusStack: FocusEntryDto[];
43675
+ /** Cross-turn references resolved so far. */
43676
+ resolvedCoreferences: ResolvedCoreferenceDto[];
43677
+ }
42017
43678
 
42018
43679
  type conversation_ClaimAnnotationDto = ClaimAnnotationDto;
42019
43680
  type conversation_ConversationMessageRequest = ConversationMessageRequest;
@@ -42021,12 +43682,15 @@ type conversation_ConversationMessageResponse = ConversationMessageResponse;
42021
43682
  type conversation_ConversationSummaryDto = ConversationSummaryDto;
42022
43683
  type conversation_ConversationTurnsResponse = ConversationTurnsResponse;
42023
43684
  type conversation_DerivationSummaryDto = DerivationSummaryDto;
43685
+ type conversation_FocusEntryDto = FocusEntryDto;
42024
43686
  type conversation_ListConversationsResponse = ListConversationsResponse;
42025
43687
  type conversation_ProofTraceNodeDto = ProofTraceNodeDto;
43688
+ type conversation_ResolvedCoreferenceDto = ResolvedCoreferenceDto;
43689
+ type conversation_SessionGraphDto = SessionGraphDto;
42026
43690
  type conversation_TurnDto = TurnDto;
42027
43691
  type conversation_UICustomizationDto = UICustomizationDto;
42028
43692
  declare namespace conversation {
42029
- export type { conversation_ClaimAnnotationDto as ClaimAnnotationDto, conversation_ConversationMessageRequest as ConversationMessageRequest, conversation_ConversationMessageResponse as ConversationMessageResponse, conversation_ConversationSummaryDto as ConversationSummaryDto, conversation_ConversationTurnsResponse as ConversationTurnsResponse, conversation_DerivationSummaryDto as DerivationSummaryDto, conversation_ListConversationsResponse as ListConversationsResponse, conversation_ProofTraceNodeDto as ProofTraceNodeDto, SourceExcerptDto$1 as SourceExcerptDto, conversation_TurnDto as TurnDto, conversation_UICustomizationDto as UICustomizationDto };
43693
+ export type { conversation_ClaimAnnotationDto as ClaimAnnotationDto, conversation_ConversationMessageRequest as ConversationMessageRequest, conversation_ConversationMessageResponse as ConversationMessageResponse, conversation_ConversationSummaryDto as ConversationSummaryDto, conversation_ConversationTurnsResponse as ConversationTurnsResponse, conversation_DerivationSummaryDto as DerivationSummaryDto, conversation_FocusEntryDto as FocusEntryDto, conversation_ListConversationsResponse as ListConversationsResponse, conversation_ProofTraceNodeDto as ProofTraceNodeDto, conversation_ResolvedCoreferenceDto as ResolvedCoreferenceDto, conversation_SessionGraphDto as SessionGraphDto, SourceExcerptDto$1 as SourceExcerptDto, conversation_TurnDto as TurnDto, conversation_UICustomizationDto as UICustomizationDto };
42030
43694
  }
42031
43695
 
42032
43696
  /**
@@ -42115,6 +43779,28 @@ declare class ConversationClient {
42115
43779
  * ```
42116
43780
  */
42117
43781
  getTurns(conversationId: string): Promise<ConversationTurnsResponse>;
43782
+ /**
43783
+ * Get the session memory graph for a conversation.
43784
+ *
43785
+ * @param conversationId - The conversation ID.
43786
+ * @returns The session's focus stack (entities ranked by ACT-R activation) and
43787
+ * the cross-turn coreferences resolved so far.
43788
+ * @throws {ApiError} If the request fails.
43789
+ *
43790
+ * @remarks
43791
+ * Inspects the session memory for a conversation: the focus stack (entities
43792
+ * ranked by ACT-R activation) and the cross-turn references resolved so far.
43793
+ *
43794
+ * @example
43795
+ * ```typescript
43796
+ * const graph = await client.conversation.getSessionGraph('conv-uuid');
43797
+ * console.log(`Turn ${graph.currentTurn}`);
43798
+ * for (const entry of graph.focusStack) {
43799
+ * console.log(`#${entry.rank} ${entry.label ?? entry.termId} (${entry.activation})`);
43800
+ * }
43801
+ * ```
43802
+ */
43803
+ getSessionGraph(conversationId: string): Promise<SessionGraphDto>;
42118
43804
  /**
42119
43805
  * Delete a conversation and all its turns.
42120
43806
  *
@@ -43715,6 +45401,2184 @@ declare class OperationsClient {
43715
45401
  antiUnify(request: AntiUnifyRequest): Promise<AntiUnifyResponse>;
43716
45402
  }
43717
45403
 
45404
+ declare class Actions<SecurityDataType = unknown> {
45405
+ http: HttpClient<SecurityDataType>;
45406
+ constructor(http: HttpClient<SecurityDataType>);
45407
+ /**
45408
+ * No description
45409
+ *
45410
+ * @tags actions
45411
+ * @name ApplyAction
45412
+ * @summary Apply a typed action transactionally.
45413
+ * @request POST:/api/v1/actions/apply
45414
+ * @secure
45415
+ */
45416
+ applyAction: (data: ApplyActionRequest$1, params?: RequestParams) => Promise<HttpResponse<ApplyActionResponse$1, ApplyActionResponse$1>>;
45417
+ }
45418
+
45419
+ /**
45420
+ * One scalar feature projected as an ontology property.
45421
+ *
45422
+ * @remarks
45423
+ * Projected from a sort's appropriateness conditions. Wire shape (`PropertyDto`)
45424
+ * uses camelCase field names (`apiName`, `dataType`).
45425
+ */
45426
+ interface Property {
45427
+ /** The feature name (Palantir property apiName). */
45428
+ apiName: string;
45429
+ /** The declared value-type hint, or `"string"` when unspecified. */
45430
+ dataType: string;
45431
+ /** Whether the feature is required by the sort's appropriateness conditions. */
45432
+ required: boolean;
45433
+ }
45434
+ /**
45435
+ * One action parameter projected from an action input spec.
45436
+ *
45437
+ * @remarks
45438
+ * Wire shape (`ActionParameterDto`) uses the same field names; this type is
45439
+ * shared with the {@link ActionType} projection.
45440
+ */
45441
+ interface ActionParameter {
45442
+ /** Parameter (input feature) name. */
45443
+ name: string;
45444
+ /** Whether the input is required. */
45445
+ required: boolean;
45446
+ }
45447
+ /**
45448
+ * One projected action type from the system action-spec catalog.
45449
+ *
45450
+ * @remarks
45451
+ * Wire shape (`ActionTypeDto`) uses camelCase field names
45452
+ * (`apiName`, `displayName`).
45453
+ */
45454
+ interface ActionType {
45455
+ /** Action sort name (Palantir action-type apiName). */
45456
+ apiName: string;
45457
+ /** Human-facing name (the action sort name). */
45458
+ displayName: string;
45459
+ /** Parameters — required inputs first, then optional. */
45460
+ parameters: ActionParameter[];
45461
+ }
45462
+ /**
45463
+ * Response for `GET /api/v1/ontology/action-types`.
45464
+ *
45465
+ * @remarks
45466
+ * Shared with the Actions domain via `./actions.js`.
45467
+ */
45468
+ interface ActionTypeListResponse {
45469
+ /** The projected action types. */
45470
+ actionTypes: ActionType[];
45471
+ /** Number of action types returned. */
45472
+ count: number;
45473
+ }
45474
+ /**
45475
+ * One projected function type from the tenant's function store.
45476
+ *
45477
+ * @remarks
45478
+ * Wire shape (`FunctionTypeDto`) uses camelCase field names
45479
+ * (`apiName`, `displayName`, `clausesCount`).
45480
+ */
45481
+ interface FunctionType {
45482
+ /** Function name (Palantir function-type apiName). */
45483
+ apiName: string;
45484
+ /** Number of named-feature parameters (the function's arity). */
45485
+ arity: number;
45486
+ /** Number of defining clauses (homoiconic rules) backing the function. */
45487
+ clausesCount: number;
45488
+ /** Human-facing name (the function name). */
45489
+ displayName: string;
45490
+ }
45491
+ /**
45492
+ * Response for `GET /api/v1/ontology/function-types`.
45493
+ */
45494
+ interface FunctionTypeListResponse {
45495
+ /** Number of function types returned. */
45496
+ count: number;
45497
+ /** The projected function types, ordered by apiName. */
45498
+ functionTypes: FunctionType[];
45499
+ }
45500
+ /**
45501
+ * One projected interface type from a non-maximal (abstract) sort.
45502
+ *
45503
+ * @remarks
45504
+ * Wire shape (`InterfaceTypeDto`) uses camelCase field names
45505
+ * (`apiName`, `displayName`, `extendsInterfaceTypes`).
45506
+ */
45507
+ interface InterfaceType {
45508
+ /** Sort name (Palantir interface-type apiName). */
45509
+ apiName: string;
45510
+ /** Sort description, if any. */
45511
+ description?: string | null;
45512
+ /** Human-facing name (the sort name). */
45513
+ displayName: string;
45514
+ /** apiNames of supersorts that are themselves interfaces (extended interfaces). */
45515
+ extendsInterfaceTypes: string[];
45516
+ /** The appropriate scalar features that form the inherited contract. */
45517
+ properties: Property[];
45518
+ }
45519
+ /**
45520
+ * Response for `GET /api/v1/ontology/interface-types`.
45521
+ */
45522
+ interface InterfaceTypeListResponse {
45523
+ /** Number of interface types returned. */
45524
+ count: number;
45525
+ /** The projected interface types. */
45526
+ interfaceTypes: InterfaceType[];
45527
+ }
45528
+ /**
45529
+ * One projected link type from a referring feature.
45530
+ *
45531
+ * @remarks
45532
+ * Wire shape (`LinkTypeDto`) uses camelCase field names
45533
+ * (`apiName`, `displayName`, `linkedObjectTypeApiName`, `objectTypeApiName`).
45534
+ */
45535
+ interface LinkType {
45536
+ /** Qualified apiName `"<sort>.<feature>"`. */
45537
+ apiName: string;
45538
+ /** Cardinality — `ONE`, because OSF features are functional. */
45539
+ cardinality: string;
45540
+ /** The feature name. */
45541
+ displayName: string;
45542
+ /** The target object type (the feature's value sort). */
45543
+ linkedObjectTypeApiName: string;
45544
+ /** The source object type (the sort declaring the feature). */
45545
+ objectTypeApiName: string;
45546
+ }
45547
+ /**
45548
+ * Response for `GET /api/v1/ontology/link-types`.
45549
+ */
45550
+ interface LinkTypeListResponse {
45551
+ /** Number of link types returned. */
45552
+ count: number;
45553
+ /** The projected link types. */
45554
+ linkTypes: LinkType[];
45555
+ }
45556
+ /**
45557
+ * One projected object type from a tenant sort.
45558
+ *
45559
+ * @remarks
45560
+ * Wire shape (`ObjectTypeDto`) uses camelCase field names
45561
+ * (`apiName`, `displayName`, `implementsInterfaceTypes`, `primaryKey`).
45562
+ */
45563
+ interface ObjectType {
45564
+ /** Sort name (Palantir object-type apiName). */
45565
+ apiName: string;
45566
+ /** Sort description, if any. */
45567
+ description?: string | null;
45568
+ /** Human-facing name (the sort name). */
45569
+ displayName: string;
45570
+ /** apiNames of the supersorts this sort refines (the interfaces it implements). */
45571
+ implementsInterfaceTypes: string[];
45572
+ /** Primary key — Ψ-terms are identified by their `TermId`. */
45573
+ primaryKey: string[];
45574
+ /** Appropriate scalar features projected as properties. */
45575
+ properties: Property[];
45576
+ /** Lifecycle status — always `ACTIVE` for a live sort. */
45577
+ status: string;
45578
+ }
45579
+ /**
45580
+ * Response for `GET /api/v1/ontology/object-types`.
45581
+ */
45582
+ interface ObjectTypeListResponse {
45583
+ /** Number of object types returned. */
45584
+ count: number;
45585
+ /** The projected object types. */
45586
+ objectTypes: ObjectType[];
45587
+ }
45588
+
45589
+ type ontologyFacade_ActionParameter = ActionParameter;
45590
+ type ontologyFacade_ActionType = ActionType;
45591
+ type ontologyFacade_ActionTypeListResponse = ActionTypeListResponse;
45592
+ type ontologyFacade_FunctionType = FunctionType;
45593
+ type ontologyFacade_FunctionTypeListResponse = FunctionTypeListResponse;
45594
+ type ontologyFacade_InterfaceType = InterfaceType;
45595
+ type ontologyFacade_InterfaceTypeListResponse = InterfaceTypeListResponse;
45596
+ type ontologyFacade_LinkType = LinkType;
45597
+ type ontologyFacade_LinkTypeListResponse = LinkTypeListResponse;
45598
+ type ontologyFacade_ObjectType = ObjectType;
45599
+ type ontologyFacade_ObjectTypeListResponse = ObjectTypeListResponse;
45600
+ type ontologyFacade_Property = Property;
45601
+ declare namespace ontologyFacade {
45602
+ export type { ontologyFacade_ActionParameter as ActionParameter, ontologyFacade_ActionType as ActionType, ontologyFacade_ActionTypeListResponse as ActionTypeListResponse, ontologyFacade_FunctionType as FunctionType, ontologyFacade_FunctionTypeListResponse as FunctionTypeListResponse, ontologyFacade_InterfaceType as InterfaceType, ontologyFacade_InterfaceTypeListResponse as InterfaceTypeListResponse, ontologyFacade_LinkType as LinkType, ontologyFacade_LinkTypeListResponse as LinkTypeListResponse, ontologyFacade_ObjectType as ObjectType, ontologyFacade_ObjectTypeListResponse as ObjectTypeListResponse, ontologyFacade_Property as Property };
45603
+ }
45604
+
45605
+ /**
45606
+ * One typed parameter of an action schema.
45607
+ *
45608
+ * @remarks
45609
+ * Wire shape (`ParamSpecDto`) uses snake_case (`param_type`).
45610
+ */
45611
+ interface ParamSpec {
45612
+ /** Feature name. */
45613
+ name: string;
45614
+ /** Appropriateness type: `integer`, `real`, `string`, `boolean`, or `any`. */
45615
+ paramType: string;
45616
+ /** Whether the input must be bound for the action to be `Ready`. */
45617
+ required?: boolean;
45618
+ }
45619
+ /**
45620
+ * A validation rule over an action's parameters.
45621
+ *
45622
+ * @remarks
45623
+ * Tagged discriminated union with `rule` as the discriminant. The wire shape
45624
+ * (`ActionParamRuleDto`) is externally tagged by rule name
45625
+ * (`non_empty_string`, `int_range`, `real_range`, `one_of`).
45626
+ */
45627
+ type ActionParamRule = {
45628
+ /** String parameter, when present, must be non-empty. */
45629
+ rule: 'non_empty_string';
45630
+ /** Parameter the rule applies to. */
45631
+ param: string;
45632
+ } | {
45633
+ /** Integer parameter, when present, in `[min, max]`. */
45634
+ rule: 'int_range';
45635
+ /** Parameter the rule applies to. */
45636
+ param: string;
45637
+ /** Inclusive lower bound. */
45638
+ min: number;
45639
+ /** Inclusive upper bound. */
45640
+ max: number;
45641
+ } | {
45642
+ /** Real parameter, when present, in `[min, max]`. */
45643
+ rule: 'real_range';
45644
+ /** Parameter the rule applies to. */
45645
+ param: string;
45646
+ /** Inclusive lower bound. */
45647
+ min: number;
45648
+ /** Inclusive upper bound. */
45649
+ max: number;
45650
+ } | {
45651
+ /** String parameter, when present, must be one of `allowed`. */
45652
+ rule: 'one_of';
45653
+ /** Parameter the rule applies to. */
45654
+ param: string;
45655
+ /** Permitted values. */
45656
+ allowed: string[];
45657
+ };
45658
+ /**
45659
+ * A declarative side-effect fired after the action applies.
45660
+ *
45661
+ * @remarks
45662
+ * Wire shape (`ActionSideEffectDto`) uses the same field names.
45663
+ */
45664
+ interface ActionSideEffect {
45665
+ /** Notification title. */
45666
+ title: string;
45667
+ /** Notification body. */
45668
+ body: string;
45669
+ /** Delivery channel: `webhook`, `email`, `in_app`, or `browser_push`. */
45670
+ channel: string;
45671
+ /** Recipient/target (webhook URL or recipient address). */
45672
+ target: string;
45673
+ }
45674
+ /**
45675
+ * A typed, validated, RBAC-bound action schema.
45676
+ *
45677
+ * @remarks
45678
+ * Wire shape (`ActionTypeDefDto`) uses snake_case for `required_roles` and
45679
+ * `side_effects`.
45680
+ */
45681
+ interface ActionTypeDef {
45682
+ /** Action type name (the action sort). */
45683
+ name: string;
45684
+ /** Typed parameters. */
45685
+ params?: ParamSpec[];
45686
+ /** Roles required to apply this action (empty ⇒ unrestricted). */
45687
+ requiredRoles?: string[];
45688
+ /** Validation rules over parameters. */
45689
+ rules?: ActionParamRule[];
45690
+ /** Side-effects to dispatch once the action applies. */
45691
+ sideEffects?: ActionSideEffect[];
45692
+ }
45693
+ /**
45694
+ * A multi-term edit committed atomically when an action is `Ready`.
45695
+ *
45696
+ * @remarks
45697
+ * Tagged discriminated union with `op` as the discriminant. The wire shape
45698
+ * (`TermEditDto`) is externally tagged (`{ put: ... }` or `{ remove: ... }`).
45699
+ * The `put` payload reuses the standard {@link CreateTermRequest} body.
45700
+ */
45701
+ type TermEdit = {
45702
+ /** Create or overwrite a term. */
45703
+ op: 'put';
45704
+ /** The term-creation body (tagged {@link ValueDto} features). */
45705
+ term: CreateTermRequest;
45706
+ } | {
45707
+ /** Remove an existing term by id. */
45708
+ op: 'remove';
45709
+ /** Term UUID to remove. */
45710
+ termId: string;
45711
+ };
45712
+ /**
45713
+ * Request to apply a typed action transactionally.
45714
+ *
45715
+ * @remarks
45716
+ * Wire shape (`ApplyActionRequest`) uses snake_case (`caller_roles`).
45717
+ * Bound inputs map feature names to arbitrary JSON values.
45718
+ */
45719
+ interface ApplyActionRequest {
45720
+ /** The action schema to apply. */
45721
+ action: ActionTypeDef;
45722
+ /** Bound input features (`feature → JSON value`). */
45723
+ inputs?: Record<string, JsonValue$1>;
45724
+ /** Roles held by the caller (checked against `action.requiredRoles`). */
45725
+ callerRoles?: string[];
45726
+ /** Multi-term edits to commit atomically when the action is `Ready`. */
45727
+ edits?: TermEdit[];
45728
+ }
45729
+ /**
45730
+ * Outcome of applying an action.
45731
+ *
45732
+ * @remarks
45733
+ * Tagged discriminated union with `outcome` as the discriminant. The wire
45734
+ * shape (`ApplyActionResponse`) uses the same discriminant with snake_case
45735
+ * fields (`side_effects_dispatched`, `side_effects_failed`).
45736
+ */
45737
+ type ApplyActionResponse = {
45738
+ /** The action applied successfully. */
45739
+ outcome: 'applied';
45740
+ /** Number of side-effects delivered successfully. */
45741
+ sideEffectsDispatched: number;
45742
+ /** Number of side-effects whose delivery failed (apply still succeeded). */
45743
+ sideEffectsFailed: number;
45744
+ } | {
45745
+ /** The action is waiting for required inputs to be bound. */
45746
+ outcome: 'suspended';
45747
+ /** Names of the unbound required parameters. */
45748
+ missing: string[];
45749
+ } | {
45750
+ /** The action was rejected before applying. */
45751
+ outcome: 'rejected';
45752
+ /** Human-readable reason. */
45753
+ reason: string;
45754
+ } | {
45755
+ /** The action applied then rolled back. */
45756
+ outcome: 'rolled_back';
45757
+ /** Human-readable cause. */
45758
+ reason: string;
45759
+ };
45760
+
45761
+ type actions_ActionParamRule = ActionParamRule;
45762
+ type actions_ActionParameter = ActionParameter;
45763
+ type actions_ActionSideEffect = ActionSideEffect;
45764
+ type actions_ActionType = ActionType;
45765
+ type actions_ActionTypeDef = ActionTypeDef;
45766
+ type actions_ActionTypeListResponse = ActionTypeListResponse;
45767
+ type actions_ApplyActionRequest = ApplyActionRequest;
45768
+ type actions_ApplyActionResponse = ApplyActionResponse;
45769
+ type actions_ParamSpec = ParamSpec;
45770
+ type actions_TermEdit = TermEdit;
45771
+ declare namespace actions {
45772
+ export type { actions_ActionParamRule as ActionParamRule, actions_ActionParameter as ActionParameter, actions_ActionSideEffect as ActionSideEffect, actions_ActionType as ActionType, actions_ActionTypeDef as ActionTypeDef, actions_ActionTypeListResponse as ActionTypeListResponse, actions_ApplyActionRequest as ApplyActionRequest, actions_ApplyActionResponse as ApplyActionResponse, actions_ParamSpec as ParamSpec, actions_TermEdit as TermEdit };
45773
+ }
45774
+
45775
+ /**
45776
+ * Resource client for applying typed actions.
45777
+ *
45778
+ * @remarks
45779
+ * Provides access to the transactional action-application endpoint. An action
45780
+ * is a typed, validated, RBAC-bound schema; applying it binds inputs, runs
45781
+ * parameter rules, commits any atomic term edits, and dispatches declarative
45782
+ * side-effects.
45783
+ *
45784
+ * Uses normalizers to convert between the SDK surface types (camelCase,
45785
+ * `op`/`rule`/`outcome`-discriminated unions) and the wire format
45786
+ * (snake_case, externally tagged unions) at the boundary.
45787
+ */
45788
+ declare class ActionsClient {
45789
+ /** @internal */
45790
+ private readonly api;
45791
+ /** @internal */
45792
+ constructor(api: Actions);
45793
+ /**
45794
+ * Apply a typed action transactionally.
45795
+ *
45796
+ * @param request - The action schema, bound inputs, caller roles, and any
45797
+ * atomic term edits to commit when the action is `Ready`.
45798
+ * @returns The outcome — `applied` (with side-effect dispatch counts),
45799
+ * `suspended` (with the unbound required parameters), `rejected`, or
45800
+ * `rolled_back` (each with a reason).
45801
+ * @throws {ApiError} If the request fails.
45802
+ *
45803
+ * @remarks
45804
+ * Calls `POST /api/v1/actions/apply`. The request is converted to the wire
45805
+ * format (snake_case fields such as `caller_roles`, externally tagged
45806
+ * `rules`/`edits`) before sending; the response is normalized back to the
45807
+ * `outcome`-discriminated SDK union.
45808
+ *
45809
+ * @example
45810
+ * ```typescript
45811
+ * const result = await client.actions.applyAction({
45812
+ * action: {
45813
+ * name: 'approve_invoice',
45814
+ * params: [{ name: 'invoice_id', paramType: 'string', required: true }],
45815
+ * requiredRoles: ['finance'],
45816
+ * },
45817
+ * inputs: { invoice_id: 'INV-42' },
45818
+ * callerRoles: ['finance'],
45819
+ * });
45820
+ * if (result.outcome === 'applied') {
45821
+ * console.log(result.sideEffectsDispatched);
45822
+ * } else if (result.outcome === 'suspended') {
45823
+ * console.log('missing', result.missing);
45824
+ * }
45825
+ * ```
45826
+ */
45827
+ applyAction(request: ApplyActionRequest): Promise<ApplyActionResponse>;
45828
+ }
45829
+
45830
+ declare class ComplianceMarkings<SecurityDataType = unknown> {
45831
+ http: HttpClient<SecurityDataType>;
45832
+ constructor(http: HttpClient<SecurityDataType>);
45833
+ /**
45834
+ * No description
45835
+ *
45836
+ * @tags compliance-markings
45837
+ * @name Gate
45838
+ * @summary `POST /api/v1/compliance/markings/gate` — may a reader holding `clearance` see data marked `marking`? Unknown level names yield 400.
45839
+ * @request POST:/api/v1/compliance/markings/gate
45840
+ * @secure
45841
+ */
45842
+ gate: (data: GateRequest$1, params?: RequestParams) => Promise<HttpResponse<GateResponse$1, void>>;
45843
+ /**
45844
+ * No description
45845
+ *
45846
+ * @tags compliance-markings
45847
+ * @name ListLevels
45848
+ * @summary `GET /api/v1/compliance/markings/levels` — the classification lattice.
45849
+ * @request GET:/api/v1/compliance/markings/levels
45850
+ * @secure
45851
+ */
45852
+ listLevels: (params?: RequestParams) => Promise<HttpResponse<ListLevelsResponse$1, any>>;
45853
+ /**
45854
+ * No description
45855
+ *
45856
+ * @tags compliance-markings
45857
+ * @name ReadableTerms
45858
+ * @summary `GET /api/v1/compliance/markings/readable-terms?clearance=` — the tenant's terms a requester holding `clearance` may read. Withheld (residuated) terms are absent and only counted. `clearance` defaults to `Unclassified`.
45859
+ * @request GET:/api/v1/compliance/markings/readable-terms
45860
+ * @secure
45861
+ */
45862
+ readableTerms: (query?: {
45863
+ /** Clearance level (defaults to Unclassified) */
45864
+ clearance?: string;
45865
+ }, params?: RequestParams) => Promise<HttpResponse<ReadableTermsResponse$1, void>>;
45866
+ }
45867
+
45868
+ /**
45869
+ * Request to evaluate a classification gate.
45870
+ *
45871
+ * @remarks
45872
+ * Sent to `POST /api/v1/compliance/markings/gate`. Asks whether a reader
45873
+ * holding `clearance` may see data marked `marking`. Both fields are
45874
+ * classification level names from the lattice (e.g. `"Unclassified"`,
45875
+ * `"Secret"`). Unknown level names yield a 400 error.
45876
+ */
45877
+ interface GateRequest {
45878
+ /** Classification level the reader holds. */
45879
+ clearance: string;
45880
+ /** Classification level the data is marked with. */
45881
+ marking: string;
45882
+ }
45883
+ /**
45884
+ * Result of a classification gate evaluation.
45885
+ *
45886
+ * @remarks
45887
+ * Returned by `POST /api/v1/compliance/markings/gate`. `dominates` is the
45888
+ * boolean verdict (does the clearance dominate the marking?); `decision` is
45889
+ * the human-readable rendering of that verdict.
45890
+ */
45891
+ interface GateResponse {
45892
+ /** The clearance level that was evaluated. */
45893
+ clearance: string;
45894
+ /** Human-readable gate decision. */
45895
+ decision: string;
45896
+ /** Whether the clearance dominates the marking (the access verdict). */
45897
+ dominates: boolean;
45898
+ /** The marking level that was evaluated. */
45899
+ marking: string;
45900
+ }
45901
+ /**
45902
+ * A single classification level in the lattice.
45903
+ *
45904
+ * @remarks
45905
+ * Returned as an element of {@link ListLevelsResponse}. `level` is the numeric
45906
+ * rank within the lattice (0 = least sensitive); `name` is the level's label.
45907
+ */
45908
+ interface ClassificationLevelDto {
45909
+ /** Numeric rank of the level within the lattice (0 = least sensitive). */
45910
+ level: number;
45911
+ /** Level name (e.g. "Unclassified", "Secret"). */
45912
+ name: string;
45913
+ }
45914
+ /**
45915
+ * The classification lattice.
45916
+ *
45917
+ * @remarks
45918
+ * Returned by `GET /api/v1/compliance/markings/levels`.
45919
+ */
45920
+ interface ListLevelsResponse {
45921
+ /** The classification levels, ordered by the lattice. */
45922
+ levels: ClassificationLevelDto[];
45923
+ }
45924
+ /**
45925
+ * A term the requester is cleared to read, with its marking.
45926
+ *
45927
+ * @remarks
45928
+ * Returned as an element of {@link ReadableTermsResponse}.
45929
+ */
45930
+ interface ReadableTermDto {
45931
+ /** Term ID (UUID). */
45932
+ id: string;
45933
+ /** Classification level the term is marked with. */
45934
+ marking: string;
45935
+ }
45936
+ /**
45937
+ * The tenant's terms a requester holding a given clearance may read.
45938
+ *
45939
+ * @remarks
45940
+ * Returned by `GET /api/v1/compliance/markings/readable-terms`. Withheld
45941
+ * (residuated) terms are absent from `readable` and only reflected in
45942
+ * `withheldCount`.
45943
+ */
45944
+ interface ReadableTermsResponse {
45945
+ /** The clearance level that was evaluated. */
45946
+ clearance: string;
45947
+ /** The readable terms with their markings. */
45948
+ readable: ReadableTermDto[];
45949
+ /** Number of terms the requester may read. */
45950
+ readableCount: number;
45951
+ /** Number of terms withheld (residuated) from the requester. */
45952
+ withheldCount: number;
45953
+ }
45954
+
45955
+ type complianceMarkings_ClassificationLevelDto = ClassificationLevelDto;
45956
+ type complianceMarkings_GateRequest = GateRequest;
45957
+ type complianceMarkings_GateResponse = GateResponse;
45958
+ type complianceMarkings_ListLevelsResponse = ListLevelsResponse;
45959
+ type complianceMarkings_ReadableTermDto = ReadableTermDto;
45960
+ type complianceMarkings_ReadableTermsResponse = ReadableTermsResponse;
45961
+ declare namespace complianceMarkings {
45962
+ export type { complianceMarkings_ClassificationLevelDto as ClassificationLevelDto, complianceMarkings_GateRequest as GateRequest, complianceMarkings_GateResponse as GateResponse, complianceMarkings_ListLevelsResponse as ListLevelsResponse, complianceMarkings_ReadableTermDto as ReadableTermDto, complianceMarkings_ReadableTermsResponse as ReadableTermsResponse };
45963
+ }
45964
+
45965
+ /**
45966
+ * Resource client for classification marking (clearance gating) operations.
45967
+ *
45968
+ * @remarks
45969
+ * Provides access to the compliance-markings endpoints, which evaluate the
45970
+ * classification lattice: whether a reader holding a clearance may see data
45971
+ * carrying a marking, the lattice of classification levels, and the tenant's
45972
+ * terms a given clearance may read.
45973
+ *
45974
+ * This is distinct from the broader `compliance` resource.
45975
+ *
45976
+ * Uses normalizers to convert between camelCase (SDK surface) and
45977
+ * snake_case (wire format) at the boundary.
45978
+ */
45979
+ declare class ComplianceMarkingsClient {
45980
+ /** @internal */
45981
+ private readonly api;
45982
+ /** @internal */
45983
+ constructor(api: ComplianceMarkings);
45984
+ /**
45985
+ * Evaluate whether a clearance may see data carrying a marking.
45986
+ *
45987
+ * @param request - The clearance and marking level names to evaluate.
45988
+ * @returns The gate decision, including the `dominates` verdict.
45989
+ * @throws {ApiError} If a level name is unknown (400) or the request fails.
45990
+ *
45991
+ * @remarks
45992
+ * Wire format is snake_case; both `clearance` and `marking` are
45993
+ * classification level names from the lattice.
45994
+ *
45995
+ * @example
45996
+ * ```typescript
45997
+ * const result = await client.complianceMarkings.gate({
45998
+ * clearance: 'Secret',
45999
+ * marking: 'Confidential',
46000
+ * });
46001
+ * console.log(result.dominates); // true
46002
+ * console.log(result.decision); // human-readable verdict
46003
+ * ```
46004
+ */
46005
+ gate(request: GateRequest): Promise<GateResponse>;
46006
+ /**
46007
+ * List the classification lattice.
46008
+ *
46009
+ * @returns The classification levels, ordered by the lattice.
46010
+ * @throws {ApiError} If the request fails.
46011
+ *
46012
+ * @remarks
46013
+ * Wire format is snake_case; each level carries a numeric `level` rank and a
46014
+ * `name`.
46015
+ *
46016
+ * @example
46017
+ * ```typescript
46018
+ * const { levels } = await client.complianceMarkings.listLevels();
46019
+ * console.log(levels.map((l) => l.name)); // ["Unclassified", "Confidential", ...]
46020
+ * ```
46021
+ */
46022
+ listLevels(): Promise<ListLevelsResponse>;
46023
+ /**
46024
+ * List the tenant's terms a requester holding a given clearance may read.
46025
+ *
46026
+ * @param clearance - Clearance level name. Defaults to `Unclassified` on the
46027
+ * backend when omitted.
46028
+ * @returns The readable terms and the readable/withheld counts.
46029
+ * @throws {ApiError} If the clearance name is unknown (400) or the request fails.
46030
+ *
46031
+ * @remarks
46032
+ * Wire format is snake_case (`readable_count`, `withheld_count`). Withheld
46033
+ * (residuated) terms are absent from `readable` and only reflected in
46034
+ * `withheldCount`. The `clearance` argument is passed as the optional
46035
+ * `clearance` query parameter.
46036
+ *
46037
+ * @example
46038
+ * ```typescript
46039
+ * const result = await client.complianceMarkings.readableTerms('Secret');
46040
+ * console.log(result.readableCount);
46041
+ * console.log(result.withheldCount);
46042
+ * console.log(result.readable.map((t) => t.id));
46043
+ * ```
46044
+ */
46045
+ readableTerms(clearance?: string): Promise<ReadableTermsResponse>;
46046
+ }
46047
+
46048
+ declare class Feasibility<SecurityDataType = unknown> {
46049
+ http: HttpClient<SecurityDataType>;
46050
+ constructor(http: HttpClient<SecurityDataType>);
46051
+ /**
46052
+ * No description
46053
+ *
46054
+ * @tags feasibility
46055
+ * @name AssumeFeasibilityVar
46056
+ * @summary Assume a flat decision variable `true` in a feasibility session; returns the trichotomy delta and the updated classification — the per-assumption click path for sessions begun via [`begin_feasibility_session`].
46057
+ * @request POST:/api/v1/feasibility/sessions/{session_id}/assumptions
46058
+ * @secure
46059
+ */
46060
+ assumeFeasibilityVar: (sessionId: string, data: AssumptionRequest$1, params?: RequestParams) => Promise<HttpResponse<SchedulingDeltaResponse$1, void>>;
46061
+ /**
46062
+ * No description
46063
+ *
46064
+ * @tags feasibility
46065
+ * @name BeginFeasibilitySession
46066
+ * @summary Begin a generic constraint-model feasibility session and return its id + the empty-assumptions trichotomy over `0..num_decision_vars`. The declarative-compiler interactive all-feasibilities surface — clicks assume flat variables via [`assume_feasibility_var`].
46067
+ * @request POST:/api/v1/feasibility/sessions
46068
+ * @secure
46069
+ */
46070
+ beginFeasibilitySession: (data: GenericModelRequest$1, params?: RequestParams) => Promise<HttpResponse<SchedulingSessionResponse$1, void>>;
46071
+ /**
46072
+ * No description
46073
+ *
46074
+ * @tags feasibility
46075
+ * @name EndFeasibilitySession
46076
+ * @summary End (drop) a feasibility session.
46077
+ * @request DELETE:/api/v1/feasibility/sessions/{session_id}
46078
+ * @secure
46079
+ */
46080
+ endFeasibilitySession: (sessionId: string, params?: RequestParams) => Promise<HttpResponse<EndSchedulingResponse$1, void>>;
46081
+ /**
46082
+ * No description
46083
+ *
46084
+ * @tags feasibility
46085
+ * @name GetFeasibilitySession
46086
+ * @summary Get a feasibility session's current classification.
46087
+ * @request GET:/api/v1/feasibility/sessions/{session_id}
46088
+ * @secure
46089
+ */
46090
+ getFeasibilitySession: (sessionId: string, params?: RequestParams) => Promise<HttpResponse<SchedulingSessionResponse$1, void>>;
46091
+ /**
46092
+ * No description
46093
+ *
46094
+ * @tags feasibility
46095
+ * @name RetractFeasibilityAssumption
46096
+ * @summary Retract the most recent assumption, restoring the prior classification (no re-solve).
46097
+ * @request DELETE:/api/v1/feasibility/sessions/{session_id}/assumptions/last
46098
+ * @secure
46099
+ */
46100
+ retractFeasibilityAssumption: (sessionId: string, params?: RequestParams) => Promise<HttpResponse<SchedulingSessionResponse$1, void>>;
46101
+ }
46102
+
46103
+ /**
46104
+ * Comparison sense of a {@link LinearConstraint}.
46105
+ *
46106
+ * @remarks
46107
+ * Wire values (snake_case): `"leq"`, `"geq"`, `"eq"`.
46108
+ */
46109
+ type ConstraintSense = 'leq' | 'geq' | 'eq';
46110
+ /**
46111
+ * Direction of an {@link Objective} function.
46112
+ *
46113
+ * @remarks
46114
+ * Wire values (snake_case): `"minimize"`, `"maximize"`.
46115
+ */
46116
+ type ObjectiveSense = 'minimize' | 'maximize';
46117
+ /**
46118
+ * Kind of a {@link VariableSpec} decision variable. Defaults server-side to
46119
+ * `"continuous"`.
46120
+ *
46121
+ * @remarks
46122
+ * Wire values (snake_case): `"continuous"`, `"integer"`, `"binary"`.
46123
+ */
46124
+ type VarKind = 'continuous' | 'integer' | 'binary';
46125
+ /**
46126
+ * Backend-selection hint. `"auto"` (default) routes CP-SAT for fully discrete
46127
+ * problems and HiGHS for any continuous variable.
46128
+ *
46129
+ * @remarks
46130
+ * Wire values (snake_case): `"auto"`, `"prefer_cp"`, `"prefer_lp"`.
46131
+ */
46132
+ type SolverHint = 'auto' | 'prefer_cp' | 'prefer_lp';
46133
+ /**
46134
+ * Status reported by the solver for a solve or classification.
46135
+ *
46136
+ * @remarks
46137
+ * Wire values (snake_case): `"optimal"`, `"feasible"`, `"infeasible"`,
46138
+ * `"unbounded"`, `"unknown"`.
46139
+ */
46140
+ type SolutionStatus = 'optimal' | 'feasible' | 'infeasible' | 'unbounded' | 'unknown';
46141
+ /**
46142
+ * Per-variable classification — the ILP analog of flow-network edge
46143
+ * classification (Dulmage-Mendelsohn).
46144
+ *
46145
+ * @remarks
46146
+ * Wire values (snake_case): `"always_used"`, `"sometimes_used"`,
46147
+ * `"never_used"`.
46148
+ */
46149
+ type VariableClassification = 'always_used' | 'sometimes_used' | 'never_used';
46150
+ /**
46151
+ * Relational operator used by the `compare` variant of a {@link BoolExpr}.
46152
+ *
46153
+ * @remarks
46154
+ * Wire values (snake_case): `"equal"`, `"not_equal"`, `"less_than"`,
46155
+ * `"less_than_or_equal"`, `"greater_than"`, `"greater_than_or_equal"`.
46156
+ */
46157
+ type RelOp = 'equal' | 'not_equal' | 'less_than' | 'less_than_or_equal' | 'greater_than' | 'greater_than_or_equal';
46158
+ /**
46159
+ * A single decision variable. Names must be unique within a problem and are
46160
+ * echoed verbatim in the response `values` map.
46161
+ *
46162
+ * @remarks
46163
+ * Wire shape (snake_case): `{ kind, lower_bound, name, upper_bound }`.
46164
+ */
46165
+ interface VariableSpec {
46166
+ /** Caller-chosen identifier. Must be unique. */
46167
+ name: string;
46168
+ /** Variable kind. Defaults to `"continuous"`. */
46169
+ kind?: VarKind;
46170
+ /** Lower bound. Use negative infinity for unbounded below. */
46171
+ lowerBound?: number;
46172
+ /** Upper bound. Use positive infinity for unbounded above. Ignored for `"binary"` (forced to 1). */
46173
+ upperBound?: number;
46174
+ }
46175
+ /**
46176
+ * A linear constraint `Σ coef_i · x_i (sense) rhs`. Variables not referenced in
46177
+ * `coefficients` are treated as if their coefficient is zero.
46178
+ *
46179
+ * @remarks
46180
+ * Wire shape (snake_case): `{ coefficients, name, rhs, sense }`. This is the
46181
+ * solver/feasibility linear-constraint model; it is distinct from the
46182
+ * `Optimize` namespace's `LinearConstraint`.
46183
+ */
46184
+ interface LinearConstraint {
46185
+ /** Variable-name → coefficient. */
46186
+ coefficients: Record<string, number>;
46187
+ /** Right-hand side. */
46188
+ rhs: number;
46189
+ /** Comparison sense. */
46190
+ sense: ConstraintSense;
46191
+ /** Optional caller-supplied label, returned in error reports. */
46192
+ name?: string | null;
46193
+ }
46194
+ /**
46195
+ * Objective function to optimize.
46196
+ *
46197
+ * @remarks
46198
+ * Wire shape (snake_case): `{ coefficients, constant, sense }`.
46199
+ */
46200
+ interface Objective {
46201
+ /** Direction of the objective function. */
46202
+ sense: ObjectiveSense;
46203
+ /** Variable-name → coefficient. */
46204
+ coefficients?: Record<string, number>;
46205
+ /** Constant addend. */
46206
+ constant?: number;
46207
+ }
46208
+ /**
46209
+ * One term `coeff · var` of a {@link LinExpr}.
46210
+ *
46211
+ * @remarks
46212
+ * Wire shape (snake_case): `{ coeff, var }`.
46213
+ */
46214
+ interface LinTerm {
46215
+ /** The integer coefficient. */
46216
+ coeff: number;
46217
+ /** The flat decision-variable index. */
46218
+ var: number;
46219
+ }
46220
+ /**
46221
+ * A linear expression `Σ coeff·var + constant` over flat decision-variable
46222
+ * indices.
46223
+ *
46224
+ * @remarks
46225
+ * Wire shape (snake_case): `{ constant, terms }`.
46226
+ */
46227
+ interface LinExpr {
46228
+ /** The constant addend. */
46229
+ constant?: number;
46230
+ /** The `coeff·var` terms. */
46231
+ terms?: LinTerm[];
46232
+ }
46233
+ /**
46234
+ * A literal over a flat decision-variable index, with a required polarity.
46235
+ *
46236
+ * @remarks
46237
+ * Wire shape (snake_case): `{ value, var }`.
46238
+ */
46239
+ interface Lit {
46240
+ /** The required polarity (`true` ⇒ the var is set, `false` ⇒ unset). */
46241
+ value: boolean;
46242
+ /** The flat decision-variable index. */
46243
+ var: number;
46244
+ }
46245
+ /**
46246
+ * A boolean-valued expression over flat decision-variable indices.
46247
+ *
46248
+ * @remarks
46249
+ * Tagged discriminated union keyed on `type`. Wire format (snake_case)
46250
+ * mirrors this shape verbatim.
46251
+ */
46252
+ type BoolExpr = {
46253
+ type: 'lit';
46254
+ value: boolean;
46255
+ var: number;
46256
+ } | {
46257
+ type: 'const';
46258
+ value: boolean;
46259
+ } | {
46260
+ type: 'not';
46261
+ expr: BoolExpr;
46262
+ } | {
46263
+ type: 'and';
46264
+ exprs: BoolExpr[];
46265
+ } | {
46266
+ type: 'or';
46267
+ exprs: BoolExpr[];
46268
+ } | {
46269
+ type: 'implies';
46270
+ left: BoolExpr;
46271
+ right: BoolExpr;
46272
+ } | {
46273
+ type: 'iff';
46274
+ left: BoolExpr;
46275
+ right: BoolExpr;
46276
+ } | {
46277
+ type: 'xor';
46278
+ left: BoolExpr;
46279
+ right: BoolExpr;
46280
+ } | {
46281
+ type: 'compare';
46282
+ left: LinExpr;
46283
+ op: RelOp;
46284
+ right: LinExpr;
46285
+ };
46286
+ /**
46287
+ * A temporal rule enforced over a `regular` timeline.
46288
+ *
46289
+ * @remarks
46290
+ * Tagged discriminated union keyed on `type`. Wire format (snake_case)
46291
+ * mirrors this shape verbatim.
46292
+ */
46293
+ type TemporalRule = {
46294
+ type: 'no_consec';
46295
+ } | {
46296
+ type: 'capacity';
46297
+ max1ShiftPerDay: boolean;
46298
+ maxDays: number;
46299
+ } | {
46300
+ type: 'max_consecutive_nights';
46301
+ k: number;
46302
+ };
46303
+ /**
46304
+ * A typed constraint over the flat decision variables.
46305
+ *
46306
+ * @remarks
46307
+ * Tagged discriminated union keyed on `type`. Wire format (snake_case)
46308
+ * mirrors this shape verbatim; the `regular` variant's `rules` use
46309
+ * {@link TemporalRule} and the `forbid`/`arithmetic` variants use {@link Lit} /
46310
+ * {@link BoolExpr}.
46311
+ */
46312
+ type TypedConstraint = {
46313
+ type: 'global_cardinality';
46314
+ vars: number[];
46315
+ min: number;
46316
+ max?: number | null;
46317
+ } | {
46318
+ type: 'forbid';
46319
+ lits: Lit[];
46320
+ } | {
46321
+ type: 'pin';
46322
+ var: number;
46323
+ } | {
46324
+ type: 'regular';
46325
+ vars: number[];
46326
+ days: number;
46327
+ shifts: number;
46328
+ available: boolean[];
46329
+ rules: TemporalRule[];
46330
+ } | {
46331
+ type: 'all_different';
46332
+ vars: number[];
46333
+ } | {
46334
+ type: 'arithmetic';
46335
+ expr: BoolExpr;
46336
+ };
46337
+ /**
46338
+ * A single decision over which to explore alternatives. Each must have
46339
+ * `alternativeCount ≥ 2`.
46340
+ *
46341
+ * @remarks
46342
+ * Wire shape (snake_case): `{ alternative_count, description, variable_name }`.
46343
+ */
46344
+ interface ChoicePoint {
46345
+ /** Number of alternatives. */
46346
+ alternativeCount: number;
46347
+ /** Description of what this choice represents. */
46348
+ description: string;
46349
+ /** Optional variable name for arithmetic constraints. */
46350
+ variableName?: string | null;
46351
+ }
46352
+ /**
46353
+ * A generic constraint-model request used to begin a feasibility session.
46354
+ *
46355
+ * @remarks
46356
+ * Wire shape (snake_case): `{ choice_points, constraints, objective }`. Owned here
46357
+ * as part of the shared cluster; consumed by the Feasibility domain.
46358
+ */
46359
+ interface GenericModelRequest {
46360
+ /** The decisions to explore, in order. Each must have `alternativeCount ≥ 2`. */
46361
+ choicePoints: ChoicePoint[];
46362
+ /** The typed constraints over the flat decision variables. */
46363
+ constraints?: TypedConstraint[];
46364
+ /**
46365
+ * Optional linear objective to **maximize** (`Σ weight·var` over the true
46366
+ * decision variables), as `(var, weight)` terms. Empty/omitted ⇒ pure-feasibility
46367
+ * mode (the trichotomy over all feasible completions). Non-empty ⇒ optimize mode:
46368
+ * the trichotomy is taken over the **maximum-weight** completions and the responses
46369
+ * carry `totalScore` (the optimum). A var absent from the list has weight `0`;
46370
+ * duplicate vars sum.
46371
+ */
46372
+ objective?: LinTerm[];
46373
+ }
46374
+ /**
46375
+ * Request body for `POST /api/v1/solver/solve`.
46376
+ *
46377
+ * @remarks
46378
+ * Wire shape (snake_case): `{ constraints, gap_tolerance, hint, objective,
46379
+ * time_limit_ms, variables }`.
46380
+ */
46381
+ interface SolveProblemRequest {
46382
+ /** The decision variables of the problem. */
46383
+ variables: VariableSpec[];
46384
+ /** Linear constraints over the variables. */
46385
+ constraints?: LinearConstraint[];
46386
+ /** Objective function; omit for a pure feasibility solve. */
46387
+ objective?: Objective | null;
46388
+ /** Backend-selection hint. */
46389
+ hint?: SolverHint;
46390
+ /** Relative MIP gap tolerance (e.g. `0.01` for 1%). `0.0` means solve to proven optimum. */
46391
+ gapTolerance?: number | null;
46392
+ /** Wall-clock limit per solve, in milliseconds. Defaults server-side to 30000. */
46393
+ timeLimitMs?: number | null;
46394
+ }
46395
+ /**
46396
+ * Response body for `POST /api/v1/solver/solve`.
46397
+ *
46398
+ * @remarks
46399
+ * Wire shape (snake_case): `{ message, objective_value, solve_time_ms, solver,
46400
+ * status, values }`.
46401
+ */
46402
+ interface SolveProblemResponse {
46403
+ /** Status reported by the solver. */
46404
+ status: SolutionStatus;
46405
+ /** `"cp_sat"` or `"highs"`. */
46406
+ solver: string;
46407
+ /** Variable-name → optimal value. Empty for infeasible/unbounded. */
46408
+ values: Record<string, number>;
46409
+ /** Objective value at the optimum, when an objective was supplied. */
46410
+ objectiveValue?: number | null;
46411
+ /** Wall-clock solve time inside the solver service, in milliseconds. */
46412
+ solveTimeMs: number;
46413
+ /** Optional diagnostic message (e.g. when status is `"unknown"`). */
46414
+ message?: string | null;
46415
+ }
46416
+ /**
46417
+ * Request body for `POST /api/v1/solver/classify`. Same fields as
46418
+ * {@link SolveProblemRequest} plus an optional list of variable names whose
46419
+ * classification is requested; omitting it classifies every binary variable.
46420
+ *
46421
+ * @remarks
46422
+ * Wire shape (snake_case): `{ constraints, gap_tolerance, hint, objective,
46423
+ * time_limit_ms, variables, variables_of_interest }`.
46424
+ */
46425
+ interface ClassifyProblemRequest {
46426
+ /** The decision variables of the problem. */
46427
+ variables: VariableSpec[];
46428
+ /** Linear constraints over the variables. */
46429
+ constraints?: LinearConstraint[];
46430
+ /** Objective function; omit for a pure feasibility classification. */
46431
+ objective?: Objective | null;
46432
+ /** Backend-selection hint. */
46433
+ hint?: SolverHint;
46434
+ /** Relative MIP gap tolerance. */
46435
+ gapTolerance?: number | null;
46436
+ /** Wall-clock limit per solve, in milliseconds. */
46437
+ timeLimitMs?: number | null;
46438
+ /** Variables to classify. Omit (or send empty) to classify every binary variable. */
46439
+ variablesOfInterest?: string[] | null;
46440
+ }
46441
+ /**
46442
+ * Response body for `POST /api/v1/solver/classify`.
46443
+ *
46444
+ * @remarks
46445
+ * Wire shape (snake_case): `{ baseline_values, classifications, message,
46446
+ * solve_time_ms, solver, status }`.
46447
+ */
46448
+ interface ClassifyProblemResponse {
46449
+ /** Status reported by the solver. */
46450
+ status: SolutionStatus;
46451
+ /** `"cp_sat"` or `"highs"`. */
46452
+ solver: string;
46453
+ /** Variable-name → classification. Empty when the baseline is infeasible. */
46454
+ classifications: Record<string, VariableClassification>;
46455
+ /** Variable-name → baseline solve value. A concrete witness alongside the classification. */
46456
+ baselineValues: Record<string, number>;
46457
+ /** Wall-clock solve time inside the solver service, in milliseconds. */
46458
+ solveTimeMs: number;
46459
+ /** Optional diagnostic message. */
46460
+ message?: string | null;
46461
+ }
46462
+ /**
46463
+ * Response body for `GET /api/v1/solver/health`.
46464
+ *
46465
+ * @remarks
46466
+ * Wire shape (snake_case): `{ status }`.
46467
+ */
46468
+ interface SolverHealthResponse {
46469
+ /** Liveness marker — `"ok"` when the upstream solver service is reachable. */
46470
+ status: string;
46471
+ }
46472
+
46473
+ type solver_BoolExpr = BoolExpr;
46474
+ type solver_ChoicePoint = ChoicePoint;
46475
+ type solver_ClassifyProblemRequest = ClassifyProblemRequest;
46476
+ type solver_ClassifyProblemResponse = ClassifyProblemResponse;
46477
+ type solver_ConstraintSense = ConstraintSense;
46478
+ type solver_GenericModelRequest = GenericModelRequest;
46479
+ type solver_LinExpr = LinExpr;
46480
+ type solver_LinTerm = LinTerm;
46481
+ type solver_LinearConstraint = LinearConstraint;
46482
+ type solver_Lit = Lit;
46483
+ type solver_Objective = Objective;
46484
+ type solver_ObjectiveSense = ObjectiveSense;
46485
+ type solver_RelOp = RelOp;
46486
+ type solver_SolutionStatus = SolutionStatus;
46487
+ type solver_SolveProblemRequest = SolveProblemRequest;
46488
+ type solver_SolveProblemResponse = SolveProblemResponse;
46489
+ type solver_SolverHealthResponse = SolverHealthResponse;
46490
+ type solver_SolverHint = SolverHint;
46491
+ type solver_TemporalRule = TemporalRule;
46492
+ type solver_TypedConstraint = TypedConstraint;
46493
+ type solver_VarKind = VarKind;
46494
+ type solver_VariableClassification = VariableClassification;
46495
+ type solver_VariableSpec = VariableSpec;
46496
+ declare namespace solver {
46497
+ export type { solver_BoolExpr as BoolExpr, solver_ChoicePoint as ChoicePoint, solver_ClassifyProblemRequest as ClassifyProblemRequest, solver_ClassifyProblemResponse as ClassifyProblemResponse, solver_ConstraintSense as ConstraintSense, solver_GenericModelRequest as GenericModelRequest, solver_LinExpr as LinExpr, solver_LinTerm as LinTerm, solver_LinearConstraint as LinearConstraint, solver_Lit as Lit, solver_Objective as Objective, solver_ObjectiveSense as ObjectiveSense, solver_RelOp as RelOp, solver_SolutionStatus as SolutionStatus, solver_SolveProblemRequest as SolveProblemRequest, solver_SolveProblemResponse as SolveProblemResponse, solver_SolverHealthResponse as SolverHealthResponse, solver_SolverHint as SolverHint, solver_TemporalRule as TemporalRule, solver_TypedConstraint as TypedConstraint, solver_VarKind as VarKind, solver_VariableClassification as VariableClassification, solver_VariableSpec as VariableSpec };
46498
+ }
46499
+
46500
+ /**
46501
+ * Request to assume a single flat decision variable `true` within a session.
46502
+ *
46503
+ * @remarks
46504
+ * Wire shape (snake_case): `{ var }`.
46505
+ */
46506
+ interface AssumptionRequest {
46507
+ /** The flat decision-variable index to assume `true`. */
46508
+ var: number;
46509
+ }
46510
+ /**
46511
+ * The per-cell trichotomy classification of a feasibility session.
46512
+ *
46513
+ * @remarks
46514
+ * Wire shape (snake_case): `{ confirmed_false, confirmed_true, sometimes }`.
46515
+ * Cells are referenced by flat decision-variable index.
46516
+ */
46517
+ interface Classification {
46518
+ /** Cells in every valid completion — forced/highlighted. */
46519
+ confirmedTrue: number[];
46520
+ /** Cells in no valid completion — gray these out. */
46521
+ confirmedFalse: number[];
46522
+ /** Cells that are a free choice. */
46523
+ sometimes: number[];
46524
+ }
46525
+ /**
46526
+ * Response carrying a session id and its current classification.
46527
+ *
46528
+ * @remarks
46529
+ * Wire shape (snake_case): `{ classification, session_id, total_score }`.
46530
+ */
46531
+ interface SchedulingSessionResponse {
46532
+ /** Opaque session id. */
46533
+ sessionId: string;
46534
+ /** The current per-cell trichotomy. */
46535
+ classification: Classification;
46536
+ /**
46537
+ * In optimize mode (the request carried an `objective`), the optimum
46538
+ * `Σ weight·var` over the optimal completions at the current pins; absent for
46539
+ * pure-feasibility models.
46540
+ */
46541
+ totalScore?: number | null;
46542
+ }
46543
+ /**
46544
+ * Response from assuming a variable: the full classification after the pin plus
46545
+ * the cells whose status changed.
46546
+ *
46547
+ * @remarks
46548
+ * Wire shape (snake_case): `{ classification, newly_confirmed_false,
46549
+ * newly_confirmed_true, total_score }`.
46550
+ */
46551
+ interface SchedulingDeltaResponse {
46552
+ /** The full classification after the pin. */
46553
+ classification: Classification;
46554
+ /** Cells that became `confirmedTrue` on this pin (incl. the pinned cell). */
46555
+ newlyConfirmedTrue: number[];
46556
+ /** Cells that became `confirmedFalse` on this pin. */
46557
+ newlyConfirmedFalse: number[];
46558
+ /**
46559
+ * In optimize mode, the optimum `Σ weight·var` after this assumption; absent
46560
+ * for pure-feasibility models. The optimum can drop as pins shrink the optimal
46561
+ * set, so always trust `classification` for repaint — the optimize delta can
46562
+ * also un-confirm cells.
46563
+ */
46564
+ totalScore?: number | null;
46565
+ }
46566
+ /**
46567
+ * Response from ending a feasibility session.
46568
+ *
46569
+ * @remarks
46570
+ * Wire shape (snake_case): `{ ended }`.
46571
+ */
46572
+ interface EndSchedulingResponse {
46573
+ /** Whether a live session was removed. */
46574
+ ended: boolean;
46575
+ }
46576
+
46577
+ type feasibility_AssumptionRequest = AssumptionRequest;
46578
+ type feasibility_Classification = Classification;
46579
+ type feasibility_EndSchedulingResponse = EndSchedulingResponse;
46580
+ type feasibility_SchedulingDeltaResponse = SchedulingDeltaResponse;
46581
+ type feasibility_SchedulingSessionResponse = SchedulingSessionResponse;
46582
+ declare namespace feasibility {
46583
+ export type { feasibility_AssumptionRequest as AssumptionRequest, feasibility_Classification as Classification, feasibility_EndSchedulingResponse as EndSchedulingResponse, feasibility_SchedulingDeltaResponse as SchedulingDeltaResponse, feasibility_SchedulingSessionResponse as SchedulingSessionResponse };
46584
+ }
46585
+
46586
+ /**
46587
+ * Resource client for interactive constraint-model feasibility sessions.
46588
+ *
46589
+ * @remarks
46590
+ * A session is begun from a generic constraint model
46591
+ * ({@link GenericModelRequest}) and returns its id plus the empty-assumptions
46592
+ * trichotomy over the flat decision variables. Each subsequent assumption pins
46593
+ * a variable `true` and returns the resulting classification delta; the most
46594
+ * recent assumption can be retracted without a re-solve.
46595
+ *
46596
+ * Uses normalizers to convert between camelCase (SDK surface) and snake_case
46597
+ * (wire format) at the boundary.
46598
+ */
46599
+ declare class FeasibilityClient {
46600
+ /** @internal */
46601
+ private readonly api;
46602
+ /** @internal */
46603
+ constructor(api: Feasibility);
46604
+ /**
46605
+ * Begin a generic constraint-model feasibility session.
46606
+ *
46607
+ * @param request - The constraint model: choice points and typed constraints
46608
+ * over the flat decision variables.
46609
+ * @returns The new session id and the empty-assumptions trichotomy.
46610
+ * @throws {ApiError} If the request fails.
46611
+ *
46612
+ * @remarks
46613
+ * Wraps `POST /api/v1/feasibility/sessions` (snake_case wire format).
46614
+ *
46615
+ * @example
46616
+ * ```typescript
46617
+ * const session = await client.feasibility.beginFeasibilitySession({
46618
+ * choicePoints: [{ alternativeCount: 2, description: 'shift A or B' }],
46619
+ * constraints: [{ type: 'all_different', vars: [0, 1] }],
46620
+ * });
46621
+ * console.log(session.sessionId);
46622
+ * console.log(session.classification.sometimes);
46623
+ * ```
46624
+ */
46625
+ beginFeasibilitySession(request: GenericModelRequest): Promise<SchedulingSessionResponse>;
46626
+ /**
46627
+ * Assume a flat decision variable `true` within a session.
46628
+ *
46629
+ * @param sessionId - The session id returned by
46630
+ * {@link FeasibilityClient.beginFeasibilitySession}.
46631
+ * @param request - The flat decision-variable index to pin `true`.
46632
+ * @returns The trichotomy delta and the updated classification.
46633
+ * @throws {ApiError} If the session does not exist or the request fails.
46634
+ *
46635
+ * @remarks
46636
+ * Wraps `POST /api/v1/feasibility/sessions/{session_id}/assumptions`
46637
+ * (snake_case wire format).
46638
+ *
46639
+ * @example
46640
+ * ```typescript
46641
+ * const delta = await client.feasibility.assumeFeasibilityVar(sessionId, { var: 0 });
46642
+ * console.log(delta.newlyConfirmedTrue);
46643
+ * console.log(delta.newlyConfirmedFalse);
46644
+ * ```
46645
+ */
46646
+ assumeFeasibilityVar(sessionId: string, request: AssumptionRequest): Promise<SchedulingDeltaResponse>;
46647
+ /**
46648
+ * Retract the most recent assumption, restoring the prior classification.
46649
+ *
46650
+ * @param sessionId - The session id.
46651
+ * @returns The restored classification (no re-solve is performed).
46652
+ * @throws {ApiError} If the session does not exist or the request fails.
46653
+ *
46654
+ * @remarks
46655
+ * Wraps `DELETE /api/v1/feasibility/sessions/{session_id}/assumptions/last`
46656
+ * (snake_case wire format).
46657
+ *
46658
+ * @example
46659
+ * ```typescript
46660
+ * const session = await client.feasibility.retractFeasibilityAssumption(sessionId);
46661
+ * console.log(session.classification.sometimes);
46662
+ * ```
46663
+ */
46664
+ retractFeasibilityAssumption(sessionId: string): Promise<SchedulingSessionResponse>;
46665
+ /**
46666
+ * Get a session's current classification.
46667
+ *
46668
+ * @param sessionId - The session id.
46669
+ * @returns The session id and its current trichotomy.
46670
+ * @throws {ApiError} If the session does not exist or the request fails.
46671
+ *
46672
+ * @remarks
46673
+ * Wraps `GET /api/v1/feasibility/sessions/{session_id}` (snake_case wire
46674
+ * format).
46675
+ *
46676
+ * @example
46677
+ * ```typescript
46678
+ * const session = await client.feasibility.getFeasibilitySession(sessionId);
46679
+ * console.log(session.classification.confirmedTrue);
46680
+ * ```
46681
+ */
46682
+ getFeasibilitySession(sessionId: string): Promise<SchedulingSessionResponse>;
46683
+ /**
46684
+ * End (drop) a feasibility session.
46685
+ *
46686
+ * @param sessionId - The session id.
46687
+ * @returns Whether a live session was removed.
46688
+ * @throws {ApiError} If the request fails.
46689
+ *
46690
+ * @remarks
46691
+ * Wraps `DELETE /api/v1/feasibility/sessions/{session_id}` (snake_case wire
46692
+ * format).
46693
+ *
46694
+ * @example
46695
+ * ```typescript
46696
+ * const result = await client.feasibility.endFeasibilitySession(sessionId);
46697
+ * console.log(result.ended); // true
46698
+ * ```
46699
+ */
46700
+ endFeasibilitySession(sessionId: string): Promise<EndSchedulingResponse>;
46701
+ }
46702
+
46703
+ declare class Solver<SecurityDataType = unknown> {
46704
+ http: HttpClient<SecurityDataType>;
46705
+ constructor(http: HttpClient<SecurityDataType>);
46706
+ /**
46707
+ * @description Returns per-variable always_used / sometimes_used / never_used classifications. Used by the rostering page to render the same trichotomy view-model as the flow-network scheduling page.
46708
+ *
46709
+ * @tags solver
46710
+ * @name ClassifyProblem
46711
+ * @summary Forward a classify request to the external solver service.
46712
+ * @request POST:/api/v1/solver/classify
46713
+ * @secure
46714
+ */
46715
+ classifyProblem: (data: ClassifyProblemRequest$1, params?: RequestParams) => Promise<HttpResponse<ClassifyProblemResponse$1, void>>;
46716
+ /**
46717
+ * No description
46718
+ *
46719
+ * @tags solver
46720
+ * @name SolveProblem
46721
+ * @summary Forward a solve request to the external solver service.
46722
+ * @request POST:/api/v1/solver/solve
46723
+ * @secure
46724
+ */
46725
+ solveProblem: (data: SolveProblemRequest$1, params?: RequestParams) => Promise<HttpResponse<SolveProblemResponse$1, void>>;
46726
+ /**
46727
+ * No description
46728
+ *
46729
+ * @tags solver
46730
+ * @name SolverHealth
46731
+ * @summary Liveness probe — forwards to the solver service's `/health` endpoint so callers can confirm the upstream is reachable from inside the backend's network.
46732
+ * @request GET:/api/v1/solver/health
46733
+ */
46734
+ solverHealth: (params?: RequestParams) => Promise<HttpResponse<SolverHealthResponse$1, void>>;
46735
+ }
46736
+
46737
+ /**
46738
+ * Resource client for the external constraint-solver service.
46739
+ *
46740
+ * @remarks
46741
+ * Forwards linear / mixed-integer constraint problems to the upstream solver
46742
+ * (CP-SAT or HiGHS, selected via {@link SolveProblemRequest.hint}) and returns
46743
+ * either an optimal solution or a per-variable always/sometimes/never-used
46744
+ * classification.
46745
+ *
46746
+ * Uses normalizers to convert between camelCase (SDK surface) and snake_case
46747
+ * (wire format) at the boundary.
46748
+ */
46749
+ declare class SolverClient {
46750
+ /** @internal */
46751
+ private readonly api;
46752
+ /** @internal */
46753
+ constructor(api: Solver);
46754
+ /**
46755
+ * Classify each variable as always-used, sometimes-used, or never-used
46756
+ * across the feasible (or optimal) region of a constraint problem.
46757
+ *
46758
+ * @param request - The problem: variables, constraints, optional objective,
46759
+ * solver hint, and the variables of interest to classify.
46760
+ * @returns The per-variable classifications plus a baseline witness solution.
46761
+ * @throws {ApiError} If the request fails or the solver service is unreachable.
46762
+ *
46763
+ * @remarks
46764
+ * Wraps `POST /api/v1/solver/classify` (snake_case wire format). Omit
46765
+ * `variablesOfInterest` to classify every binary variable.
46766
+ *
46767
+ * @example
46768
+ * ```typescript
46769
+ * const result = await client.solver.classifyProblem({
46770
+ * variables: [
46771
+ * { name: 'x', kind: 'binary' },
46772
+ * { name: 'y', kind: 'binary' },
46773
+ * ],
46774
+ * constraints: [
46775
+ * { coefficients: { x: 1, y: 1 }, sense: 'leq', rhs: 1 },
46776
+ * ],
46777
+ * });
46778
+ * console.log(result.status); // "optimal"
46779
+ * console.log(result.classifications); // { x: "sometimes_used", y: "sometimes_used" }
46780
+ * ```
46781
+ */
46782
+ classifyProblem(request: ClassifyProblemRequest): Promise<ClassifyProblemResponse>;
46783
+ /**
46784
+ * Solve a linear / mixed-integer constraint problem.
46785
+ *
46786
+ * @param request - The problem: variables, constraints, optional objective,
46787
+ * solver hint, gap tolerance, and time limit.
46788
+ * @returns The solution status, solver used, optimal variable values, and
46789
+ * objective value (when an objective was supplied).
46790
+ * @throws {ApiError} If the request fails or the solver service is unreachable.
46791
+ *
46792
+ * @remarks
46793
+ * Wraps `POST /api/v1/solver/solve` (snake_case wire format). Omit
46794
+ * `objective` for a pure feasibility solve.
46795
+ *
46796
+ * @example
46797
+ * ```typescript
46798
+ * const result = await client.solver.solveProblem({
46799
+ * variables: [
46800
+ * { name: 'chairs', kind: 'integer', lowerBound: 0 },
46801
+ * { name: 'tables', kind: 'integer', lowerBound: 0 },
46802
+ * ],
46803
+ * constraints: [
46804
+ * { coefficients: { chairs: 1, tables: 3 }, sense: 'leq', rhs: 12 },
46805
+ * ],
46806
+ * objective: { sense: 'maximize', coefficients: { chairs: 3, tables: 5 } },
46807
+ * });
46808
+ * console.log(result.status); // "optimal"
46809
+ * console.log(result.objectiveValue); // 20
46810
+ * ```
46811
+ */
46812
+ solveProblem(request: SolveProblemRequest): Promise<SolveProblemResponse>;
46813
+ /**
46814
+ * Liveness probe for the upstream solver service.
46815
+ *
46816
+ * @returns A status marker — `status` is `"ok"` when the upstream solver
46817
+ * service responded to its `/health` endpoint.
46818
+ * @throws {ApiError} If the request fails or the solver service is unreachable.
46819
+ *
46820
+ * @remarks
46821
+ * Wraps `GET /api/v1/solver/health` (snake_case wire format).
46822
+ *
46823
+ * @example
46824
+ * ```typescript
46825
+ * const health = await client.solver.solverHealth();
46826
+ * console.log(health.status); // "ok"
46827
+ * ```
46828
+ */
46829
+ solverHealth(): Promise<SolverHealthResponse>;
46830
+ }
46831
+
46832
+ declare class OntologyAlignment<SecurityDataType = unknown> {
46833
+ http: HttpClient<SecurityDataType>;
46834
+ constructor(http: HttpClient<SecurityDataType>);
46835
+ /**
46836
+ * No description
46837
+ *
46838
+ * @tags ontology_alignment
46839
+ * @name AlignOntology
46840
+ * @summary Align a domain ontology to the upper ontology (BFO-2020).
46841
+ * @request POST:/api/v1/ontology/align
46842
+ * @secure
46843
+ */
46844
+ alignOntology: (data: AlignOntologyRequest$1, params?: RequestParams) => Promise<HttpResponse<AlignOntologyResponse$1, void>>;
46845
+ }
46846
+
46847
+ /**
46848
+ * Request to align a domain ontology against one or more upper ontologies.
46849
+ *
46850
+ * @remarks
46851
+ * Sent to `POST /api/v1/ontology/align`. Wire format is snake_case
46852
+ * (`domain_owl`).
46853
+ */
46854
+ interface AlignOntologyRequest {
46855
+ /** Domain ontology to align, as OWL/RDF-XML. */
46856
+ domainOwl: string;
46857
+ /** Upper ontologies to align against. Defaults to `["BFO"]` when empty. */
46858
+ targets?: string[];
46859
+ }
46860
+ /**
46861
+ * A confirmed SKOS correspondence from a domain class to an upper-ontology class.
46862
+ */
46863
+ interface AlignmentMatchDto {
46864
+ /** Domain sort name. */
46865
+ domainSort: string;
46866
+ /** SKOS relation: `exactMatch` / `broadMatch` / `narrowMatch` / `closeMatch`. */
46867
+ matchType: string;
46868
+ /** Upper-ontology class CURIE (e.g. the BFO IRI's CURIE form). */
46869
+ targetCurie: string;
46870
+ /** Upper-ontology class label. */
46871
+ targetLabel: string;
46872
+ }
46873
+ /**
46874
+ * Two upper-ontology candidates a domain class cannot map to simultaneously
46875
+ * (their lattice meet is ⊥ — e.g. disjoint BFO branches).
46876
+ */
46877
+ interface AlignmentConflictDto {
46878
+ /** Domain sort name whose candidates conflict. */
46879
+ domainSort: string;
46880
+ /** The kept (higher-scored) candidate CURIE. */
46881
+ targetA: string;
46882
+ /** The rejected, incompatible candidate CURIE. */
46883
+ targetB: string;
46884
+ }
46885
+ /**
46886
+ * A SKOS external-ontology alignment attached to a sort.
46887
+ *
46888
+ * @remarks
46889
+ * Populated by the upper-ontology aligner so each correspondence is a live,
46890
+ * queryable property of the sort rather than a separate static export.
46891
+ */
46892
+ interface ExternalMatchDto {
46893
+ /** SKOS mapping relation: `exactMatch` | `closeMatch` | `broadMatch` | `narrowMatch`. */
46894
+ matchType: string;
46895
+ /** CURIE of the aligned external concept (e.g. `obo:BFO_0000023`). */
46896
+ ontologyId: string;
46897
+ /** How the match was discovered: `grounding` | `manual` | `import` | `inferred`. */
46898
+ source: string;
46899
+ }
46900
+ /**
46901
+ * Response from an ontology-alignment run.
46902
+ */
46903
+ interface AlignOntologyResponse {
46904
+ /** Surfaced ⊥-conflicts among proposed candidates. */
46905
+ conflicts: AlignmentConflictDto[];
46906
+ /** Number of domain sorts considered. */
46907
+ domainSorts: number;
46908
+ /** The MAPPING artifact as Turtle (`skos:*` + `kortexya:confidence`). */
46909
+ mappingTtl: string;
46910
+ /** Confirmed SKOS correspondences. */
46911
+ matches: AlignmentMatchDto[];
46912
+ /** Number of upper-ontology target sorts indexed. */
46913
+ targetSorts: number;
46914
+ }
46915
+
46916
+ type ontologyAlignment_AlignOntologyRequest = AlignOntologyRequest;
46917
+ type ontologyAlignment_AlignOntologyResponse = AlignOntologyResponse;
46918
+ type ontologyAlignment_AlignmentConflictDto = AlignmentConflictDto;
46919
+ type ontologyAlignment_AlignmentMatchDto = AlignmentMatchDto;
46920
+ type ontologyAlignment_ExternalMatchDto = ExternalMatchDto;
46921
+ declare namespace ontologyAlignment {
46922
+ export type { ontologyAlignment_AlignOntologyRequest as AlignOntologyRequest, ontologyAlignment_AlignOntologyResponse as AlignOntologyResponse, ontologyAlignment_AlignmentConflictDto as AlignmentConflictDto, ontologyAlignment_AlignmentMatchDto as AlignmentMatchDto, ontologyAlignment_ExternalMatchDto as ExternalMatchDto };
46923
+ }
46924
+
46925
+ /**
46926
+ * Resource client for ontology-alignment operations.
46927
+ *
46928
+ * @remarks
46929
+ * Provides access to the upper-ontology aligner, which maps a domain
46930
+ * ontology (OWL/RDF-XML) onto an upper ontology such as BFO-2020 and
46931
+ * surfaces SKOS correspondences and ⊥-conflicts.
46932
+ *
46933
+ * Uses normalizers to convert between camelCase (SDK surface) and
46934
+ * snake_case (wire format) at the boundary.
46935
+ */
46936
+ declare class OntologyAlignmentClient {
46937
+ /** @internal */
46938
+ private readonly api;
46939
+ /** @internal */
46940
+ constructor(api: OntologyAlignment);
46941
+ /**
46942
+ * Align a domain ontology to an upper ontology (e.g. BFO-2020).
46943
+ *
46944
+ * @param request - The domain ontology (OWL/RDF-XML) and optional target
46945
+ * upper ontologies to align against.
46946
+ * @returns The alignment result: confirmed SKOS matches, surfaced conflicts,
46947
+ * the MAPPING artifact as Turtle, and the counts of domain/target sorts.
46948
+ * @throws {ApiError} If the request fails.
46949
+ *
46950
+ * @remarks
46951
+ * Sent to `POST /api/v1/ontology/align`. The request and response use the
46952
+ * snake_case wire format (`domain_owl`, `mapping_ttl`, `domain_sorts`,
46953
+ * `target_sorts`); this client normalizes to/from camelCase at the boundary.
46954
+ * When `targets` is empty or omitted, the backend defaults to `["BFO"]`.
46955
+ *
46956
+ * @example
46957
+ * ```typescript
46958
+ * const result = await client.ontologyAlignment.alignOntology({
46959
+ * domainOwl: '<rdf:RDF>...</rdf:RDF>',
46960
+ * targets: ['BFO'],
46961
+ * });
46962
+ * console.log(result.matches.length); // confirmed correspondences
46963
+ * console.log(result.conflicts.length); // ⊥-conflicts to review
46964
+ * console.log(result.mappingTtl); // Turtle MAPPING artifact
46965
+ * ```
46966
+ */
46967
+ alignOntology(request: AlignOntologyRequest): Promise<AlignOntologyResponse>;
46968
+ }
46969
+
46970
+ declare class OntologyFacade<SecurityDataType = unknown> {
46971
+ http: HttpClient<SecurityDataType>;
46972
+ constructor(http: HttpClient<SecurityDataType>);
46973
+ /**
46974
+ * No description
46975
+ *
46976
+ * @tags ontology_facade
46977
+ * @name ListActionTypes
46978
+ * @summary List action types — projected from the system action-spec catalog.
46979
+ * @request GET:/api/v1/ontology/action-types
46980
+ * @secure
46981
+ */
46982
+ listActionTypes: (params?: RequestParams) => Promise<HttpResponse<ActionTypeListResponse$1, any>>;
46983
+ /**
46984
+ * No description
46985
+ *
46986
+ * @tags ontology_facade
46987
+ * @name ListFunctionTypes
46988
+ * @summary List function types — projected from the tenant's function store.
46989
+ * @request GET:/api/v1/ontology/function-types
46990
+ * @secure
46991
+ */
46992
+ listFunctionTypes: (params?: RequestParams) => Promise<HttpResponse<FunctionTypeListResponse$1, any>>;
46993
+ /**
46994
+ * No description
46995
+ *
46996
+ * @tags ontology_facade
46997
+ * @name ListInterfaceTypes
46998
+ * @summary List interface types — projected from non-maximal (abstract) sorts.
46999
+ * @request GET:/api/v1/ontology/interface-types
47000
+ * @secure
47001
+ */
47002
+ listInterfaceTypes: (params?: RequestParams) => Promise<HttpResponse<InterfaceTypeListResponse$1, any>>;
47003
+ /**
47004
+ * No description
47005
+ *
47006
+ * @tags ontology_facade
47007
+ * @name ListLinkTypes
47008
+ * @summary List link types — projected from referring features across the tenant's sorts.
47009
+ * @request GET:/api/v1/ontology/link-types
47010
+ * @secure
47011
+ */
47012
+ listLinkTypes: (params?: RequestParams) => Promise<HttpResponse<LinkTypeListResponse$1, any>>;
47013
+ /**
47014
+ * No description
47015
+ *
47016
+ * @tags ontology_facade
47017
+ * @name ListObjectTypes
47018
+ * @summary List object types — projected from the tenant's sorts.
47019
+ * @request GET:/api/v1/ontology/object-types
47020
+ * @secure
47021
+ */
47022
+ listObjectTypes: (params?: RequestParams) => Promise<HttpResponse<ObjectTypeListResponse$1, any>>;
47023
+ }
47024
+
47025
+ /**
47026
+ * Resource client for the ontology facade.
47027
+ *
47028
+ * @remarks
47029
+ * Provides read-only projections of the tenant's ontology in a Palantir-style
47030
+ * view — object types (sorts), interface types (abstract sorts), link types
47031
+ * (referring features), function types (the function store), and action types
47032
+ * (the system action-spec catalog).
47033
+ *
47034
+ * Uses normalizers to convert between the SDK surface types and the wire
47035
+ * format at the boundary.
47036
+ */
47037
+ declare class OntologyFacadeClient {
47038
+ /** @internal */
47039
+ private readonly api;
47040
+ /** @internal */
47041
+ constructor(api: OntologyFacade);
47042
+ /**
47043
+ * List action types projected from the system action-spec catalog.
47044
+ *
47045
+ * @returns The projected action types with a count.
47046
+ * @throws {ApiError} If the request fails.
47047
+ *
47048
+ * @remarks
47049
+ * Calls `GET /api/v1/ontology/action-types`. Wire fields are camelCase
47050
+ * (`actionTypes`, `apiName`, `displayName`).
47051
+ *
47052
+ * @example
47053
+ * ```typescript
47054
+ * const { actionTypes, count } = await client.ontologyFacade.listActionTypes();
47055
+ * console.log(count, actionTypes[0]?.apiName);
47056
+ * ```
47057
+ */
47058
+ listActionTypes(): Promise<ActionTypeListResponse>;
47059
+ /**
47060
+ * List function types projected from the tenant's function store.
47061
+ *
47062
+ * @returns The projected function types with a count, ordered by apiName.
47063
+ * @throws {ApiError} If the request fails.
47064
+ *
47065
+ * @remarks
47066
+ * Calls `GET /api/v1/ontology/function-types`. Wire fields are camelCase
47067
+ * (`functionTypes`, `apiName`, `clausesCount`).
47068
+ *
47069
+ * @example
47070
+ * ```typescript
47071
+ * const { functionTypes } = await client.ontologyFacade.listFunctionTypes();
47072
+ * console.log(functionTypes.map((f) => f.apiName));
47073
+ * ```
47074
+ */
47075
+ listFunctionTypes(): Promise<FunctionTypeListResponse>;
47076
+ /**
47077
+ * List interface types projected from non-maximal (abstract) sorts.
47078
+ *
47079
+ * @returns The projected interface types with a count.
47080
+ * @throws {ApiError} If the request fails.
47081
+ *
47082
+ * @remarks
47083
+ * Calls `GET /api/v1/ontology/interface-types`. Wire fields are camelCase
47084
+ * (`interfaceTypes`, `apiName`, `extendsInterfaceTypes`).
47085
+ *
47086
+ * @example
47087
+ * ```typescript
47088
+ * const { interfaceTypes } = await client.ontologyFacade.listInterfaceTypes();
47089
+ * console.log(interfaceTypes[0]?.extendsInterfaceTypes);
47090
+ * ```
47091
+ */
47092
+ listInterfaceTypes(): Promise<InterfaceTypeListResponse>;
47093
+ /**
47094
+ * List link types projected from referring features across the tenant's sorts.
47095
+ *
47096
+ * @returns The projected link types with a count.
47097
+ * @throws {ApiError} If the request fails.
47098
+ *
47099
+ * @remarks
47100
+ * Calls `GET /api/v1/ontology/link-types`. Wire fields are camelCase
47101
+ * (`linkTypes`, `apiName`, `linkedObjectTypeApiName`, `objectTypeApiName`).
47102
+ *
47103
+ * @example
47104
+ * ```typescript
47105
+ * const { linkTypes } = await client.ontologyFacade.listLinkTypes();
47106
+ * console.log(linkTypes[0]?.objectTypeApiName);
47107
+ * ```
47108
+ */
47109
+ listLinkTypes(): Promise<LinkTypeListResponse>;
47110
+ /**
47111
+ * List object types projected from the tenant's sorts.
47112
+ *
47113
+ * @returns The projected object types with a count.
47114
+ * @throws {ApiError} If the request fails.
47115
+ *
47116
+ * @remarks
47117
+ * Calls `GET /api/v1/ontology/object-types`. Wire fields are camelCase
47118
+ * (`objectTypes`, `apiName`, `implementsInterfaceTypes`, `primaryKey`).
47119
+ *
47120
+ * @example
47121
+ * ```typescript
47122
+ * const { objectTypes } = await client.ontologyFacade.listObjectTypes();
47123
+ * console.log(objectTypes.map((o) => o.apiName));
47124
+ * ```
47125
+ */
47126
+ listObjectTypes(): Promise<ObjectTypeListResponse>;
47127
+ }
47128
+
47129
+ declare class OntologyBridge<SecurityDataType = unknown> {
47130
+ http: HttpClient<SecurityDataType>;
47131
+ constructor(http: HttpClient<SecurityDataType>);
47132
+ /**
47133
+ * @description Creates a mapping between an OSF sort and a SQL table, enabling OSFQL-to-SQL transpilation for that sort.
47134
+ *
47135
+ * @tags ontology_bridge
47136
+ * @name BindSort
47137
+ * @summary Bind a sort to a SQL table with explicit column mappings.
47138
+ * @request POST:/api/v1/ontology/bindings
47139
+ * @secure
47140
+ */
47141
+ bindSort: (data: BindSortRequest$1, params?: RequestParams) => Promise<HttpResponse<BindSortResponse$1, void>>;
47142
+ /**
47143
+ * @description Produces query tools, write tools, and inference tools from the current sort hierarchy and SQL bindings, along with a system prompt suitable for grounding an LLM.
47144
+ *
47145
+ * @tags ontology_bridge
47146
+ * @name GroundedSchema
47147
+ * @summary Generate ontology-grounded NL tool schemas.
47148
+ * @request GET:/api/v1/ontology/grounded-schema
47149
+ * @secure
47150
+ */
47151
+ groundedSchema: (params?: RequestParams) => Promise<HttpResponse<GroundedSchemaResponse$1, any>>;
47152
+ /**
47153
+ * @description The "Palantir refugee on-ramp": parses a Foundry-shape ontology export and registers its object/interface types as sorts and link types as referring features (via the same path as OWL import). Returns the created sorts plus a report of what mapped and what needs review (unsupported property types, action types).
47154
+ *
47155
+ * @tags ontology_bridge
47156
+ * @name ImportFoundry
47157
+ * @summary Import a Foundry ontology export into the sort hierarchy (Q1.8).
47158
+ * @request POST:/api/v1/ontology/import-foundry
47159
+ * @secure
47160
+ */
47161
+ importFoundry: (data: ImportFoundryRequest$1, params?: RequestParams) => Promise<HttpResponse<ImportFoundryResponse$1, void>>;
47162
+ /**
47163
+ * @description Parses the OWL XML, converts classes to sorts, and registers them. Returns the created sort names and discovered relations.
47164
+ *
47165
+ * @tags ontology_bridge
47166
+ * @name ImportOwl
47167
+ * @summary Import an OWL/RDF ontology into the sort hierarchy.
47168
+ * @request POST:/api/v1/ontology/import
47169
+ * @secure
47170
+ */
47171
+ importOwl: (data: ImportOwlRequest$1, params?: RequestParams) => Promise<HttpResponse<ImportOwlResponse$1, void>>;
47172
+ /**
47173
+ * @description Returns all active bindings between OSF sorts and SQL tables.
47174
+ *
47175
+ * @tags ontology_bridge
47176
+ * @name ListBindings
47177
+ * @summary List all sort-table bindings.
47178
+ * @request GET:/api/v1/ontology/bindings
47179
+ * @secure
47180
+ */
47181
+ listBindings: (params?: RequestParams) => Promise<HttpResponse<ListBindingsResponse$1, any>>;
47182
+ /**
47183
+ * @description Parses the OSFQL query, compiles it, and transpiles the first `ScanBySort` operation to SQL using the current sort-table bindings.
47184
+ *
47185
+ * @tags ontology_bridge
47186
+ * @name Transpile
47187
+ * @summary Transpile an OSFQL query to SQL.
47188
+ * @request POST:/api/v1/ontology/transpile
47189
+ * @secure
47190
+ */
47191
+ transpile: (data: TranspileRequest$1, params?: RequestParams) => Promise<HttpResponse<TranspileResponse$1, void>>;
47192
+ /**
47193
+ * @description Unbinds a sort from its SQL table, disabling SQL transpilation for it.
47194
+ *
47195
+ * @tags ontology_bridge
47196
+ * @name UnbindSort
47197
+ * @summary Remove a sort-table binding.
47198
+ * @request DELETE:/api/v1/ontology/bindings/{sort_name}
47199
+ * @secure
47200
+ */
47201
+ unbindSort: (sortName: string, params?: RequestParams) => Promise<HttpResponse<void, void>>;
47202
+ }
47203
+
47204
+ /**
47205
+ * A column mapping between a SQL column and an OSF feature.
47206
+ *
47207
+ * @remarks
47208
+ * Used in {@link BindSortRequest}. Wire format is snake_case (`sql_type`).
47209
+ */
47210
+ interface ColumnMappingDto {
47211
+ /** SQL column name. */
47212
+ column: string;
47213
+ /** OSF feature name. */
47214
+ feature: string;
47215
+ /** Whether the column is nullable. */
47216
+ nullable?: boolean;
47217
+ /**
47218
+ * SQL type (e.g., "VARCHAR(255)", "INTEGER"). Omit or leave empty to have
47219
+ * the server introspect the real type from the registered source's live
47220
+ * schema (falls back to TEXT if the source isn't connected).
47221
+ */
47222
+ sqlType?: string;
47223
+ }
47224
+ /**
47225
+ * Request to bind an OSF sort to a SQL table with explicit column mappings.
47226
+ *
47227
+ * @remarks
47228
+ * Sent to `POST /api/v1/ontology/bindings`. Wire format is snake_case
47229
+ * (`key_columns`, `sort_name`, `source_id`, `table_name`).
47230
+ */
47231
+ interface BindSortRequest {
47232
+ /** Column mappings: feature name to column spec. */
47233
+ columns: ColumnMappingDto[];
47234
+ /** Primary key column names. */
47235
+ keyColumns?: string[];
47236
+ /** Sort name to bind. */
47237
+ sortName: string;
47238
+ /** External source identifier. */
47239
+ sourceId: string;
47240
+ /** SQL table name. */
47241
+ tableName: string;
47242
+ }
47243
+ /**
47244
+ * Response from binding a sort to a SQL table.
47245
+ */
47246
+ interface BindSortResponse {
47247
+ /** Whether the binding was successful. */
47248
+ bound: boolean;
47249
+ /** Sort name that was bound. */
47250
+ sortName: string;
47251
+ /** SQL table the sort is bound to. */
47252
+ tableName: string;
47253
+ }
47254
+ /**
47255
+ * Summary of a single active sort-table binding.
47256
+ */
47257
+ interface BindingSummaryDto {
47258
+ /** Number of bound features/columns. */
47259
+ featureCount: number;
47260
+ /** Primary key column names. */
47261
+ keyColumns: string[];
47262
+ /** Sort ID (UUID string). */
47263
+ sortId: string;
47264
+ /** External source identifier. */
47265
+ sourceId: string;
47266
+ /** SQL table name. */
47267
+ tableName: string;
47268
+ }
47269
+ /**
47270
+ * Response listing all active sort-table bindings.
47271
+ */
47272
+ interface ListBindingsResponse {
47273
+ /** Active sort-table bindings. */
47274
+ bindings: BindingSummaryDto[];
47275
+ }
47276
+ /**
47277
+ * Response from generating ontology-grounded NL tool schemas.
47278
+ */
47279
+ interface GroundedSchemaResponse {
47280
+ /** Number of inference tools. */
47281
+ inferenceTools: number;
47282
+ /** Human-readable ontology summary. */
47283
+ ontologySummary: string;
47284
+ /** Number of query tools generated. */
47285
+ queryTools: number;
47286
+ /** System prompt for LLM grounding. */
47287
+ systemPrompt: string;
47288
+ /** Number of write tools generated. */
47289
+ writeTools: number;
47290
+ }
47291
+ /**
47292
+ * Request to import a Foundry ontology export into the sort hierarchy.
47293
+ *
47294
+ * @remarks
47295
+ * Sent to `POST /api/v1/ontology/import-foundry`. Wire format is snake_case
47296
+ * (`foundry_json`).
47297
+ */
47298
+ interface ImportFoundryRequest {
47299
+ /** The Foundry ontology export, as JSON. */
47300
+ foundryJson: string;
47301
+ }
47302
+ /**
47303
+ * An item imported with a caveat or skipped — needs human review.
47304
+ */
47305
+ interface FoundryReviewItemDto {
47306
+ /** What kind of item (`property_type`, `action_type`). */
47307
+ kind: string;
47308
+ /** The item's apiName. */
47309
+ name: string;
47310
+ /** Why it needs review. */
47311
+ reason: string;
47312
+ }
47313
+ /**
47314
+ * Response from a Foundry import: what was created plus a mapped/review-needed report.
47315
+ */
47316
+ interface ImportFoundryResponse {
47317
+ /** Interface types mapped to (super) sorts. */
47318
+ mappedInterfaceTypes: number;
47319
+ /** Link types mapped to referring features. */
47320
+ mappedLinks: number;
47321
+ /** Object types mapped to sorts. */
47322
+ mappedObjectTypes: number;
47323
+ /** Properties mapped to features. */
47324
+ mappedProperties: number;
47325
+ /** Number of relations discovered from link types. */
47326
+ relationsDiscovered: number;
47327
+ /** Items imported with a caveat or skipped — need human review. */
47328
+ reviewNeeded: FoundryReviewItemDto[];
47329
+ /** Names of sorts created (object + interface types). */
47330
+ sortsCreated: string[];
47331
+ }
47332
+ /**
47333
+ * Request to import an OWL/RDF ontology into the sort hierarchy.
47334
+ *
47335
+ * @remarks
47336
+ * Sent to `POST /api/v1/ontology/import`. Wire format is snake_case (`rdf_xml`).
47337
+ */
47338
+ interface ImportOwlRequest {
47339
+ /** OWL/RDF XML content to import. */
47340
+ rdfXml: string;
47341
+ }
47342
+ /**
47343
+ * Response from an OWL ontology import.
47344
+ */
47345
+ interface ImportOwlResponse {
47346
+ /** Names of reified sorts created (many-to-many with attributes). */
47347
+ reifiedSortsCreated: string[];
47348
+ /** Number of relations discovered from OWL object properties. */
47349
+ relationsDiscovered: number;
47350
+ /** Names of sorts created from OWL classes. */
47351
+ sortsCreated: string[];
47352
+ }
47353
+ /**
47354
+ * Request to transpile an OSFQL query to SQL.
47355
+ *
47356
+ * @remarks
47357
+ * Sent to `POST /api/v1/ontology/transpile`. Wire format is snake_case
47358
+ * (the `osfql` and `dialect` fields are already lowercase).
47359
+ */
47360
+ interface TranspileRequest {
47361
+ /** SQL dialect: "postgres", "mysql", or "sqlite". */
47362
+ dialect?: string;
47363
+ /** OSFQL query to transpile. */
47364
+ osfql: string;
47365
+ }
47366
+ /**
47367
+ * Response from OSFQL-to-SQL transpilation.
47368
+ */
47369
+ interface TranspileResponse {
47370
+ /** Whether the entire plan is SQL-transpilable. */
47371
+ fullyTranspilable: boolean;
47372
+ /** Number of parameters in the generated SQL. */
47373
+ paramCount: number;
47374
+ /** Source ID the query targets. */
47375
+ sourceId?: string | null;
47376
+ /** Generated SQL query. */
47377
+ sql: string;
47378
+ }
47379
+
47380
+ type ontologyBridge_BindSortRequest = BindSortRequest;
47381
+ type ontologyBridge_BindSortResponse = BindSortResponse;
47382
+ type ontologyBridge_BindingSummaryDto = BindingSummaryDto;
47383
+ type ontologyBridge_ColumnMappingDto = ColumnMappingDto;
47384
+ type ontologyBridge_FoundryReviewItemDto = FoundryReviewItemDto;
47385
+ type ontologyBridge_GroundedSchemaResponse = GroundedSchemaResponse;
47386
+ type ontologyBridge_ImportFoundryRequest = ImportFoundryRequest;
47387
+ type ontologyBridge_ImportFoundryResponse = ImportFoundryResponse;
47388
+ type ontologyBridge_ImportOwlRequest = ImportOwlRequest;
47389
+ type ontologyBridge_ImportOwlResponse = ImportOwlResponse;
47390
+ type ontologyBridge_ListBindingsResponse = ListBindingsResponse;
47391
+ type ontologyBridge_TranspileRequest = TranspileRequest;
47392
+ type ontologyBridge_TranspileResponse = TranspileResponse;
47393
+ declare namespace ontologyBridge {
47394
+ export type { ontologyBridge_BindSortRequest as BindSortRequest, ontologyBridge_BindSortResponse as BindSortResponse, ontologyBridge_BindingSummaryDto as BindingSummaryDto, ontologyBridge_ColumnMappingDto as ColumnMappingDto, ontologyBridge_FoundryReviewItemDto as FoundryReviewItemDto, ontologyBridge_GroundedSchemaResponse as GroundedSchemaResponse, ontologyBridge_ImportFoundryRequest as ImportFoundryRequest, ontologyBridge_ImportFoundryResponse as ImportFoundryResponse, ontologyBridge_ImportOwlRequest as ImportOwlRequest, ontologyBridge_ImportOwlResponse as ImportOwlResponse, ontologyBridge_ListBindingsResponse as ListBindingsResponse, ontologyBridge_TranspileRequest as TranspileRequest, ontologyBridge_TranspileResponse as TranspileResponse };
47395
+ }
47396
+
47397
+ /**
47398
+ * Resource client for ontology-bridge operations.
47399
+ *
47400
+ * @remarks
47401
+ * Bridges the OSF sort hierarchy to external systems: binds sorts to SQL
47402
+ * tables, transpiles OSFQL queries to SQL, imports OWL/RDF and Foundry
47403
+ * ontologies into the sort hierarchy, and generates ontology-grounded NL
47404
+ * tool schemas for LLM grounding.
47405
+ *
47406
+ * Uses normalizers to convert between camelCase (SDK surface) and
47407
+ * snake_case (wire format) at the boundary.
47408
+ */
47409
+ declare class OntologyBridgeClient {
47410
+ /** @internal */
47411
+ private readonly api;
47412
+ /** @internal */
47413
+ constructor(api: OntologyBridge);
47414
+ /**
47415
+ * Bind a sort to a SQL table with explicit column mappings.
47416
+ *
47417
+ * @param request - The sort name, target table, source identifier, key
47418
+ * columns, and per-feature column mappings.
47419
+ * @returns Whether the binding succeeded plus the bound sort and table names.
47420
+ * @throws {ApiError} If the request fails.
47421
+ *
47422
+ * @remarks
47423
+ * Sent to `POST /api/v1/ontology/bindings`. Request/response use the
47424
+ * snake_case wire format (`sort_name`, `table_name`, `source_id`,
47425
+ * `key_columns`, `sql_type`); this client normalizes at the boundary.
47426
+ * Creates a mapping enabling OSFQL-to-SQL transpilation for that sort.
47427
+ *
47428
+ * @example
47429
+ * ```typescript
47430
+ * const result = await client.ontologyBridge.bindSort({
47431
+ * sortName: 'person',
47432
+ * tableName: 'people',
47433
+ * sourceId: 'warehouse',
47434
+ * keyColumns: ['id'],
47435
+ * columns: [
47436
+ * { feature: 'name', column: 'full_name' },
47437
+ * { feature: 'age', column: 'age', sqlType: 'INTEGER' },
47438
+ * ],
47439
+ * });
47440
+ * console.log(result.bound); // true
47441
+ * ```
47442
+ */
47443
+ bindSort(request: BindSortRequest): Promise<BindSortResponse>;
47444
+ /**
47445
+ * Generate ontology-grounded NL tool schemas.
47446
+ *
47447
+ * @returns Counts of query/write/inference tools, a human-readable ontology
47448
+ * summary, and a system prompt suitable for grounding an LLM.
47449
+ * @throws {ApiError} If the request fails.
47450
+ *
47451
+ * @remarks
47452
+ * Sent to `GET /api/v1/ontology/grounded-schema`. The response uses the
47453
+ * snake_case wire format (`query_tools`, `write_tools`, `inference_tools`,
47454
+ * `ontology_summary`, `system_prompt`); this client normalizes at the
47455
+ * boundary. Tools are derived from the current sort hierarchy and SQL
47456
+ * bindings.
47457
+ *
47458
+ * @example
47459
+ * ```typescript
47460
+ * const schema = await client.ontologyBridge.groundedSchema();
47461
+ * console.log(schema.queryTools); // number of query tools
47462
+ * console.log(schema.systemPrompt); // LLM grounding prompt
47463
+ * ```
47464
+ */
47465
+ groundedSchema(): Promise<GroundedSchemaResponse>;
47466
+ /**
47467
+ * Import a Foundry ontology export into the sort hierarchy.
47468
+ *
47469
+ * @param request - The Foundry ontology export, as a JSON string.
47470
+ * @returns The counts of mapped object/interface types, properties, links,
47471
+ * and discovered relations, the names of created sorts, and a list of
47472
+ * items needing human review.
47473
+ * @throws {ApiError} If the request fails.
47474
+ *
47475
+ * @remarks
47476
+ * Sent to `POST /api/v1/ontology/import-foundry`. Request/response use the
47477
+ * snake_case wire format (`foundry_json`, `mapped_object_types`,
47478
+ * `mapped_interface_types`, `mapped_properties`, `mapped_links`,
47479
+ * `relations_discovered`, `review_needed`, `sorts_created`); this client
47480
+ * normalizes at the boundary. Parses a Foundry-shape export and registers its
47481
+ * object/interface types as sorts and link types as referring features.
47482
+ *
47483
+ * @example
47484
+ * ```typescript
47485
+ * const result = await client.ontologyBridge.importFoundry({
47486
+ * foundryJson: foundryExportString,
47487
+ * });
47488
+ * console.log(result.sortsCreated); // names of created sorts
47489
+ * console.log(result.reviewNeeded); // items needing review
47490
+ * ```
47491
+ */
47492
+ importFoundry(request: ImportFoundryRequest): Promise<ImportFoundryResponse>;
47493
+ /**
47494
+ * Import an OWL/RDF ontology into the sort hierarchy.
47495
+ *
47496
+ * @param request - The OWL/RDF-XML content to import.
47497
+ * @returns The names of created sorts, the names of reified sorts created,
47498
+ * and the number of relations discovered from OWL object properties.
47499
+ * @throws {ApiError} If the request fails.
47500
+ *
47501
+ * @remarks
47502
+ * Sent to `POST /api/v1/ontology/import`. Request/response use the snake_case
47503
+ * wire format (`rdf_xml`, `sorts_created`, `reified_sorts_created`,
47504
+ * `relations_discovered`); this client normalizes at the boundary. Parses the
47505
+ * OWL XML, converts classes to sorts, and registers them.
47506
+ *
47507
+ * @example
47508
+ * ```typescript
47509
+ * const result = await client.ontologyBridge.importOwl({
47510
+ * rdfXml: '<rdf:RDF>...</rdf:RDF>',
47511
+ * });
47512
+ * console.log(result.sortsCreated); // names of sorts created
47513
+ * console.log(result.relationsDiscovered); // count of relations
47514
+ * ```
47515
+ */
47516
+ importOwl(request: ImportOwlRequest): Promise<ImportOwlResponse>;
47517
+ /**
47518
+ * List all sort-table bindings.
47519
+ *
47520
+ * @returns All active bindings between OSF sorts and SQL tables.
47521
+ * @throws {ApiError} If the request fails.
47522
+ *
47523
+ * @remarks
47524
+ * Sent to `GET /api/v1/ontology/bindings`. The response uses the snake_case
47525
+ * wire format (`feature_count`, `key_columns`, `sort_id`, `source_id`,
47526
+ * `table_name`); this client normalizes at the boundary.
47527
+ *
47528
+ * @example
47529
+ * ```typescript
47530
+ * const result = await client.ontologyBridge.listBindings();
47531
+ * for (const binding of result.bindings) {
47532
+ * console.log(binding.sortId, '->', binding.tableName);
47533
+ * }
47534
+ * ```
47535
+ */
47536
+ listBindings(): Promise<ListBindingsResponse>;
47537
+ /**
47538
+ * Transpile an OSFQL query to SQL.
47539
+ *
47540
+ * @param request - The OSFQL query and optional SQL dialect ("postgres",
47541
+ * "mysql", or "sqlite").
47542
+ * @returns The generated SQL, whether the entire plan is SQL-transpilable,
47543
+ * the parameter count, and the source ID the query targets.
47544
+ * @throws {ApiError} If the request fails.
47545
+ *
47546
+ * @remarks
47547
+ * Sent to `POST /api/v1/ontology/transpile`. The response uses the snake_case
47548
+ * wire format (`fully_transpilable`, `param_count`, `source_id`); this client
47549
+ * normalizes at the boundary. Parses and compiles the OSFQL query, then
47550
+ * transpiles the first `ScanBySort` operation to SQL using the current
47551
+ * sort-table bindings.
47552
+ *
47553
+ * @example
47554
+ * ```typescript
47555
+ * const result = await client.ontologyBridge.transpile({
47556
+ * osfql: 'MATCH person(name: ?N);',
47557
+ * dialect: 'postgres',
47558
+ * });
47559
+ * console.log(result.sql); // generated SQL
47560
+ * console.log(result.fullyTranspilable); // true if fully SQL-backed
47561
+ * ```
47562
+ */
47563
+ transpile(request: TranspileRequest): Promise<TranspileResponse>;
47564
+ /**
47565
+ * Remove a sort-table binding.
47566
+ *
47567
+ * @param sortName - The name of the sort to unbind.
47568
+ * @throws {ApiError} If the request fails.
47569
+ *
47570
+ * @remarks
47571
+ * Sent to `DELETE /api/v1/ontology/bindings/{sort_name}`. Unbinds a sort from
47572
+ * its SQL table, disabling SQL transpilation for it. Returns no body.
47573
+ *
47574
+ * @example
47575
+ * ```typescript
47576
+ * await client.ontologyBridge.unbindSort('person');
47577
+ * ```
47578
+ */
47579
+ unbindSort(sortName: string): Promise<void>;
47580
+ }
47581
+
43718
47582
  /** Core knowledge base operations — types, records, rules, functions, constraints, and queries. */
43719
47583
  interface CoreGroup {
43720
47584
  readonly types: SortsClient;
@@ -43908,6 +47772,20 @@ declare class ReasoningLayerClient {
43908
47772
  readonly compliance: ComplianceClient;
43909
47773
  /** Low-level term-graph operations (anti-unification / LGG). */
43910
47774
  readonly operations: OperationsClient;
47775
+ /** Typed-action engine — apply a typed action transactionally with multi-term edits. */
47776
+ readonly actions: ActionsClient;
47777
+ /** Classification/clearance gating over the marking lattice (compliance markings). */
47778
+ readonly complianceMarkings: ComplianceMarkingsClient;
47779
+ /** Interactive constraint-model feasibility sessions (assume/retract with trichotomy classification). */
47780
+ readonly feasibility: FeasibilityClient;
47781
+ /** External constraint solver — classify and solve generic optimization problems. */
47782
+ readonly solver: SolverClient;
47783
+ /** Ontology alignment to the upper ontology (BFO-2020). */
47784
+ readonly ontologyAlignment: OntologyAlignmentClient;
47785
+ /** Ontology facade — project object/link/interface/function/action types from the sort hierarchy. */
47786
+ readonly ontologyFacade: OntologyFacadeClient;
47787
+ /** Ontology bridge — OSF↔SQL bindings, OWL/Foundry import, OSFQL→SQL transpilation. */
47788
+ readonly ontologyBridge: OntologyBridgeClient;
43911
47789
  private _core?;
43912
47790
  private _ai?;
43913
47791
  private _reasoning?;
@@ -44934,7 +48812,7 @@ declare const LP: {
44934
48812
  * // { coefficients: { chairs: 1, tables: 3 }, op: '<=', rhs: 12, label: 'wood' }
44935
48813
  * ```
44936
48814
  */
44937
- readonly constraint: (coefficients: LinearExpression, op: ConstraintOperator, rhs: number, label?: string) => LinearConstraint;
48815
+ readonly constraint: (coefficients: LinearExpression, op: ConstraintOperator, rhs: number, label?: string) => LinearConstraint$1;
44938
48816
  /**
44939
48817
  * Create non-negativity bounds (>= 0) for the given variables.
44940
48818
  *
@@ -45382,4 +49260,4 @@ declare function toUntaggedFeatures(features: PlainFeatureMap): Record<string, F
45382
49260
  */
45383
49261
  declare function toTermInputDto(input: PsiTermInput | TermInputDto): TermInputDto;
45384
49262
 
45385
- 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 ArithmeticOp, type AuthConfig, AuthenticationError, type BackwardChainRequest, type BackwardChainResponse, BadRequestError, type BulkAddTermsRequest, type BulkAddTermsResponse, type BulkCreateSortsRequest, type BulkCreateSortsResponse, cdl as CDL, causal as Causal, type ClassifyEdgesInput, type ClassifyEdgesVars, type ClearTermsResponse, type ClientConfig, cognitive as Cognitive, collections as Collections, communities as Communities, type ComparisonOp, compliance as Compliance, type ConstrainedPlainVar, Constraint, 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, Flow, type FlowProblem as FlowBuilderProblem, type FlowEdgeInput, type FlowEdgeOptions, flowNetworks as FlowNetworks, type FlowNode, type FlowProblemInputBase, 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, type MaxFlowInput, type MaxFlowVars, type MinCostMaxFlowInput, type MinCostMaxFlowVars, type MinCutInput, type MinCutVars, namespaces as Namespaces, NetworkError, neuroSymbolic as NeuroSymbolic, NotFoundError, ontology as Ontology, type Operand, 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 };
49263
+ export { ANY_ROLE, actionReviews as ActionReviews, actions as Actions, type AddFactRequest, type AddFactResponse, type AddRuleRequest, type AddRuleResponse, admin as Admin, type AiGroup, analysis as Analysis, type AnalysisGroup, ApiError, type ApiResponse, type ArithmeticOp, type AuthConfig, AuthenticationError, type BackwardChainRequest, type BackwardChainResponse, BadRequestError, type BulkAddTermsRequest, type BulkAddTermsResponse, type BulkCreateSortsRequest, type BulkCreateSortsResponse, cdl as CDL, causal as Causal, type ClassifyEdgesInput, type ClassifyEdgesVars, type ClearTermsResponse, type ClientConfig, cognitive as Cognitive, collections as Collections, communities as Communities, type ComparisonOp, compliance as Compliance, complianceMarkings as ComplianceMarkings, type ConstrainedPlainVar, Constraint, 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, feasibility as Feasibility, type FeatureInputValueDto, type FeatureValueDto, Flow, type FlowProblem as FlowBuilderProblem, type FlowEdgeInput, type FlowEdgeOptions, flowNetworks as FlowNetworks, type FlowNode, type FlowProblemInputBase, 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, type MaxFlowInput, type MaxFlowVars, type MinCostMaxFlowInput, type MinCostMaxFlowVars, type MinCutInput, type MinCutVars, namespaces as Namespaces, NetworkError, neuroSymbolic as NeuroSymbolic, NotFoundError, ontology as Ontology, ontologyAlignment as OntologyAlignment, ontologyBridge as OntologyBridge, ontologyFacade as OntologyFacade, type Operand, 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, solver as Solver, 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 };