Skip to content

Add CLAUDE.md and Claude Code skills#143

Merged
TheDZhon merged 7 commits intomainfrom
feat/claude-code-setup
Mar 16, 2026
Merged

Add CLAUDE.md and Claude Code skills#143
TheDZhon merged 7 commits intomainfrom
feat/claude-code-setup

Conversation

@tamtamchik
Copy link
Member

@tamtamchik tamtamchik commented Mar 15, 2026

Summary

  • CLAUDE.md — project guidance file for Claude Code: common commands, architecture overview, config schema, and code style conventions
  • 4 custom skills in .claude/skills/:
    • /new-config — generate a verification config for a new contract/deployment, with full schema reference and per-chain explorer hostnames
    • /validate-config — validate a config file before running (addresses, required fields, YAML quoting, cross-references)
    • /debug-diff — diagnose failed verifications: walks through digest output, identifies root causes, suggests fixes
    • /add-explorer — step-by-step guide for adding a new blockchain explorer API, covering the dispatch architecture in explorer.py

Test plan

  • Verify /new-config generates a valid config when invoked in Claude Code
  • Verify /validate-config catches common mistakes (missing fields, unquoted YAML hex, bad addresses)
  • Verify /debug-diff provides useful guidance after a failed diffyscan run
  • Verify /add-explorer instructions are accurate against current explorer.py structure

Add project guidance file and four custom skills:
- /new-config: generate verification configs for new contracts
- /validate-config: validate config files before running
- /debug-diff: diagnose failed verifications
- /add-explorer: guide for adding new blockchain explorer support
Copilot AI review requested due to automatic review settings March 15, 2026 00:08
@tamtamchik tamtamchik requested a review from a team as a code owner March 15, 2026 00:08
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds Claude Code–oriented repository guidance and a set of Claude skills intended to streamline creating, validating, debugging, and extending Diffyscan configurations/explorer support.

Changes:

  • Introduces CLAUDE.md with project commands, architecture notes, config schema summary, and style conventions.
  • Adds four Claude skills under .claude/skills/ for config generation/validation, troubleshooting diff failures, and adding new explorer support.
  • Documents explorer hostnames/tokens, common config pitfalls (YAML hex quoting), and suggested rerun/debug workflows.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 9 comments.

Show a summary per file
File Description
CLAUDE.md Repository guidance for Claude Code: commands, architecture overview, config schema, env vars, style.
.claude/skills/new-config/SKILL.md Skill instructions for generating new verification configs, including explorer hostname/token reference table.
.claude/skills/validate-config/SKILL.md Skill instructions for validating config structure, addresses, and common mistakes before running Diffyscan.
.claude/skills/debug-diff/SKILL.md Skill instructions for diagnosing failed runs via digest outputs and common root causes.
.claude/skills/add-explorer/SKILL.md Skill instructions for adding a new explorer integration aligned with explorer.py dispatch/parsing.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

All 4 skills rewritten by writer agents and verified by devil's
advocate reviewer against actual source code.

Key fixes:
- new-config: fix hallucinated function name (_resolve_explorer_backend
  -> _get_explorer_fetcher); add network field to template; prefer YAML
  format; clarify explorer_hostname_env_var is CI convention only
- validate-config: accurate YAML hex validation description; clarify
  what code validates vs best-practice recommendations; document
  explorer_hostname_env_var as CI-only
- debug-diff: correct all paths (digest/{timestamp}/diffs/); real error
  messages verified against code; clarify immutable diff returns False
- add-explorer: document Etherscan v2 as preferred; full dispatcher
  table; all 4 fetcher endpoints and response formats documented
- new-config: scrollscan uses ETHERSCAN_EXPLORER_TOKEN fallback, not "no token"
- debug-diff: complete the truncated library error message to match source
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds Claude Code-specific project guidance and reusable “skills” to help generate, validate, and troubleshoot diffyscan verification configs and explorer integrations.

Changes:

  • Add CLAUDE.md with repo commands, architecture overview, config schema summary, and style conventions.
  • Add Claude Code skills under .claude/skills/ for config creation, validation, diff debugging, and adding explorer support.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
CLAUDE.md New Claude Code guidance: commands, architecture, config schema summary, env vars, style.
.claude/skills/new-config/SKILL.md Skill to generate new verification configs (schema + explorer hostname guidance).
.claude/skills/validate-config/SKILL.md Skill to validate configs against TypedDict/runtime behavior + common pitfalls.
.claude/skills/debug-diff/SKILL.md Skill to diagnose source/bytecode mismatches using digest outputs and common error signatures.
.claude/skills/add-explorer/SKILL.md Skill describing explorer dispatch architecture and steps to add new explorer support.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

- CLAUDE.md: add network key to config schema snippet
- new-config: routescan hostname uses Etherscan fetcher, not Blockscout
- add-explorer: document zkSync fetcher as outlier missing solcInput
Copy link
Contributor

@TheDZhon TheDZhon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

- debug-diff: remove "suggests fixes" from description, drop discouraged
  --skip-binary-comparison and --log-level/--quiet flags
- add-explorer: note limitations with flattened/single-file contracts
- new-config: add best practices for strict configs
TheDZhon
TheDZhon previously approved these changes Mar 16, 2026
Copy link
Contributor

@TheDZhon TheDZhon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GG

@TheDZhon TheDZhon merged commit 3148269 into main Mar 16, 2026
12 checks passed
@TheDZhon TheDZhon deleted the feat/claude-code-setup branch March 16, 2026 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants