Automatically infer loop invariants for code verification and correctness proofs. Use when analyzing loops to identify properties that hold throughout execution, generating assertions for verification, proving loop correctness, or documenting loop behavior. Supports Python, Java, C/C++, and language-agnostic analysis. Generates invariants as code assertions (assert statements). Triggers when users ask to infer invariants, find loop properties, generate loop assertions, prove loop correctness, or verify loop behavior.
94
92%
Does it follow best practices?
Impact
97%
1.12xAverage score across 3 eval scenarios
Passed
No known issues
Quality
Discovery
100%Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.
This is an excellent skill description that clearly defines a specialized capability (loop invariant inference) with comprehensive trigger terms and explicit usage guidance. It uses proper third-person voice throughout, specifies supported languages and output format, and provides multiple natural phrases users might say when needing this skill. The description is distinctive enough to avoid conflicts with general code analysis skills.
| Dimension | Reasoning | Score |
|---|---|---|
Specificity | Lists multiple specific concrete actions: 'infer loop invariants', 'analyzing loops to identify properties', 'generating assertions for verification', 'proving loop correctness', 'documenting loop behavior'. Also specifies supported languages and output format (assert statements). | 3 / 3 |
Completeness | Clearly answers both what ('Automatically infer loop invariants for code verification and correctness proofs') and when ('Use when analyzing loops...', 'Triggers when users ask to...'). Has explicit trigger guidance with multiple specific scenarios. | 3 / 3 |
Trigger Term Quality | Excellent coverage of natural terms users would say: 'infer invariants', 'loop properties', 'loop assertions', 'prove loop correctness', 'verify loop behavior'. Includes both technical terms that domain experts would use and action-oriented phrases. | 3 / 3 |
Distinctiveness Conflict Risk | Very clear niche focused specifically on loop invariants and formal verification. Unlikely to conflict with general code analysis or testing skills due to the specialized terminology around invariants, correctness proofs, and verification. | 3 / 3 |
Total | 12 / 12 Passed |
Implementation
85%Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.
This is a well-structured, highly actionable skill with excellent workflow clarity and appropriate progressive disclosure. The main weakness is verbosity—explaining loop types Claude already knows and providing redundant multi-language examples that could be consolidated. The verification workflow and concrete assertion examples are particularly strong.
Suggestions
Remove or significantly condense Section 1 (Identify the Loop) - Claude already knows loop types and doesn't need basic definitions of for/while/do-while loops
Consolidate multi-language examples into a single primary language (Python) with brief notes on language-specific syntax differences rather than full duplicate examples
| Dimension | Reasoning | Score |
|---|---|---|
Conciseness | The skill is comprehensive but includes some unnecessary verbosity, such as explaining basic loop types Claude already knows and providing multiple language examples that repeat similar concepts. The content could be tightened significantly. | 2 / 3 |
Actionability | Provides fully executable code examples across Python, Java, and C/C++. The assertions are copy-paste ready, and the workflow examples show complete before/after transformations with concrete invariant expressions. | 3 / 3 |
Workflow Clarity | Clear 6-step workflow with explicit verification steps (initialization, maintenance, termination). The verification section provides a proper feedback loop for checking invariant correctness, and complex cases are handled with specific guidance. | 3 / 3 |
Progressive Disclosure | Well-structured with clear sections progressing from overview to complex cases. References external file (invariant-patterns.md) for comprehensive patterns, keeping the main skill focused. Navigation is clear with descriptive headers. | 3 / 3 |
Total | 11 / 12 Passed |
Validation
100%Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.
Validation — 11 / 11 Passed
Validation for skill structure
No warnings or errors.
0f00a4f
Table of Contents
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.