Token导航 LogoToken导航TokenDH.com
研究检索只读github未标认证来源可访问许可证需确认审计通过

clarity-check清晰度检查

Agent Skill

clarity-check 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

1,983

周安装

81

GitHub Stars

5

下载量

642
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:clarity-check(清晰度检查)
来源仓库:https://github.com/aibtcdev/skills
仓库路径:skills/clarity-check
安装命令:
npx skills add https://github.com/aibtcdev/skills --skill clarity-check
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/aibtcdev/skills --skill clarity-check

简介

clarity-check 是 Clarity 合约预部署验证门控技能,检查语法、弃用关键词与错误传播等问题。

  • 适用于合约上线前的自动化检测,配合现有合约技能完成部署流程。
  • 支持批量运行检查并提供详细错误定位,提升代码质量与部署安全性。
  • 使用前应确认项目测试框架与运行环境,避免误改关键逻辑或触发意外副作用。
  • 适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

SKILL.md

Clarity Check Skill

Pre-deployment validation gate for Clarity smart contracts. Runs automated checks for syntax errors, deprecated keywords, incorrect sender checks, error propagation issues, and missing tests. Pairs with the existing contract skill for deploy operations.

Usage

This is a doc-only skill. Agents read this file to understand available checks and invoke them through the skill framework. The CLI interface below documents the planned implementation.

bun run clarity-check/clarity-check.ts <subcommand> [options]

Subcommands

validate

Run all automated checks against a Clarity contract file.

bun run clarity-check/clarity-check.ts validate --source <path-to-file.clar> [--project-dir <clarinet-project-dir>]

Options:

  • --source (required) — Path to the .clar source file to validate
  • --project-dir (optional) — Clarinet project directory for clarinet check integration; auto-detected from source path if omitted

Output:

{
  "file": "contracts/my-contract.clar",
  "passed": false,
  "checks": [
    {
      "name": "syntax",
      "status": "pass",
      "description": "clarinet check passes"
    },
    {
      "name": "deprecated-keywords",
      "status": "fail",
      "description": "Deprecated keywords found",
      "findings": [
        {
          "line": 15,
          "keyword": "block-height",
          "replacement": "stacks-block-height",
          "severity": "warning"
        }
      ]
    },
    {
      "name": "sender-checks",
      "status": "warn",
      "description": "Sender check analysis",
      "findings": [
        {
          "line": 22,
          "issue": "Token transfer uses contract-caller instead of tx-sender",
          "recommendation": "Use tx-sender for token operations to preserve human identity through proxies",
          "severity": "warning"
        }
      ]
    }
  ],
  "summary": {
    "total": 7,
    "pass": 5,
    "fail": 1,
    "warn": 1
  }
}

checklist

Generate a human-readable pre-deployment checklist for a contract, combining automated checks with manual verification items.

bun run clarity-check/clarity-check.ts checklist --source <path-to-file.clar> [--project-dir <clarinet-project-dir>]

Options:

  • --source (required) — Path to the .clar source file
  • --project-dir (optional) — Clarinet project directory

Output:

{
  "file": "contracts/my-contract.clar",
  "automated": [
    {"check": "clarinet check passes", "status": "pass"},
    {"check": "No deprecated keywords", "status": "fail", "details": "Found: block-height on line 15"},
    {"check": "Correct sender checks", "status": "warn", "details": "1 finding"},
    {"check": "Error propagation uses try!", "status": "pass"},
    {"check": "No dead code or unused features", "status": "pass"},
    {"check": "Events follow structured format", "status": "pass"},
    {"check": "Error codes are unique", "status": "pass"}
  ],
  "manual": [
    "Verify tests exist and pass (npm test)",
    "Check execution costs in clarinet console (::get_costs)",
    "Review post-conditions for all token operations",
    "Verify trait whitelisting if external contracts are called",
    "Test on testnet before mainnet deployment",
    "Document contract address after deployment"
  ]
}

Checks Performed

Automated

CheckWhat it detects
Syntaxclarinet check errors and warnings
Deprecated keywordsblock-height (use stacks-block-height), other legacy keywords
Sender checkstx-sender vs contract-caller misuse in token operations
Error propagationunwrap! used where try! is more appropriate for recoverable errors
Dead codeUnused private functions, unreachable branches
Event formatEvents missing notification/payload structure
Error code uniquenessDuplicate error code constants
Public function returnsFunctions missing (response ok err) return type

Manual (Checklist Only)

CheckWhy it matters
Tests exist and passEnsures behavior is verified
Execution costsPrevents exceeding block limits
Post-conditionsProtects users from unexpected token transfers
Trait whitelistingPrevents unauthorized contract interactions
Testnet deploymentCatches issues before mainnet

Notes

  • Requires clarinet CLI installed locally for syntax checking
  • If clarinet is not found, syntax check is skipped with a warning
  • Static analysis only — does not execute the contract or run tests
  • Use clarity-test-scaffold to generate tests, then clarity-audit for deep review
  • Complements clarinet check by adding Clarity-specific best practice checks that the compiler doesn't enforce

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

36.31%
按下载量换算233

Claude

30.87%
按下载量换算198

Cursor

20.79%
按下载量换算133

Gemini CLI

9.45%
按下载量换算61

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

只读

该 Skill 主要提供规则、说明或参考内容,本身偏只读;真正读写文件、联网或执行命令仍取决于宿主 Agent 的任务。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills