Agent skill · Code Review & Quality

contextvar-opportunity-finder

Detect explicit user_id parameters in functions to identify potential opportunities for using ambient context. This is an investigation tool that flags instances for human review, not a prescriptive analyzer.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill contextvar-opportunity-finder --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 7 KB
Bundled scripts: none
Path: skills/analysis/contextvar-opportunity-finder/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Contextvar Opportunity Finder An intelligent grep tool that finds all explicit `user_id` usage patterns in Python code. Reports findings with context for human review. --- ## Core Principle This is a **detection-only** skill - It finds and reports all instances of explicit user_id usage without making judgments about correctness. Read every file completely, one at a time, and report findings for EACH file before moving to the next. No shortcuts, no grep tricks, no "I'll infer from patterns". Complete reads only! **What it does**: Scans code, detects patterns, reports everything it finds. **What it doesn't do**: Make recommendations, filter results, or determine what's "right" or "wrong". --- ## Detection Patterns ### Pattern 1: Direct user_id Parameter Look for functions with `user_id` in their parameters: ```python def function_name(..., user_id: str, ...): def function_name(..., user_id: Optional[str], ...): def function_name(..., user_id=None, ...): ``` ### Pattern 2: user_id Extraction from Dicts/Objects Look for functions extracting user_id from parameters: ```python def function_name(self, context: Dict[str, Any]): user_id = context.get('user_id') def function_name(self, ev

What's inside
Steps it walks through
  1. Core Principle
  2. Detection Patterns
  3. Pattern 1: Direct userid Parameter
  4. Pattern 2: userid Extraction from Dicts/Objects
  5. Pattern 3: Redundant Context Setting
  6. Pattern 4: Threading Through Layers
  7. Pattern 5: Bad Dual-Mode Pattern
  8. Pattern 6: Convenience Function Wrappers
  9. Pattern 7: Request Body User IDs
  10. Context Clues to Report
  11. Class/Inheritance Context
  12. Function Context
  13. Call Context
  14. Code Patterns
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the contextvar-opportunity-finder skill do?

Detect explicit user_id parameters in functions to identify potential opportunities for using ambient context. This is an investigation tool that flags instances for human review, not a prescriptive analyzer.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill contextvar-opportunity-finder --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going