/bugfinding:metamorphic-testingfrom bugfinding
Guides metamorphic bugfinding by deriving valid relations between transformed executions. Use when expected outputs are unavailable, extending round-trip checks, or testing transformations whose state, effects, numerical rules or result composition can invalidate an apparent equivalence.
Ships in bugfinding. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Search related executions whose observations must satisfy a justified relation. A violated valid relation exposes an inconsistency; agreement cannot establish ground truth because both executions can share a defect. The TLP authors state that TLP "cannot establish a ground truth" because an operator or function might "consistently behave incorrectly" (Query Partitioning, §§2 and 6).
Read the real producer, enabled semantics and existing oracle. State the admissible original input/state, transformation, transformed execution conditions, required observation and composition rule. Explain what implementation behavior the transformation changes and why the relation still holds; the TLP authors call it "crucial to select one that stresses the DBMS and its query optimizer in different ways" (Query Partitioning, §1). Query partitioning illustrates why composition varies by feature rather than following one universal equality rule (Query Partitioning, §3).
Check effects, evaluation multiplicity, exceptional behavior and nondeterminism before using an algebraic rewrite: SQLite's x BETWEEN y AND z equals x>=y AND x<=z "except that with BETWEEN, the x expression is only evaluated once", and a CASE base expression "is evaluated just once" (SQLite expressions, §§6–7). Numeric rearrangement also needs the target's overflow, rounding and empty/NULL rules: SQLite's sum() raises an error when "an integer overflow occurs at any point during the computation", and returns NULL where total() returns 0.0 for no non-NULL input (SQLite aggregates, §3). The TLP paper's epsilon comparison rests on its own stated assumption that SUM() and AVG() are commutative (Query Partitioning, §3); use numerical-oracles for a justified error contract rather than inventing epsilon. Read relation design when constructing or reviewing a relation.
Reuse the target's existing representation, formatter and transformations; the TLP authors expect "any database generator and query generator that provides control over the format of the queries generated" to serve (Query Partitioning, §2). Construct valid original state/programs, select applicable relations, and derive the dependent variants. SQLancer's actual TLP producer generates an original query and predicate, negated-predicate and NULL variants; its reproducer retains them together (TLPWhereOracle, lines 141–195).
Count admitted originals, completed transformed executions and actual relation evaluations separately. Expected-error skips are not successful comparisons: the inspected SQLancer helper raises IgnoreMeException for unavailable/expected-error results (ComparatorHelper, lines 57–58 and 73–77). Use harness-sensitivity to verify that an existing healthy case and representative violation discriminate through this relation; examples of suitable controls are in worked relations.
Match the observation to the guarantee. Preserve required columns, types, multiplicities and effects; compare ordering only where promised. SQLite's UNION "works the same way as UNION ALL, except that duplicate rows are removed", and without ORDER BY "the order in which the rows are returned is undefined" (SQLite SELECT, §§3–4). Inspect the actual comparator: SQLancer's shown helper reads first-column strings, removes a trailing decimal point followed only by zeros, and checks count plus sets, or count alone under its size-only option, which is weaker than complete row-bag equality (ComparatorHelper, lines 61–63 and 89–112).
Retain original setup/world, original and transformed programs, transformation parameters, enabled configuration, raw outcomes, admissibility evidence and selected violation. SQLancer's bug log keeps "the other statements to set up the database state", and its documented manual reduction for TLP requires "checking that both queries still produce a different result" (SQLancer README, Logs and Reducing bugs).
After shrinking an original or setup, regenerate its variants and re-establish relation preconditions before re-checking the disagreement; this pack's rule extends SQLancer's statement-at-a-time replay, which re-applies the oracle after each removal (SQLancer README, Reducing bugs). For world/program adaptations, retain dependent identities and observations through the target's real owners. Use failure-reduction for reduction mechanics, semantic-program-generation for valid program construction, and evidence-based-triage for attribution. These links define this pack's ownership.
Return the relation and its contract basis, tested domain, actual evaluation counts, paired replay artifacts, observed contradiction and unresolved assumptions. A mismatch under an invalid relation is not a demonstrated product violation. The TLP paper states "Our testing does not apply to transactions, window functions, sequences, and non-deterministic functions", and MySQL verifiers considered three of its reports false positives, one on whether an empty string is a valid DECIMAL (Query Partitioning, §§5.1 and 6).
For a fitting DBMS target, read SQLancer operation; for misleading shortcuts, read common mistakes. Select execution and budget through bugfinding-campaign and the project's existing authority.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub ctoth/computational-bugfinding-skills-plugin --plugin bugfinding26 skills in this plugin
/bounded-model-checkingGuides source-linked CBMC, JBMC and Kani checks with explicit input domains, unwind bounds and executable counterexamples. Use when finite hard paths or invariants merit solver search beyond fuzzing, or when interpreting bounded verification, vacuous success or counterexample playback./bugfinding-campaignGuides compute-budgeted bugfinding campaigns by finding gaps in existing generators, execution models and correctness oracles. Use when choosing what to test next, extending an established fuzzing setup, or deciding whether more compute will produce useful evidence./configuration-differential-testingOther plugins' skills for the same job