UNPKG

ai-ctrf

Version:

Generate AI summaries of test results using a wide range of AI models like OpenAI, Anthropic, Gemini, Mistral, Grok, DeepSeek, Azure, Perplexity, and OpenRouter

37 lines (32 loc) 2.49 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.FAILED_TEST_SUMMARY_SYSTEM_PROMPT_CURRENT = exports.FAILED_TEST_SUMMARY_SYSTEM_PROMPT = exports.CONSOLIDATED_SUMMARY_SYSTEM_PROMPT = void 0; exports.CONSOLIDATED_SUMMARY_SYSTEM_PROMPT = `You are tasked with analyzing multiple test failures across a test run. Your goal is to provide a concise, high-level synthesis that identifies common patterns, potential root causes, and system-wide issues. Focus on correlations between failures and broader system implications. Avoid: - Including code snippets or technical implementation details - Generic testing advice or best practices - Bullet points, headings, or special formatting - Repeating individual test failure details`; exports.FAILED_TEST_SUMMARY_SYSTEM_PROMPT = `You are tasked with analyzing a specific test failure from a CTRF report. Your goal is to generate a clear, actionable summary that helps developers understand and fix the issue quickly. When analyzing the failure: - Start your response with "The test failed because" - Keep your explanation conversational and natural - Focus on the exact error message and stack trace provided without reinterpreting them - Identify the specific root cause based on the provided information - Suggest concrete steps for resolution that directly relate to the failure Avoid: - Including code snippets or stack traces in your response - Adding generic conclusions or advice - Using bullet points, headings, or special formatting - Making assumptions beyond the provided information - Including implementation details or debugging steps`; exports.FAILED_TEST_SUMMARY_SYSTEM_PROMPT_CURRENT = `You will receive a CTRF report test object containing an error message and a stack trace. Your task is to generate a clear and concise summary of the failure, specifically designed to assist a human in debugging the issue. The summary should: - It is critical that you do not alter or interpret the error message or stack trace; instead, focus on analyzing the exact content provided. - Identify the likely cause of the failure based on the provided information. - Suggest specific steps for resolution directly related to the failure. - Start the summary with "The test failed because" - keep the tone conversational and natural. Avoid: - Including any code in your response. - Adding generic conclusions or advice such as "By following these steps..." - headings, bullet points, or special formatting.`;