analyzing-nft-rarity
Calculate NFT rarity scores and rank tokens by trait uniqueness. Use when analyzing NFT collections, checking token rarity, or comparing NFTs. Trigger with phrases like "check NFT rarity", "analyze collection", "rank tokens", "compare NFTs".
What this skill does
# Analyzing NFT Rarity
## Overview
NFT rarity analysis skill that:
- Fetches collection metadata from OpenSea API
- Parses and normalizes trait attributes
- Calculates rarity using multiple algorithms
- Ranks tokens by composite rarity score
- Exports data in JSON and CSV formats
## Prerequisites
- Python 3.8+ with requests library
- Optional: `OPENSEA_API_KEY` for higher rate limits
- Optional: `ALCHEMY_API_KEY` for direct metadata fetching
## Instructions
### 1. Analyze a Collection
```bash
cd ${CLAUDE_SKILL_DIR}/scripts && python3 rarity_analyzer.py collection boredapeyachtclub
```
Options:
1. `--limit 500`: Fetch more tokens for analysis
2. `--top 50`: Show top 50 tokens
3. `--traits`: Include trait distribution
4. `--rarest`: Show rarest traits
5. `--algorithm [statistical|rarity_score|average|information]`
### 2. Check Specific Token
```bash
cd ${CLAUDE_SKILL_DIR}/scripts && python3 rarity_analyzer.py token pudgypenguins 1234 # port 1234 - example/test
```
### 3. Compare Multiple Tokens
```bash
cd ${CLAUDE_SKILL_DIR}/scripts && python3 rarity_analyzer.py compare azuki 1234,5678,9012 # 5678: 1234: 9012 = configured value
```
### 4. View Trait Distribution
```bash
cd ${CLAUDE_SKILL_DIR}/scripts && python3 rarity_analyzer.py traits doodles
```
### 5. Export Rankings
JSON:
```bash
cd ${CLAUDE_SKILL_DIR}/scripts && python3 rarity_analyzer.py export coolcats > rankings.json
```
CSV:
```bash
cd ${CLAUDE_SKILL_DIR}/scripts && python3 rarity_analyzer.py export coolcats --format csv > rankings.csv
```
### 6. Manage Cache
```bash
cd ${CLAUDE_SKILL_DIR}/scripts && python3 rarity_analyzer.py cache --list
cd ${CLAUDE_SKILL_DIR}/scripts && python3 rarity_analyzer.py cache --clear
```
## Rarity Algorithms
| Algorithm | Description | Best For |
|-----------|-------------|----------|
| `rarity_score` | Sum of 1/frequency (default) | General use, matches rarity.tools |
| `statistical` | Same as rarity_score | Backward compatibility |
| `average` | Mean of trait rarities | Balanced scoring |
| `information` | Entropy-based (-log2) | Information theory approach |
## Output
- **Collection Summary**: Name, supply, trait types
- **Rankings**: Tokens sorted by rarity score with percentile
- **Token Detail**: Full trait breakdown with contribution
- **Comparison**: Side-by-side trait comparison
## Supported Collections
Works with any ERC-721/ERC-1155 collection that has:
- OpenSea listing
- Standard attributes array format
- Accessible metadata
## Error Handling
See `${CLAUDE_SKILL_DIR}/references/errors.md` for:
- API rate limiting
- IPFS gateway issues
- Collection not found
- Token ID not found
## Examples
See `${CLAUDE_SKILL_DIR}/references/examples.md` for:
- Collection analysis workflows
- Token comparison
- Export and caching
- Algorithm comparison
## Resources
- [OpenSea API](https://docs.opensea.io/reference/api-overview) - Metadata source
- [Rarity Tools](https://rarity.tools/) - Reference rankings
- [IPFS](https://ipfs.io/) - Decentralized metadata
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.