Agent skill

Find Shortest Dictionary Key Combination Covering Target Set

Generates optimized Python code to find the minimum number of keys from a dictionary where the union of their values matches a target set, prioritizing performance and avoiding recursion errors.

ECNU-ICALKgithub.com/ECNU-ICALKGitHub ↗
claude-code
Install
npx skills add ECNU-ICALK/AutoSkill --skill find-shortest-dictionary-key-combination-covering-target-set --agent claude-code

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

Facts
Files in the skill folder: 1
SKILL.md size: 2 KB
Bundled scripts: none
Version: 0.1.0
Path: SkillBank/ConvSkill/english_gpt3.5_8/find-shortest-dictionary-key-combination-covering-target-set/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 539
Language: Python

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

From the SKILL.md

# Find Shortest Dictionary Key Combination Covering Target Set Generates optimized Python code to find the minimum number of keys from a dictionary where the union of their values matches a target set, prioritizing performance and avoiding recursion errors. ## Prompt # Role & Objective You are a Python optimization specialist. Your task is to write code that finds the shortest combination of keys from a dictionary such that the union of the values associated with those keys equals a specific target set. # Operational Rules & Constraints 1. Input format: A dictionary where keys map to lists of items (e.g., `{1: [1], 2: [2, 3]}`) and a target set (e.g., `{1, 2, 3, 4}`). 2. Output format: Print or return the keys of the shortest valid combination. 3. Performance: The solution must be optimized for performance to handle large inputs (e.g., dictionaries with hundreds of keys and targets with hundreds of items) without hitting recursion depth limits or excessive iteration times. 4. Avoid brute-force `itertools.combinations` for large inputs. 5. Ensure the code handles the data types correctly (e.g., converting lists to sets for union operations). # Anti-Patterns Do not use simple recursi

What's inside
Steps it walks through
  1. Prompt
  2. Triggers
More from AutoSkill
All skills →
About this skill
What does the Find Shortest Dictionary Key Combination Covering Target Set skill do?

Generates optimized Python code to find the minimum number of keys from a dictionary where the union of their values matches a target set, prioritizing performance and avoiding recursion errors.

How do I install it?

Run `npx skills add ECNU-ICALK/AutoSkill --skill find-shortest-dictionary-key-combination-covering-target-set --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 ECNU-ICALK/AutoSkill, a repository with 539 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