본문으로 건너뛰기
Skillpedia
테스트15k · #10960

create-formal-verification-skill

하는 일

이 스킬은 어시스턴트가 버그 비용이 가장 큰 코드의 속성을 확인하도록 형식 검증을 쓰는 재사용 가능한 스킬을 만들게 합니다. 재시도, 경쟁 상태, 파서처럼 까다로운 로직을 가진 팀을 위한 스킬입니다.

사용하는 경우

  • ✓경쟁 상태, 재시도 로직, 상태 기계에 테스트 이상이 필요할 때.
  • ✓명시된 범위의 모든 경우에 불변식이 성립하는지 증명하고 싶을 때.
  • ✓핵심 영역의 버그가 비싸고 테스트가 그 경우에 거의 닿지 않을 때.

스킬 링크

https://github.com/cursor/plugins/blob/main/harness/pstack/claude-code/skills/create-formal-verification-skill/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/cursor/plugins/blob/main/harness/pstack/claude-code/skills/create-formal-verification-skill/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“우리 작업 큐의 경쟁 상태를 모델 검사하고, 팀이 앞으로의 변경에도 다시 실행할 수 있는 스킬을 만들어 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

어시스턴트는 코드에서 가장 가치 있는 대상을 고르고, 그 질문에 맞는 검증 도구를 고르고, 속성 하나를 검사한 뒤, 앞으로의 에이전트가 다시 확인하는 방법을 알려 주는 프로젝트 스킬을 씁니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Create a formal verification skill

In Claude Code, read the Claude Code adapter once per session before you follow this skill. It maps the Cursor names in pstack skills to Claude Code.

A test checks the cases that someone thought to write. Formal verification checks every case in a stated scope: every order of steps in a model, every input up to a bound, or every input. This skill finds the part of the repo where that matters most, verifies one property of it, and leaves a project-local skill that lets the next agent check a change against that property. Write that skill for an agent who reads it cold, mid-change, and has never seen your work. The user must be able to trust the result and act on it without learning the verification language.

Choose the target from the code

Answer from the codebase, and ask the user only what you cannot observe. If the user named an area or a bug, start there.

A good target is a promise the code makes, where a break harms users and tests rarely reach the case that breaks it. Choose the strongest such target in the repo, not the one that is easiest to verify.

Let the question choose the tool

Pick the tool that answers the question at the lowest cost: a model checker, a proof assistant, an SMT-backed verifier, or another tool. Whether events can happen in a bad order usually suits a model checker over a small model of the design, and TLA+ is the default for that in any language. Whether the code itself behaves for every input, as with memory safety, overflow, or a data-structure invariant, usually suits a verifier that runs on the code. If no verifier runs on this language, say so, and test the real code with generated inputs, not a hand model of the function. A property that must hold at every size, where a bound is not enough, can need a proof. Prefer a tool that the repo's developers can install and run, and tell the user why you chose it.

What makes it good

  • True to the code. Every part of the model or proof points to code that a reviewer can open. What the verification treats as one indivisible step is one indivisible step in the code. Names come from this repo.
  • Able to fail. A check that you have never seen fail proves nothing. Show each property failing on a broken variant of the code it guards, such as a removed check or a reordered step.
  • Findings stay findings. When the current code breaks the property, report it with the counterexample in the code's terms. Do not weaken the property or the model until it passes, and do not change product code unless the user asks.
  • Honest about scope. Say what is verified, under which bounds and assumptions, and what is left out. A pass covers the model or the bound, not the whole system.
  • Readable without the tool. State the property and the harm in one plain sentence each. Tell a counterexample as a short sequence of steps in the code's words.
  • Cheap to rerun. One command, a reproducible tool version, and a run short enough that the next agent will use it on every relevant change.
  • Kept in step with the code. Record which files and functions each check covers, and the commit at which you last confirmed that the verification describes them. When the covered code changes after that commit, the next agent can see that the verification needs another look.

Generate the verify skill

Write a project-local skill with frontmatter that names the area and says when to use it. Without frontmatter, the skill never registers. From the skill alone, the next agent must be able to tell whether a change touches the verified code, run the check, tell a real bug from a modeling error, and update the verification when a change is intended. Put the coverage record and the sync commit in the skill, and tell the next agent to move the sync commit forward only after it confirms that the verification describes the code at the new commit. Use this repo's real commands, paths, and nouns, and leave no placeholders.

If the check is a TLA+ model, tell the next agent to read every result with the pstack /statechart skill. It shows each invariant violation the checker finds as its shortest path in plain words. When the check passes, /statechart draws a chart of how the system moves between states. Refer to /statechart by name. Its commands, options, and file paths change between releases and machines, so copy none of them into the generated ski

자주 묻는 질문

팀이 검증 언어를 배워야 하나요?

아닙니다. 스킬은 팀이 도구를 배우지 않고도 결과를 신뢰하고 조치할 수 있도록 쓰입니다.

대상은 어떻게 고르나요?

코드에서 고릅니다. 깨졌을 때 사용자가 해를 입고 테스트가 실패를 거의 다루지 않는 곳의 가장 강한 약속입니다.

어떤 도구를 쓰나요?

가장 낮은 비용으로 질문에 답하는 도구를 씁니다. 모델 검사기나 증명 보조 도구 등입니다.

상세 정보

작성자의 원본 설명

Generate a project-local skill that formally verifies the code where a bug costs the most and tests reach the least, in any language, with whichever verification tool fits. Use for /create-formal-verification-skill, \"model-check this race\", \"prove this invariant\", or when concurrency, retries, state machines, parsers, or unsafe code need more than tests.

repo: cursor/plugins

인기도

GitHub 스타
15k
순위
#10960
라이선스
—
업데이트
2026. 10. 31.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