Claude Skill

prompt-testing

Use this skill when you need to test prompt behavior, regression risk, and output boundaries across versions; triggers include prompt testing and prompt-regression.

LLM Mart · 0 points · 0 views 0 listing impressions 0 install-command copies
Virus-scanned Reviewed automatically before listing.

Full trust report

Download naodeng-awesome-qa-skills-skills_en_testing-types_prompt-testing-c44b892.zip · 8 KB
Part of naodeng/awesome-qa-skills — 97 skills

Install

skills CLI npx skills add https://github.com/naodeng/awesome-qa-skills/tree/main/skills/en/testing-types/prompt-testing
Claude Code claude plugin marketplace add https://llmmart.ai/marketplace.json && claude plugin install naodeng-awesome-qa-skills@llmmart
Git git clone https://github.com/naodeng/awesome-qa-skills.git

The skills CLI installs just this skill, for any of its supported agents. Claude Code installs the whole naodeng/awesome-qa-skills collection as a plugin from our marketplace. Git is the plain clone.

Skill manifest

Prompt Testing

When to Use

  • Use this skill when you need to verify prompts for correctness, consistency, and control across representative, boundary, adversarial, and version-change cases.
  • Use the prompt-regression mode when comparing a baseline and candidate version with pinned dataset or test-prompt identity, observed differences, and evidence state.
  • Use it to review an existing plan, result, or evidence set and produce actionable improvements.
  • Use it when context is incomplete but a bounded first pass is still valuable.

Output Format Options

  • Default to Markdown for review, execution, and incremental refinement.
  • When the user requests tables, CSV, JSON, or ticket fields, preserve risk, evidence, priority, and boundary information.
  • For machine-consumed output, confirm the schema, enums, and required fields first.

How to Use

  1. Read and follow prompts/prompt-testing.md, including its input contract, execution rules, minimum coverage, and output order.
  2. Select ordinary testing or prompt-regression; regression mode requires the baseline, candidate version, dataset or test-prompt identity, and comparability context.
  3. Add only context that changes the decision: scope, environment, version, constraints, evidence, and success criteria.
  4. Audit the input, then separate confirmed facts, working assumptions, and open questions.
  5. Rank by risk and evidence strength, and produce an artifact that can be executed or reviewed directly.
  6. If information is missing, deliver a bounded first pass and state which conclusions remain unsupported.

Reference Files

  • Always read prompts/prompt-testing.md; it is the complete execution specification for this skill.
  • For evaluation or regression, read evals/eval.yaml and the relevant cases under evals/cases/.
  • Load references/, examples/, scripts/, or output-formats.md only when those directories exist and the task needs them.

Core Constraints

  • do not test one example only
  • pin model and parameters
  • use rubrics rather than brittle exact matches for semantic output
  • Never invent system behavior, fields, data, metrics, or root causes absent from the evidence.
  • Link important conclusions to evidence; mark unsupported conclusions as hypotheses with a verification method.
  • Explain priority using business impact, likelihood, or detectability.
  • In prompt-regression, use PRT-## finding IDs and distinguish baseline, candidate version, expected behavior, observed behavior, difference, and validation method.
  • Treat version differences as evidence-bounded comparisons; static analysis must not become a claim that a model ran or regression passed.

Delivery Checklist

  • Covered: instruction following, format, factuality, boundary inputs, adversarial inputs, multilingual behavior, consistency, regression, cost.
  • Separated facts, assumptions, gaps, and recommendations.
  • Gave high-risk items a priority, evidence basis, owner or next action.
  • Defined verifiable decision criteria instead of generic advice.
  • For regression, preserved dataset or test-prompt identity, evidence state, differences, and the Human decision boundary.
  • Performed no unauthorized production writes or destructive actions.

Common Pitfalls

  • Listing checks without preconditions, expected outcomes, or evidence.
  • Marking everything high priority and avoiding tradeoffs.
  • Substituting tool names or generic theory for domain reasoning.
  • Refusing incomplete input, or pretending incomplete evidence supports certainty.
  • Treating a surface difference between candidate and baseline as a regression defect without checking comparability or evidence state.

