Context Detection Skill

Detect protocol type from Solana smart contract source code and select matching audit templates.

56|9|Updated Jan 25, 2026
One-click install
npx skills add https://github.com/0x-Shashi/WEB3-AUDIT-SKILLS --skill context-detection-skill
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Context Detection Skill
Source: https://github.com/0x-Shashi/WEB3-AUDIT-SKILLS/tree/main/skills/advanced/context-detection
Command: npx skills add https://github.com/0x-Shashi/WEB3-AUDIT-SKILLS --skill context-detection-skill

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Automatically identify the type of protocol being audited to load appropriate checklists, templates, and vulnerability patterns without manual configuration. Use when starting any new audit to classify the protocol (DeFi lending, AMM, bridge, governance, etc.) and surface the most relevant checks.

Core Features & Use Cases

  • Detects protocol type from contract signals, imports, and state variables.
  • Loads the appropriate templates and checklists for lending, dex, bridge, governance, staking, NFT, and vault types.
  • Supports multi-type detection and surfaces the most relevant checks for complex protocols.

Quick Start

Provide the contract sources to auto-detect the protocol type and load the corresponding templates.

Frequently Asked Questions about Context Detection Skill

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I identify a smart contract protocol type during an audit?

Protocol type detection works by scanning verified smart contract source code for specific function signatures, state variable names, and imports. It then matches these signals to classify the protocol and return ranked confidence scores for template loading.

Can I automatically load security checklists for DeFi lending and bridge protocols?

Yes, you can automatically load security checklists for DeFi lending, AMM, bridge, and staking protocols. By detecting the protocol type from contract signals, the appropriate vulnerability templates and checks are surfaced without needing manual configuration.

How do I audit complex smart contracts that combine multiple protocol types?

To audit complex smart contracts combining multiple protocol types, the detection engine supports multi-type detection. It evaluates the source code and surfaces the most relevant checks for each detected scenario, such as overlapping NFT and vault characteristics.

What contract inputs are needed to auto-detect protocol type and load audit templates?

You need to provide verified smart contract source code as input to auto-detect the protocol type. The engine requires access to function signatures, state variable names, and imports to accurately classify the protocol and load the correct templates.

Does protocol classification work for governance, staking, and vault/yield scenarios?

Yes, protocol classification works for governance, staking, and vault/yield scenarios. The detection engine analyzes contract signals to correctly categorize these protocols and apply the corresponding security checklists and vulnerability patterns.