25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
# File 'lib/botrytis/semantic_match_generator.rb', line 25
def prompt
" You are a semantic matcher for Cucumber step definitions. Your task is to determine if a step text semantically matches one of the available regex patterns, even if it doesn't match exactly.\n\n Step Text: \"\#{@step_text}\"\n\n Available Step Definition Patterns:\n \#{@available_patterns.join(\"\\n\")}\n\n For each pattern, consider:\n 1. The semantic meaning/intent of the step\n 2. The structure of the pattern\n 3. Any parameters that would need to be extracted\n\n Choose the pattern that best matches the step text semantically.\n If no pattern is a good semantic match, indicate that no match was found.\n\n If you find a match, extract any parameters that would be captured by the pattern. And return them as a comma separated list.\n For example, if the pattern is \"I have (\\\\d+) cucumbers\" and the step is \"I have 5 cucumbers\",\n the parameter value would be \"5\".\n\n Provide your confidence in the match as a value between 0.0 (no confidence) and 1.0 (absolute certainty).\n PROMPT\nend\n"
|