@lmnr-ai/types 0.8.48 → 0.8.50

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
@@ -2,7 +2,7 @@
2
2
  /**
3
3
  * Options for masking different types of input fields during browser session recording.
4
4
  */
5
- interface MaskInputOptions {
5
+ export interface MaskInputOptions {
6
6
  textarea?: boolean;
7
7
  text?: boolean;
8
8
  number?: boolean;
@@ -13,7 +13,7 @@ interface MaskInputOptions {
13
13
  /**
14
14
  * Options for browser session recording configuration.
15
15
  */
16
- interface SessionRecordingOptions {
16
+ export interface SessionRecordingOptions {
17
17
  maskInputOptions?: MaskInputOptions;
18
18
  }
19
19
  //#endregion
@@ -23,7 +23,7 @@ interface SessionRecordingOptions {
23
23
  * wrappers consume `output` (a JSON string) and `attributes` to reconstruct the
24
24
  * call result; `name`/`input` are unused by replay.
25
25
  */
26
- interface CachedSpan {
26
+ export interface CachedSpan {
27
27
  name: string;
28
28
  input: string;
29
29
  output: string;
@@ -48,7 +48,7 @@ interface CachedSpan {
48
48
  * for a debug run (no opt-in env var). `session_id` is the PRIMARY field read at
49
49
  * startup to decide "join existing session vs. mint a new one".
50
50
  */
51
- interface DebugSessionFile {
51
+ export interface DebugSessionFile {
52
52
  /** Current debug session id (UUID). The thing read at startup. Required. */
53
53
  session_id: string;
54
54
  /** Root trace id produced by the most recent run in this session, or null. */
@@ -63,36 +63,36 @@ interface DebugSessionFile {
63
63
  started_at: string;
64
64
  }
65
65
  /** Directory the debug-session file lives in, relative to the working dir. */
66
- declare const DEBUG_SESSION_DIR = ".lmnr";
66
+ export declare const DEBUG_SESSION_DIR = ".lmnr";
67
67
  /** Filename of the debug-session file inside {@link DEBUG_SESSION_DIR}. */
68
- declare const DEBUG_SESSION_FILE = "debug-session.json";
68
+ export declare const DEBUG_SESSION_FILE = "debug-session.json";
69
69
  //#endregion
70
70
  //#region src/utils.d.ts
71
- type StringUUID = `${string}-${string}-${string}-${string}-${string}`;
72
- declare const errorMessage: (error: unknown) => string;
71
+ export type StringUUID = `${string}-${string}-${string}-${string}-${string}`;
72
+ export declare const errorMessage: (error: unknown) => string;
73
73
  //#endregion
74
74
  //#region src/evaluation.d.ts
75
- type InitEvaluationResponse = {
75
+ export type InitEvaluationResponse = {
76
76
  id: StringUUID;
77
77
  createdAt: Date;
78
78
  groupId: string;
79
79
  name: string;
80
80
  projectId: StringUUID;
81
81
  };
82
- type Dataset = {
82
+ export type Dataset = {
83
83
  id: StringUUID;
84
84
  name: string;
85
85
  createdAt: string;
86
86
  };
87
- type PushDatapointsResponse = {
87
+ export type PushDatapointsResponse = {
88
88
  datasetId: StringUUID;
89
89
  };
90
- type EvaluationDatapointDatasetLink = {
90
+ export type EvaluationDatapointDatasetLink = {
91
91
  datasetId: StringUUID;
92
92
  datapointId: StringUUID;
93
93
  createdAt: string;
94
94
  };
95
- type EvaluationDatapoint<D, T, O> = {
95
+ export type EvaluationDatapoint<D, T, O> = {
96
96
  id: StringUUID;
97
97
  data: D;
98
98
  target?: T;
@@ -104,23 +104,23 @@ type EvaluationDatapoint<D, T, O> = {
104
104
  executorSpanId?: string;
105
105
  datasetLink?: EvaluationDatapointDatasetLink;
106
106
  };
107
- interface Datapoint<D = any, T = any> {
107
+ export interface Datapoint<D = any, T = any> {
108
108
  data: D;
109
109
  target?: T;
110
110
  metadata?: Record<string, any>;
111
111
  }
112
- type GetDatapointsResponse<D, T> = {
112
+ export type GetDatapointsResponse<D, T> = {
113
113
  items: Datapoint<D, T>[];
114
114
  totalCount: number;
115
115
  anyInProject: boolean;
116
116
  };
117
- type SemanticSearchResult = {
117
+ export type SemanticSearchResult = {
118
118
  datasetId: StringUUID;
119
119
  data: Record<string, any>;
120
120
  content: string;
121
121
  score: number;
122
122
  };
123
- type SemanticSearchResponse = {
123
+ export type SemanticSearchResponse = {
124
124
  results: SemanticSearchResult[];
125
125
  };
126
126
  //#endregion
@@ -128,12 +128,12 @@ type SemanticSearchResponse = {
128
128
  /**
129
129
  * OpenTelemetry SDK types (imported as needed by implementations)
130
130
  */
131
- type SpanExporter = any;
132
- type SpanProcessor = any;
131
+ export type SpanExporter = any;
132
+ export type SpanProcessor = any;
133
133
  /**
134
134
  * Options for initializing the Laminar SDK.
135
135
  */
136
- interface InitializeOptions {
136
+ export interface InitializeOptions {
137
137
  /**
138
138
  * The API Key for sending traces data. Optional.
139
139
  */
@@ -269,13 +269,13 @@ interface InitializeOptions {
269
269
  * app-server's `LlmProfileResponse`). Self-hosted only; on Laminar Cloud every
270
270
  * route 404s with `{error: "LLM profiles are not available on this deployment"}`.
271
271
  */
272
- type LlmProfileProvider = "openai_completions" | "openai_responses" | "gemini" | "bedrock" | "azure_chat_completions" | "azure_responses" | "azure_anthropic" | "custom";
272
+ export type LlmProfileProvider = "openai_completions" | "openai_responses" | "gemini" | "bedrock" | "azure_chat_completions" | "azure_responses" | "azure_anthropic" | "custom";
273
273
  /**
274
274
  * How the profile authenticates. `api_key` for every provider except Bedrock,
275
275
  * which takes AWS keys (secret arrives separately in `secrets`) or a bearer
276
276
  * token.
277
277
  */
278
- type LlmProfileAuth = {
278
+ export type LlmProfileAuth = {
279
279
  type: "api_key";
280
280
  } | {
281
281
  type: "aws_keys";
@@ -287,7 +287,7 @@ type LlmProfileAuth = {
287
287
  * Non-secret provider options. The server normalizes per provider: absent
288
288
  * fields are omitted on the wire, never `null`.
289
289
  */
290
- interface LlmProfileConfig {
290
+ export interface LlmProfileConfig {
291
291
  auth: LlmProfileAuth;
292
292
  /** Bedrock. */
293
293
  region?: string;
@@ -305,13 +305,13 @@ interface LlmProfileConfig {
305
305
  * value (fully starred when short) and custom header names only. Absent slots
306
306
  * arrive as explicit `null` (the server does not omit them).
307
307
  */
308
- interface LlmProfileSecretMasks {
308
+ export interface LlmProfileSecretMasks {
309
309
  apiKey?: string | null;
310
310
  secretAccessKey?: string | null;
311
311
  token?: string | null;
312
312
  headers: string[];
313
313
  }
314
- interface LlmProfile {
314
+ export interface LlmProfile {
315
315
  id: string;
316
316
  workspaceId: string;
317
317
  name: string;
@@ -337,25 +337,25 @@ interface LlmProfile {
337
337
  * `type` is a plain string on the wire so new types need no client bump.
338
338
  */
339
339
  /** Block type the CLI knows how to render. `type` is a plain string on the wire. */
340
- type SessionBlockType = "trace" | "evaluation" | "text" | "command";
340
+ export type SessionBlockType = "trace" | "evaluation" | "text" | "command";
341
341
  /** `content` of a `trace` block. */
342
- interface TraceBlockContent {
342
+ export interface TraceBlockContent {
343
343
  traceId: string;
344
344
  /** Legacy note folded onto the trace block at ingest, if any. */
345
345
  note?: string | null;
346
346
  }
347
347
  /** `content` of an `evaluation` block. */
348
- interface EvaluationBlockContent {
348
+ export interface EvaluationBlockContent {
349
349
  evaluationId: string;
350
350
  /** Legacy note folded onto the evaluation block at ingest, if any. */
351
351
  note?: string | null;
352
352
  }
353
353
  /** `content` of a `text` block — a standalone agent note. */
354
- interface TextBlockContent {
354
+ export interface TextBlockContent {
355
355
  text: string;
356
356
  }
357
357
  /** `content` of a `command` block — a CLI command recorded into the session. */
358
- interface CommandBlockContent {
358
+ export interface CommandBlockContent {
359
359
  /** The command path, e.g. `"sql query"` or `"ask"`. */
360
360
  command: string;
361
361
  /** The command's positional arguments (raw — may contain the query text). */
@@ -370,13 +370,13 @@ interface CommandBlockContent {
370
370
  reasoning?: string | null;
371
371
  }
372
372
  /** Union of the known block content shapes. */
373
- type SessionBlockContent = TraceBlockContent | EvaluationBlockContent | TextBlockContent | CommandBlockContent;
373
+ export type SessionBlockContent = TraceBlockContent | EvaluationBlockContent | TextBlockContent | CommandBlockContent;
374
374
  /**
375
375
  * One block in a debugger session (from `GET /v1/cli/rollouts/{sessionId}/blocks`).
376
376
  * `content` is loose (`Record<string, unknown>`) since `type` is open-ended;
377
377
  * narrow it with the `*BlockContent` interfaces above once `type` is known.
378
378
  */
379
- interface SessionBlock {
379
+ export interface SessionBlock {
380
380
  /** Block id (deterministic UUIDv5 for trace/eval blocks; random for text). */
381
381
  id: string;
382
382
  /** ISO-8601 creation timestamp — the sort key for rendering oldest-first. */
@@ -392,7 +392,7 @@ interface SessionBlock {
392
392
  * A signal's payload schema — the structured output the LLM must return. Every
393
393
  * field is required; enums are a string field with an `enum` array.
394
394
  */
395
- interface SignalStructuredOutput {
395
+ export interface SignalStructuredOutput {
396
396
  type: "object";
397
397
  properties: Record<string, {
398
398
  type: string;
@@ -406,7 +406,7 @@ interface SignalStructuredOutput {
406
406
  * not a column list: these are the only two shapes the backend evaluates, so
407
407
  * anything else would be stored and then silently never fire.
408
408
  */
409
- type SignalTrigger = {
409
+ export type SignalTrigger = {
410
410
  type: "rootSpanFinished";
411
411
  } | {
412
412
  type: "spanName";
@@ -418,14 +418,14 @@ type SignalTrigger = {
418
418
  * firing trace. Extra keys are preserved so the shape can grow server-side
419
419
  * without an SDK release.
420
420
  */
421
- interface SignalFilter {
421
+ export interface SignalFilter {
422
422
  column: string;
423
423
  operator: string;
424
424
  value: unknown;
425
425
  [key: string]: unknown;
426
426
  }
427
- type SignalMode = "batch" | "realtime";
428
- interface Signal {
427
+ export type SignalMode = "batch" | "realtime";
428
+ export interface Signal {
429
429
  id: string;
430
430
  projectId: string;
431
431
  name: string;
@@ -450,7 +450,7 @@ interface Signal {
450
450
  * `GET /signals/{id}`). `trigger`/`filters` are stored Filter[] JSON
451
451
  * (`signal_triggers.value` / `filters`), not the CLI tagged {@link SignalTrigger}.
452
452
  */
453
- interface SignalDefinition {
453
+ export interface SignalDefinition {
454
454
  name: string;
455
455
  prompt: string;
456
456
  structuredOutputSchema: SignalStructuredOutput;
@@ -467,7 +467,7 @@ interface SignalDefinition {
467
467
  * One historical judge definition. `GET /signals/{id}`'s `version` field is
468
468
  * only the current pointer; this is the version log.
469
469
  */
470
- interface SignalVersion {
470
+ export interface SignalVersion {
471
471
  version: number;
472
472
  definition: SignalDefinition;
473
473
  createdAt: string;
@@ -486,7 +486,7 @@ interface SignalVersion {
486
486
  * `lmnr-cli sql schema` renders whatever the server returns.
487
487
  */
488
488
  /** One column of a queryable table. `type` is the ClickHouse type as a string. */
489
- interface SqlSchemaColumn {
489
+ export interface SqlSchemaColumn {
490
490
  name: string;
491
491
  /** ClickHouse type, e.g. `UUID`, `DateTime64(9,'UTC')`, `String (enum status)`. */
492
492
  type: string;
@@ -496,18 +496,18 @@ interface SqlSchemaColumn {
496
496
  * One logical table. The caller writes this name; the engine rewrites it to a
497
497
  * project-scoped view.
498
498
  */
499
- interface SqlSchemaTable {
499
+ export interface SqlSchemaTable {
500
500
  name: string;
501
501
  description: string;
502
502
  columns: SqlSchemaColumn[];
503
503
  }
504
504
  /** A constrained column and the literals it accepts. */
505
- interface SqlSchemaEnum {
505
+ export interface SqlSchemaEnum {
506
506
  name: string;
507
507
  values: string[];
508
508
  }
509
509
  /** Full response body of the schema endpoint. */
510
- interface SqlSchema {
510
+ export interface SqlSchema {
511
511
  tables: SqlSchemaTable[];
512
512
  enums: SqlSchemaEnum[];
513
513
  }
@@ -520,12 +520,12 @@ interface SqlSchema {
520
520
  * Pipeline spans are top-level spans created by the pipeline runner.
521
521
  * Executor and evaluator spans are top-level spans added automatically when doing evaluations.
522
522
  */
523
- type SpanType = "DEFAULT" | "LLM" | "EXECUTOR" | "EVALUATOR" | "HUMAN_EVALUATOR" | "EVALUATION" | "TOOL" | "CACHED";
523
+ export type SpanType = "DEFAULT" | "LLM" | "EXECUTOR" | "EVALUATOR" | "HUMAN_EVALUATOR" | "EVALUATION" | "TOOL" | "CACHED";
524
524
  /**
525
525
  * Trace types to categorize traces.
526
526
  * They are used as association properties passed to all spans in a trace.
527
527
  */
528
- type TraceType = "DEFAULT" | "EVALUATION";
528
+ export type TraceType = "DEFAULT" | "EVALUATION";
529
529
  /**
530
530
  * Tracing levels to conditionally disable tracing.
531
531
  *
@@ -533,7 +533,7 @@ type TraceType = "DEFAULT" | "EVALUATION";
533
533
  * META_ONLY - Only metadata is sent (e.g. tokens, costs, etc.).
534
534
  * ALL - All data is sent.
535
535
  */
536
- declare enum TracingLevel {
536
+ export declare enum TracingLevel {
537
537
  OFF = "off",
538
538
  META_ONLY = "meta_only",
539
539
  ALL = "all"
@@ -553,7 +553,7 @@ declare enum TracingLevel {
553
553
  * cacheUntil - the cache-window span-id needle, kept VERBATIM (hyphenated or
554
554
  * not, full UUID or short suffix) — the server resolves it.
555
555
  */
556
- type DebugContext = {
556
+ export type DebugContext = {
557
557
  enabled: boolean;
558
558
  sessionId?: string;
559
559
  replayTraceId?: string;
@@ -569,7 +569,7 @@ type DebugContext = {
569
569
  * spanIdsPath - The span IDs path leading to this span.
570
570
  * debug - Propagated debugger context, if any (debug-replay v2).
571
571
  */
572
- type LaminarSpanContext = {
572
+ export type LaminarSpanContext = {
573
573
  spanId: StringUUID;
574
574
  traceId: StringUUID;
575
575
  isRemote: boolean;
@@ -582,7 +582,7 @@ type LaminarSpanContext = {
582
582
  tracingLevel?: TracingLevel;
583
583
  debug?: DebugContext;
584
584
  };
585
- type Event = {
585
+ export type Event = {
586
586
  id: StringUUID;
587
587
  templateName: string;
588
588
  timestamp: Date;
@@ -590,5 +590,4 @@ type Event = {
590
590
  value: number | string | null;
591
591
  };
592
592
  //#endregion
593
- export { CachedSpan, CommandBlockContent, DEBUG_SESSION_DIR, DEBUG_SESSION_FILE, Datapoint, Dataset, DebugContext, DebugSessionFile, EvaluationBlockContent, EvaluationDatapoint, EvaluationDatapointDatasetLink, Event, GetDatapointsResponse, InitEvaluationResponse, InitializeOptions, LaminarSpanContext, LlmProfile, LlmProfileAuth, LlmProfileConfig, LlmProfileProvider, LlmProfileSecretMasks, MaskInputOptions, PushDatapointsResponse, SemanticSearchResponse, SemanticSearchResult, SessionBlock, SessionBlockContent, SessionBlockType, SessionRecordingOptions, Signal, SignalDefinition, SignalFilter, SignalMode, SignalStructuredOutput, SignalTrigger, SignalVersion, SpanExporter, SpanProcessor, SpanType, SqlSchema, SqlSchemaColumn, SqlSchemaEnum, SqlSchemaTable, StringUUID, TextBlockContent, TraceBlockContent, TraceType, TracingLevel, errorMessage };
594
593
  //# sourceMappingURL=index.d.cts.map
package/dist/index.d.mts CHANGED
@@ -2,7 +2,7 @@
2
2
  /**
3
3
  * Options for masking different types of input fields during browser session recording.
4
4
  */
5
- interface MaskInputOptions {
5
+ export interface MaskInputOptions {
6
6
  textarea?: boolean;
7
7
  text?: boolean;
8
8
  number?: boolean;
@@ -13,7 +13,7 @@ interface MaskInputOptions {
13
13
  /**
14
14
  * Options for browser session recording configuration.
15
15
  */
16
- interface SessionRecordingOptions {
16
+ export interface SessionRecordingOptions {
17
17
  maskInputOptions?: MaskInputOptions;
18
18
  }
19
19
  //#endregion
@@ -23,7 +23,7 @@ interface SessionRecordingOptions {
23
23
  * wrappers consume `output` (a JSON string) and `attributes` to reconstruct the
24
24
  * call result; `name`/`input` are unused by replay.
25
25
  */
26
- interface CachedSpan {
26
+ export interface CachedSpan {
27
27
  name: string;
28
28
  input: string;
29
29
  output: string;
@@ -48,7 +48,7 @@ interface CachedSpan {
48
48
  * for a debug run (no opt-in env var). `session_id` is the PRIMARY field read at
49
49
  * startup to decide "join existing session vs. mint a new one".
50
50
  */
51
- interface DebugSessionFile {
51
+ export interface DebugSessionFile {
52
52
  /** Current debug session id (UUID). The thing read at startup. Required. */
53
53
  session_id: string;
54
54
  /** Root trace id produced by the most recent run in this session, or null. */
@@ -63,36 +63,36 @@ interface DebugSessionFile {
63
63
  started_at: string;
64
64
  }
65
65
  /** Directory the debug-session file lives in, relative to the working dir. */
66
- declare const DEBUG_SESSION_DIR = ".lmnr";
66
+ export declare const DEBUG_SESSION_DIR = ".lmnr";
67
67
  /** Filename of the debug-session file inside {@link DEBUG_SESSION_DIR}. */
68
- declare const DEBUG_SESSION_FILE = "debug-session.json";
68
+ export declare const DEBUG_SESSION_FILE = "debug-session.json";
69
69
  //#endregion
70
70
  //#region src/utils.d.ts
71
- type StringUUID = `${string}-${string}-${string}-${string}-${string}`;
72
- declare const errorMessage: (error: unknown) => string;
71
+ export type StringUUID = `${string}-${string}-${string}-${string}-${string}`;
72
+ export declare const errorMessage: (error: unknown) => string;
73
73
  //#endregion
74
74
  //#region src/evaluation.d.ts
75
- type InitEvaluationResponse = {
75
+ export type InitEvaluationResponse = {
76
76
  id: StringUUID;
77
77
  createdAt: Date;
78
78
  groupId: string;
79
79
  name: string;
80
80
  projectId: StringUUID;
81
81
  };
82
- type Dataset = {
82
+ export type Dataset = {
83
83
  id: StringUUID;
84
84
  name: string;
85
85
  createdAt: string;
86
86
  };
87
- type PushDatapointsResponse = {
87
+ export type PushDatapointsResponse = {
88
88
  datasetId: StringUUID;
89
89
  };
90
- type EvaluationDatapointDatasetLink = {
90
+ export type EvaluationDatapointDatasetLink = {
91
91
  datasetId: StringUUID;
92
92
  datapointId: StringUUID;
93
93
  createdAt: string;
94
94
  };
95
- type EvaluationDatapoint<D, T, O> = {
95
+ export type EvaluationDatapoint<D, T, O> = {
96
96
  id: StringUUID;
97
97
  data: D;
98
98
  target?: T;
@@ -104,23 +104,23 @@ type EvaluationDatapoint<D, T, O> = {
104
104
  executorSpanId?: string;
105
105
  datasetLink?: EvaluationDatapointDatasetLink;
106
106
  };
107
- interface Datapoint<D = any, T = any> {
107
+ export interface Datapoint<D = any, T = any> {
108
108
  data: D;
109
109
  target?: T;
110
110
  metadata?: Record<string, any>;
111
111
  }
112
- type GetDatapointsResponse<D, T> = {
112
+ export type GetDatapointsResponse<D, T> = {
113
113
  items: Datapoint<D, T>[];
114
114
  totalCount: number;
115
115
  anyInProject: boolean;
116
116
  };
117
- type SemanticSearchResult = {
117
+ export type SemanticSearchResult = {
118
118
  datasetId: StringUUID;
119
119
  data: Record<string, any>;
120
120
  content: string;
121
121
  score: number;
122
122
  };
123
- type SemanticSearchResponse = {
123
+ export type SemanticSearchResponse = {
124
124
  results: SemanticSearchResult[];
125
125
  };
126
126
  //#endregion
@@ -128,12 +128,12 @@ type SemanticSearchResponse = {
128
128
  /**
129
129
  * OpenTelemetry SDK types (imported as needed by implementations)
130
130
  */
131
- type SpanExporter = any;
132
- type SpanProcessor = any;
131
+ export type SpanExporter = any;
132
+ export type SpanProcessor = any;
133
133
  /**
134
134
  * Options for initializing the Laminar SDK.
135
135
  */
136
- interface InitializeOptions {
136
+ export interface InitializeOptions {
137
137
  /**
138
138
  * The API Key for sending traces data. Optional.
139
139
  */
@@ -269,13 +269,13 @@ interface InitializeOptions {
269
269
  * app-server's `LlmProfileResponse`). Self-hosted only; on Laminar Cloud every
270
270
  * route 404s with `{error: "LLM profiles are not available on this deployment"}`.
271
271
  */
272
- type LlmProfileProvider = "openai_completions" | "openai_responses" | "gemini" | "bedrock" | "azure_chat_completions" | "azure_responses" | "azure_anthropic" | "custom";
272
+ export type LlmProfileProvider = "openai_completions" | "openai_responses" | "gemini" | "bedrock" | "azure_chat_completions" | "azure_responses" | "azure_anthropic" | "custom";
273
273
  /**
274
274
  * How the profile authenticates. `api_key` for every provider except Bedrock,
275
275
  * which takes AWS keys (secret arrives separately in `secrets`) or a bearer
276
276
  * token.
277
277
  */
278
- type LlmProfileAuth = {
278
+ export type LlmProfileAuth = {
279
279
  type: "api_key";
280
280
  } | {
281
281
  type: "aws_keys";
@@ -287,7 +287,7 @@ type LlmProfileAuth = {
287
287
  * Non-secret provider options. The server normalizes per provider: absent
288
288
  * fields are omitted on the wire, never `null`.
289
289
  */
290
- interface LlmProfileConfig {
290
+ export interface LlmProfileConfig {
291
291
  auth: LlmProfileAuth;
292
292
  /** Bedrock. */
293
293
  region?: string;
@@ -305,13 +305,13 @@ interface LlmProfileConfig {
305
305
  * value (fully starred when short) and custom header names only. Absent slots
306
306
  * arrive as explicit `null` (the server does not omit them).
307
307
  */
308
- interface LlmProfileSecretMasks {
308
+ export interface LlmProfileSecretMasks {
309
309
  apiKey?: string | null;
310
310
  secretAccessKey?: string | null;
311
311
  token?: string | null;
312
312
  headers: string[];
313
313
  }
314
- interface LlmProfile {
314
+ export interface LlmProfile {
315
315
  id: string;
316
316
  workspaceId: string;
317
317
  name: string;
@@ -337,25 +337,25 @@ interface LlmProfile {
337
337
  * `type` is a plain string on the wire so new types need no client bump.
338
338
  */
339
339
  /** Block type the CLI knows how to render. `type` is a plain string on the wire. */
340
- type SessionBlockType = "trace" | "evaluation" | "text" | "command";
340
+ export type SessionBlockType = "trace" | "evaluation" | "text" | "command";
341
341
  /** `content` of a `trace` block. */
342
- interface TraceBlockContent {
342
+ export interface TraceBlockContent {
343
343
  traceId: string;
344
344
  /** Legacy note folded onto the trace block at ingest, if any. */
345
345
  note?: string | null;
346
346
  }
347
347
  /** `content` of an `evaluation` block. */
348
- interface EvaluationBlockContent {
348
+ export interface EvaluationBlockContent {
349
349
  evaluationId: string;
350
350
  /** Legacy note folded onto the evaluation block at ingest, if any. */
351
351
  note?: string | null;
352
352
  }
353
353
  /** `content` of a `text` block — a standalone agent note. */
354
- interface TextBlockContent {
354
+ export interface TextBlockContent {
355
355
  text: string;
356
356
  }
357
357
  /** `content` of a `command` block — a CLI command recorded into the session. */
358
- interface CommandBlockContent {
358
+ export interface CommandBlockContent {
359
359
  /** The command path, e.g. `"sql query"` or `"ask"`. */
360
360
  command: string;
361
361
  /** The command's positional arguments (raw — may contain the query text). */
@@ -370,13 +370,13 @@ interface CommandBlockContent {
370
370
  reasoning?: string | null;
371
371
  }
372
372
  /** Union of the known block content shapes. */
373
- type SessionBlockContent = TraceBlockContent | EvaluationBlockContent | TextBlockContent | CommandBlockContent;
373
+ export type SessionBlockContent = TraceBlockContent | EvaluationBlockContent | TextBlockContent | CommandBlockContent;
374
374
  /**
375
375
  * One block in a debugger session (from `GET /v1/cli/rollouts/{sessionId}/blocks`).
376
376
  * `content` is loose (`Record<string, unknown>`) since `type` is open-ended;
377
377
  * narrow it with the `*BlockContent` interfaces above once `type` is known.
378
378
  */
379
- interface SessionBlock {
379
+ export interface SessionBlock {
380
380
  /** Block id (deterministic UUIDv5 for trace/eval blocks; random for text). */
381
381
  id: string;
382
382
  /** ISO-8601 creation timestamp — the sort key for rendering oldest-first. */
@@ -392,7 +392,7 @@ interface SessionBlock {
392
392
  * A signal's payload schema — the structured output the LLM must return. Every
393
393
  * field is required; enums are a string field with an `enum` array.
394
394
  */
395
- interface SignalStructuredOutput {
395
+ export interface SignalStructuredOutput {
396
396
  type: "object";
397
397
  properties: Record<string, {
398
398
  type: string;
@@ -406,7 +406,7 @@ interface SignalStructuredOutput {
406
406
  * not a column list: these are the only two shapes the backend evaluates, so
407
407
  * anything else would be stored and then silently never fire.
408
408
  */
409
- type SignalTrigger = {
409
+ export type SignalTrigger = {
410
410
  type: "rootSpanFinished";
411
411
  } | {
412
412
  type: "spanName";
@@ -418,14 +418,14 @@ type SignalTrigger = {
418
418
  * firing trace. Extra keys are preserved so the shape can grow server-side
419
419
  * without an SDK release.
420
420
  */
421
- interface SignalFilter {
421
+ export interface SignalFilter {
422
422
  column: string;
423
423
  operator: string;
424
424
  value: unknown;
425
425
  [key: string]: unknown;
426
426
  }
427
- type SignalMode = "batch" | "realtime";
428
- interface Signal {
427
+ export type SignalMode = "batch" | "realtime";
428
+ export interface Signal {
429
429
  id: string;
430
430
  projectId: string;
431
431
  name: string;
@@ -450,7 +450,7 @@ interface Signal {
450
450
  * `GET /signals/{id}`). `trigger`/`filters` are stored Filter[] JSON
451
451
  * (`signal_triggers.value` / `filters`), not the CLI tagged {@link SignalTrigger}.
452
452
  */
453
- interface SignalDefinition {
453
+ export interface SignalDefinition {
454
454
  name: string;
455
455
  prompt: string;
456
456
  structuredOutputSchema: SignalStructuredOutput;
@@ -467,7 +467,7 @@ interface SignalDefinition {
467
467
  * One historical judge definition. `GET /signals/{id}`'s `version` field is
468
468
  * only the current pointer; this is the version log.
469
469
  */
470
- interface SignalVersion {
470
+ export interface SignalVersion {
471
471
  version: number;
472
472
  definition: SignalDefinition;
473
473
  createdAt: string;
@@ -486,7 +486,7 @@ interface SignalVersion {
486
486
  * `lmnr-cli sql schema` renders whatever the server returns.
487
487
  */
488
488
  /** One column of a queryable table. `type` is the ClickHouse type as a string. */
489
- interface SqlSchemaColumn {
489
+ export interface SqlSchemaColumn {
490
490
  name: string;
491
491
  /** ClickHouse type, e.g. `UUID`, `DateTime64(9,'UTC')`, `String (enum status)`. */
492
492
  type: string;
@@ -496,18 +496,18 @@ interface SqlSchemaColumn {
496
496
  * One logical table. The caller writes this name; the engine rewrites it to a
497
497
  * project-scoped view.
498
498
  */
499
- interface SqlSchemaTable {
499
+ export interface SqlSchemaTable {
500
500
  name: string;
501
501
  description: string;
502
502
  columns: SqlSchemaColumn[];
503
503
  }
504
504
  /** A constrained column and the literals it accepts. */
505
- interface SqlSchemaEnum {
505
+ export interface SqlSchemaEnum {
506
506
  name: string;
507
507
  values: string[];
508
508
  }
509
509
  /** Full response body of the schema endpoint. */
510
- interface SqlSchema {
510
+ export interface SqlSchema {
511
511
  tables: SqlSchemaTable[];
512
512
  enums: SqlSchemaEnum[];
513
513
  }
@@ -520,12 +520,12 @@ interface SqlSchema {
520
520
  * Pipeline spans are top-level spans created by the pipeline runner.
521
521
  * Executor and evaluator spans are top-level spans added automatically when doing evaluations.
522
522
  */
523
- type SpanType = "DEFAULT" | "LLM" | "EXECUTOR" | "EVALUATOR" | "HUMAN_EVALUATOR" | "EVALUATION" | "TOOL" | "CACHED";
523
+ export type SpanType = "DEFAULT" | "LLM" | "EXECUTOR" | "EVALUATOR" | "HUMAN_EVALUATOR" | "EVALUATION" | "TOOL" | "CACHED";
524
524
  /**
525
525
  * Trace types to categorize traces.
526
526
  * They are used as association properties passed to all spans in a trace.
527
527
  */
528
- type TraceType = "DEFAULT" | "EVALUATION";
528
+ export type TraceType = "DEFAULT" | "EVALUATION";
529
529
  /**
530
530
  * Tracing levels to conditionally disable tracing.
531
531
  *
@@ -533,7 +533,7 @@ type TraceType = "DEFAULT" | "EVALUATION";
533
533
  * META_ONLY - Only metadata is sent (e.g. tokens, costs, etc.).
534
534
  * ALL - All data is sent.
535
535
  */
536
- declare enum TracingLevel {
536
+ export declare enum TracingLevel {
537
537
  OFF = "off",
538
538
  META_ONLY = "meta_only",
539
539
  ALL = "all"
@@ -553,7 +553,7 @@ declare enum TracingLevel {
553
553
  * cacheUntil - the cache-window span-id needle, kept VERBATIM (hyphenated or
554
554
  * not, full UUID or short suffix) — the server resolves it.
555
555
  */
556
- type DebugContext = {
556
+ export type DebugContext = {
557
557
  enabled: boolean;
558
558
  sessionId?: string;
559
559
  replayTraceId?: string;
@@ -569,7 +569,7 @@ type DebugContext = {
569
569
  * spanIdsPath - The span IDs path leading to this span.
570
570
  * debug - Propagated debugger context, if any (debug-replay v2).
571
571
  */
572
- type LaminarSpanContext = {
572
+ export type LaminarSpanContext = {
573
573
  spanId: StringUUID;
574
574
  traceId: StringUUID;
575
575
  isRemote: boolean;
@@ -582,7 +582,7 @@ type LaminarSpanContext = {
582
582
  tracingLevel?: TracingLevel;
583
583
  debug?: DebugContext;
584
584
  };
585
- type Event = {
585
+ export type Event = {
586
586
  id: StringUUID;
587
587
  templateName: string;
588
588
  timestamp: Date;
@@ -590,5 +590,4 @@ type Event = {
590
590
  value: number | string | null;
591
591
  };
592
592
  //#endregion
593
- export { CachedSpan, CommandBlockContent, DEBUG_SESSION_DIR, DEBUG_SESSION_FILE, Datapoint, Dataset, DebugContext, DebugSessionFile, EvaluationBlockContent, EvaluationDatapoint, EvaluationDatapointDatasetLink, Event, GetDatapointsResponse, InitEvaluationResponse, InitializeOptions, LaminarSpanContext, LlmProfile, LlmProfileAuth, LlmProfileConfig, LlmProfileProvider, LlmProfileSecretMasks, MaskInputOptions, PushDatapointsResponse, SemanticSearchResponse, SemanticSearchResult, SessionBlock, SessionBlockContent, SessionBlockType, SessionRecordingOptions, Signal, SignalDefinition, SignalFilter, SignalMode, SignalStructuredOutput, SignalTrigger, SignalVersion, SpanExporter, SpanProcessor, SpanType, SqlSchema, SqlSchemaColumn, SqlSchemaEnum, SqlSchemaTable, StringUUID, TextBlockContent, TraceBlockContent, TraceType, TracingLevel, errorMessage };
594
593
  //# sourceMappingURL=index.d.mts.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lmnr-ai/types",
3
- "version": "0.8.48",
3
+ "version": "0.8.50",
4
4
  "description": "Shared types for Laminar AI SDK",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.mjs",