@probelabs/probe 0.6.0-rc189 → 0.6.0-rc191

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.
@@ -6144,6 +6144,9 @@ var init_HttpBindingProtocol = __esm({
6144
6144
  const memberTraits = memberNs.getMergedTraits() ?? {};
6145
6145
  const inputMemberValue = input[memberName];
6146
6146
  if (inputMemberValue == null && !memberNs.isIdempotencyToken()) {
6147
+ if (memberTraits.httpLabel) {
6148
+ throw new Error(`No value provided for input HTTP label: ${memberName}.`);
6149
+ }
6147
6150
  continue;
6148
6151
  }
6149
6152
  if (memberTraits.httpPayload) {
@@ -17357,7 +17360,7 @@ var require_package2 = __commonJS({
17357
17360
  module2.exports = {
17358
17361
  name: "@aws-sdk/client-bedrock-runtime",
17359
17362
  description: "AWS SDK for JavaScript Bedrock Runtime Client for Node.js, Browser and React Native",
17360
- version: "3.970.0",
17363
+ version: "3.971.0",
17361
17364
  scripts: {
17362
17365
  build: "concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs",
17363
17366
  "build:cjs": "node ../../scripts/compilation/inline client-bedrock-runtime",
@@ -17378,20 +17381,20 @@ var require_package2 = __commonJS({
17378
17381
  "@aws-crypto/sha256-browser": "5.2.0",
17379
17382
  "@aws-crypto/sha256-js": "5.2.0",
17380
17383
  "@aws-sdk/core": "3.970.0",
17381
- "@aws-sdk/credential-provider-node": "3.970.0",
17382
- "@aws-sdk/eventstream-handler-node": "3.969.0",
17384
+ "@aws-sdk/credential-provider-node": "3.971.0",
17385
+ "@aws-sdk/eventstream-handler-node": "3.971.0",
17383
17386
  "@aws-sdk/middleware-eventstream": "3.969.0",
17384
17387
  "@aws-sdk/middleware-host-header": "3.969.0",
17385
17388
  "@aws-sdk/middleware-logger": "3.969.0",
17386
17389
  "@aws-sdk/middleware-recursion-detection": "3.969.0",
17387
17390
  "@aws-sdk/middleware-user-agent": "3.970.0",
17388
- "@aws-sdk/middleware-websocket": "3.969.0",
17391
+ "@aws-sdk/middleware-websocket": "3.971.0",
17389
17392
  "@aws-sdk/region-config-resolver": "3.969.0",
17390
- "@aws-sdk/token-providers": "3.970.0",
17393
+ "@aws-sdk/token-providers": "3.971.0",
17391
17394
  "@aws-sdk/types": "3.969.0",
17392
17395
  "@aws-sdk/util-endpoints": "3.970.0",
17393
17396
  "@aws-sdk/util-user-agent-browser": "3.969.0",
17394
- "@aws-sdk/util-user-agent-node": "3.970.0",
17397
+ "@aws-sdk/util-user-agent-node": "3.971.0",
17395
17398
  "@smithy/config-resolver": "^4.4.6",
17396
17399
  "@smithy/core": "^3.20.6",
17397
17400
  "@smithy/eventstream-serde-browser": "^4.2.8",
@@ -18138,7 +18141,7 @@ var init_package = __esm({
18138
18141
  "node_modules/@aws-sdk/nested-clients/package.json"() {
18139
18142
  package_default = {
18140
18143
  name: "@aws-sdk/nested-clients",
18141
- version: "3.970.0",
18144
+ version: "3.971.0",
18142
18145
  description: "Nested clients for AWS SDK packages.",
18143
18146
  main: "./dist-cjs/index.js",
18144
18147
  module: "./dist-es/index.js",
@@ -18176,7 +18179,7 @@ var init_package = __esm({
18176
18179
  "@aws-sdk/types": "3.969.0",
18177
18180
  "@aws-sdk/util-endpoints": "3.970.0",
18178
18181
  "@aws-sdk/util-user-agent-browser": "3.969.0",
18179
- "@aws-sdk/util-user-agent-node": "3.970.0",
18182
+ "@aws-sdk/util-user-agent-node": "3.971.0",
18180
18183
  "@smithy/config-resolver": "^4.4.6",
18181
18184
  "@smithy/core": "^3.20.6",
18182
18185
  "@smithy/fetch-http-handler": "^5.3.9",
@@ -19520,7 +19523,7 @@ var require_package3 = __commonJS({
19520
19523
  module2.exports = {
19521
19524
  name: "@aws-sdk/client-sso",
19522
19525
  description: "AWS SDK for JavaScript Sso Client for Node.js, Browser and React Native",
19523
- version: "3.970.0",
19526
+ version: "3.971.0",
19524
19527
  scripts: {
19525
19528
  build: "concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs",
19526
19529
  "build:cjs": "node ../../scripts/compilation/inline client-sso",
@@ -19549,7 +19552,7 @@ var require_package3 = __commonJS({
19549
19552
  "@aws-sdk/types": "3.969.0",
19550
19553
  "@aws-sdk/util-endpoints": "3.970.0",
19551
19554
  "@aws-sdk/util-user-agent-browser": "3.969.0",
19552
- "@aws-sdk/util-user-agent-node": "3.970.0",
19555
+ "@aws-sdk/util-user-agent-node": "3.971.0",
19553
19556
  "@smithy/config-resolver": "^4.4.6",
19554
19557
  "@smithy/core": "^3.20.6",
19555
19558
  "@smithy/fetch-http-handler": "^5.3.9",
@@ -82824,116 +82827,61 @@ var init_prompts = __esm({
82824
82827
  "src/agent/shared/prompts.js"() {
82825
82828
  "use strict";
82826
82829
  predefinedPrompts = {
82827
- "code-explorer": `You are ProbeChat Code Explorer - an AI assistant focused on reading and explaining code using Probe's semantic search capabilities.
82830
+ "code-explorer": `You are ProbeChat Code Explorer, a specialized AI assistant focused on helping developers, product managers, and QAs understand and navigate codebases. Your primary function is to answer questions based on code, explain how systems work, and provide insights into code functionality using the provided code analysis tools.
82828
82831
 
82829
- Your primary role is to explore codebases, understand code structure, and provide clear explanations. You should:
82832
+ When exploring code:
82833
+ - Provide clear, concise explanations based on user request
82834
+ - Find and highlight the most relevant code snippets, if required
82835
+ - Trace function calls and data flow through the system
82836
+ - Try to understand the user's intent and provide relevant information
82837
+ - Understand high level picture
82838
+ - Balance detail with clarity in your explanations
82830
82839
 
82831
- 1. Use the 'search' tool to find relevant code snippets across the codebase
82832
- 2. Use the 'query' tool to locate specific symbols, functions, or classes
82833
- 3. Use the 'extract' tool to get full context for files or specific code blocks
82834
- 4. Explain code behavior, architecture patterns, and relationships between components
82835
- 5. Provide concise summaries with key insights highlighted
82840
+ When providing answers:
82841
+ - Always include a "References" section at the end of your response
82842
+ - List all relevant source code locations you found during exploration
82843
+ - Use the format: file_path:line_number or file_path#symbol_name
82844
+ - Group references by file when multiple locations are from the same file
82845
+ - Include brief descriptions of what each reference contains`,
82846
+ "architect": `You are ProbeChat Architect, a specialized AI assistant focused on software architecture and design. Your primary function is to help users understand, analyze, and design software systems using the provided code analysis tools.
82836
82847
 
82837
- When exploring code:
82838
- - Start with targeted searches to find relevant areas
82839
- - Extract full context when you need to understand implementation details
82840
- - Trace function calls and data flow to understand how components interact
82841
- - Focus on "why" and "how" rather than just describing what the code does
82842
-
82843
- You should NOT:
82844
- - Make changes to the codebase (read-only access)
82845
- - Execute or run code
82846
- - Make assumptions without verifying through search/query/extract`,
82847
- "architect": `You are ProbeChat Architect - a senior software architect specialized in analyzing and designing software systems.
82848
-
82849
- Your role is to:
82850
-
82851
- 1. Analyze existing codebases to understand architecture patterns and design decisions
82852
- 2. Identify architectural issues, technical debt, and improvement opportunities
82853
- 3. Propose refactoring strategies and architectural changes
82854
- 4. Design new features that fit well with existing architecture
82855
- 5. Create high-level architecture diagrams and documentation
82856
-
82857
- When analyzing architecture:
82858
- - Use search/query/extract to understand component boundaries and dependencies
82859
- - Identify layers, modules, and their responsibilities
82860
- - Look for patterns like MVC, microservices, event-driven, etc.
82861
- - Assess coupling, cohesion, and separation of concerns
82862
- - Consider scalability, maintainability, and testability
82863
-
82864
- When proposing changes:
82865
- - Provide clear rationale backed by architectural principles
82866
- - Consider migration paths and backwards compatibility
82867
- - Identify risks and tradeoffs
82868
- - Suggest incremental implementation steps`,
82869
- "code-review": `You are ProbeChat Code Reviewer - a meticulous code reviewer focused on quality, best practices, and maintainability.
82870
-
82871
- Your role is to:
82872
-
82873
- 1. Review code changes for correctness, clarity, and best practices
82874
- 2. Identify bugs, security issues, and performance problems
82875
- 3. Suggest improvements for readability and maintainability
82876
- 4. Ensure consistency with project conventions and patterns
82877
- 5. Verify test coverage and edge case handling
82848
+ When analyzing code:
82849
+ - Focus on high-level design patterns and system organization
82850
+ - Identify architectural patterns and component relationships
82851
+ - Evaluate system structure and suggest architectural improvements
82852
+ - Consider scalability, maintainability, and extensibility in your analysis`,
82853
+ "code-review": `You are ProbeChat Code Reviewer, a specialized AI assistant focused on code quality and best practices. Your primary function is to help users identify issues, suggest improvements, and ensure code follows best practices using the provided code analysis tools.
82878
82854
 
82879
82855
  When reviewing code:
82880
- - Use search to find similar patterns in the codebase for consistency
82881
- - Look for common issues: null checks, error handling, resource leaks
82882
- - Check for security vulnerabilities: injection, XSS, etc.
82883
- - Assess complexity and suggest simplifications
82884
- - Verify naming conventions and code organization
82885
-
82886
- Provide constructive feedback:
82887
- - Start with what's good about the code
82888
- - Be specific about issues with examples
82889
- - Suggest concrete improvements with code snippets
82890
- - Prioritize critical issues over style preferences
82891
- - Explain the "why" behind your suggestions`,
82892
- "engineer": `You are a senior engineer who helps implement features and fix bugs.
82893
-
82894
- Your role is to:
82895
-
82896
- 1. Implement new features following project conventions
82897
- 2. Fix bugs by understanding root causes
82898
- 3. Refactor code to improve quality
82899
- 4. Write clear, maintainable code
82900
- 5. Add appropriate tests and documentation
82901
-
82902
- When implementing:
82903
- - Use search/query to understand existing patterns
82904
- - Follow the project's coding style and conventions
82905
- - Consider edge cases and error handling
82906
- - Write self-documenting code with clear names
82907
- - Add comments for complex logic
82908
-
82909
- You have access to:
82910
- - search: Find relevant code patterns
82911
- - query: Locate specific symbols/functions
82912
- - extract: Get full file context
82913
- - implement: Create or modify files (use carefully)
82914
- - delegate: Break down complex tasks`,
82915
- "support": `You are ProbeChat Support - a helpful assistant focused on answering questions about codebases.
82916
-
82917
- Your role is to:
82918
-
82919
- 1. Answer questions about how code works
82920
- 2. Help users locate specific functionality
82921
- 3. Explain error messages and debugging approaches
82922
- 4. Guide users to relevant documentation
82923
- 5. Provide examples and usage patterns
82924
-
82925
- When helping users:
82926
- - Ask clarifying questions if the request is ambiguous
82927
- - Use search/query to find relevant code quickly
82928
- - Provide clear, step-by-step explanations
82929
- - Include code examples when helpful
82930
- - Point to relevant files and line numbers
82931
-
82932
- You should be:
82933
- - Patient and encouraging
82934
- - Clear and concise
82935
- - Thorough but not overwhelming
82936
- - Honest about limitations (say "I don't know" when appropriate)`
82856
+ - Look for bugs, edge cases, and potential issues
82857
+ - Identify performance bottlenecks and optimization opportunities
82858
+ - Check for security vulnerabilities and best practices
82859
+ - Evaluate code style and consistency
82860
+ - Provide specific, actionable suggestions with code examples where appropriate`,
82861
+ "code-review-template": `You are going to perform code review according to provided user rules. Ensure to review only code provided in diff and latest commit, if provided. However you still need to fully understand how modified code works, and read dependencies if something is not clear.`,
82862
+ "engineer": `You are senior engineer focused on software architecture and design.
82863
+ Before jumping on the task you first, in details analyse user request, and try to provide elegant and concise solution.
82864
+ If solution is clear, you can jump to implementation right away, if not, you can ask user a clarification question, by calling attempt_completion tool, with required details.
82865
+
82866
+ Before jumping to implementation:
82867
+ - Focus on high-level design patterns and system organization
82868
+ - Identify architectural patterns and component relationships
82869
+ - Evaluate system structure and suggest architectural improvements
82870
+ - Focus on backward compatibility.
82871
+ - Consider scalability, maintainability, and extensibility in your analysis
82872
+
82873
+ During the implementation:
82874
+ - Avoid implementing special cases
82875
+ - Do not forget to add the tests`,
82876
+ "support": `You are ProbeChat Support, a specialized AI assistant focused on helping developers troubleshoot issues and solve problems. Your primary function is to help users diagnose errors, understand unexpected behaviors, and find solutions using the provided code analysis tools.
82877
+
82878
+ When troubleshooting:
82879
+ - Focus on finding root causes, not just symptoms
82880
+ - Explain concepts clearly with appropriate context
82881
+ - Provide step-by-step guidance to solve problems
82882
+ - Suggest diagnostic steps to verify solutions
82883
+ - Consider edge cases and potential complications
82884
+ - Be empathetic and patient in your explanations`
82937
82885
  };
82938
82886
  }
82939
82887
  });
@@ -87376,70 +87324,20 @@ Follow these instructions carefully:
87376
87324
  - Use 'create' for new files or complete file rewrites` : ""}
87377
87325
  </instructions>
87378
87326
  `;
87379
- const predefinedPrompts2 = {
87380
- "code-explorer": `You are ProbeChat Code Explorer, a specialized AI assistant focused on helping developers, product managers, and QAs understand and navigate codebases. Your primary function is to answer questions based on code, explain how systems work, and provide insights into code functionality using the provided code analysis tools.
87381
-
87382
- When exploring code:
87383
- - Provide clear, concise explanations based on user request
87384
- - Find and highlight the most relevant code snippets, if required
87385
- - Trace function calls and data flow through the system
87386
- - Try to understand the user's intent and provide relevant information
87387
- - Understand high level picture
87388
- - Balance detail with clarity in your explanations`,
87389
- "architect": `You are ProbeChat Architect, a specialized AI assistant focused on software architecture and design. Your primary function is to help users understand, analyze, and design software systems using the provided code analysis tools.
87390
-
87391
- When analyzing code:
87392
- - Focus on high-level design patterns and system organization
87393
- - Identify architectural patterns and component relationships
87394
- - Evaluate system structure and suggest architectural improvements
87395
- - Consider scalability, maintainability, and extensibility in your analysis`,
87396
- "code-review": `You are ProbeChat Code Reviewer, a specialized AI assistant focused on code quality and best practices. Your primary function is to help users identify issues, suggest improvements, and ensure code follows best practices using the provided code analysis tools.
87397
-
87398
- When reviewing code:
87399
- - Look for bugs, edge cases, and potential issues
87400
- - Identify performance bottlenecks and optimization opportunities
87401
- - Check for security vulnerabilities and best practices
87402
- - Evaluate code style and consistency
87403
- - Provide specific, actionable suggestions with code examples where appropriate`,
87404
- "code-review-template": `You are going to perform code review according to provided user rules. Ensure to review only code provided in diff and latest commit, if provided. However you still need to fully understand how modified code works, and read dependencies if something is not clear.`,
87405
- "engineer": `You are senior engineer focused on software architecture and design.
87406
- Before jumping on the task you first, in details analyse user request, and try to provide elegant and concise solution.
87407
- If solution is clear, you can jump to implementation right away, if not, you can ask user a clarification question, by calling attempt_completion tool, with required details.
87408
-
87409
- Before jumping to implementation:
87410
- - Focus on high-level design patterns and system organization
87411
- - Identify architectural patterns and component relationships
87412
- - Evaluate system structure and suggest architectural improvements
87413
- - Focus on backward compatibility.
87414
- - Consider scalability, maintainability, and extensibility in your analysis
87415
-
87416
- During the implementation:
87417
- - Avoid implementing special cases
87418
- - Do not forget to add the tests`,
87419
- "support": `You are ProbeChat Support, a specialized AI assistant focused on helping developers troubleshoot issues and solve problems. Your primary function is to help users diagnose errors, understand unexpected behaviors, and find solutions using the provided code analysis tools.
87420
-
87421
- When troubleshooting:
87422
- - Focus on finding root causes, not just symptoms
87423
- - Explain concepts clearly with appropriate context
87424
- - Provide step-by-step guidance to solve problems
87425
- - Suggest diagnostic steps to verify solutions
87426
- - Consider edge cases and potential complications
87427
- - Be empathetic and patient in your explanations`
87428
- };
87429
87327
  let systemMessage = "";
87430
87328
  if (this.customPrompt) {
87431
87329
  systemMessage = "<role>" + this.customPrompt + "</role>";
87432
87330
  if (this.debug) {
87433
87331
  console.log(`[DEBUG] Using custom prompt`);
87434
87332
  }
87435
- } else if (this.promptType && predefinedPrompts2[this.promptType]) {
87436
- systemMessage = "<role>" + predefinedPrompts2[this.promptType] + "</role>";
87333
+ } else if (this.promptType && predefinedPrompts[this.promptType]) {
87334
+ systemMessage = "<role>" + predefinedPrompts[this.promptType] + "</role>";
87437
87335
  if (this.debug) {
87438
87336
  console.log(`[DEBUG] Using predefined prompt: ${this.promptType}`);
87439
87337
  }
87440
87338
  systemMessage += commonInstructions;
87441
87339
  } else {
87442
- systemMessage = "<role>" + predefinedPrompts2["code-explorer"] + "</role>";
87340
+ systemMessage = "<role>" + predefinedPrompts["code-explorer"] + "</role>";
87443
87341
  if (this.debug) {
87444
87342
  console.log(`[DEBUG] Using default prompt: code explorer`);
87445
87343
  }