@probelabs/visor 0.1.164-ee → 0.1.165-ee

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.
@@ -318,6 +318,18 @@ inputs:
318
318
  schema:
319
319
  type: boolean
320
320
 
321
+ - name: router_model
322
+ required: false
323
+ description: Override AI model for intent routing (e.g., gemini-3-flash-preview for cheaper/faster classification)
324
+ schema:
325
+ type: string
326
+
327
+ - name: router_provider
328
+ required: false
329
+ description: Override AI provider for intent routing (google, anthropic, openai)
330
+ schema:
331
+ type: string
332
+
321
333
  # =========================================================================
322
334
  # Outputs
323
335
  # =========================================================================
@@ -375,6 +387,8 @@ steps:
375
387
  tags:
376
388
  expression: "inputs.tags || []"
377
389
  routing_instructions: "{{ inputs.routing_instructions }}"
390
+ model: "{{ inputs.router_model }}"
391
+ provider: "{{ inputs.router_provider }}"
378
392
 
379
393
  # -------------------------------------------------------------------------
380
394
  # Step 2: Build dynamic configuration for the AI step
@@ -89,6 +89,18 @@ inputs:
89
89
  schema:
90
90
  type: string
91
91
 
92
+ - name: model
93
+ required: false
94
+ description: Override AI model for classification (e.g., gemini-3-flash-preview)
95
+ schema:
96
+ type: string
97
+
98
+ - name: provider
99
+ required: false
100
+ description: Override AI provider for classification (google, anthropic, openai)
101
+ schema:
102
+ type: string
103
+
92
104
  outputs:
93
105
  - name: intent
94
106
  description: Selected intent ID
@@ -134,6 +146,8 @@ steps:
134
146
  - "true"
135
147
  guarantee: "output?.intent != null"
136
148
  ai:
149
+ model: "{{ inputs.model }}"
150
+ provider: "{{ inputs.provider }}"
137
151
  skip_code_context: true
138
152
  skip_slack_context: false
139
153
  disableTools: true
@@ -318,6 +318,18 @@ inputs:
318
318
  schema:
319
319
  type: boolean
320
320
 
321
+ - name: router_model
322
+ required: false
323
+ description: Override AI model for intent routing (e.g., gemini-3-flash-preview for cheaper/faster classification)
324
+ schema:
325
+ type: string
326
+
327
+ - name: router_provider
328
+ required: false
329
+ description: Override AI provider for intent routing (google, anthropic, openai)
330
+ schema:
331
+ type: string
332
+
321
333
  # =========================================================================
322
334
  # Outputs
323
335
  # =========================================================================
@@ -375,6 +387,8 @@ steps:
375
387
  tags:
376
388
  expression: "inputs.tags || []"
377
389
  routing_instructions: "{{ inputs.routing_instructions }}"
390
+ model: "{{ inputs.router_model }}"
391
+ provider: "{{ inputs.router_provider }}"
378
392
 
379
393
  # -------------------------------------------------------------------------
380
394
  # Step 2: Build dynamic configuration for the AI step
@@ -89,6 +89,18 @@ inputs:
89
89
  schema:
90
90
  type: string
91
91
 
92
+ - name: model
93
+ required: false
94
+ description: Override AI model for classification (e.g., gemini-3-flash-preview)
95
+ schema:
96
+ type: string
97
+
98
+ - name: provider
99
+ required: false
100
+ description: Override AI provider for classification (google, anthropic, openai)
101
+ schema:
102
+ type: string
103
+
92
104
  outputs:
93
105
  - name: intent
94
106
  description: Selected intent ID
@@ -134,6 +146,8 @@ steps:
134
146
  - "true"
135
147
  guarantee: "output?.intent != null"
136
148
  ai:
149
+ model: "{{ inputs.model }}"
150
+ provider: "{{ inputs.provider }}"
137
151
  skip_code_context: true
138
152
  skip_slack_context: false
139
153
  disableTools: true
package/dist/index.js CHANGED
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
- process.env.VISOR_VERSION = '0.1.164';
2
+ process.env.VISOR_VERSION = '0.1.165';
3
3
  process.env.PROBE_VERSION = '0.6.0-rc278';
