algorithm-design

Model problems and select algorithms with correctness arguments and tradeoffs.

7|Updated Feb 14, 2026
One-click install
npx skills add https://github.com/KentoShimizu/sw-agent-skills --skill algorithm-design-kentoshimizu
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: algorithm-design
Source: https://github.com/KentoShimizu/sw-agent-skills/tree/main/skills/algorithm-design
Command: npx skills add https://github.com/KentoShimizu/sw-agent-skills --skill algorithm-design-kentoshimizu

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Design algorithms by modeling constraints, enumerating candidate strategies, proving correctness, and selecting data structures with explicit tradeoffs. Use when implementation success depends on algorithm choice or decomposition under unclear constraints, from vague outcome requests to concrete directives; do not use for persistence schema or deployment topology decisions.

Core Features & Use Cases

  • Formal problem modeling and invariant reasoning to drive algorithm selection.
  • Comparative evaluation of candidate strategies with explicit tradeoffs and risk analysis.
  • Deliverable rationale including chosen data structures, correctness arguments, and verification plans.

Quick Start

Provide an implementable algorithm decision with explicit correctness reasoning and tradeoffs for a given problem.

Frequently Asked Questions about algorithm-design

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

FAQPage Schema
How do I design an algorithm with explicit correctness reasoning and tradeoffs?

To design an algorithm with correctness reasoning, formalize problem constraints, enumerate candidate strategies, and select data structures while documenting invariants and tradeoffs. This approach ensures chosen strategies are backed by proof sketches and test plans.

What is the best way to choose data structures under uncertain constraints?

Choosing data structures under uncertain constraints requires comparative evaluation of candidate strategies with explicit tradeoff and risk analysis. You select the optimal structure by formalizing the problem model and applying invariant reasoning to meet outcome requirements.

When do I need formal problem modeling for algorithm selection?

You need formal problem modeling for algorithm selection when implementation success depends on algorithm choice under unclear constraints. It applies to tasks requiring explicit assumptions, invariant reasoning, and documented edge cases for vague outcome requests.

How do I prove algorithm correctness and document edge cases?

To prove algorithm correctness, apply invariant reasoning to the selected approach and generate proof sketches. Document edge cases during problem modeling to ensure the final deliverable includes a formal rationale and a verification plan.

Can I use this approach for persistence schema or deployment topology decisions?

No, this approach is not suitable for persistence schema or deployment topology decisions. It specifically targets algorithm choice, data-structure decisions, and decomposition under unclear constraints, providing tradeoff analysis and correctness arguments.

Does algorithm design require explicit assumptions for vague outcome requests?

Yes, algorithm design for vague outcome requests requires explicit assumptions to drive data-structure decisions. Formalizing these assumptions allows for comparative evaluation of candidate strategies and ensures documented invariant reasoning.