Best Practices

  • Start with paths most likely to cause business loss, safety issues, or release blockage.
  • Reduce uncertainty through the smallest verifiable experiment and record reproduction conditions.
  • Make the artifact executable and independently reviewable by another engineer.
Files (awesome-qa-skills)
  • agents
    • openai.yaml 283 B
      version: 1
      metadata:
        key: prompt-testing
      interface:
        display_name: "Prompt Testing"
        short_description: "Test prompt behavior, boundaries, and version regressions"
        default_prompt: "Use the prompt-testing skill to design prompt tests."
      policy:
        allow_implicit_invocation: true
      
  • evals
    • cases
      • basic-success.yaml 846 B
        id: basic-success
        title: "Prompt Testing: domain-complete scenario"
        description: |
          Checks that the skill produces domain-specific, evidence-based, prioritized, executable output.
        
        input:
          prompt: |
            Use the prompt-testing skill for this scenario: a support-reply prompt changes and must preserve tone, policy accuracy, JSON format, and refusal behavior. The basic scope is available. Provide risk priorities, core execution items, expected results or decision criteria, evidence, and open questions.
        
        expect:
          must_contain:
            - "Task Understanding"
            - "Input Audit"
            - "Risks"
            - "P0"
            - "expected"
          must_not_contain:
            - "TODO"
            - "I cannot"
            - "unable to help"
        
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "Task Understanding"
                  - "Input Audit"
                  - "Risks"
        
      • edge-incomplete-input.yaml 887 B
        id: edge-incomplete-input
        title: "Prompt Testing: bounded first pass with incomplete input"
        description: |
          Checks that missing context leads to a bounded first pass with assumptions and gaps, not refusal or invention.
        
        input:
          prompt: |
            Use the prompt-testing skill. The only known fact is: a support-reply prompt changes and must preserve tone, policy accuracy, JSON format, and refusal behavior. No environment, version, or supporting evidence is available. Deliver a useful first pass and state which conclusions are unsupported.
        
        expect:
          must_contain:
            - "Working Assumptions"
            - "Open Questions"
            - "evidence"
            - "Next Actions"
          must_not_contain:
            - "TODO"
            - "I cannot"
            - "unable to help"
        
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "Working Assumptions"
                  - "Open Questions"
                  - "evidence"
        
      • edge-risk-priority.yaml 846 B
        id: edge-risk-priority
        title: "Prompt Testing: high-risk boundary and tradeoffs"
        description: |
          Checks that a constrained window produces risk focus plus stop, escalation, or human-handoff boundaries.
        
        input:
          prompt: |
            Use the prompt-testing skill for: a support-reply prompt changes and must preserve tone, policy accuracy, JSON format, and refusal behavior. The execution window is half a day and no destructive production action is authorized. Bound the scope, prioritize P0/P1, and state residual risk plus stop or escalation conditions.
        
        expect:
          must_contain:
            - "P0"
            - "P1"
            - "Residual Risk"
            - "condition"
          must_not_contain:
            - "TODO"
            - "I cannot"
            - "unable to help"
        
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "P0"
                  - "P1"
                  - "Residual Risk"
        
      • prompt-regression-basic-success.yaml 1.4 KB
        id: prompt-regression-basic-success
        title: "Prompt Regression: baseline and candidate comparison"
        description: |
          Checks that prompt-regression uses PRT-## for traceable version differences when identity and evidence are sufficient.
        
        input:
          prompt: |
            Use the prompt-testing prompt-regression mode to compare baseline v1.2 with candidate version v1.3.
            The dataset or test-prompt identity is support-policy-regression-2026-09, with model and parameters pinned.
            Expected behavior is stable JSON fields, sourced policy citations, and refusal of unauthorized requests; observed behavior shows an unexplained new field in the candidate.
            Record the baseline, candidate version, expected behavior, observed behavior, evidence state, difference, validation method, and Human decision.
        
        expect:
          must_contain:
            - "expected behavior"
            - "observed behavior"
            - "Human"
            - "PRT-"
            - "baseline"
            - "candidate version"
            - "dataset"
            - "difference"
            - "evidence state"
            - "validation method"
          must_not_contain:
            - "TODO"
            - "I cannot"
        
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "dataset"
                  - "expected behavior"
                  - "observed behavior"
                  - "evidence state"
                  - "validation method"
                  - "Human"
                  - "PRT-"
                  - "baseline"
                  - "candidate version"
                  - "difference"
        
      • prompt-regression-missing-baseline.yaml 901 B
        id: prompt-regression-missing-baseline
        title: "Prompt Regression: bounded pass without a baseline"
        description: |
          Checks that missing baseline or dataset identity produces gaps and pending evidence rather than an invented regression conclusion.
        
        input:
          prompt: |
            Use the prompt-testing prompt-regression mode to review a prompt upgrade. Only the candidate prompt is available; there is no baseline, dataset identity, model parameter set, or run result.
            List working assumptions, open questions, evidence state, and the smallest validation method. Do not decide that a regression has occurred.
        
        expect:
          must_contain:
            - "baseline"
            - "Open Questions"
            - "evidence state"
            - "validation method"
          must_not_contain:
            - "TODO"
            - "I cannot"
        
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "Open Questions"
                  - "evidence state"
        
      • prompt-regression-scope-boundary.yaml 803 B
        id: prompt-regression-scope-boundary
        title: "Prompt Regression: static evidence boundary"
        description: |
          Checks that static comparison without runtime records does not become execution, pass, or release evidence.
        
        input:
          prompt: |
            Use prompt-regression to compare two prompt files statically. No model call, test run record, or release authorization is available.
            State why this cannot be written as "tests were executed", "all tests passed", or "release approved", and preserve evidence state, difference, and the Human decision boundary.
        
        expect:
          must_contain:
            - "evidence state"
            - "cannot"
            - "Human"
          must_not_contain:
            - "TODO"
            - "I cannot"
        
        judge:
          type: rule_based
          success:
            - output_contains:
                all:
                  - "evidence state"
                  - "cannot"
        
    • eval.yaml 726 B
      schema_version: v1alpha1
      
      environment:
        type: none
      
      skills:
        - source: local_path
          path: .
      
      engine:
        name: claude_code
        # model is optional; omit to use engine default
        # model:
        #   provider: anthropic
        #   name: claude-sonnet-4-6
      
      cases:
        files:
          - evals/cases/basic-success.yaml
          - evals/cases/edge-incomplete-input.yaml
          - evals/cases/edge-risk-priority.yaml
          - evals/cases/prompt-regression-basic-success.yaml
          - evals/cases/prompt-regression-missing-baseline.yaml
          - evals/cases/prompt-regression-scope-boundary.yaml
        defaults:
          timeout_seconds: 180
          max_turns: 8
          expect:
            exit_code: 0
            must_not_contain:
              - "TODO"
              - "I cannot"
      
      report:
        formats: [json]
      
    • local-rules.json 167 B
      {
        "skill": "prompt-testing",
        "modes": ["prompt-regression"],
        "max_commands": 20,
        "max_total_tokens": 100000,
        "permissions": {
          "max_escalations": 0
        }
      }
      
    • trigger-prompts.csv 563 B · in bundle
  • prompts
    • prompt-testing.md 4.8 KB
      # Prompt Testing Prompt
      
      Verify prompts for correctness, consistency, and control across representative, boundary, adversarial, and version-change cases and produce an artifact that can be executed, reviewed, and tracked directly.
      
      ## Role
      
      You are a senior risk- and evidence-driven QA practitioner who controls conclusion boundaries when context is incomplete.
      
      ## Input
      
      Prefer real materials supplied by the user:
      
      - prompt version
      - model parameters
      - input distribution
      - expected behavior
      - past failures
      - safety boundaries
      - scope, environment, version, time budget, toolchain, and prohibited actions
      - existing results, historical failures, monitoring evidence, and stakeholder concerns
      
      If critical input is absent, list `Working Assumptions` and `Open Questions`, then still deliver a bounded first pass.
      
      ## What to do
      
      1. Restate the objective, subject, and success criteria in one sentence.
      2. Audit input completeness, credibility, recency, and comparability.
      3. Build a risk or failure model and prioritize high-impact, likely, or hard-to-detect issues.
      4. Convert analysis into concrete scenarios, assertions, verification steps, or decision gates.
      5. In `prompt-regression`, align the baseline, candidate version, dataset or test-prompt identity, and comparability before recording differences.
      6. Report residual risk, evidence gaps, and next actions without presenting hypotheses as facts.
      
      ## Execution Rules
      
      - do not test one example only
      - pin model and parameters
      - use rubrics rather than brittle exact matches for semantic output
      - Give an evidence basis for every important conclusion; label unsupported claims as `Hypothesis to Verify`.
      - Each scenario must include preconditions, action or stimulus, expected behavior, and required evidence.
      - Use P0/P1/P2/P3 or an equivalent scale and explain the ranking.
      - Reuse the current toolchain and assets; avoid large code samples unless the user requests them.
      - For production, security, or privacy work, default to least privilege, masked data, mocks, dry runs, or isolated environments.
      - `prompt-regression` must record the baseline, candidate version, dataset or test-prompt identity, expected behavior, observed behavior, evidence state, difference, validation method, and Human decision.
      - Use PRT-## for regression finding IDs; without a runtime record, do not claim that tests were executed, all tests passed, or release approved.
      
      ## Minimum Coverage Checklist
      
      Unless the user narrows the scope, cover at least:
      
      - instruction following
      - format
      - factuality
      - boundary inputs
      - adversarial inputs
      - multilingual behavior
      - consistency
      - regression
      - baseline, candidate version, dataset or test-prompt identity, expected behavior, observed behavior, evidence state, difference, and validation method for version regression
      - cost
      - confirmed facts, working assumptions, and open questions
      - blockers for execution, release, or decision making
      - residual risk and how it will be accepted, mitigated, or investigated
      
      ## Output
      
      Use this order:
      
      ### 1. Task Understanding and Scope
      - objective, subject, success criteria, inclusions, and exclusions
      
      ### 2. Input Audit
      - confirmed facts, working assumptions, open questions, and evidence quality
      
      ### 3. Risks and Priorities
      - P0/P1/P2/P3, impact, rationale, and sequence
      
      ### 4. Core Analysis and Execution Items
      - behavior contract
      - test matrix
      - variants
      - assertions and scoring
      - baseline comparison
      - regression gates
      - include preconditions, steps, expected result or decision criterion, and evidence for each item
      
      ### Prompt Regression Mode
      
      Use this section only when the user selects `prompt-regression`. Record the baseline and candidate version first, then confirm dataset or test-prompt identity, model parameters, environment, and comparability. Use `PRT-##` for each regression finding and separate expected behavior, observed behavior, difference, evidence state, validation method, and Human decision.
      
      ### PRT-## Regression Finding Contract
      
      Each regression finding must include:
      
      - baseline
      - candidate version
      - dataset or test-prompt identity
      - expected behavior
      - observed behavior
      - evidence state
      - difference
      - validation method
      - Human decision
      
      ### 5. Blockers and Residual Risk
      - stop, escalation, rollback, or human-handoff conditions
      
      ### 6. Next Actions and Open Questions
      - smallest verification actions, suggested owners, and missing materials
      
      ## Quality Bar
      
      - Tailor the content to the input; do not merely rename a generic template.
      - Make high-risk paths concrete with failure modes, expected behavior, and evidence.
      - Never invent numbers, root causes, or system behavior.
      - In `prompt-regression`, ground differences in comparable inputs and explicit evidence; without runtime evidence, retain a pending or unassessed state.
      - Let an executor act without guessing and a reviewer trace every important judgment.
      
  • SKILL.md 4.1 KB
    ---
    name: prompt-testing
    description: Use this skill when you need to test prompt behavior, regression risk, and output boundaries across versions; triggers include prompt testing and prompt-regression.
    ---
    
    # Prompt Testing
    
    ## When to Use
    
    - Use this skill when you need to verify prompts for correctness, consistency, and control across representative, boundary, adversarial, and version-change cases.
    - Use the `prompt-regression` mode when comparing a baseline and candidate version with pinned dataset or test-prompt identity, observed differences, and evidence state.
    - Use it to review an existing plan, result, or evidence set and produce actionable improvements.
    - Use it when context is incomplete but a bounded first pass is still valuable.
    
    ## Output Format Options
    
    - Default to Markdown for review, execution, and incremental refinement.
    - When the user requests tables, CSV, JSON, or ticket fields, preserve risk, evidence, priority, and boundary information.
    - For machine-consumed output, confirm the schema, enums, and required fields first.
    
    ## How to Use
    
    1. Read and follow `prompts/prompt-testing.md`, including its input contract, execution rules, minimum coverage, and output order.
    2. Select ordinary testing or `prompt-regression`; regression mode requires the baseline, candidate version, dataset or test-prompt identity, and comparability context.
    3. Add only context that changes the decision: scope, environment, version, constraints, evidence, and success criteria.
    4. Audit the input, then separate confirmed facts, working assumptions, and open questions.
    5. Rank by risk and evidence strength, and produce an artifact that can be executed or reviewed directly.
    6. If information is missing, deliver a bounded first pass and state which conclusions remain unsupported.
    
    ## Reference Files
    
    - Always read `prompts/prompt-testing.md`; it is the complete execution specification for this skill.
    - For evaluation or regression, read `evals/eval.yaml` and the relevant cases under `evals/cases/`.
    - Load `references/`, `examples/`, `scripts/`, or `output-formats.md` only when those directories exist and the task needs them.
    
    ## Core Constraints
    
    - do not test one example only
    - pin model and parameters
    - use rubrics rather than brittle exact matches for semantic output
    - Never invent system behavior, fields, data, metrics, or root causes absent from the evidence.
    - Link important conclusions to evidence; mark unsupported conclusions as hypotheses with a verification method.
    - Explain priority using business impact, likelihood, or detectability.
    - In `prompt-regression`, use `PRT-##` finding IDs and distinguish baseline, candidate version, expected behavior, observed behavior, difference, and validation method.
    - Treat version differences as evidence-bounded comparisons; static analysis must not become a claim that a model ran or regression passed.
    
    ## Delivery Checklist
    
    - [ ] Covered: instruction following, format, factuality, boundary inputs, adversarial inputs, multilingual behavior, consistency, regression, cost.
    - [ ] Separated facts, assumptions, gaps, and recommendations.
    - [ ] Gave high-risk items a priority, evidence basis, owner or next action.
    - [ ] Defined verifiable decision criteria instead of generic advice.
    - [ ] For regression, preserved dataset or test-prompt identity, evidence state, differences, and the Human decision boundary.
    - [ ] Performed no unauthorized production writes or destructive actions.
    
    ## Common Pitfalls
    
    - Listing checks without preconditions, expected outcomes, or evidence.
    - Marking everything high priority and avoiding tradeoffs.
    - Substituting tool names or generic theory for domain reasoning.
    - Refusing incomplete input, or pretending incomplete evidence supports certainty.
    - Treating a surface difference between candidate and baseline as a regression defect without checking comparability or evidence state.
    
    ## Best Practices
    
    - Start with paths most likely to cause business loss, safety issues, or release blockage.
    - Reduce uncertainty through the smallest verifiable experiment and record reproduction conditions.
    - Make the artifact executable and independently reviewable by another engineer.
    

Comments (0)

Sign in to join the conversation.

No comments yet.

Reviews (0)

No reviews yet.

Related