feat(A1.7): Add install_skill MCP tool for one-command workflow automation

Implements complete end-to-end skill installation in a single command:
fetch_config → scrape_docs → enhance_skill_local → package_skill → upload_skill

Changes:
- MCP Tool: Added install_skill_tool() to server.py (~300 lines)
  - Input validation (config_name XOR config_path)
  - 5-phase orchestration with error handling
  - Dry-run mode for workflow preview
  - Mandatory AI enhancement (30-60 sec, 3/10→9/10 quality boost)
  - Auto-upload to Claude (if ANTHROPIC_API_KEY set)

- CLI Integration: New install command
  - Created install_skill.py CLI wrapper (~150 lines)
  - Updated main.py with install subcommand
  - Added entry point to pyproject.toml

- Testing: Comprehensive test suite
  - Created test_install_skill.py with 13 tests
  - Tests cover validation, dry-run, orchestration, error handling
  - All tests passing (13/13)

- Documentation: Updated all user-facing docs
  - CLAUDE.md: Added MCP tool (10 tools total) and CLI examples
  - README.md: Added prominent one-command workflow section
  - FLEXIBLE_ROADMAP.md: Marked A1.7 as complete

Features:
- Zero friction: One command instead of 5 separate steps
- Quality guaranteed: Mandatory enhancement ensures 9/10 quality
- Complete automation: From config to uploaded skill
- Intelligent: Auto-detects config type (name vs path)
- Flexible: Dry-run, unlimited, no-upload modes
- Well-tested: 13 unit tests with mocking

Usage:
  skill-seekers install --config react
  skill-seekers install --config configs/custom.json --no-upload
  skill-seekers install --config django --unlimited
  skill-seekers install --config react --dry-run

Closes #204

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
yusyus
2025-12-21 20:17:59 +03:00
parent 0c02ac7344
commit b7cd317efb
8 changed files with 1067 additions and 3 deletions

View File

@@ -187,6 +187,73 @@ python3 src/skill_seekers/cli/doc_scraper.py --config configs/react.json
**Time:** ~25 minutes | **Quality:** Production-ready | **Cost:** Free
---
## 🚀 **NEW!** One-Command Install Workflow (v2.1.1)
**The fastest way to go from config to uploaded skill - complete automation:**
```bash
# Install React skill from official configs (auto-uploads to Claude)
skill-seekers install --config react
# Install from local config file
skill-seekers install --config configs/custom.json
# Install without uploading (package only)
skill-seekers install --config django --no-upload
# Unlimited scraping (no page limits)
skill-seekers install --config godot --unlimited
# Preview workflow without executing
skill-seekers install --config react --dry-run
```
**Time:** 20-45 minutes total | **Quality:** Production-ready (9/10) | **Cost:** Free
### What it does automatically:
1.**Fetches config** from API (if config name provided)
2.**Scrapes documentation** (respects rate limits, handles pagination)
3.**AI Enhancement (MANDATORY)** - 30-60 sec, quality boost from 3/10 → 9/10
4.**Packages skill** to .zip file
5.**Uploads to Claude** (if ANTHROPIC_API_KEY set)
### Why use this?
- **Zero friction** - One command instead of 5 separate steps
- **Quality guaranteed** - Enhancement is mandatory, ensures professional output
- **Complete automation** - From config name to uploaded skill in Claude
- **Time savings** - Fully automated end-to-end workflow
### Phases executed:
```
📥 PHASE 1: Fetch Config (if config name provided)
📖 PHASE 2: Scrape Documentation
✨ PHASE 3: AI Enhancement (MANDATORY - no skip option)
📦 PHASE 4: Package Skill
☁️ PHASE 5: Upload to Claude (optional, requires API key)
```
**Requirements:**
- ANTHROPIC_API_KEY environment variable (for auto-upload)
- Claude Code Max plan (for local AI enhancement)
**Example:**
```bash
# Set API key once
export ANTHROPIC_API_KEY=sk-ant-your-key-here
# Run one command - sit back and relax!
skill-seekers install --config react
# Result: React skill uploaded to Claude in 20-45 minutes
```
---
## Usage Examples
### Documentation Scraping