4
- process.env.VISOR_COMMIT_SHA = '3fe559c29c2798f520483a79493f3eda97710e62';
5
- process.env.VISOR_COMMIT_SHORT = '3fe559c';
4
+ process.env.VISOR_COMMIT_SHA = '0431072b1fb3764b178496aa042aaa2a90adfd84';
5
+ process.env.VISOR_COMMIT_SHORT = '0431072';
6
6
  /******/ (() => { // webpackBootstrap
7
7
  /******/ var __webpack_modules__ = ({
8
8
 
@@ -181328,7 +181328,20 @@ class AICheckProvider extends check_provider_interface_1.CheckProvider {
181328
181328
  aiConfig.apiKey = aiAny.apiKey;
181329
181329
  }
181330
181330
  if (aiAny.model !== undefined) {
181331
- aiConfig.model = aiAny.model;
181331
+ let modelVal = String(aiAny.model);
181332
+ if (modelVal.includes('{{')) {
181333
+ try {
181334
+ const rendered = await this.liquidEngine.parseAndRender(modelVal, {
181335
+ inputs: config.workflowInputs || {},
181336
+ env: process.env,
181337
+ });
181338
+ modelVal = rendered.trim();
181339
+ }
181340
+ catch { }
181341
+ }
181342
+ if (modelVal) {
181343
+ aiConfig.model = modelVal;
181344
+ }
181332
181345
  }
181333
181346
  if (aiAny.timeout !== undefined) {
181334
181347
  aiConfig.timeout = aiAny.timeout;
@@ -181338,7 +181351,20 @@ class AICheckProvider extends check_provider_interface_1.CheckProvider {
181338
181351
  aiConfig.maxIterations = Number(raw);
181339
181352
  }
181340
181353
  if (aiAny.provider !== undefined) {
181341
- aiConfig.provider = aiAny.provider;
181354
+ let providerVal = String(aiAny.provider);
181355
+ if (providerVal.includes('{{')) {
181356
+ try {
181357
+ const rendered = await this.liquidEngine.parseAndRender(providerVal, {
181358
+ inputs: config.workflowInputs || {},
181359
+ env: process.env,
181360
+ });
181361
+ providerVal = rendered.trim();
181362
+ }
181363
+ catch { }
181364
+ }
181365
+ if (providerVal) {
181366
+ aiConfig.provider = providerVal;
181367
+ }
181342
181368
  }
181343
181369
  if (aiAny.debug !== undefined) {
181344
181370
  aiConfig.debug = aiAny.debug;
@@ -1 +1 @@
1
- {"version":3,"file":"ai-check-provider.d.ts","sourceRoot":"","sources":["file:///home/runner/work/visor/visor/src/providers/ai-check-provider.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAChF,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AACxC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AA6B5C;;GAEG;AACH,qBAAa,eAAgB,SAAQ,aAAa;IAChD,OAAO,CAAC,eAAe,CAAkB;IACzC,OAAO,CAAC,YAAY,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O,CAAC;IAYrC,eAAe,IAAI,MAAM,EAAE;CAQ5B"}
1
+ {"version":3,"file":"ai-check-provider.d.ts","sourceRoot":"","sources":["file:///home/runner/work/visor/visor/src/providers/ai-check-provider.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAChF,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AACxC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AA6B5C;;GAEG;AACH,qBAAa,eAAgB,SAAQ,aAAa;IAChD,OAAO,CAAC,eAAe,CAAkB;IACzC,OAAO,CAAC,YAAY,CAA0C;IAC9D,OAAO,CAAC,OAAO,CAAwB;;IAQvC,OAAO,IAAI,MAAM;IAIjB,cAAc,IAAI,MAAM;IAIxB,8DAA8D;IAC9D,OAAO,CAAC,QAAQ;IAWhB,uFAAuF;IACvF,OAAO,CAAC,sBAAsB;IAgCxB,cAAc,CAAC,MAAM,EAAE,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC;IAkDvD;;OAEG;IACH,OAAO,CAAC,kBAAkB;IAqB1B;;OAEG;IACH,OAAO,CAAC,qBAAqB;IAiB7B;;OAEG;YACW,aAAa;IA8B3B;;OAEG;YACW,UAAU;IAsExB;;OAEG;YACW,kBAAkB;IA0ChC;;OAEG;YACW,oBAAoB;IA6QlC;;;OAGG;YACW,YAAY;IA6IpB,OAAO,CACX,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,mBAAmB,EAC3B,kBAAkB,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,aAAa,CAAC,EAC/C,WAAW,CAAC,EAAE;QAAE,eAAe,CAAC,EAAE,MAAM,CAAC;QAAC,YAAY,CAAC,EAAE,OAAO,CAAA;KAAE,GACjE,OAAO,CAAC,aAAa,CAAC;YAiBX,iBAAiB;IAukC/B;;;OAGG;IACH,OAAO,CAAC,mBAAmB;IA0B3B;;;OAGG;IACH,OAAO,CAAC,qBAAqB;IAsE7B;;;OAGG;IACH,OAAO,CAAC,oBAAoB;IAsG5B;;;OAGG;IACH,OAAO,CAAC,oBAAoB;IA8F5B;;;OAGG;IACH,OAAO,CAAC,sBAAsB;IAmE9B;;;OAGG;IACH,OAAO,CAAC,YAAY;IAuBpB;;;OAGG;IACH,OAAO,CAAC,eAAe;IAUvB;;;;;OAKG;IACH,MAAM,CAAC,qBAAqB,CAAC,WAAW,EAAE,MAAM,EAAE,GAAG,SAAS,EAAE,WAAW,EAAE,MAAM,EAAE,GAAG,MAAM,EAAE;IAWhG,sBAAsB,IAAI,MAAM,EAAE;IA4C5B,WAAW,IAAI,OAAO,CAAC,OAAO,CAAC;IAYrC,eAAe,IAAI,MAAM,EAAE;CAQ5B"}
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  CheckProviderRegistry,
3
3
  init_check_provider_registry
4
- } from "./chunk-N4SZPYA6.mjs";
4
+ } from "./chunk-ODEDLFSQ.mjs";
5
5
  import "./chunk-KFKHU6CM.mjs";
6
6
  import "./chunk-AVMMKGLQ.mjs";
7
7
  import "./chunk-LG4AUKHB.mjs";
@@ -26,4 +26,4 @@ init_check_provider_registry();
26
26
  export {
27
27
  CheckProviderRegistry
28
28
  };
29
- //# sourceMappingURL=check-provider-registry-AWFYHQAW.mjs.map
29
+ //# sourceMappingURL=check-provider-registry-5ZE2KMA2.mjs.map
@@ -3965,7 +3965,7 @@ async function executeWorkflowAsTool(workflowId, args, context2, argsOverrides)
3965
3965
  ...args,
3966
3966
  ...argsOverrides
3967
3967
  };
3968
- const { WorkflowCheckProvider: WorkflowCheckProvider2 } = await import("./workflow-check-provider-JORTTXVH.mjs");
3968
+ const { WorkflowCheckProvider: WorkflowCheckProvider2 } = await import("./workflow-check-provider-HGHSY5QF.mjs");
3969
3969
  const provider = new WorkflowCheckProvider2();
3970
3970
  const checkConfig = {
3971
3971
  type: "workflow",
@@ -13033,7 +13033,7 @@ var init_state_machine_execution_engine = __esm({
13033
13033
  try {
13034
13034
  const map = options?.webhookContext?.webhookData;
13035
13035
  if (map) {
13036
- const { CheckProviderRegistry: CheckProviderRegistry2 } = await import("./check-provider-registry-AWFYHQAW.mjs");
13036
+ const { CheckProviderRegistry: CheckProviderRegistry2 } = await import("./check-provider-registry-5ZE2KMA2.mjs");
13037
13037
  const reg = CheckProviderRegistry2.getInstance();
13038
13038
  const p = reg.getProvider("http_input");
13039
13039
  if (p && typeof p.setWebhookContext === "function") p.setWebhookContext(map);
@@ -13156,7 +13156,7 @@ var init_state_machine_execution_engine = __esm({
13156
13156
  tag_filter: tagFilter
13157
13157
  } : config;
13158
13158
  try {
13159
- const { CheckProviderRegistry: CheckProviderRegistry2 } = await import("./check-provider-registry-AWFYHQAW.mjs");
13159
+ const { CheckProviderRegistry: CheckProviderRegistry2 } = await import("./check-provider-registry-5ZE2KMA2.mjs");
13160
13160
  const registry = CheckProviderRegistry2.getInstance();
13161
13161
  registry.setCustomTools(configWithTagFilter.tools || {});
13162
13162
  } catch (error) {
@@ -13220,7 +13220,7 @@ var init_state_machine_execution_engine = __esm({
13220
13220
  try {
13221
13221
  const webhookData = this.executionContext?.webhookContext?.webhookData;
13222
13222
  if (webhookData instanceof Map) {
13223
- const { extractSlackContext: extractSlackContext2 } = await import("./schedule-tool-handler-CT5DUQ32.mjs");
13223
+ const { extractSlackContext: extractSlackContext2 } = await import("./schedule-tool-handler-DPZEXA25.mjs");
13224
13224
  const slackCtx = extractSlackContext2(webhookData);
13225
13225
  if (slackCtx) {
13226
13226
  const payload = Array.from(webhookData.values())[0];
@@ -17056,7 +17056,20 @@ ${preview}`);
17056
17056
  aiConfig.apiKey = aiAny2.apiKey;
17057
17057
  }
17058
17058
  if (aiAny2.model !== void 0) {
17059
- aiConfig.model = aiAny2.model;
17059
+ let modelVal = String(aiAny2.model);
17060
+ if (modelVal.includes("{{")) {
17061
+ try {
17062
+ const rendered = await this.liquidEngine.parseAndRender(modelVal, {
17063
+ inputs: config.workflowInputs || {},
17064
+ env: process.env
17065
+ });
17066
+ modelVal = rendered.trim();
17067
+ } catch {
17068
+ }
17069
+ }
17070
+ if (modelVal) {
17071
+ aiConfig.model = modelVal;
17072
+ }
17060
17073
  }
17061
17074
  if (aiAny2.timeout !== void 0) {
17062
17075
  aiConfig.timeout = aiAny2.timeout;
@@ -17066,7 +17079,20 @@ ${preview}`);
17066
17079
  aiConfig.maxIterations = Number(raw);
17067
17080
  }
17068
17081
  if (aiAny2.provider !== void 0) {
17069
- aiConfig.provider = aiAny2.provider;
17082
+ let providerVal = String(aiAny2.provider);
17083
+ if (providerVal.includes("{{")) {
17084
+ try {
17085
+ const rendered = await this.liquidEngine.parseAndRender(providerVal, {
17086
+ inputs: config.workflowInputs || {},
17087
+ env: process.env
17088
+ });
17089
+ providerVal = rendered.trim();
17090
+ } catch {
17091
+ }
17092
+ }
17093
+ if (providerVal) {
17094
+ aiConfig.provider = providerVal;
17095
+ }
17070
17096
  }
17071
17097
  if (aiAny2.debug !== void 0) {
17072
17098
  aiConfig.debug = aiAny2.debug;
@@ -40742,8 +40768,8 @@ function buildBuiltinGlobals(opts) {
40742
40768
  const asyncFunctionNames = /* @__PURE__ */ new Set();
40743
40769
  const scheduleFn = async (args = {}) => {
40744
40770
  try {
40745
- const { handleScheduleAction: handleScheduleAction2, buildScheduleToolContext: buildScheduleToolContext2 } = await import("./schedule-tool-SPUM47DS.mjs");
40746
- const { extractSlackContext: extractSlackContext2 } = await import("./schedule-tool-handler-CT5DUQ32.mjs");
40771
+ const { handleScheduleAction: handleScheduleAction2, buildScheduleToolContext: buildScheduleToolContext2 } = await import("./schedule-tool-SBBVNRBS.mjs");
40772
+ const { extractSlackContext: extractSlackContext2 } = await import("./schedule-tool-handler-DPZEXA25.mjs");
40747
40773
  const parentCtx = opts.sessionInfo?._parentContext;
40748
40774
  const webhookData = parentCtx?.prInfo?.eventContext?.webhookData;
40749
40775
  const visorCfg = parentCtx?.config;
@@ -43888,4 +43914,4 @@ undici/lib/fetch/body.js:
43888
43914
  undici/lib/websocket/frame.js:
43889
43915
  (*! ws. MIT License. Einar Otto Stangvik <einaros@gmail.com> *)
43890
43916
  */
43891
- //# sourceMappingURL=chunk-N4SZPYA6.mjs.map
43917
+ //# sourceMappingURL=chunk-ODEDLFSQ.mjs.map