Borrowing it
Nothing to install: this file belongs to AbdumajidRashidov/mycop. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/AbdumajidRashidov/mycop/main/CLAUDE.mdgit clone --depth 1 https://github.com/AbdumajidRashidov/mycopWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/abdumajidrashidov/mycop/claude-md)<a href="https://agentmods.dev/instructions/abdumajidrashidov/mycop/claude-md"><img src="https://agentmods.dev/badge/instructions/abdumajidrashidov/mycop/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/abdumajidrashidov/mycop/claude-md"><img src="https://agentmods.dev/badge/instructions/abdumajidrashidov/mycop/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.01383 | $0.01383 |
| Opus 5 | $0.00691 | $0.00691 |
| Sonnet 5 | $0.00277 | $0.00277 |
| Haiku 4.5 | $0.00138 | $0.00138 |
Grade A, and why
mycop CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 74 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
What is mycop
mycop is an AI-powered code security scanner (SAST) written in Rust. It detects vulnerabilities in AI-generated code targeting Python, JavaScript, TypeScript, Go, and Java, with 200 built-in YAML security rules covering OWASP Top 10 and CWE Top 25.
Build & Development Commands
cargo build # Debug build
cargo build --release # Optimized release build
cargo test --verbose # Run all tests
cargo test scanner_tests # Run a specific test module
cargo fmt --all -- --check # Check formatting (CI enforced)
cargo clippy --all-targets -- -D warnings # Lint (CI enforced, warnings are errors)
CI runs on both Ubuntu and macOS with stable Rust. All PRs must pass fmt, clippy, build, and test.
Architecture
Data Flow
CLI parsing (clap) → Config loading (.scanrc.yml) → File discovery (walkdir + gitignore) → Rule loading (embedded YAML via include_str!) → Parallel scanning (Rayon) → Severity filtering → Optional AI processing → Output reporting
Module Map (src/)
- cli.rs — Clap-derived CLI definitions. Subcommands:
scan,fix,review,init,rules list,deps check,mcp - main.rs — Command routing and orchestration for all subcommands
- scanner/ — Core scanning engine
engine.rs— Parallel file scanning with Rayon (scan_filesreturnsVec<Finding>)language.rs— Language detection from file extensions (Python, JS, TS, Go, Java)file_discovery.rs— File globbing, gitignore-aware traversal,--diffmode via git
- rules/ — Security rule system
registry.rs— Loads 200 YAML rules embedded at compile time viainclude_str!fromrules/python/,rules/javascript/,rules/go/, andrules/java/matcher.rs— Pattern matching using tree-sitter AST queries + regex. ProducesFindingstructsparser.rs— YAML rule deserialization
- ai/ — Pluggable AI backends behind the
AiBackendtraittypes.rs—AiBackendtrait withexplain(),deep_review(),fix_file()methodsmod.rs— Auto-detection and factory (detect_ai_provider,create_backend). Priority: Claude CLI → Anthropic API → OpenAI API → Ollama → rule-based fallback- Provider impls:
claude_cli.rs,anthropic.rs,openai.rs,ollama.rs,rule_based.rs prompt.rs— Prompt templates for AI interactions
- fixer.rs — Auto-fix flow: groups findings per file, sends to AI, extracts
<FIXED_FILE>tags from response, generates diffs, optionally writes back and re-scans for verification. Also providesdiff_to_string()for generating plain-text diffs - mcp/ — MCP (Model Context Protocol) server for agentic tool integration
mod.rs—MycopMcpServerstruct implementingServerHandlertrait. Handleslist_tools,call_tool,list_resources,read_resource. Starts STDIO transport viaMycopMcpServer::run()tools.rs— 5 MCP tools implemented onMycopMcpServerusing#[tool]proc macro:scan,list_rules,explain_finding,review,check_deps. Thefixtool is intentionally excluded from MCP — agentic tools should read scan findings and apply fixes themselves. Sync impl functions bridged to async viatokio::task::spawn_blocking. Tools registered viarmcp::tool_box!macrotypes.rs— MCP-specific request/response schemas withDeserialize + JsonSchema(inputs) andSerialize(outputs). Separate from core types to isolate MCP concernsconvert.rs— Conversions between core types (Finding,Rule) and MCP output types (FindingOutput,RuleOutput)
- reporter/ — Output formatters implementing the
Reportertraitterminal.rs(colored),json.rs,sarif.rs(for CI/IDE integration)
- config/scanrc.rs — Loads
.scanrc.yml/.mycop.ymlconfig (ignore patterns, min_severity, fail_on, ai_provider)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 11d ago First seen · 74 lines · 1,383 tokens per session scan A 9c68c625d94d
mycop CLAUDE.md is an instructions file published in the GitHub repository AbdumajidRashidov/mycop (9 stars, last pushed 6mo ago), licensed MIT. It adds 1,383 tokens to every session, about $0.0069 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other instructions, from other repositories
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.