@infersec/conduit 1.113.0 → 1.114.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,6 +2,7 @@ import type { CreateEngineBody, UpdateEngineBody } from "../managementClient/ind
2
2
  import type { ManagementCommandOptions } from "./managementOptions.js";
3
3
  export interface EngineCreateCommandOptions extends ManagementCommandOptions {
4
4
  arg?: string[];
5
+ baseUrl?: string;
5
6
  type?: string;
6
7
  }
7
8
  export declare function buildEngineCreateBody(options: EngineCreateCommandOptions): CreateEngineBody;
@@ -18,6 +18,7 @@ export declare class ModelManager extends EventEmitter<ModelManagerEvents> {
18
18
  private uniqueName;
19
19
  readonly contextLength: number | null;
20
20
  protected readonly logger: Logger;
21
+ private discoveredModelNames;
21
22
  private engineProcess;
22
23
  private healthPollInterval;
23
24
  private lastEngineError;
@@ -49,8 +50,11 @@ export declare class ModelManager extends EventEmitter<ModelManagerEvents> {
49
50
  get lastExitCode(): number | null;
50
51
  get lastExitSignal(): NodeJS.Signals | null;
51
52
  get state(): EngineLifecycleState;
53
+ get resolvedServedModelName(): string | null;
52
54
  get wasRunning(): boolean;
55
+ private get customBaseURL();
53
56
  private checkEngineReadiness;
57
+ private checkCustomReadiness;
54
58
  private checkGenericHealthReadiness;
55
59
  private checkLlamacppReadiness;
56
60
  private checkVLLMReadiness;
@@ -60,6 +64,7 @@ export declare class ModelManager extends EventEmitter<ModelManagerEvents> {
60
64
  private get lockFilePath();
61
65
  private acquireDownloadLock;
62
66
  private recordEngineError;
67
+ private requireCustomBaseURL;
63
68
  private releaseDownloadLock;
64
69
  private bindEngineProcessEvents;
65
70
  private startEngineProcess;
@@ -19,7 +19,8 @@ export interface EngineExecutionReportSource {
19
19
  * Flattens flat CLI extra-arg tokens into [arg, value] pairs, sorted by ARG NAME (ascending, ties by
20
20
  * value). `--flag=value` pairs split on the first `=`; a bare `--flag` consumes the following token
21
21
  * as its value when that token does not start with "-" (classic CLI convention); anything else
22
- * (flags, non-strings) is dropped.
22
+ * (flags, non-strings) is dropped. Secret-like option values are masked before pairing so they
23
+ * never reach execution reports.
23
24
  */
24
25
  export declare function pairExtraArgs(tokens: unknown): Array<[string, string]>;
25
26
  /**
@@ -27,6 +27,7 @@ interface MonitorEngineResponseOptions extends EngineMetricsLoggerOptions {
27
27
  engineType: string;
28
28
  onComplete?: (result: EngineMetricsCompletion) => void | Promise<void>;
29
29
  requestStartedAt?: number;
30
+ responseModelName?: string | null;
30
31
  }
31
32
  interface EngineMetricsLogOptions extends EngineMetricsLoggerOptions {
32
33
  error?: Error;
@@ -37,7 +38,7 @@ interface EngineMetricsLogOptions extends EngineMetricsLoggerOptions {
37
38
  interface MonitorEngineResponseResult {
38
39
  stream: Readable;
39
40
  }
40
- export declare function monitorEngineResponseStream({ agentEngineType, body, contextLength, engineConfig, engineType, logger, onComplete, requestBodyBytes, requestPath, requestStartedAt }: MonitorEngineResponseOptions): MonitorEngineResponseResult;
41
- export declare function monitorEngineResponseSingle({ agentEngineType, body, contextLength, engineConfig, engineType, logger, onComplete, requestBodyBytes, requestPath, requestStartedAt }: MonitorEngineResponseOptions): MonitorEngineResponseResult;
41
+ export declare function monitorEngineResponseStream({ agentEngineType, body, contextLength, engineConfig, engineType, logger, onComplete, requestBodyBytes, requestPath, requestStartedAt, responseModelName }: MonitorEngineResponseOptions): MonitorEngineResponseResult;
42
+ export declare function monitorEngineResponseSingle({ agentEngineType, body, contextLength, engineConfig, engineType, logger, onComplete, requestBodyBytes, requestPath, requestStartedAt, responseModelName }: MonitorEngineResponseOptions): MonitorEngineResponseResult;
42
43
  export declare function logEngineMetrics({ agentEngineType, error, level, logger, requestBodyBytes, requestPath, responseBytes, usage }: EngineMetricsLogOptions): void;
43
44
  export {};
@@ -19,6 +19,14 @@ export declare function applyChatTemplateKwargs({ body, model }: {
19
19
  body: PlainObject;
20
20
  model: LLMModel;
21
21
  }): PlainObject;
22
+ export declare function serializeRequestBody(body: unknown, { model, path, servedModelName }?: {
23
+ model?: LLMModel;
24
+ path?: string;
25
+ servedModelName?: string | null;
26
+ }): {
27
+ bytes: number;
28
+ payload: string;
29
+ };
22
30
  export declare function proxyEmbeddingsRoute({ body, conduitConfiguration, endpointId, logger, modelID, modelManager, reportMetrics, signal }: {
23
31
  body: unknown;
24
32
  conduitConfiguration: InferenceAgentConfiguration;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@infersec/conduit",
3
3
  "description": "End user conduit agent for connecting local LLMs to the cloud.",
4
- "version": "1.113.0",
4
+ "version": "1.114.0",
5
5
  "bin": {
6
6
  "infersec-conduit": "./dist/cli.js"
7
7
  },