---
name: test-skill-trigger-collisions
description: "Grade which skills an agent actually loaded for each labelled test prompt, finding missed activations and neighbouring skills that wrongly trigger on shared words. Use when someone is tuning skill descriptions, adding a skill beside similar ones or checking routing in a skill library."
license: CC-BY-4.0
metadata:
  author: Raq.com
  version: "2026-11-22"
  homepage: https://skills.raq.com/skills/test-skill-trigger-collisions
---

# Test when neighbouring skills activate

Grade recorded skill selections against labelled requests, including cases where a second skill wrongly activates on the same wording.

## When to use this skill

- Someone is adding a skill next to similar ones and wants to know whether prompts route to the right one.
- Users report that the wrong skill loads, or two skills load, for a common request.
- A skill description is being revised and someone wants a before-and-after check on labelled prompts.

## When not to use it

- Judging the quality of the work done once a skill loaded. Use the paired skill evaluation skill.
- Installation problems, such as a skill missing from the catalogue altogether. Check the client's skill locations and loading diagnostics first.
- Rewriting the descriptions. This skill grades routing; its findings feed a separate description edit.

## What you need

- A skill catalogue or pair of neighbouring descriptions, a labelled prompt set and the actual activation trace for each prompt.
- For each prompt specify every acceptable set of active skills, including the empty set for a true negative. Distinguish observed no activation from an absent trace.

## Ask before you start

If any of these are missing or unclear, ask before doing the work.

- What is the labelled prompt set, and for each prompt which sets of skills are acceptable, including an empty set where no skill should load?
- How was activation captured: a tool-call log, a file-read trace or the client's debug output? A model mentioning a skill is not evidence that it loaded.
- Which prompts are being held back to check a later description change?

## Method

1. Write or review prompts in users' own words around each boundary: the right task in indirect wording, similar vocabulary with a different deliverable, a request that genuinely needs both skills, and a request that needs neither. The Agent Skills guide suggests about 20, half that should trigger and half near-misses that should not.
2. Label every acceptable set of skills for each prompt before looking at any trace.
3. Read activation from the trace: which SKILL.md files were loaded or which activation calls were made. A good answer, or a mention of a skill's name, is not proof of activation. If capture failed, mark the prompt unobserved.
4. Compare the observed set with each acceptable set as sets, ignoring order. A match with any acceptable set passes.
5. If no acceptable set matches, compare with the one needing the fewest additions and removals, breaking ties by input order. A required skill that did not load is missing; an unwanted skill that loaded is extra. A substitution shows both.
6. Count passing and observed prompts. Activation varies between runs, so where possible run each prompt several times; the guide suggests three runs and a trigger-rate threshold of 0.5.
7. Group repeated errors by the shared phrase or concept that caused them, and keep the held-out prompts unused until a revised description is ready to test.

## Checks before you deliver

- Treating every multi-skill selection as a collision unfairly penalises prompts that need both capabilities.
- Scoring no trace as no activation flatters negative prompts and fabricates misses on positive ones.
- Negative prompts with no shared vocabulary, such as a weather question, which test nothing about the boundary.
- Fixing a failure by pasting the failed prompt's keywords into the description, which overfits to the test set.
- Judging from a single run per prompt when activation varies from run to run.

## How to present the result

Start with the score: prompts passed out of prompts observed, and how many were unobserved. Then a table: prompt ID, result, missing skills and extra skills. Group mismatches by the overlapping phrase that caused them, and finish with the boundary each pair of descriptions needs to state, as input for a description edit.

## Worked example

**Request:** Grade each routing trace. Brackets show sets of skill slugs; braces separate accepted alternatives.

**Supplied material:**

```text
P1 'Have we paid this supplier bill?' accept [bank-match]; trace [bank-match,invoice-check].
P2 'Did the tradesperson charge what we agreed?' accept [invoice-check]; trace [bank-match].
P3 'Write a thank-you note' accept []; trace [] (captured).
```

**Answer:** Only the thank-you note routed correctly. The supplier-payment request loaded an unnecessary invoice checker. The tradesperson’s price check loaded the bank matcher and missed the invoice checker it needed.

## Structured output for tests

For an ordinary job, answer in the format above and point back to the supplied evidence. Use this structure only for the test cases published with this skill, or when someone asks for structured JSON.

Return prompts in supplied order as rows with id, result ('pass', 'mismatch' or 'unobserved'), missing and extra as alphabetically sorted skill slugs. Unobserved rows have empty arrays. Return passed and observed as counts of passing and observed prompts. Treat selections as sets.

## Sources

- [Agent Skills: optimising skill descriptions](https://agentskills.io/skill-creation/optimizing-descriptions): Recommends about 20 labelled queries with near-miss negatives, checking whether the agent loaded SKILL.md, running each query several times against a trigger-rate threshold, and keeping a validation split to avoid overfitting the description.
- [Agent Skills: how to add skills support to your agent](https://agentskills.io/client-implementation/adding-skills-support): Separates disclosure of the skill catalogue from activation, which happens when the model reads SKILL.md or calls an activation tool. That activation record is the evidence this skill grades.

Test cases and an answer checker for this skill: https://skills.raq.com/skills/test-skill-trigger-collisions
