Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Doc2AHP

Turning academic decision theory into a practical tool for developers

中文

Doc2AHP is a Claude Code Skill that brings structured multi-criteria decision analysis to software engineering, based on the principles from the paper "Doc2AHP: Inferring Structured Multi-Criteria Decision Models via Semantic Trees with LLMs".

The Problem

Tech stack selection, architecture decisions, library comparisons — these decisions often:

  • Involve multiple conflicting evaluation dimensions
  • Rely on gut feeling rather than systematic analysis
  • Lack traceable decision records

Doc2AHP uses the AHP (Analytic Hierarchy Process) framework to transform vague "feelings" into quantifiable, traceable, structured decisions.

Two Input Modes

Doc2AHP supports two ways to begin a decision analysis:

  • Mode A: Document-Grounded — Extract criteria from actual documents (requirements docs, tech specs, web search results) with full source traceability. Faithful to the paper's "Doc → AHP" pipeline. See example
  • Mode B: Quick Analysis — Generate criteria from LLM domain knowledge for rapid exploration. Faster, but less traceable.

Quick Start

Installation

Copy the skill/doc2ahp-decision/ directory into your project's .claude/skills/:

# In your project root
mkdir -p .claude/skills
cp -r path/to/doc2ahp/skill/doc2ahp-decision .claude/skills/

Usage

Describe your decision scenario in Claude Code. The skill will guide you through the decision process:

  1. Input Mode Selection — Choose Document-Grounded or Quick Analysis mode
  2. Framework Construction — Define goal, extract criteria, build hierarchy
  3. Multi-Perspective Evaluation — Evaluate from technical, business, ops perspectives
  4. Consensus Aggregation — Merge perspectives into consensus weights
  5. Consistency Check — Ensure logical consistency of judgments
  6. Alternative Scoring — Weighted scoring to produce rankings
  7. Decision Report — Structured, archivable report output

Examples

Featured (polished, verified calculations)

Scenario Key AHP Concept File
AI Foundation Model API Selection Multi-perspective disagreement & consensus examples/ai-model-selection.md
Programming Language for Trading System Leader Agent constraint & sensitivity analysis examples/language-holy-war.md
Senior Developer Career Path AHP beyond technology (inner-voice perspectives) examples/career-path-decision.md
Microservices vs Monolith Architecture Leader Agent priority constraint examples/architecture-decision.md
Cloud Provider Selection (Document-Grounded) Doc-grounded criteria extraction (Mode A) examples/doc-grounded-cloud-selection.md
JS Runtime Selection (Real Data) Full calculation with real benchmark data examples/js-runtime-selection/

More examples

Scenario File
Frontend Framework Selection examples/more/tech-stack-selection.md
State Management Library Comparison examples/more/library-comparison.md
Database for Social App at Scale examples/more/database-selection.md
AI Coding Assistant Showdown examples/more/coding-assistant-showdown.md

Core Principles

  • Zero Dependencies: Pure Skill approach — the LLM itself is the AHP computation engine
  • Cognitive Constraints: Max 7 criteria per level, max 3 depth levels (Miller's Law)
  • Multi-Perspective Evaluation: Simulates the paper's multi-agent mechanism to reduce single-viewpoint bias
  • Consistency Verification: Transitivity checks ensure logical coherence

Project Structure

doc2ahp/
├── skill/doc2ahp-decision/   # Claude Code Skill (core)
├── docs/methodology.md        # Detailed methodology
├── paper/PAPER_SUMMARY.md     # Paper summary
└── examples/                  # Usage examples

When to Use

Good fit: 3+ alternatives, multi-dimensional trade-offs, architecture-level decisions, need to explain rationale to team

Not ideal: Simple A/B choices, single-dimension decisions, urgent decisions

Learn More

Citation

If the skill / methodology / examples in this project help your work, please cite the original paper:

@article{Wu2026Doc2AHP,
    author    = {Hongjia Wu and Shuai Zhou and Hongxin Zhang and Wei Chen},
    title     = {Doc2AHP: Inferring Structured Multi-Criteria Decision Models via Semantic Trees with LLMs},
    journal   = {arXiv preprint arXiv:2601.16479},
    year      = {2026},
    doi       = {10.48550/arXiv.2601.16479}
}

License

MIT

About

Doc2AHP: A Claude Code Skill for structured multi-criteria decision analysis using AHP methodology

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors