@probelabs/visor 0.1.76 → 0.1.77

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.js CHANGED
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
- process.env.VISOR_VERSION = '0.1.76';
3
- process.env.PROBE_VERSION = '0.6.0-rc119';
2
+ process.env.VISOR_VERSION = '0.1.77';
3
+ process.env.PROBE_VERSION = '0.6.0-rc120';
4
4
  /******/ (() => { // webpackBootstrap
5
5
  /******/ var __webpack_modules__ = ({
6
6
 
@@ -105391,6 +105391,10 @@ class ConfigManager {
105391
105391
  if (!checkConfig.type) {
105392
105392
  checkConfig.type = 'ai';
105393
105393
  }
105394
+ // Backward-compat alias: accept 'logger' as 'log'
105395
+ if (checkConfig.type === 'logger') {
105396
+ checkConfig.type = 'log';
105397
+ }
105394
105398
  if (!this.validCheckTypes.includes(checkConfig.type)) {
105395
105399
  errors.push({
105396
105400
  field: `checks.${checkName}.type`,
@@ -105427,6 +105431,8 @@ class ConfigManager {
105427
105431
  });
105428
105432
  }
105429
105433
  }
105434
+ // Note: Do not add special-case validation for log 'message' here.
105435
+ // Schema (Ajv) permits 'message' and related keys; provider enforces at execution time.
105430
105436
  // HTTP input checks require endpoint field
105431
105437
  if (checkConfig.type === 'http_input' && !checkConfig.endpoint) {
105432
105438
  errors.push({
@@ -106625,980 +106631,932 @@ exports.FailureConditionEvaluator = FailureConditionEvaluator;
106625
106631
  Object.defineProperty(exports, "__esModule", ({ value: true }));
106626
106632
  exports.configSchema = void 0;
106627
106633
  // AUTO-GENERATED FILE. DO NOT EDIT.
106628
- // Generated by scripts/generate-config-schema.js from src/types/config.ts
106634
+ // Generated by scripts/generate-config-schema.js from src/types/config.ts
106629
106635
  exports.configSchema = {
106630
- "$schema": "http://json-schema.org/draft-07/schema#",
106631
- "$ref": "#/definitions/VisorConfig",
106632
- "definitions": {
106633
- "VisorConfig": {
106634
- "type": "object",
106635
- "properties": {
106636
- "version": {
106637
- "type": "string",
106638
- "description": "Configuration version"
106636
+ $schema: 'http://json-schema.org/draft-07/schema#',
106637
+ $ref: '#/definitions/VisorConfig',
106638
+ definitions: {
106639
+ VisorConfig: {
106640
+ type: 'object',
106641
+ properties: {
106642
+ version: {
106643
+ type: 'string',
106644
+ description: 'Configuration version',
106639
106645
  },
106640
- "extends": {
106641
- "anyOf": [
106646
+ extends: {
106647
+ anyOf: [
106642
106648
  {
106643
- "type": "string"
106649
+ type: 'string',
106644
106650
  },
106645
106651
  {
106646
- "type": "array",
106647
- "items": {
106648
- "type": "string"
106649
- }
106650
- }
106652
+ type: 'array',
106653
+ items: {
106654
+ type: 'string',
106655
+ },
106656
+ },
106651
106657
  ],
106652
- "description": "Extends from other configurations - can be file path, HTTP(S) URL, or \"default\""
106658
+ description: 'Extends from other configurations - can be file path, HTTP(S) URL, or "default"',
106653
106659
  },
106654
- "checks": {
106655
- "$ref": "#/definitions/Record%3Cstring%2CCheckConfig%3E",
106656
- "description": "Check configurations"
106660
+ checks: {
106661
+ $ref: '#/definitions/Record%3Cstring%2CCheckConfig%3E',
106662
+ description: 'Check configurations',
106657
106663
  },
106658
- "output": {
106659
- "$ref": "#/definitions/OutputConfig",
106660
- "description": "Output configuration"
106664
+ output: {
106665
+ $ref: '#/definitions/OutputConfig',
106666
+ description: 'Output configuration',
106661
106667
  },
106662
- "http_server": {
106663
- "$ref": "#/definitions/HttpServerConfig",
106664
- "description": "HTTP server configuration for receiving webhooks"
106668
+ http_server: {
106669
+ $ref: '#/definitions/HttpServerConfig',
106670
+ description: 'HTTP server configuration for receiving webhooks',
106665
106671
  },
106666
- "env": {
106667
- "$ref": "#/definitions/EnvConfig",
106668
- "description": "Global environment variables"
106672
+ env: {
106673
+ $ref: '#/definitions/EnvConfig',
106674
+ description: 'Global environment variables',
106669
106675
  },
106670
- "ai_model": {
106671
- "type": "string",
106672
- "description": "Global AI model setting"
106676
+ ai_model: {
106677
+ type: 'string',
106678
+ description: 'Global AI model setting',
106673
106679
  },
106674
- "ai_provider": {
106675
- "type": "string",
106676
- "description": "Global AI provider setting"
106680
+ ai_provider: {
106681
+ type: 'string',
106682
+ description: 'Global AI provider setting',
106677
106683
  },
106678
- "ai_mcp_servers": {
106679
- "$ref": "#/definitions/Record%3Cstring%2CMcpServerConfig%3E",
106680
- "description": "Global MCP servers configuration for AI checks"
106684
+ ai_mcp_servers: {
106685
+ $ref: '#/definitions/Record%3Cstring%2CMcpServerConfig%3E',
106686
+ description: 'Global MCP servers configuration for AI checks',
106681
106687
  },
106682
- "max_parallelism": {
106683
- "type": "number",
106684
- "description": "Maximum number of checks to run in parallel (default: 3)"
106688
+ max_parallelism: {
106689
+ type: 'number',
106690
+ description: 'Maximum number of checks to run in parallel (default: 3)',
106685
106691
  },
106686
- "fail_fast": {
106687
- "type": "boolean",
106688
- "description": "Stop execution when any check fails (default: false)"
106692
+ fail_fast: {
106693
+ type: 'boolean',
106694
+ description: 'Stop execution when any check fails (default: false)',
106689
106695
  },
106690
- "fail_if": {
106691
- "type": "string",
106692
- "description": "Simple global fail condition - fails if expression evaluates to true"
106696
+ fail_if: {
106697
+ type: 'string',
106698
+ description: 'Simple global fail condition - fails if expression evaluates to true',
106693
106699
  },
106694
- "failure_conditions": {
106695
- "$ref": "#/definitions/FailureConditions",
106696
- "description": "Global failure conditions - optional (deprecated, use fail_if)"
106700
+ failure_conditions: {
106701
+ $ref: '#/definitions/FailureConditions',
106702
+ description: 'Global failure conditions - optional (deprecated, use fail_if)',
106697
106703
  },
106698
- "tag_filter": {
106699
- "$ref": "#/definitions/TagFilter",
106700
- "description": "Tag filter for selective check execution"
106704
+ tag_filter: {
106705
+ $ref: '#/definitions/TagFilter',
106706
+ description: 'Tag filter for selective check execution',
106707
+ },
106708
+ routing: {
106709
+ $ref: '#/definitions/RoutingDefaults',
106710
+ description: 'Optional routing defaults for retry/goto/run policies',
106701
106711
  },
106702
- "routing": {
106703
- "$ref": "#/definitions/RoutingDefaults",
106704
- "description": "Optional routing defaults for retry/goto/run policies"
106705
- }
106706
106712
  },
106707
- "required": [
106708
- "version",
106709
- "checks",
106710
- "output"
106711
- ],
106712
- "additionalProperties": false,
106713
- "description": "Main Visor configuration",
106714
- "patternProperties": {
106715
- "^x-": {}
106716
- }
106713
+ required: ['version', 'checks', 'output'],
106714
+ additionalProperties: false,
106715
+ description: 'Main Visor configuration',
106716
+ patternProperties: {
106717
+ '^x-': {},
106718
+ },
106717
106719
  },
106718
- "Record<string,CheckConfig>": {
106719
- "type": "object",
106720
- "additionalProperties": {
106721
- "$ref": "#/definitions/CheckConfig"
106722
- }
106720
+ 'Record<string,CheckConfig>': {
106721
+ type: 'object',
106722
+ additionalProperties: {
106723
+ $ref: '#/definitions/CheckConfig',
106724
+ },
106723
106725
  },
106724
- "CheckConfig": {
106725
- "type": "object",
106726
- "properties": {
106727
- "type": {
106728
- "$ref": "#/definitions/ConfigCheckType",
106729
- "description": "Type of check to perform (defaults to 'ai' if not specified)"
106726
+ CheckConfig: {
106727
+ type: 'object',
106728
+ properties: {
106729
+ type: {
106730
+ $ref: '#/definitions/ConfigCheckType',
106731
+ description: "Type of check to perform (defaults to 'ai' if not specified)",
106730
106732
  },
106731
- "prompt": {
106732
- "type": "string",
106733
- "description": "AI prompt for the check - can be inline string or file path (auto-detected) - required for AI checks"
106733
+ prompt: {
106734
+ type: 'string',
106735
+ description: 'AI prompt for the check - can be inline string or file path (auto-detected) - required for AI checks',
106734
106736
  },
106735
- "appendPrompt": {
106736
- "type": "string",
106737
- "description": "Additional prompt to append when extending configurations - merged with parent prompt"
106737
+ appendPrompt: {
106738
+ type: 'string',
106739
+ description: 'Additional prompt to append when extending configurations - merged with parent prompt',
106738
106740
  },
106739
- "exec": {
106740
- "type": "string",
106741
- "description": "Command execution with Liquid template support - required for command checks"
106741
+ exec: {
106742
+ type: 'string',
106743
+ description: 'Command execution with Liquid template support - required for command checks',
106742
106744
  },
106743
- "stdin": {
106744
- "type": "string",
106745
- "description": "Stdin input for tools with Liquid template support - optional for tool checks"
106745
+ stdin: {
106746
+ type: 'string',
106747
+ description: 'Stdin input for tools with Liquid template support - optional for tool checks',
106746
106748
  },
106747
- "url": {
106748
- "type": "string",
106749
- "description": "HTTP URL - required for http output checks"
106749
+ url: {
106750
+ type: 'string',
106751
+ description: 'HTTP URL - required for http output checks',
106750
106752
  },
106751
- "body": {
106752
- "type": "string",
106753
- "description": "HTTP body template (Liquid) - required for http output checks"
106753
+ body: {
106754
+ type: 'string',
106755
+ description: 'HTTP body template (Liquid) - required for http output checks',
106754
106756
  },
106755
- "method": {
106756
- "type": "string",
106757
- "description": "HTTP method (defaults to POST)"
106757
+ method: {
106758
+ type: 'string',
106759
+ description: 'HTTP method (defaults to POST)',
106758
106760
  },
106759
- "headers": {
106760
- "$ref": "#/definitions/Record%3Cstring%2Cstring%3E",
106761
- "description": "HTTP headers"
106761
+ headers: {
106762
+ $ref: '#/definitions/Record%3Cstring%2Cstring%3E',
106763
+ description: 'HTTP headers',
106762
106764
  },
106763
- "endpoint": {
106764
- "type": "string",
106765
- "description": "HTTP endpoint path - required for http_input checks"
106765
+ endpoint: {
106766
+ type: 'string',
106767
+ description: 'HTTP endpoint path - required for http_input checks',
106766
106768
  },
106767
- "transform": {
106768
- "type": "string",
106769
- "description": "Transform template for http_input data (Liquid) - optional"
106769
+ transform: {
106770
+ type: 'string',
106771
+ description: 'Transform template for http_input data (Liquid) - optional',
106770
106772
  },
106771
- "transform_js": {
106772
- "type": "string",
106773
- "description": "Transform using JavaScript expressions (evaluated in secure sandbox) - optional"
106773
+ transform_js: {
106774
+ type: 'string',
106775
+ description: 'Transform using JavaScript expressions (evaluated in secure sandbox) - optional',
106774
106776
  },
106775
- "schedule": {
106776
- "type": "string",
106777
- "description": "Cron schedule expression (e.g., \"0 2 * * *\") - optional for any check type"
106777
+ schedule: {
106778
+ type: 'string',
106779
+ description: 'Cron schedule expression (e.g., "0 2 * * *") - optional for any check type',
106778
106780
  },
106779
- "focus": {
106780
- "type": "string",
106781
- "description": "Focus area for the check (security/performance/style/architecture/all) - optional"
106781
+ focus: {
106782
+ type: 'string',
106783
+ description: 'Focus area for the check (security/performance/style/architecture/all) - optional',
106782
106784
  },
106783
- "command": {
106784
- "type": "string",
106785
- "description": "Command that triggers this check (e.g., \"review\", \"security-scan\") - optional"
106785
+ command: {
106786
+ type: 'string',
106787
+ description: 'Command that triggers this check (e.g., "review", "security-scan") - optional',
106786
106788
  },
106787
- "on": {
106788
- "type": "array",
106789
- "items": {
106790
- "$ref": "#/definitions/EventTrigger"
106789
+ on: {
106790
+ type: 'array',
106791
+ items: {
106792
+ $ref: '#/definitions/EventTrigger',
106791
106793
  },
106792
- "description": "Events that trigger this check (defaults to ['manual'] if not specified)"
106794
+ description: "Events that trigger this check (defaults to ['manual'] if not specified)",
106793
106795
  },
106794
- "triggers": {
106795
- "type": "array",
106796
- "items": {
106797
- "type": "string"
106796
+ triggers: {
106797
+ type: 'array',
106798
+ items: {
106799
+ type: 'string',
106798
106800
  },
106799
- "description": "File patterns that trigger this check (optional)"
106801
+ description: 'File patterns that trigger this check (optional)',
106800
106802
  },
106801
- "ai": {
106802
- "$ref": "#/definitions/AIProviderConfig",
106803
- "description": "AI provider configuration (optional)"
106803
+ ai: {
106804
+ $ref: '#/definitions/AIProviderConfig',
106805
+ description: 'AI provider configuration (optional)',
106804
106806
  },
106805
- "ai_model": {
106806
- "type": "string",
106807
- "description": "AI model to use for this check - overrides global setting"
106807
+ ai_model: {
106808
+ type: 'string',
106809
+ description: 'AI model to use for this check - overrides global setting',
106808
106810
  },
106809
- "ai_provider": {
106810
- "type": "string",
106811
- "description": "AI provider to use for this check - overrides global setting"
106811
+ ai_provider: {
106812
+ type: 'string',
106813
+ description: 'AI provider to use for this check - overrides global setting',
106812
106814
  },
106813
- "ai_mcp_servers": {
106814
- "$ref": "#/definitions/Record%3Cstring%2CMcpServerConfig%3E",
106815
- "description": "MCP servers for this AI check - overrides global setting"
106815
+ ai_mcp_servers: {
106816
+ $ref: '#/definitions/Record%3Cstring%2CMcpServerConfig%3E',
106817
+ description: 'MCP servers for this AI check - overrides global setting',
106816
106818
  },
106817
- "claude_code": {
106818
- "$ref": "#/definitions/ClaudeCodeConfig",
106819
- "description": "Claude Code configuration (for claude-code type checks)"
106819
+ claude_code: {
106820
+ $ref: '#/definitions/ClaudeCodeConfig',
106821
+ description: 'Claude Code configuration (for claude-code type checks)',
106820
106822
  },
106821
- "env": {
106822
- "$ref": "#/definitions/EnvConfig",
106823
- "description": "Environment variables for this check"
106823
+ env: {
106824
+ $ref: '#/definitions/EnvConfig',
106825
+ description: 'Environment variables for this check',
106824
106826
  },
106825
- "depends_on": {
106826
- "type": "array",
106827
- "items": {
106828
- "type": "string"
106827
+ depends_on: {
106828
+ type: 'array',
106829
+ items: {
106830
+ type: 'string',
106829
106831
  },
106830
- "description": "Check IDs that this check depends on (optional)"
106832
+ description: 'Check IDs that this check depends on (optional)',
106831
106833
  },
106832
- "group": {
106833
- "type": "string",
106834
- "description": "Group name for comment separation (e.g., \"code-review\", \"pr-overview\") - optional"
106834
+ group: {
106835
+ type: 'string',
106836
+ description: 'Group name for comment separation (e.g., "code-review", "pr-overview") - optional',
106835
106837
  },
106836
- "schema": {
106837
- "anyOf": [
106838
+ schema: {
106839
+ anyOf: [
106838
106840
  {
106839
- "type": "string"
106841
+ type: 'string',
106840
106842
  },
106841
106843
  {
106842
- "$ref": "#/definitions/Record%3Cstring%2Cunknown%3E"
106843
- }
106844
+ $ref: '#/definitions/Record%3Cstring%2Cunknown%3E',
106845
+ },
106844
106846
  ],
106845
- "description": "Schema type for template rendering (e.g., \"code-review\", \"markdown\") or inline JSON schema object - optional"
106847
+ description: 'Schema type for template rendering (e.g., "code-review", "markdown") or inline JSON schema object - optional',
106846
106848
  },
106847
- "template": {
106848
- "$ref": "#/definitions/CustomTemplateConfig",
106849
- "description": "Custom template configuration - optional"
106849
+ template: {
106850
+ $ref: '#/definitions/CustomTemplateConfig',
106851
+ description: 'Custom template configuration - optional',
106850
106852
  },
106851
- "if": {
106852
- "type": "string",
106853
- "description": "Condition to determine if check should run - runs if expression evaluates to true"
106853
+ if: {
106854
+ type: 'string',
106855
+ description: 'Condition to determine if check should run - runs if expression evaluates to true',
106854
106856
  },
106855
- "reuse_ai_session": {
106856
- "type": "boolean",
106857
- "description": "Whether to reuse AI session from dependency checks (only works with depends_on)"
106857
+ reuse_ai_session: {
106858
+ type: 'boolean',
106859
+ description: 'Whether to reuse AI session from dependency checks (only works with depends_on)',
106858
106860
  },
106859
- "fail_if": {
106860
- "type": "string",
106861
- "description": "Simple fail condition - fails check if expression evaluates to true"
106861
+ fail_if: {
106862
+ type: 'string',
106863
+ description: 'Simple fail condition - fails check if expression evaluates to true',
106862
106864
  },
106863
- "failure_conditions": {
106864
- "$ref": "#/definitions/FailureConditions",
106865
- "description": "Check-specific failure conditions - optional (deprecated, use fail_if)"
106865
+ failure_conditions: {
106866
+ $ref: '#/definitions/FailureConditions',
106867
+ description: 'Check-specific failure conditions - optional (deprecated, use fail_if)',
106866
106868
  },
106867
- "tags": {
106868
- "type": "array",
106869
- "items": {
106870
- "type": "string"
106869
+ tags: {
106870
+ type: 'array',
106871
+ items: {
106872
+ type: 'string',
106871
106873
  },
106872
- "description": "Tags for categorizing and filtering checks (e.g., [\"local\", \"fast\", \"security\"])"
106874
+ description: 'Tags for categorizing and filtering checks (e.g., ["local", "fast", "security"])',
106873
106875
  },
106874
- "forEach": {
106875
- "type": "boolean",
106876
- "description": "Process output as array and run dependent checks for each item"
106876
+ forEach: {
106877
+ type: 'boolean',
106878
+ description: 'Process output as array and run dependent checks for each item',
106877
106879
  },
106878
- "on_fail": {
106879
- "$ref": "#/definitions/OnFailConfig",
106880
- "description": "Failure routing configuration for this check (retry/goto/run)"
106880
+ on_fail: {
106881
+ $ref: '#/definitions/OnFailConfig',
106882
+ description: 'Failure routing configuration for this check (retry/goto/run)',
106883
+ },
106884
+ on_success: {
106885
+ $ref: '#/definitions/OnSuccessConfig',
106886
+ description: 'Success routing configuration for this check (post-actions and optional goto)',
106887
+ },
106888
+ message: {
106889
+ type: 'string',
106890
+ description: 'Message template for log checks',
106891
+ },
106892
+ level: {
106893
+ type: 'string',
106894
+ enum: ['debug', 'info', 'warn', 'error'],
106895
+ description: 'Log level for log checks',
106896
+ },
106897
+ include_pr_context: {
106898
+ type: 'boolean',
106899
+ description: 'Include PR context in log output',
106900
+ },
106901
+ include_dependencies: {
106902
+ type: 'boolean',
106903
+ description: 'Include dependency summaries in log output',
106904
+ },
106905
+ include_metadata: {
106906
+ type: 'boolean',
106907
+ description: 'Include execution metadata in log output',
106881
106908
  },
106882
- "on_success": {
106883
- "$ref": "#/definitions/OnSuccessConfig",
106884
- "description": "Success routing configuration for this check (post-actions and optional goto)"
106885
- }
106886
106909
  },
106887
- "additionalProperties": false,
106888
- "description": "Configuration for a single check",
106889
- "patternProperties": {
106890
- "^x-": {}
106891
- }
106910
+ additionalProperties: false,
106911
+ description: 'Configuration for a single check',
106912
+ patternProperties: {
106913
+ '^x-': {},
106914
+ },
106892
106915
  },
106893
- "ConfigCheckType": {
106894
- "type": "string",
106895
- "enum": [
106896
- "ai",
106897
- "command",
106898
- "http",
106899
- "http_input",
106900
- "http_client",
106901
- "noop",
106902
- "log",
106903
- "claude-code"
106904
- ],
106905
- "description": "Valid check types in configuration"
106916
+ ConfigCheckType: {
106917
+ type: 'string',
106918
+ enum: ['ai', 'command', 'http', 'http_input', 'http_client', 'noop', 'log', 'claude-code'],
106919
+ description: 'Valid check types in configuration',
106906
106920
  },
106907
- "Record<string,string>": {
106908
- "type": "object",
106909
- "additionalProperties": {
106910
- "type": "string"
106911
- }
106921
+ 'Record<string,string>': {
106922
+ type: 'object',
106923
+ additionalProperties: {
106924
+ type: 'string',
106925
+ },
106912
106926
  },
106913
- "EventTrigger": {
106914
- "type": "string",
106915
- "enum": [
106916
- "pr_opened",
106917
- "pr_updated",
106918
- "pr_closed",
106919
- "issue_opened",
106920
- "issue_comment",
106921
- "manual",
106922
- "schedule",
106923
- "webhook_received"
106927
+ EventTrigger: {
106928
+ type: 'string',
106929
+ enum: [
106930
+ 'pr_opened',
106931
+ 'pr_updated',
106932
+ 'pr_closed',
106933
+ 'issue_opened',
106934
+ 'issue_comment',
106935
+ 'manual',
106936
+ 'schedule',
106937
+ 'webhook_received',
106924
106938
  ],
106925
- "description": "Valid event triggers for checks"
106939
+ description: 'Valid event triggers for checks',
106926
106940
  },
106927
- "AIProviderConfig": {
106928
- "type": "object",
106929
- "properties": {
106930
- "provider": {
106931
- "type": "string",
106932
- "enum": [
106933
- "google",
106934
- "anthropic",
106935
- "openai",
106936
- "bedrock",
106937
- "mock"
106938
- ],
106939
- "description": "AI provider to use"
106941
+ AIProviderConfig: {
106942
+ type: 'object',
106943
+ properties: {
106944
+ provider: {
106945
+ type: 'string',
106946
+ enum: ['google', 'anthropic', 'openai', 'bedrock', 'mock'],
106947
+ description: 'AI provider to use',
106940
106948
  },
106941
- "model": {
106942
- "type": "string",
106943
- "description": "Model name to use"
106949
+ model: {
106950
+ type: 'string',
106951
+ description: 'Model name to use',
106944
106952
  },
106945
- "apiKey": {
106946
- "type": "string",
106947
- "description": "API key (usually from environment variables)"
106953
+ apiKey: {
106954
+ type: 'string',
106955
+ description: 'API key (usually from environment variables)',
106948
106956
  },
106949
- "timeout": {
106950
- "type": "number",
106951
- "description": "Request timeout in milliseconds"
106957
+ timeout: {
106958
+ type: 'number',
106959
+ description: 'Request timeout in milliseconds',
106952
106960
  },
106953
- "debug": {
106954
- "type": "boolean",
106955
- "description": "Enable debug mode"
106961
+ debug: {
106962
+ type: 'boolean',
106963
+ description: 'Enable debug mode',
106964
+ },
106965
+ mcpServers: {
106966
+ $ref: '#/definitions/Record%3Cstring%2CMcpServerConfig%3E',
106967
+ description: 'MCP servers configuration',
106956
106968
  },
106957
- "mcpServers": {
106958
- "$ref": "#/definitions/Record%3Cstring%2CMcpServerConfig%3E",
106959
- "description": "MCP servers configuration"
106960
- }
106961
106969
  },
106962
- "additionalProperties": false,
106963
- "description": "AI provider configuration",
106964
- "patternProperties": {
106965
- "^x-": {}
106966
- }
106970
+ additionalProperties: false,
106971
+ description: 'AI provider configuration',
106972
+ patternProperties: {
106973
+ '^x-': {},
106974
+ },
106967
106975
  },
106968
- "Record<string,McpServerConfig>": {
106969
- "type": "object",
106970
- "additionalProperties": {
106971
- "$ref": "#/definitions/McpServerConfig"
106972
- }
106976
+ 'Record<string,McpServerConfig>': {
106977
+ type: 'object',
106978
+ additionalProperties: {
106979
+ $ref: '#/definitions/McpServerConfig',
106980
+ },
106973
106981
  },
106974
- "McpServerConfig": {
106975
- "type": "object",
106976
- "properties": {
106977
- "command": {
106978
- "type": "string",
106979
- "description": "Command to execute for the MCP server"
106982
+ McpServerConfig: {
106983
+ type: 'object',
106984
+ properties: {
106985
+ command: {
106986
+ type: 'string',
106987
+ description: 'Command to execute for the MCP server',
106980
106988
  },
106981
- "args": {
106982
- "type": "array",
106983
- "items": {
106984
- "type": "string"
106989
+ args: {
106990
+ type: 'array',
106991
+ items: {
106992
+ type: 'string',
106985
106993
  },
106986
- "description": "Arguments to pass to the command"
106994
+ description: 'Arguments to pass to the command',
106995
+ },
106996
+ env: {
106997
+ $ref: '#/definitions/Record%3Cstring%2Cstring%3E',
106998
+ description: 'Environment variables for the MCP server',
106987
106999
  },
106988
- "env": {
106989
- "$ref": "#/definitions/Record%3Cstring%2Cstring%3E",
106990
- "description": "Environment variables for the MCP server"
106991
- }
106992
107000
  },
106993
- "required": [
106994
- "command"
106995
- ],
106996
- "additionalProperties": false,
106997
- "description": "MCP Server configuration",
106998
- "patternProperties": {
106999
- "^x-": {}
107000
- }
107001
+ required: ['command'],
107002
+ additionalProperties: false,
107003
+ description: 'MCP Server configuration',
107004
+ patternProperties: {
107005
+ '^x-': {},
107006
+ },
107001
107007
  },
107002
- "ClaudeCodeConfig": {
107003
- "type": "object",
107004
- "properties": {
107005
- "allowedTools": {
107006
- "type": "array",
107007
- "items": {
107008
- "type": "string"
107008
+ ClaudeCodeConfig: {
107009
+ type: 'object',
107010
+ properties: {
107011
+ allowedTools: {
107012
+ type: 'array',
107013
+ items: {
107014
+ type: 'string',
107009
107015
  },
107010
- "description": "List of allowed tools for Claude Code to use"
107016
+ description: 'List of allowed tools for Claude Code to use',
107011
107017
  },
107012
- "maxTurns": {
107013
- "type": "number",
107014
- "description": "Maximum number of turns in conversation"
107018
+ maxTurns: {
107019
+ type: 'number',
107020
+ description: 'Maximum number of turns in conversation',
107015
107021
  },
107016
- "systemPrompt": {
107017
- "type": "string",
107018
- "description": "System prompt for Claude Code"
107022
+ systemPrompt: {
107023
+ type: 'string',
107024
+ description: 'System prompt for Claude Code',
107019
107025
  },
107020
- "mcpServers": {
107021
- "$ref": "#/definitions/Record%3Cstring%2CMcpServerConfig%3E",
107022
- "description": "MCP servers configuration"
107026
+ mcpServers: {
107027
+ $ref: '#/definitions/Record%3Cstring%2CMcpServerConfig%3E',
107028
+ description: 'MCP servers configuration',
107023
107029
  },
107024
- "subagent": {
107025
- "type": "string",
107026
- "description": "Path to subagent script"
107030
+ subagent: {
107031
+ type: 'string',
107032
+ description: 'Path to subagent script',
107027
107033
  },
107028
- "hooks": {
107029
- "type": "object",
107030
- "properties": {
107031
- "onStart": {
107032
- "type": "string",
107033
- "description": "Called when check starts"
107034
+ hooks: {
107035
+ type: 'object',
107036
+ properties: {
107037
+ onStart: {
107038
+ type: 'string',
107039
+ description: 'Called when check starts',
107034
107040
  },
107035
- "onEnd": {
107036
- "type": "string",
107037
- "description": "Called when check ends"
107041
+ onEnd: {
107042
+ type: 'string',
107043
+ description: 'Called when check ends',
107044
+ },
107045
+ onError: {
107046
+ type: 'string',
107047
+ description: 'Called when check encounters an error',
107038
107048
  },
107039
- "onError": {
107040
- "type": "string",
107041
- "description": "Called when check encounters an error"
107042
- }
107043
107049
  },
107044
- "additionalProperties": false,
107045
- "description": "Event hooks for lifecycle management",
107046
- "patternProperties": {
107047
- "^x-": {}
107048
- }
107049
- }
107050
+ additionalProperties: false,
107051
+ description: 'Event hooks for lifecycle management',
107052
+ patternProperties: {
107053
+ '^x-': {},
107054
+ },
107055
+ },
107056
+ },
107057
+ additionalProperties: false,
107058
+ description: 'Claude Code configuration',
107059
+ patternProperties: {
107060
+ '^x-': {},
107050
107061
  },
107051
- "additionalProperties": false,
107052
- "description": "Claude Code configuration",
107053
- "patternProperties": {
107054
- "^x-": {}
107055
- }
107056
107062
  },
107057
- "EnvConfig": {
107058
- "type": "object",
107059
- "additionalProperties": {
107060
- "type": [
107061
- "string",
107062
- "number",
107063
- "boolean"
107064
- ]
107063
+ EnvConfig: {
107064
+ type: 'object',
107065
+ additionalProperties: {
107066
+ type: ['string', 'number', 'boolean'],
107065
107067
  },
107066
- "description": "Environment variable reference configuration"
107068
+ description: 'Environment variable reference configuration',
107067
107069
  },
107068
- "Record<string,unknown>": {
107069
- "type": "object",
107070
- "additionalProperties": {}
107070
+ 'Record<string,unknown>': {
107071
+ type: 'object',
107072
+ additionalProperties: {},
107071
107073
  },
107072
- "CustomTemplateConfig": {
107073
- "type": "object",
107074
- "properties": {
107075
- "file": {
107076
- "type": "string",
107077
- "description": "Path to custom template file (relative to config file or absolute)"
107074
+ CustomTemplateConfig: {
107075
+ type: 'object',
107076
+ properties: {
107077
+ file: {
107078
+ type: 'string',
107079
+ description: 'Path to custom template file (relative to config file or absolute)',
107080
+ },
107081
+ content: {
107082
+ type: 'string',
107083
+ description: 'Raw template content as string',
107078
107084
  },
107079
- "content": {
107080
- "type": "string",
107081
- "description": "Raw template content as string"
107082
- }
107083
107085
  },
107084
- "additionalProperties": false,
107085
- "description": "Custom template configuration",
107086
- "patternProperties": {
107087
- "^x-": {}
107088
- }
107086
+ additionalProperties: false,
107087
+ description: 'Custom template configuration',
107088
+ patternProperties: {
107089
+ '^x-': {},
107090
+ },
107089
107091
  },
107090
- "FailureConditions": {
107091
- "type": "object",
107092
- "additionalProperties": {
107093
- "$ref": "#/definitions/FailureCondition"
107092
+ FailureConditions: {
107093
+ type: 'object',
107094
+ additionalProperties: {
107095
+ $ref: '#/definitions/FailureCondition',
107094
107096
  },
107095
- "description": "Collection of failure conditions"
107097
+ description: 'Collection of failure conditions',
107096
107098
  },
107097
- "FailureCondition": {
107098
- "anyOf": [
107099
+ FailureCondition: {
107100
+ anyOf: [
107099
107101
  {
107100
- "$ref": "#/definitions/SimpleFailureCondition"
107102
+ $ref: '#/definitions/SimpleFailureCondition',
107101
107103
  },
107102
107104
  {
107103
- "$ref": "#/definitions/ComplexFailureCondition"
107104
- }
107105
+ $ref: '#/definitions/ComplexFailureCondition',
107106
+ },
107105
107107
  ],
107106
- "description": "Failure condition - can be a simple expression string or complex object"
107108
+ description: 'Failure condition - can be a simple expression string or complex object',
107107
107109
  },
107108
- "SimpleFailureCondition": {
107109
- "type": "string",
107110
- "description": "Simple failure condition - just an expression string"
107110
+ SimpleFailureCondition: {
107111
+ type: 'string',
107112
+ description: 'Simple failure condition - just an expression string',
107111
107113
  },
107112
- "ComplexFailureCondition": {
107113
- "type": "object",
107114
- "properties": {
107115
- "condition": {
107116
- "type": "string",
107117
- "description": "Expression to evaluate using Function Constructor"
107114
+ ComplexFailureCondition: {
107115
+ type: 'object',
107116
+ properties: {
107117
+ condition: {
107118
+ type: 'string',
107119
+ description: 'Expression to evaluate using Function Constructor',
107118
107120
  },
107119
- "message": {
107120
- "type": "string",
107121
- "description": "Human-readable message when condition is met"
107121
+ message: {
107122
+ type: 'string',
107123
+ description: 'Human-readable message when condition is met',
107122
107124
  },
107123
- "severity": {
107124
- "$ref": "#/definitions/FailureConditionSeverity",
107125
- "description": "Severity level of the failure"
107125
+ severity: {
107126
+ $ref: '#/definitions/FailureConditionSeverity',
107127
+ description: 'Severity level of the failure',
107128
+ },
107129
+ halt_execution: {
107130
+ type: 'boolean',
107131
+ description: 'Whether this condition should halt execution',
107126
107132
  },
107127
- "halt_execution": {
107128
- "type": "boolean",
107129
- "description": "Whether this condition should halt execution"
107130
- }
107131
107133
  },
107132
- "required": [
107133
- "condition"
107134
- ],
107135
- "additionalProperties": false,
107136
- "description": "Complex failure condition with additional metadata",
107137
- "patternProperties": {
107138
- "^x-": {}
107139
- }
107134
+ required: ['condition'],
107135
+ additionalProperties: false,
107136
+ description: 'Complex failure condition with additional metadata',
107137
+ patternProperties: {
107138
+ '^x-': {},
107139
+ },
107140
107140
  },
107141
- "FailureConditionSeverity": {
107142
- "type": "string",
107143
- "enum": [
107144
- "error",
107145
- "warning",
107146
- "info"
107147
- ],
107148
- "description": "Failure condition severity levels"
107141
+ FailureConditionSeverity: {
107142
+ type: 'string',
107143
+ enum: ['error', 'warning', 'info'],
107144
+ description: 'Failure condition severity levels',
107149
107145
  },
107150
- "OnFailConfig": {
107151
- "type": "object",
107152
- "properties": {
107153
- "retry": {
107154
- "$ref": "#/definitions/RetryPolicy",
107155
- "description": "Retry policy"
107146
+ OnFailConfig: {
107147
+ type: 'object',
107148
+ properties: {
107149
+ retry: {
107150
+ $ref: '#/definitions/RetryPolicy',
107151
+ description: 'Retry policy',
107156
107152
  },
107157
- "run": {
107158
- "type": "array",
107159
- "items": {
107160
- "type": "string"
107153
+ run: {
107154
+ type: 'array',
107155
+ items: {
107156
+ type: 'string',
107161
107157
  },
107162
- "description": "Remediation steps to run before reattempt"
107158
+ description: 'Remediation steps to run before reattempt',
107163
107159
  },
107164
- "goto": {
107165
- "type": "string",
107166
- "description": "Jump back to an ancestor step (by id)"
107160
+ goto: {
107161
+ type: 'string',
107162
+ description: 'Jump back to an ancestor step (by id)',
107167
107163
  },
107168
- "goto_js": {
107169
- "type": "string",
107170
- "description": "Dynamic goto: JS expression returning step id or null"
107164
+ goto_js: {
107165
+ type: 'string',
107166
+ description: 'Dynamic goto: JS expression returning step id or null',
107167
+ },
107168
+ run_js: {
107169
+ type: 'string',
107170
+ description: 'Dynamic remediation list: JS expression returning string[]',
107171
107171
  },
107172
- "run_js": {
107173
- "type": "string",
107174
- "description": "Dynamic remediation list: JS expression returning string[]"
107175
- }
107176
107172
  },
107177
- "additionalProperties": false,
107178
- "description": "Failure routing configuration per check",
107179
- "patternProperties": {
107180
- "^x-": {}
107181
- }
107173
+ additionalProperties: false,
107174
+ description: 'Failure routing configuration per check',
107175
+ patternProperties: {
107176
+ '^x-': {},
107177
+ },
107182
107178
  },
107183
- "RetryPolicy": {
107184
- "type": "object",
107185
- "properties": {
107186
- "max": {
107187
- "type": "number",
107188
- "description": "Maximum retry attempts (excluding the first attempt)"
107179
+ RetryPolicy: {
107180
+ type: 'object',
107181
+ properties: {
107182
+ max: {
107183
+ type: 'number',
107184
+ description: 'Maximum retry attempts (excluding the first attempt)',
107185
+ },
107186
+ backoff: {
107187
+ $ref: '#/definitions/BackoffPolicy',
107188
+ description: 'Backoff policy',
107189
107189
  },
107190
- "backoff": {
107191
- "$ref": "#/definitions/BackoffPolicy",
107192
- "description": "Backoff policy"
107193
- }
107194
107190
  },
107195
- "additionalProperties": false,
107196
- "description": "Retry policy for a step",
107197
- "patternProperties": {
107198
- "^x-": {}
107199
- }
107191
+ additionalProperties: false,
107192
+ description: 'Retry policy for a step',
107193
+ patternProperties: {
107194
+ '^x-': {},
107195
+ },
107200
107196
  },
107201
- "BackoffPolicy": {
107202
- "type": "object",
107203
- "properties": {
107204
- "mode": {
107205
- "type": "string",
107206
- "enum": [
107207
- "fixed",
107208
- "exponential"
107209
- ],
107210
- "description": "Backoff mode"
107197
+ BackoffPolicy: {
107198
+ type: 'object',
107199
+ properties: {
107200
+ mode: {
107201
+ type: 'string',
107202
+ enum: ['fixed', 'exponential'],
107203
+ description: 'Backoff mode',
107204
+ },
107205
+ delay_ms: {
107206
+ type: 'number',
107207
+ description: 'Initial delay in milliseconds',
107211
107208
  },
107212
- "delay_ms": {
107213
- "type": "number",
107214
- "description": "Initial delay in milliseconds"
107215
- }
107216
107209
  },
107217
- "additionalProperties": false,
107218
- "description": "Backoff policy for retries",
107219
- "patternProperties": {
107220
- "^x-": {}
107221
- }
107210
+ additionalProperties: false,
107211
+ description: 'Backoff policy for retries',
107212
+ patternProperties: {
107213
+ '^x-': {},
107214
+ },
107222
107215
  },
107223
- "OnSuccessConfig": {
107224
- "type": "object",
107225
- "properties": {
107226
- "run": {
107227
- "type": "array",
107228
- "items": {
107229
- "type": "string"
107216
+ OnSuccessConfig: {
107217
+ type: 'object',
107218
+ properties: {
107219
+ run: {
107220
+ type: 'array',
107221
+ items: {
107222
+ type: 'string',
107230
107223
  },
107231
- "description": "Post-success steps to run"
107224
+ description: 'Post-success steps to run',
107232
107225
  },
107233
- "goto": {
107234
- "type": "string",
107235
- "description": "Optional jump back to ancestor step (by id)"
107226
+ goto: {
107227
+ type: 'string',
107228
+ description: 'Optional jump back to ancestor step (by id)',
107236
107229
  },
107237
- "goto_js": {
107238
- "type": "string",
107239
- "description": "Dynamic goto: JS expression returning step id or null"
107230
+ goto_js: {
107231
+ type: 'string',
107232
+ description: 'Dynamic goto: JS expression returning step id or null',
107233
+ },
107234
+ run_js: {
107235
+ type: 'string',
107236
+ description: 'Dynamic post-success steps: JS expression returning string[]',
107240
107237
  },
107241
- "run_js": {
107242
- "type": "string",
107243
- "description": "Dynamic post-success steps: JS expression returning string[]"
107244
- }
107245
107238
  },
107246
- "additionalProperties": false,
107247
- "description": "Success routing configuration per check",
107248
- "patternProperties": {
107249
- "^x-": {}
107250
- }
107239
+ additionalProperties: false,
107240
+ description: 'Success routing configuration per check',
107241
+ patternProperties: {
107242
+ '^x-': {},
107243
+ },
107251
107244
  },
107252
- "OutputConfig": {
107253
- "type": "object",
107254
- "properties": {
107255
- "pr_comment": {
107256
- "$ref": "#/definitions/PrCommentOutput",
107257
- "description": "PR comment configuration"
107245
+ OutputConfig: {
107246
+ type: 'object',
107247
+ properties: {
107248
+ pr_comment: {
107249
+ $ref: '#/definitions/PrCommentOutput',
107250
+ description: 'PR comment configuration',
107258
107251
  },
107259
- "file_comment": {
107260
- "$ref": "#/definitions/FileCommentOutput",
107261
- "description": "File comment configuration (optional)"
107252
+ file_comment: {
107253
+ $ref: '#/definitions/FileCommentOutput',
107254
+ description: 'File comment configuration (optional)',
107262
107255
  },
107263
- "github_checks": {
107264
- "$ref": "#/definitions/GitHubCheckOutput",
107265
- "description": "GitHub check runs configuration (optional)"
107256
+ github_checks: {
107257
+ $ref: '#/definitions/GitHubCheckOutput',
107258
+ description: 'GitHub check runs configuration (optional)',
107259
+ },
107260
+ suppressionEnabled: {
107261
+ type: 'boolean',
107262
+ description: 'Whether to enable issue suppression via visor-disable comments (default: true)',
107266
107263
  },
107267
- "suppressionEnabled": {
107268
- "type": "boolean",
107269
- "description": "Whether to enable issue suppression via visor-disable comments (default: true)"
107270
- }
107271
107264
  },
107272
- "required": [
107273
- "pr_comment"
107274
- ],
107275
- "additionalProperties": false,
107276
- "description": "Output configuration",
107277
- "patternProperties": {
107278
- "^x-": {}
107279
- }
107265
+ required: ['pr_comment'],
107266
+ additionalProperties: false,
107267
+ description: 'Output configuration',
107268
+ patternProperties: {
107269
+ '^x-': {},
107270
+ },
107280
107271
  },
107281
- "PrCommentOutput": {
107282
- "type": "object",
107283
- "properties": {
107284
- "format": {
107285
- "$ref": "#/definitions/ConfigOutputFormat",
107286
- "description": "Format of the output"
107272
+ PrCommentOutput: {
107273
+ type: 'object',
107274
+ properties: {
107275
+ format: {
107276
+ $ref: '#/definitions/ConfigOutputFormat',
107277
+ description: 'Format of the output',
107287
107278
  },
107288
- "group_by": {
107289
- "$ref": "#/definitions/GroupByOption",
107290
- "description": "How to group the results"
107279
+ group_by: {
107280
+ $ref: '#/definitions/GroupByOption',
107281
+ description: 'How to group the results',
107291
107282
  },
107292
- "collapse": {
107293
- "type": "boolean",
107294
- "description": "Whether to collapse sections by default"
107283
+ collapse: {
107284
+ type: 'boolean',
107285
+ description: 'Whether to collapse sections by default',
107286
+ },
107287
+ debug: {
107288
+ $ref: '#/definitions/DebugConfig',
107289
+ description: 'Debug mode configuration (optional)',
107295
107290
  },
107296
- "debug": {
107297
- "$ref": "#/definitions/DebugConfig",
107298
- "description": "Debug mode configuration (optional)"
107299
- }
107300
107291
  },
107301
- "required": [
107302
- "format",
107303
- "group_by",
107304
- "collapse"
107305
- ],
107306
- "additionalProperties": false,
107307
- "description": "PR comment output configuration",
107308
- "patternProperties": {
107309
- "^x-": {}
107310
- }
107292
+ required: ['format', 'group_by', 'collapse'],
107293
+ additionalProperties: false,
107294
+ description: 'PR comment output configuration',
107295
+ patternProperties: {
107296
+ '^x-': {},
107297
+ },
107311
107298
  },
107312
- "ConfigOutputFormat": {
107313
- "type": "string",
107314
- "enum": [
107315
- "table",
107316
- "json",
107317
- "markdown",
107318
- "sarif"
107319
- ],
107320
- "description": "Valid output formats"
107299
+ ConfigOutputFormat: {
107300
+ type: 'string',
107301
+ enum: ['table', 'json', 'markdown', 'sarif'],
107302
+ description: 'Valid output formats',
107321
107303
  },
107322
- "GroupByOption": {
107323
- "type": "string",
107324
- "enum": [
107325
- "check",
107326
- "file",
107327
- "severity"
107328
- ],
107329
- "description": "Valid grouping options"
107304
+ GroupByOption: {
107305
+ type: 'string',
107306
+ enum: ['check', 'file', 'severity'],
107307
+ description: 'Valid grouping options',
107330
107308
  },
107331
- "DebugConfig": {
107332
- "type": "object",
107333
- "properties": {
107334
- "enabled": {
107335
- "type": "boolean",
107336
- "description": "Enable debug mode"
107309
+ DebugConfig: {
107310
+ type: 'object',
107311
+ properties: {
107312
+ enabled: {
107313
+ type: 'boolean',
107314
+ description: 'Enable debug mode',
107337
107315
  },
107338
- "includePrompts": {
107339
- "type": "boolean",
107340
- "description": "Include AI prompts in debug output"
107316
+ includePrompts: {
107317
+ type: 'boolean',
107318
+ description: 'Include AI prompts in debug output',
107341
107319
  },
107342
- "includeRawResponses": {
107343
- "type": "boolean",
107344
- "description": "Include raw AI responses in debug output"
107320
+ includeRawResponses: {
107321
+ type: 'boolean',
107322
+ description: 'Include raw AI responses in debug output',
107345
107323
  },
107346
- "includeTiming": {
107347
- "type": "boolean",
107348
- "description": "Include timing information"
107324
+ includeTiming: {
107325
+ type: 'boolean',
107326
+ description: 'Include timing information',
107327
+ },
107328
+ includeProviderInfo: {
107329
+ type: 'boolean',
107330
+ description: 'Include provider information',
107349
107331
  },
107350
- "includeProviderInfo": {
107351
- "type": "boolean",
107352
- "description": "Include provider information"
107353
- }
107354
107332
  },
107355
- "required": [
107356
- "enabled",
107357
- "includePrompts",
107358
- "includeRawResponses",
107359
- "includeTiming",
107360
- "includeProviderInfo"
107333
+ required: [
107334
+ 'enabled',
107335
+ 'includePrompts',
107336
+ 'includeRawResponses',
107337
+ 'includeTiming',
107338
+ 'includeProviderInfo',
107361
107339
  ],
107362
- "additionalProperties": false,
107363
- "description": "Debug mode configuration",
107364
- "patternProperties": {
107365
- "^x-": {}
107366
- }
107340
+ additionalProperties: false,
107341
+ description: 'Debug mode configuration',
107342
+ patternProperties: {
107343
+ '^x-': {},
107344
+ },
107367
107345
  },
107368
- "FileCommentOutput": {
107369
- "type": "object",
107370
- "properties": {
107371
- "enabled": {
107372
- "type": "boolean",
107373
- "description": "Whether file comments are enabled"
107346
+ FileCommentOutput: {
107347
+ type: 'object',
107348
+ properties: {
107349
+ enabled: {
107350
+ type: 'boolean',
107351
+ description: 'Whether file comments are enabled',
107352
+ },
107353
+ inline: {
107354
+ type: 'boolean',
107355
+ description: 'Whether to show inline comments',
107374
107356
  },
107375
- "inline": {
107376
- "type": "boolean",
107377
- "description": "Whether to show inline comments"
107378
- }
107379
107357
  },
107380
- "required": [
107381
- "enabled",
107382
- "inline"
107383
- ],
107384
- "additionalProperties": false,
107385
- "description": "File comment output configuration",
107386
- "patternProperties": {
107387
- "^x-": {}
107388
- }
107358
+ required: ['enabled', 'inline'],
107359
+ additionalProperties: false,
107360
+ description: 'File comment output configuration',
107361
+ patternProperties: {
107362
+ '^x-': {},
107363
+ },
107389
107364
  },
107390
- "GitHubCheckOutput": {
107391
- "type": "object",
107392
- "properties": {
107393
- "enabled": {
107394
- "type": "boolean",
107395
- "description": "Whether GitHub check runs are enabled"
107365
+ GitHubCheckOutput: {
107366
+ type: 'object',
107367
+ properties: {
107368
+ enabled: {
107369
+ type: 'boolean',
107370
+ description: 'Whether GitHub check runs are enabled',
107396
107371
  },
107397
- "per_check": {
107398
- "type": "boolean",
107399
- "description": "Whether to create individual check runs per configured check"
107372
+ per_check: {
107373
+ type: 'boolean',
107374
+ description: 'Whether to create individual check runs per configured check',
107375
+ },
107376
+ name_prefix: {
107377
+ type: 'string',
107378
+ description: 'Custom name prefix for check runs',
107400
107379
  },
107401
- "name_prefix": {
107402
- "type": "string",
107403
- "description": "Custom name prefix for check runs"
107404
- }
107405
107380
  },
107406
- "required": [
107407
- "enabled",
107408
- "per_check"
107409
- ],
107410
- "additionalProperties": false,
107411
- "description": "GitHub Check Runs output configuration",
107412
- "patternProperties": {
107413
- "^x-": {}
107414
- }
107381
+ required: ['enabled', 'per_check'],
107382
+ additionalProperties: false,
107383
+ description: 'GitHub Check Runs output configuration',
107384
+ patternProperties: {
107385
+ '^x-': {},
107386
+ },
107415
107387
  },
107416
- "HttpServerConfig": {
107417
- "type": "object",
107418
- "properties": {
107419
- "enabled": {
107420
- "type": "boolean",
107421
- "description": "Whether HTTP server is enabled"
107388
+ HttpServerConfig: {
107389
+ type: 'object',
107390
+ properties: {
107391
+ enabled: {
107392
+ type: 'boolean',
107393
+ description: 'Whether HTTP server is enabled',
107422
107394
  },
107423
- "port": {
107424
- "type": "number",
107425
- "description": "Port to listen on"
107395
+ port: {
107396
+ type: 'number',
107397
+ description: 'Port to listen on',
107426
107398
  },
107427
- "host": {
107428
- "type": "string",
107429
- "description": "Host/IP to bind to (defaults to 0.0.0.0)"
107399
+ host: {
107400
+ type: 'string',
107401
+ description: 'Host/IP to bind to (defaults to 0.0.0.0)',
107430
107402
  },
107431
- "tls": {
107432
- "$ref": "#/definitions/TlsConfig",
107433
- "description": "TLS/SSL configuration for HTTPS"
107403
+ tls: {
107404
+ $ref: '#/definitions/TlsConfig',
107405
+ description: 'TLS/SSL configuration for HTTPS',
107434
107406
  },
107435
- "auth": {
107436
- "$ref": "#/definitions/HttpAuthConfig",
107437
- "description": "Authentication configuration"
107407
+ auth: {
107408
+ $ref: '#/definitions/HttpAuthConfig',
107409
+ description: 'Authentication configuration',
107438
107410
  },
107439
- "endpoints": {
107440
- "type": "array",
107441
- "items": {
107442
- "$ref": "#/definitions/HttpEndpointConfig"
107411
+ endpoints: {
107412
+ type: 'array',
107413
+ items: {
107414
+ $ref: '#/definitions/HttpEndpointConfig',
107443
107415
  },
107444
- "description": "HTTP endpoints configuration"
107445
- }
107416
+ description: 'HTTP endpoints configuration',
107417
+ },
107418
+ },
107419
+ required: ['enabled', 'port'],
107420
+ additionalProperties: false,
107421
+ description: 'HTTP server configuration for receiving webhooks',
107422
+ patternProperties: {
107423
+ '^x-': {},
107446
107424
  },
107447
- "required": [
107448
- "enabled",
107449
- "port"
107450
- ],
107451
- "additionalProperties": false,
107452
- "description": "HTTP server configuration for receiving webhooks",
107453
- "patternProperties": {
107454
- "^x-": {}
107455
- }
107456
107425
  },
107457
- "TlsConfig": {
107458
- "type": "object",
107459
- "properties": {
107460
- "enabled": {
107461
- "type": "boolean",
107462
- "description": "Enable TLS/HTTPS"
107426
+ TlsConfig: {
107427
+ type: 'object',
107428
+ properties: {
107429
+ enabled: {
107430
+ type: 'boolean',
107431
+ description: 'Enable TLS/HTTPS',
107463
107432
  },
107464
- "cert": {
107465
- "type": "string",
107466
- "description": "Path to TLS certificate file or certificate content"
107433
+ cert: {
107434
+ type: 'string',
107435
+ description: 'Path to TLS certificate file or certificate content',
107467
107436
  },
107468
- "key": {
107469
- "type": "string",
107470
- "description": "Path to TLS key file or key content"
107437
+ key: {
107438
+ type: 'string',
107439
+ description: 'Path to TLS key file or key content',
107471
107440
  },
107472
- "ca": {
107473
- "type": "string",
107474
- "description": "Path to CA certificate file or CA content (optional)"
107441
+ ca: {
107442
+ type: 'string',
107443
+ description: 'Path to CA certificate file or CA content (optional)',
107444
+ },
107445
+ rejectUnauthorized: {
107446
+ type: 'boolean',
107447
+ description: 'Reject unauthorized connections (default: true)',
107475
107448
  },
107476
- "rejectUnauthorized": {
107477
- "type": "boolean",
107478
- "description": "Reject unauthorized connections (default: true)"
107479
- }
107480
107449
  },
107481
- "required": [
107482
- "enabled"
107483
- ],
107484
- "additionalProperties": false,
107485
- "description": "TLS/SSL configuration for HTTPS server",
107486
- "patternProperties": {
107487
- "^x-": {}
107488
- }
107450
+ required: ['enabled'],
107451
+ additionalProperties: false,
107452
+ description: 'TLS/SSL configuration for HTTPS server',
107453
+ patternProperties: {
107454
+ '^x-': {},
107455
+ },
107489
107456
  },
107490
- "HttpAuthConfig": {
107491
- "type": "object",
107492
- "properties": {
107493
- "type": {
107494
- "type": "string",
107495
- "enum": [
107496
- "bearer_token",
107497
- "hmac",
107498
- "basic",
107499
- "none"
107500
- ],
107501
- "description": "Authentication type"
107457
+ HttpAuthConfig: {
107458
+ type: 'object',
107459
+ properties: {
107460
+ type: {
107461
+ type: 'string',
107462
+ enum: ['bearer_token', 'hmac', 'basic', 'none'],
107463
+ description: 'Authentication type',
107502
107464
  },
107503
- "secret": {
107504
- "type": "string",
107505
- "description": "Secret or token for authentication"
107465
+ secret: {
107466
+ type: 'string',
107467
+ description: 'Secret or token for authentication',
107506
107468
  },
107507
- "username": {
107508
- "type": "string",
107509
- "description": "Username for basic auth"
107469
+ username: {
107470
+ type: 'string',
107471
+ description: 'Username for basic auth',
107472
+ },
107473
+ password: {
107474
+ type: 'string',
107475
+ description: 'Password for basic auth',
107510
107476
  },
107511
- "password": {
107512
- "type": "string",
107513
- "description": "Password for basic auth"
107514
- }
107515
107477
  },
107516
- "required": [
107517
- "type"
107518
- ],
107519
- "additionalProperties": false,
107520
- "description": "HTTP server authentication configuration",
107521
- "patternProperties": {
107522
- "^x-": {}
107523
- }
107478
+ required: ['type'],
107479
+ additionalProperties: false,
107480
+ description: 'HTTP server authentication configuration',
107481
+ patternProperties: {
107482
+ '^x-': {},
107483
+ },
107524
107484
  },
107525
- "HttpEndpointConfig": {
107526
- "type": "object",
107527
- "properties": {
107528
- "path": {
107529
- "type": "string",
107530
- "description": "Path for the webhook endpoint"
107485
+ HttpEndpointConfig: {
107486
+ type: 'object',
107487
+ properties: {
107488
+ path: {
107489
+ type: 'string',
107490
+ description: 'Path for the webhook endpoint',
107531
107491
  },
107532
- "transform": {
107533
- "type": "string",
107534
- "description": "Optional transform template (Liquid) for the received data"
107492
+ transform: {
107493
+ type: 'string',
107494
+ description: 'Optional transform template (Liquid) for the received data',
107495
+ },
107496
+ name: {
107497
+ type: 'string',
107498
+ description: 'Optional name/ID for this endpoint',
107535
107499
  },
107536
- "name": {
107537
- "type": "string",
107538
- "description": "Optional name/ID for this endpoint"
107539
- }
107540
107500
  },
107541
- "required": [
107542
- "path"
107543
- ],
107544
- "additionalProperties": false,
107545
- "description": "HTTP server endpoint configuration",
107546
- "patternProperties": {
107547
- "^x-": {}
107548
- }
107501
+ required: ['path'],
107502
+ additionalProperties: false,
107503
+ description: 'HTTP server endpoint configuration',
107504
+ patternProperties: {
107505
+ '^x-': {},
107506
+ },
107549
107507
  },
107550
- "TagFilter": {
107551
- "type": "object",
107552
- "properties": {
107553
- "include": {
107554
- "type": "array",
107555
- "items": {
107556
- "type": "string"
107508
+ TagFilter: {
107509
+ type: 'object',
107510
+ properties: {
107511
+ include: {
107512
+ type: 'array',
107513
+ items: {
107514
+ type: 'string',
107557
107515
  },
107558
- "description": "Tags that checks must have to be included (ANY match)"
107516
+ description: 'Tags that checks must have to be included (ANY match)',
107559
107517
  },
107560
- "exclude": {
107561
- "type": "array",
107562
- "items": {
107563
- "type": "string"
107518
+ exclude: {
107519
+ type: 'array',
107520
+ items: {
107521
+ type: 'string',
107564
107522
  },
107565
- "description": "Tags that will exclude checks if present (ANY match)"
107566
- }
107523
+ description: 'Tags that will exclude checks if present (ANY match)',
107524
+ },
107525
+ },
107526
+ additionalProperties: false,
107527
+ description: 'Tag filter configuration for selective check execution',
107528
+ patternProperties: {
107529
+ '^x-': {},
107567
107530
  },
107568
- "additionalProperties": false,
107569
- "description": "Tag filter configuration for selective check execution",
107570
- "patternProperties": {
107571
- "^x-": {}
107572
- }
107573
107531
  },
107574
- "RoutingDefaults": {
107575
- "type": "object",
107576
- "properties": {
107577
- "max_loops": {
107578
- "type": "number",
107579
- "description": "Per-scope cap on routing transitions (success + failure)"
107532
+ RoutingDefaults: {
107533
+ type: 'object',
107534
+ properties: {
107535
+ max_loops: {
107536
+ type: 'number',
107537
+ description: 'Per-scope cap on routing transitions (success + failure)',
107580
107538
  },
107581
- "defaults": {
107582
- "type": "object",
107583
- "properties": {
107584
- "on_fail": {
107585
- "$ref": "#/definitions/OnFailConfig"
107586
- }
107539
+ defaults: {
107540
+ type: 'object',
107541
+ properties: {
107542
+ on_fail: {
107543
+ $ref: '#/definitions/OnFailConfig',
107544
+ },
107587
107545
  },
107588
- "additionalProperties": false,
107589
- "description": "Default policies applied to checks (step-level overrides take precedence)",
107590
- "patternProperties": {
107591
- "^x-": {}
107592
- }
107593
- }
107546
+ additionalProperties: false,
107547
+ description: 'Default policies applied to checks (step-level overrides take precedence)',
107548
+ patternProperties: {
107549
+ '^x-': {},
107550
+ },
107551
+ },
107594
107552
  },
107595
- "additionalProperties": false,
107596
- "description": "Global routing defaults",
107597
- "patternProperties": {
107598
- "^x-": {}
107599
- }
107600
- }
107601
- }
107553
+ additionalProperties: false,
107554
+ description: 'Global routing defaults',
107555
+ patternProperties: {
107556
+ '^x-': {},
107557
+ },
107558
+ },
107559
+ },
107602
107560
  };
107603
107561
  exports["default"] = exports.configSchema;
107604
107562
 
@@ -195762,13 +195720,14 @@ async function validateMermaidDiagram(diagram) {
195762
195720
  };
195763
195721
  }
195764
195722
  const result = validate(diagram);
195765
- if (result.errors && result.errors.length === 0) {
195723
+ const actualErrors = (result.errors || []).filter((err) => err.severity === "error");
195724
+ if (actualErrors.length === 0) {
195766
195725
  return {
195767
195726
  isValid: true,
195768
195727
  diagramType: result.type || "unknown"
195769
195728
  };
195770
195729
  } else {
195771
- const errorMessages = (result.errors || []).map((err) => {
195730
+ const errorMessages = actualErrors.map((err) => {
195772
195731
  const location = err.line ? `line ${err.line}${err.column ? `:${err.column}` : ""}` : "";
195773
195732
  return location ? `${location} - ${err.message}` : err.message;
195774
195733
  });
@@ -195777,8 +195736,8 @@ async function validateMermaidDiagram(diagram) {
195777
195736
  diagramType: result.type || "unknown",
195778
195737
  error: errorMessages[0] || "Validation failed",
195779
195738
  detailedError: errorMessages.join("\n"),
195780
- errors: result.errors || []
195781
- // Include raw maid errors for AI fixing
195739
+ errors: actualErrors
195740
+ // Include only actual errors for AI fixing
195782
195741
  };
195783
195742
  }
195784
195743
  } catch (error2) {
@@ -196666,10 +196625,19 @@ var init_client2 = __esm({
196666
196625
  if (this.debug) {
196667
196626
  console.error(`[MCP] Calling ${toolName} with args:`, args);
196668
196627
  }
196669
- const result = await clientInfo.client.callTool({
196670
- name: tool3.originalName,
196671
- arguments: args
196628
+ const timeout = this.config?.settings?.timeout || 3e4;
196629
+ const timeoutPromise = new Promise((_2, reject2) => {
196630
+ setTimeout(() => {
196631
+ reject2(new Error(`MCP tool call timeout after ${timeout}ms`));
196632
+ }, timeout);
196672
196633
  });
196634
+ const result = await Promise.race([
196635
+ clientInfo.client.callTool({
196636
+ name: tool3.originalName,
196637
+ arguments: args
196638
+ }),
196639
+ timeoutPromise
196640
+ ]);
196673
196641
  return result;
196674
196642
  } catch (error2) {
196675
196643
  console.error(`[MCP] Error calling tool ${toolName}:`, error2);
@@ -197083,11 +197051,39 @@ var init_ProbeAgent = __esm({
197083
197051
  this.mcpServers = options.mcpServers || null;
197084
197052
  this.mcpBridge = null;
197085
197053
  this.initializeModel();
197054
+ }
197055
+ /**
197056
+ * Initialize the agent asynchronously (must be called after constructor)
197057
+ * This method initializes MCP and merges MCP tools into the tool list
197058
+ */
197059
+ async initialize() {
197086
197060
  if (this.enableMcp) {
197087
- this.initializeMCP().catch((error2) => {
197061
+ try {
197062
+ await this.initializeMCP();
197063
+ if (this.mcpBridge) {
197064
+ const mcpTools = this.mcpBridge.mcpTools || {};
197065
+ for (const [toolName, toolImpl] of Object.entries(mcpTools)) {
197066
+ this.toolImplementations[toolName] = toolImpl;
197067
+ }
197068
+ }
197069
+ if (this.debug) {
197070
+ const allToolNames = Object.keys(this.toolImplementations);
197071
+ const nativeToolCount = allToolNames.filter((name14) => !this.mcpBridge?.mcpTools?.[name14]).length;
197072
+ const mcpToolCount = allToolNames.length - nativeToolCount;
197073
+ console.error("\n[DEBUG] ========================================");
197074
+ console.error("[DEBUG] All Tools Initialized");
197075
+ console.error(`[DEBUG] Native tools: ${nativeToolCount}, MCP tools: ${mcpToolCount}`);
197076
+ console.error("[DEBUG] Available tools:");
197077
+ for (const toolName of allToolNames) {
197078
+ const isMCP = this.mcpBridge?.mcpTools?.[toolName] ? " (MCP)" : "";
197079
+ console.error(`[DEBUG] - ${toolName}${isMCP}`);
197080
+ }
197081
+ console.error("[DEBUG] ========================================\n");
197082
+ }
197083
+ } catch (error2) {
197088
197084
  console.error("[MCP] Failed to initialize MCP:", error2);
197089
197085
  this.mcpBridge = null;
197090
- });
197086
+ }
197091
197087
  }
197092
197088
  }
197093
197089
  /**
@@ -197314,20 +197310,40 @@ var init_ProbeAgent = __esm({
197314
197310
  }
197315
197311
  }
197316
197312
  /**
197317
- * Extract directory paths from listFiles tool output
197313
+ * Extract directory paths from tool output (both listFiles and extract tool)
197318
197314
  * @param {string} content - Tool output content
197319
197315
  * @returns {string[]} - Array of directory paths
197320
197316
  */
197321
197317
  extractListFilesDirectories(content) {
197322
197318
  const directories = [];
197323
- const dirPattern = /^([^\n:]+):\s*$/gm;
197319
+ const fileHeaderPattern = /^File:\s+(.+)$/gm;
197324
197320
  let match;
197321
+ while ((match = fileHeaderPattern.exec(content)) !== null) {
197322
+ const filePath = match[1].trim();
197323
+ const dir = (0, import_path9.dirname)(filePath);
197324
+ if (dir && dir !== ".") {
197325
+ directories.push(dir);
197326
+ if (this.debug) {
197327
+ console.log(`[DEBUG] Extracted directory context from File header: ${dir}`);
197328
+ }
197329
+ }
197330
+ }
197331
+ const dirPattern = /^(\/[^\n:]+|[A-Z]:\\[^\n:]+|\.\.?(?:\/[^\n:]+)?):\s*$/gm;
197325
197332
  while ((match = dirPattern.exec(content)) !== null) {
197326
197333
  const dirPath = match[1].trim();
197327
- if (dirPath && dirPath.length > 0) {
197328
- directories.push(dirPath);
197329
- if (this.debug) {
197330
- console.log(`[DEBUG] Extracted directory context from listFiles: ${dirPath}`);
197334
+ const hasInvalidChars = /\s/.test(dirPath);
197335
+ const isValidPath = !hasInvalidChars && (dirPath.startsWith("/") || // Unix absolute path
197336
+ /^[A-Z]:\\/.test(dirPath) || // Windows absolute path (C:\)
197337
+ dirPath === "." || // Current directory
197338
+ dirPath === ".." || // Parent directory
197339
+ dirPath.startsWith("./") && dirPath.length > 2 && !dirPath.includes(" ") || // ./something (no spaces)
197340
+ dirPath.startsWith("../") && dirPath.length > 3 && !dirPath.includes(" "));
197341
+ if (isValidPath) {
197342
+ if (!directories.includes(dirPath)) {
197343
+ directories.push(dirPath);
197344
+ if (this.debug) {
197345
+ console.log(`[DEBUG] Extracted directory context from listFiles: ${dirPath}`);
197346
+ }
197331
197347
  }
197332
197348
  }
197333
197349
  }
@@ -228447,7 +228463,7 @@ module.exports = /*#__PURE__*/JSON.parse('{"application/1d-interleaved-parityfec
228447
228463
  /***/ ((module) => {
228448
228464
 
228449
228465
  "use strict";
228450
- module.exports = {"rE":"0.1.76"};
228466
+ module.exports = {"rE":"0.1.77"};
228451
228467
 
228452
228468
  /***/ })
228453
228469