[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M70FNY150TATDQ3MG3NM246S":3,"skill-same:01M70FNY150TATDQ3MG3NM246S":271},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":39,"linkOnly":40,"markdownContent":41,"markdownBody":42,"frontMatter":43,"refName":44,"commitSha":45,"skillDirectory":46,"forksCount":47,"repositoryHtmlUrl":48,"repositoryHomepageUrl":49,"ownerHtmlUrl":50,"ownerBlogUrl":51,"ownerDescription":52,"updatedAt":53,"install":54,"resources":67},"01M70FNY150TATDQ3MG3NM246S","agent-skill-creator",null,"This enhanced skill should be used when the user asks to create an agent, automate a repetitive workflow, create a custom skill, or needs advanced agent creation capabilities. Activates with phrases like every day, daily I have to, I need to repeat, create agent for, automate workflow, create skill for, need to automate, turn process into agent. Supports single agents, multi-agent suites, transcript processing, template-based creation, and interactive configuration. Claude will use the enhanced protocol to research APIs, define analyses, structure everything, implement functional code, and create complete skills autonomously with optional user guidance.","shengdabai\u002FTony-Claude-Code-Skills","shengdabai","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F116417419?v=4","01M70F6D2WY5PQV5A92BKYJQEW","Tony Sheng","01M70F6D3GAAAYZ5H4CC1G8VXM",3,"MIT","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],"agent skill","agent skill creator","creator","skill creator","user","protocol","guidance","research","implement","interactive","custom skill","use","custom","for","multi-agent","functional","structure","create","transcript","capabilities","2026-11-10 10:12:30",false,"---\nname: agent-skill-creator\ndescription: This enhanced skill should be used when the user asks to create an agent, automate a repetitive workflow, create a custom skill, or needs advanced agent creation capabilities. Activates with phrases like every day, daily I have to, I need to repeat, create agent for, automate workflow, create skill for, need to automate, turn process into agent. Supports single agents, multi-agent suites, transcript processing, template-based creation, and interactive configuration. Claude will use the enhanced protocol to research APIs, define analyses, structure everything, implement functional code, and create complete skills autonomously with optional user guidance.\n---\n# Agent Creator - Meta-Skill\n\nThis skill teaches Claude Code how to autonomously create complete agents with Claude Skills.\n\n## When to Use This Skill\n\nClaude should automatically activate this skill when the user:\n\n✅ **Asks to create an agent**\n\n- \"Create an agent for [objective]\"\n- \"I need an agent that [description]\"\n- \"Develop an agent to automate [workflow]\"\n\n✅ **Asks to automate a workflow**\n\n- \"Automate this process: [description]\"\n- \"Every day I do [repetitive task], automate this\"\n- \"Turn this workflow into an agent\"\n\n✅ **Asks to create a skill**\n\n- \"Create a skill for [objective]\"\n- \"Develop a custom skill for [domain]\"\n\n✅ **Describes a repetitive process**\n\n- \"Every day I [process]... takes Xh\"\n- \"I repeatedly need to [task]\"\n- \"Manual workflow: [description]\"\n\n## Overview\n\nWhen activated, this skill guides Claude through **5 autonomous phases** to create a complete production-ready agent:\n\n```\nPHASE 1: DISCOVERY\n├─ Research available APIs\n├─ Compare options\n└─ DECIDE which to use (with justification)\n\nPHASE 2: DESIGN\n├─ Think about use cases\n├─ DEFINE useful analyses\n└─ Specify methodologies\n\nPHASE 3: ARCHITECTURE\n├─ STRUCTURE folders and files\n├─ Define necessary scripts\n└─ Plan caching and performance\n\nPHASE 4: DETECTION\n├─ DETERMINE keywords\n└─ Create precise description\n\nPHASE 5: IMPLEMENTATION\n├─ 🚨 FIRST: Create marketplace.json (MANDATORY!)\n├─ Create SKILL.md (5000+ words)\n├─ Implement Python scripts (functional!)\n├─ Write references (useful!)\n├─ Generate configs (real!)\n├─ Create README\n└─ ✅ FINAL: Test installation\n```\n\n**Output**: Complete agent in subdirectory ready to install.\n\n---\n\n## 🏗️ **Claude Skills Architecture: Understanding What We Create**\n\n### **Important Terminology Clarification**\n\nThis meta-skill creates **Claude Skills**, which come in different architectural patterns:\n\n#### **📋 Skill Types We Can Create**\n\n**1. Simple Skill** (Single focused capability)\n```\nskill-name\u002F\n├── SKILL.md              ← Single comprehensive skill file\n├── scripts\u002F              ← Optional supporting code\n├── references\u002F           ← Optional documentation\n└── assets\u002F               ← Optional templates\n```\n*Use when: Single objective, simple workflow, \u003C1000 lines code*\n\n**2. Complex Skill Suite** (Multiple specialized capabilities)\n```\nskill-suite\u002F\n├── .claude-plugin\u002F\n│   └── marketplace.json  ← Organizes multiple component skills\n├── component-1\u002F\n│   └── SKILL.md          ← Specialized sub-skill\n├── component-2\u002F\n│   └── SKILL.md          ← Another specialized sub-skill\n└── shared\u002F               ← Shared resources\n```\n*Use when: Multiple related workflows, >2000 lines code, team maintenance*\n\n#### **🎯 Architecture Decision Process**\n\nDuring **PHASE 3: ARCHITECTURE**, this skill will:\n\n1. **Analyze Complexity Requirements**\n   - Number of distinct workflows\n   - Code complexity estimation\n   - Maintenance considerations\n\n2. **Choose Appropriate Architecture**\n   - Simple task → Simple Skill\n   - Complex multi-domain task → Skill Suite\n   - Hybrid requirements → Simple skill with components\n\n3. **Apply Naming Convention**\n   - Generate descriptive base name from requirements\n   - Add \"-cskill\" suffix to identify as Claude Skill created by Agent-Skill-Creator\n   - Ensure consistent, professional naming across all created skills\n\n4. **Document the Decision**\n   - Create `DECISIONS.md` explaining architecture choice\n   - Provide rationale for selected pattern\n   - Include migration path if needed\n   - Document naming convention applied\n\n#### **🏷️ Naming Convention: \"-cskill\" Suffix**\n\n**All skills created by this Agent-Skill-Creator use the \"-cskill\" suffix:**\n\n**Simple Skills:**\n- `pdf-text-extractor-cskill\u002F`\n- `csv-data-cleaner-cskill\u002F`\n- `weekly-report-generator-cskill\u002F`\n\n**Complex Skill Suites:**\n- `financial-analysis-suite-cskill\u002F`\n- `e-commerce-automation-cskill\u002F`\n- `research-workflow-cskill\u002F`\n\n**Component Skills (within suites):**\n- `data-acquisition-cskill\u002F`\n- `technical-analysis-cskill\u002F`\n- `reporting-generator-cskill\u002F`\n\n**Purpose of \"-cskill\" suffix:**\n- ✅ **Clear Identification**: Immediately recognizable as a Claude Skill\n- ✅ **Origin Attribution**: Created by Agent-Skill-Creator\n- ✅ **Consistent Convention**: Professional naming standard\n- ✅ **Avoids Confusion**: Distinguishes from manually created skills\n- ✅ **Easy Organization**: Simple to identify and group created skills\n\n#### **📚 Reference Documentation**\n\nFor complete understanding of Claude Skills architecture, see:\n- `docs\u002FCLAUDE_SKILLS_ARCHITECTURE.md` (comprehensive guide)\n- `docs\u002FDECISION_LOGIC.md` (architecture decision framework)\n- `examples\u002F` (simple vs complex examples)\n- `examples\u002Fsimple-skill\u002F` (minimal example)\n- `examples\u002Fcomplex-skill-suite\u002F` (comprehensive example)\n\n#### **✅ What We Create**\n\n**ALWAYS creates a valid Claude Skill** - either:\n- **Simple Skill** (single SKILL.md)\n- **Complex Skill Suite** (multiple component skills with marketplace.json)\n\n**NEVER creates \"plugins\" in the traditional sense** - we create Skills, which may be organized using marketplace.json for complex suites.\n\nThis terminology consistency eliminates confusion between Skills and Plugins.\n\n---\n\n## 🧠 Invisible Intelligence: AgentDB Integration\n\n### Enhanced Intelligence (v2.1)\n\nThis skill now includes **invisible AgentDB integration** that learns from every agent creation and provides progressively smarter assistance.\n\n**What happens automatically:**\n- 🧠 **Learning Memory**: Stores every creation attempt as episodes\n- ⚡ **Progressive Enhancement**: Each creation becomes faster and more accurate\n- 🎯 **Smart Validation**: Mathematical proofs for all decisions\n- 🔄 **Graceful Operation**: Works perfectly with or without AgentDB\n\n**User Experience**: Same simple commands, agents get smarter magically!\n\n### Integration Points\n\nThe AgentDB integration is woven into the 5 phases:\n\n```\nPHASE 1: DISCOVERY\n├─ Research APIs\n├─ 🧠 Query AgentDB for similar past successes\n├─ Compare options using learned patterns\n└─ DECIDE with historical confidence\n\nPHASE 2: DESIGN\n├─ Think about use cases\n├─ 🧠 Retrieve successful analysis patterns\n├─ DEFINE using proven methodologies\n└─ Enhance with learned improvements\n\nPHASE 3: ARCHITECTURE\n├─ STRUCTURE using validated patterns\n├─ 🧠 Apply proven architectural decisions\n├─ Plan based on success history\n└─ Optimize with learned insights\n\nPHASE 4: DETECTION\n├─ DETERMINE keywords using learned patterns\n├─ 🧠 Use successful keyword combinations\n└─ Create optimized description\n\nPHASE 5: IMPLEMENTATION\n├─ Create marketplace.json\n├─ 🧠 Apply proven code patterns\n├─ Store episode for future learning\n└─ ✅ Complete with enhanced validation\n```\n\n### Learning Progression\n\n**First Creation:**\n```\n\"Create financial analysis agent\"\n→ Standard agent creation process\n→ Episode stored for learning\n→ No visible difference to user\n```\n\n**After 10+ Creations:**\n```\n\"Create financial analysis agent\"\n→ 40% faster (learned optimal queries)\n→ Better API selection (historical success)\n→ Proven architectural patterns\n→ User sees: \"⚡ Optimized based on similar successful agents\"\n```\n\n**After 30+ Days:**\n```\n\"Create financial analysis agent\"\n→ Personalized recommendations based on patterns\n→ Predictive insights about user preferences\n→ Automatic skill consolidation\n→ User sees: \"🌟 I notice you prefer comprehensive financial agents - shall I include portfolio optimization?\"\n```\n\n---\n\n## 🚀 Enhanced Features (v2.0)\n\n### Multi-Agent Architecture\n\nThe enhanced agent-creator now supports:\n\n**✅ Single Agent Creation** (Original functionality)\n```\n\"Create an agent for stock analysis\"\n→ .\u002Fstock-analysis-agent\u002F\n```\n\n**✅ Multi-Agent Suite Creation** (NEW)\n```\n\"Create a financial analysis suite with 4 agents:\nfundamental analysis, technical analysis,\nportfolio management, and risk assessment\"\n→ .\u002Ffinancial-suite\u002F\n  ├── fundamental-analysis\u002F\n  ├── technical-analysis\u002F\n  ├── portfolio-management\u002F\n  └── risk-assessment\u002F\n```\n\n**✅ Transcript Intelligence Processing** (NEW)\n```\n\"I have a YouTube transcript about e-commerce analytics,\ncan you create agents based on the workflows described?\"\n→ Automatically extracts multiple workflows\n→ Creates integrated agent suite\n```\n\n**✅ Template-Based Creation** (NEW)\n```\n\"Create an agent using the financial-analysis template\"\n→ Uses pre-configured APIs and analyses\n→ 80% faster creation\n```\n\n**✅ Interactive Configuration** (NEW)\n```\n\"Help me create an agent with preview options\"\n→ Step-by-step wizard\n→ Real-time preview\n→ Iterative refinement\n```\n\n### Enhanced Marketplace.json Support\n\n**v1.0 Format** (Still supported):\n```json\n{\n  \"name\": \"single-agent\",\n  \"plugins\": [\n    {\n      \"skills\": [\".\u002F\"]\n    }\n  ]\n}\n```\n\n**v2.0 Format** (NEW - Multi-skill support):\n```json\n{\n  \"name\": \"agent-suite\",\n  \"plugins\": [\n    {\n      \"name\": \"fundamental-analysis\",\n      \"source\": \".\u002Ffundamental-analysis\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    },\n    {\n      \"name\": \"technical-analysis\",\n      \"source\": \".\u002Ftechnical-analysis\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    }\n  ]\n}\n```\n\n---\n\n## Autonomous Creation Protocol\n\n### Fundamental Principles\n\n**Autonomy**:\n\n- ✅ Claude DECIDES which API to use (doesn't ask user)\n- ✅ Claude DEFINES which analyses to perform (based on value)\n- ✅ Claude STRUCTURES optimally (best practices)\n- ✅ Claude IMPLEMENTS complete code (no placeholders)\n- ✅ **NEW**: Claude LEARNS from experience (AgentDB integration)\n\n**Quality**:\n\n- ✅ Production-ready code (no TODOs)\n- ✅ Useful documentation (not \"see docs\")\n- ✅ Real configs (no placeholders)\n- ✅ Robust error handling\n- ✅ **NEW**: Intelligence validated with mathematical proofs\n\n**Completeness**:\n\n- ✅ Complete SKILL.md (5000+ words)\n- ✅ Functional scripts (1000+ lines total)\n- ✅ References with content (3000+ words)\n- ✅ Valid assets\u002Fconfigs\n- ✅ README with instructions\n\n### Requirements Extraction\n\nWhen user describes workflow vaguely, extract:\n\n**From what the user said**:\n\n- Domain (agriculture? finance? weather?)\n- Data source (mentioned? if not, research)\n- Main tasks (download? analyze? compare?)\n- Frequency (daily? weekly? on-demand?)\n- Current time spent (to calculate ROI)\n\n**🆕 Enhanced Analysis (v2.0)**:\n\n- **Multi-Agent Detection**: Look for keywords like \"suite\", \"multiple\", \"separate agents\"\n- **Transcript Analysis**: Detect if input is a video\u002Ftranscript requiring workflow extraction\n- **Template Matching**: Identify if user wants template-based creation\n- **Interactive Preference**: Detect if user wants guidance vs full autonomy\n- **Integration Needs**: Determine if agents should communicate with each other\n\n**🆕 Transcript Processing**:\n\nWhen user provides transcripts:\n```python\n# Enhanced transcript analysis\ndef analyze_transcript(transcript: str) -> List[WorkflowSpec]:\n    \"\"\"Extract multiple workflows from transcripts automatically\"\"\"\n    workflows = []\n\n    # 1. Identify distinct processes\n    processes = extract_processes(transcript)\n\n    # 2. Group related steps\n    for process in processes:\n        steps = extract_sequence_steps(transcript, process)\n        apis = extract_mentioned_apis(transcript, process)\n        outputs = extract_desired_outputs(transcript, process)\n\n        workflows.append(WorkflowSpec(\n            name=process,\n            steps=steps,\n            apis=apis,\n            outputs=outputs\n        ))\n\n    return workflows\n```\n\n**🆕 Multi-Agent Strategy Decision**:\n\n```python\ndef determine_creation_strategy(user_input: str, workflows: List[WorkflowSpec]) -> CreationStrategy:\n    \"\"\"Decide whether to create single agent, suite, or integrated system\"\"\"\n\n    if len(workflows) > 1:\n        if workflows_are_related(workflows):\n            return CreationStrategy.INTEGRATED_SUITE\n        else:\n            return CreationStrategy.MULTI_AGENT_SUITE\n    else:\n        return CreationStrategy.SINGLE_AGENT\n```\n\n**Questions to ask** (only if critical and not inferable):\n\n- \"Prefer free API or paid is ok?\"\n- \"Need historical data for how many years?\"\n- \"Focus on which geography\u002Fcountry?\"\n- **🆕 \"Create separate agents or integrated suite?\"** (if multiple workflows detected)\n- **🆕 \"Want interactive preview before creation?\"** (for complex projects)\n\n**Rule**: Minimize questions. Infer\u002Fdecide whenever possible.\n\n## 🎯 Template-Based Creation (NEW v2.0)\n\n### Available Templates\n\nThe enhanced agent-creator includes pre-built templates for common domains:\n\n**📊 Financial Analysis Template**\n```json\nDomain: Finance & Investments\nAPIs: Alpha Vantage, Yahoo Finance\nAnalyses: Fundamental, Technical, Portfolio\nTime: 15-20 minutes\n```\n\n**🌡️ Climate Analysis Template**\n```json\nDomain: Climate & Environmental\nAPIs: Open-Meteo, NOAA\nAnalyses: Anomalies, Trends, Seasonal\nTime: 20-25 minutes\n```\n\n**🛒 E-commerce Analytics Template**\n```json\nDomain: Business & E-commerce\nAPIs: Google Analytics, Stripe, Shopify\nAnalyses: Traffic, Revenue, Cohort, Products\nTime: 25-30 minutes\n```\n\n### Template Matching Process\n\n```python\ndef match_template(user_input: str) -> TemplateMatch:\n    \"\"\"Automatically suggest best template based on user input\"\"\"\n\n    # 1. Extract keywords from user input\n    keywords = extract_keywords(user_input)\n\n    # 2. Calculate similarity scores with all templates\n    matches = []\n    for template in available_templates:\n        score = calculate_similarity(keywords, template.keywords)\n        matches.append((template, score))\n\n    # 3. Rank by similarity\n    matches.sort(key=lambda x: x[1], reverse=True)\n\n    # 4. Return best match if confidence > threshold\n    if matches[0][1] > 0.7:\n        return TemplateMatch(template=matches[0][0], confidence=matches[0][1])\n    else:\n        return None  # No suitable template found\n```\n\n### Template Usage Examples\n\n**Direct Template Request:**\n```\n\"Create an agent using the financial-analysis template\"\n→ Uses pre-configured structure\n→ 80% faster creation\n→ Proven architecture\n```\n\n**Automatic Template Detection:**\n```\n\"I need to analyze stock performance and calculate RSI, MACD\"\n→ Detects financial domain\n→ Suggests financial-analysis template\n→ User confirms or continues custom\n```\n\n**Template Customization:**\n```\n\"Use the climate template but add drought analysis\"\n→ Starts with climate template\n→ Adds custom drought analysis\n→ Modifies structure accordingly\n```\n\n## 🚀 Batch Agent Creation (NEW v2.0)\n\n### Multi-Agent Suite Creation\n\nThe enhanced agent-creator can create multiple agents in a single operation:\n\n**When to Use Batch Creation:**\n- Transcript describes multiple distinct workflows\n- User explicitly asks for multiple agents\n- Complex system requiring specialized components\n- Microservices architecture preferred\n\n### Batch Creation Process\n\n```python\ndef create_agent_suite(user_input: str, workflows: List[WorkflowSpec]) -> AgentSuite:\n    \"\"\"Create multiple related agents in one operation\"\"\"\n\n    # 1. Analyze workflow relationships\n    relationships = analyze_workflow_relationships(workflows)\n\n    # 2. Determine optimal structure\n    if workflows_are_tightly_coupled(workflows):\n        structure = \"integrated_suite\"\n    else:\n        structure = \"independent_agents\"\n\n    # 3. Create suite directory\n    suite_name = generate_suite_name(user_input)\n    create_suite_directory(suite_name)\n\n    # 4. Create each agent\n    agents = []\n    for workflow in workflows:\n        agent = create_single_agent(workflow, suite_name)\n        agents.append(agent)\n\n    # 5. Create integration layer (if needed)\n    if structure == \"integrated_suite\":\n        create_integration_layer(agents, suite_name)\n\n    # 6. Create suite-level marketplace.json\n    create_suite_marketplace_json(suite_name, agents)\n\n    return AgentSuite(name=suite_name, agents=agents, structure=structure)\n```\n\n### Batch Creation Examples\n\n**Financial Suite Example:**\n```\n\"Create a complete financial analysis system with 4 agents:\n1. Fundamental analysis for company valuation\n2. Technical analysis for trading signals\n3. Portfolio management and optimization\n4. Risk assessment and compliance\"\n\n→ .\u002Ffinancial-analysis-suite\u002F\n  ├── .claude-plugin\u002Fmarketplace.json (multi-skill)\n  ├── fundamental-analysis\u002F\n  │   ├── SKILL.md\n  │   ├── scripts\u002F\n  │   └── tests\u002F\n  ├── technical-analysis\u002F\n  ├── portfolio-management\u002F\n  └── risk-assessment\u002F\n```\n\n**E-commerce Suite Example:**\n```\n\"Build an e-commerce analytics system based on this transcript:\n- Traffic analysis from Google Analytics\n- Revenue tracking from Stripe\n- Product performance from Shopify\n- Customer cohort analysis\n- Automated reporting dashboard\"\n\n→ .\u002Fe-commerce-analytics-suite\u002F\n  ├── traffic-analysis-agent\u002F\n  ├── revenue-tracking-agent\u002F\n  ├── product-performance-agent\u002F\n  ├── cohort-analysis-agent\u002F\n  └── reporting-dashboard-agent\u002F\n```\n\n### Multi-Skill Marketplace.json Structure\n\n**Suite-Level Configuration:**\n```json\n{\n  \"name\": \"financial-analysis-suite\",\n  \"metadata\": {\n    \"description\": \"Complete financial analysis system with fundamental, technical, portfolio, and risk analysis\",\n    \"version\": \"1.0.0\",\n    \"suite_type\": \"financial_analysis\"\n  },\n  \"plugins\": [\n    {\n      \"name\": \"fundamental-analysis-plugin\",\n      \"description\": \"Fundamental analysis for company valuation and financial metrics\",\n      \"source\": \".\u002Ffundamental-analysis\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    },\n    {\n      \"name\": \"technical-analysis-plugin\",\n      \"description\": \"Technical analysis with trading indicators and signals\",\n      \"source\": \".\u002Ftechnical-analysis\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    },\n    {\n      \"name\": \"portfolio-management-plugin\",\n      \"description\": \"Portfolio optimization and management analytics\",\n      \"source\": \".\u002Fportfolio-management\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    },\n    {\n      \"name\": \"risk-assessment-plugin\",\n      \"description\": \"Risk analysis and compliance monitoring\",\n      \"source\": \".\u002Frisk-assessment\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    }\n  ],\n  \"integrations\": {\n    \"data_sharing\": true,\n    \"cross_agent_communication\": true,\n    \"shared_utils\": \".\u002Fshared\u002F\"\n  }\n}\n```\n\n### Batch Creation Benefits\n\n**✅ Time Efficiency:**\n- Create 4 agents in ~60 minutes (vs 4 hours individually)\n- Shared utilities and infrastructure\n- Consistent architecture and documentation\n\n**✅ Integration Benefits:**\n- Agents designed to work together\n- Shared data structures and formats\n- Unified testing and deployment\n\n**✅ Maintenance Benefits:**\n- Single marketplace.json for installation\n- Coordinated versioning and updates\n- Shared troubleshooting documentation\n\n### Batch Creation Commands\n\n**Explicit Multi-Agent Request:**\n```\n\"Create 3 agents for climate analysis:\n1. Temperature anomaly detection\n2. Precipitation pattern analysis\n3. Extreme weather event tracking\n\nMake them work together as a system.\"\n```\n\n**Transcript-Based Batch Creation:**\n```\n\"Here's a transcript of a 2-hour tutorial on building\na complete business intelligence system. Create agents\nfor all the workflows described in the video.\"\n```\n\n**Template-Based Batch Creation:**\n```\n\"Use the e-commerce template to create a full analytics suite:\n- Traffic analysis\n- Revenue tracking\n- Customer analytics\n- Product performance\n- Marketing attribution\"\n```\n\n## 🎮 Interactive Configuration Wizard (NEW v2.0)\n\n### When to Use Interactive Mode\n\nThe enhanced agent-creator includes an interactive wizard for:\n\n- **Complex Projects**: Multi-agent systems, integrations\n- **User Preference**: When users want guidance vs full autonomy\n- **High-Stakes Projects**: When preview and iteration are important\n- **Learning**: Users who want to understand the creation process\n\n### Interactive Wizard Process\n\n```python\ndef interactive_agent_creation():\n    \"\"\"\n    Step-by-step guided agent creation with real-time preview\n    \"\"\"\n\n    # Step 1: Welcome and Requirements Gathering\n    print(\"🚀 Welcome to Enhanced Agent Creator!\")\n    print(\"I'll help you create custom agents through an interactive process.\")\n\n    user_needs = gather_requirements_interactively()\n\n    # Step 2: Workflow Analysis\n    print(\"\\n📋 Analyzing your requirements...\")\n    workflows = analyze_and_confirm_workflows(user_needs)\n\n    # Step 3: Strategy Selection\n    strategy = select_creation_strategy(workflows)\n    print(f\"🎯 Recommended: {strategy.description}\")\n\n    # Step 4: Preview and Refinement\n    while True:\n        preview = generate_interactive_preview(strategy)\n        show_preview(preview)\n\n        if user_approves():\n            break\n        else:\n            strategy = refine_based_on_feedback(strategy, preview)\n\n    # Step 5: Creation\n    print(\"\\n⚙️ Creating your agent(s)...\")\n    result = execute_creation(strategy)\n\n    # Step 6: Validation and Tutorial\n    validate_created_agents(result)\n    provide_usage_tutorial(result)\n\n    return result\n```\n\n### Interactive Interface Examples\n\n**Step 1: Requirements Gathering**\n```\n🚀 Welcome to Enhanced Agent Creator!\n\nLet me understand what you want to build:\n\n1. What's your main goal?\n   [ ] Automate a repetitive workflow\n   [ ] Analyze data from specific sources\n   [ ] Create custom tools for my domain\n   [ ] Build a complete system with multiple components\n\n2. What's your domain\u002Findustry?\n   [ ] Finance & Investing\n   [ ] E-commerce & Business\n   [ ] Climate & Environment\n   [ ] Healthcare & Medicine\n   [ ] Other (please specify): _______\n\n3. Do you have existing materials?\n   [ ] YouTube transcript or video\n   [ ] Documentation or tutorials\n   [ ] Existing code\u002Fscripts\n   [ ] Starting from scratch\n\nYour responses: [Finance & Investing] [Starting from scratch]\n```\n\n**Step 2: Workflow Analysis**\n```\n📋 Based on your input, I detect:\n\nDomain: Finance & Investing\nPotential Workflows:\n1. Fundamental Analysis (P\u002FE, ROE, valuation metrics)\n2. Technical Analysis (RSI, MACD, trading signals)\n3. Portfolio Management (allocation, optimization)\n4. Risk Assessment (VaR, drawdown, compliance)\n\nWhich workflows interest you? Select all that apply:\n[✓] Technical Analysis\n[✓] Portfolio Management\n[ ] Fundamental Analysis\n[ ] Risk Assessment\n\nSelected: 2 workflows detected\n```\n\n**Step 3: Strategy Selection**\n```\n🎯 Recommended Creation Strategy:\n\nMulti-Agent Suite Creation\n- Create 2 specialized agents\n- Each agent handles one workflow\n- Agents can communicate and share data\n- Unified installation and documentation\n\nEstimated Time: 35-45 minutes\nOutput: .\u002Ffinance-suite\u002F (2 agents)\n\nOptions:\n[✓] Accept recommendation\n[ ] Create single integrated agent\n[ ] Use template-based approach\n[ ] Customize strategy\n```\n\n**Step 4: Interactive Preview**\n```\n📊 Preview of Your Finance Suite:\n\nStructure:\n.\u002Ffinance-suite\u002F\n├── .claude-plugin\u002Fmarketplace.json\n├── technical-analysis-agent\u002F\n│   ├── SKILL.md (2,100 words)\n│   ├── scripts\u002F (Python, 450 lines)\n│   └── tests\u002F (15 tests)\n└── portfolio-management-agent\u002F\n    ├── SKILL.md (1,800 words)\n    ├── scripts\u002F (Python, 380 lines)\n    └── tests\u002F (12 tests)\n\nFeatures:\n✅ Real-time stock data (Alpha Vantage API)\n✅ 10 technical indicators (RSI, MACD, Bollinger...)\n✅ Portfolio optimization algorithms\n✅ Risk metrics and rebalancing alerts\n✅ Automated report generation\n\nAPIs Required:\n- Alpha Vantage (free tier available)\n- Yahoo Finance (no API key needed)\n\nWould you like to:\n[✓] Proceed with creation\n[ ] Modify technical indicators\n[ ] Add risk management features\n[ ] Change APIs\n[ ] See more details\n```\n\n### Wizard Benefits\n\n**🎯 User Empowerment:**\n- Users see exactly what will be created\n- Can modify and iterate before implementation\n- Learn about the process and architecture\n- Make informed decisions\n\n**⚡ Efficiency:**\n- Faster than custom development\n- Better than black-box creation\n- Reduces rework and iterations\n- Higher satisfaction rates\n\n**🛡️ Risk Reduction:**\n- Preview prevents misunderstandings\n- Iterative refinement catches issues early\n- Users can validate requirements\n- Clear expectations management\n\n### Interactive Commands\n\n**Start Interactive Mode:**\n```\n\"Help me create an agent with interactive options\"\n\"Walk me through creating a financial analysis system\"\n\"I want to use the configuration wizard\"\n```\n\n**Resume from Preview:**\n```\n\"Show me the preview again before creating\"\n\"Can I modify the preview you showed me?\"\n\"I want to change something in the proposed structure\"\n```\n\n**Learning Mode:**\n```\n\"Create an agent and explain each step as you go\"\n\"Teach me how agent creation works while building\"\n\"I want to understand the architecture decisions\"\n```\n\n### Wizard Customization Options\n\n**Advanced Mode:**\n```\n⚙️ Advanced Configuration Options:\n\n1. API Selection Strategy\n   [ ] Prefer free APIs\n   [ ] Prioritize data quality\n   [ ] Minimize rate limits\n   [ ] Multiple API fallbacks\n\n2. Architecture Preference\n   [ ] Modular (separate scripts per function)\n   [ ] Integrated (all-in-one scripts)\n   [ ] Hybrid (core + specialized modules)\n\n3. Testing Strategy\n   [ ] Basic functionality tests\n   [ ] Comprehensive test suite\n   [ ] Integration tests\n   [ ] Performance benchmarks\n\n4. Documentation Level\n   [ ] Minimal (API docs only)\n   [ ] Standard (complete usage guide)\n   [ ] Extensive (tutorials + examples)\n   [ ] Academic (methodology + research)\n```\n\n**Template Customization:**\n```\n🎨 Template Customization:\n\nBase Template: Financial Analysis\n✓ Include technical indicators: RSI, MACD, Bollinger Bands\n✓ Add portfolio optimization: Modern Portfolio Theory\n✓ Risk metrics: VaR, Maximum Drawdown, Sharpe Ratio\n\nAdditional Features:\n[ ] Machine learning predictions\n[ ] Sentiment analysis from news\n[ ] Options pricing models\n[ ] Cryptocurrency support\n\nRemove Features:\n[ ] Fundamental analysis (not needed)\n[ ] Economic calendar integration\n```\n\n## 🧠 Invisible Intelligence: AgentDB Integration (NEW v2.1)\n\n### What This Means for Users\n\n**The agent-creator now has \"memory\" and gets smarter over time - automatically!**\n\n✅ **No setup required** - AgentDB initializes automatically in the background\n✅ **No commands to learn** - You use the exact same natural language commands\n✅ **Invisible enhancement** - Agents become more intelligent without you doing anything\n✅ **Progressive learning** - Each agent learns from experience and shares knowledge\n\n### How It Works (Behind the Scenes)\n\nWhen you create an agent:\n```\nUser: \"Create agent for financial analysis\"\n\n🤖 Agent-Creator (v2.1):\n\"✅ Creating financial-analysis-agent with learned intelligence...\"\n\"✅ Using template with 94% historical success rate...\"\n\"✅ Applied 12 learned improvements from similar agents...\"\n\"✅ Mathematical proof: template choice validated with 98% confidence...\"\n```\n\n### Key Benefits (Automatic & Invisible)\n\n**🧠 Learning Memory:**\n- Agents remember what works and what doesn't\n- Successful patterns are automatically reused\n- Failed approaches are automatically avoided\n\n**📊 Smart Decisions:**\n- Template selection based on real success data\n- Architecture optimized from thousands of similar agents\n- API choices validated with mathematical proofs\n\n**🔄 Continuous Improvement:**\n- Each agent gets smarter with use\n- Knowledge shared across all agents automatically\n- Nightly reflection system refines capabilities\n\n### User Experience: \"The Magic Gets Better\"\n\n**First Week:**\n```\n\"Analyze Tesla stock\"\n🤖 \"📊 Tesla analysis: RSI 65.3, MACD bullish\"\n```\n\n**After One Month:**\n```\n\"Analyze Tesla stock\"\n🤖 \"📊 Tesla analysis: RSI 65.3, MACD bullish (enhanced with your patterns)\"\n🤖 \"🧠 Pattern detected: You always ask on Mondays - prepared weekly analysis\"\n🤖 \"📈 Added volatility prediction based on your usage patterns\"\n```\n\n### Technical Implementation (Invisible to Users)\n\n```python\n# This happens automatically behind the scenes\nclass AgentCreatorV21:\n    def create_agent(self, user_input):\n        # AgentDB enhancement (invisible)\n        intelligence = enhance_agent_creation(user_input)\n\n        # Enhanced template selection\n        template = intelligence.template_choice or self.default_template\n\n        # Learned improvements automatically applied\n        improvements = intelligence.learned_improvements\n\n        # Create agent with enhanced intelligence\n        return self.create_with_intelligence(template, improvements)\n```\n\n### Graceful Fallback\n\nIf AgentDB isn't available (rare), the agent-creator works exactly like v2.0:\n```\n\"Create agent for financial analysis\"\n🤖 \"✅ Agent created (standard mode)\"\n```\n\nNo interruption, no errors, just no learning enhancements.\n\n### Privacy & Performance\n\n- ✅ All learning happens locally on your machine\n- ✅ No external dependencies required\n- ✅ Automatic cleanup and optimization\n- ✅ Zero impact on creation speed\n\n---\n\n## 📦 Cross-Platform Export (NEW v3.2)\n\n### What This Feature Does\n\n**Automatically package skills for use across all Claude platforms:**\n\nSkills created in Claude Code can be exported for:\n- ✅ **Claude Desktop** - Manual .zip upload\n- ✅ **claude.ai** (Web) - Browser-based upload\n- ✅ **Claude API** - Programmatic integration\n\nThis makes your skills portable and shareable across all Claude ecosystems.\n\n### When to Activate Export\n\nClaude should activate export capabilities when user says:\n\n✅ **Export requests:**\n- \"Export [skill-name] for Desktop\"\n- \"Package [skill-name] for claude.ai\"\n- \"Create API package for [skill-name]\"\n- \"Export [skill-name] for all platforms\"\n\n✅ **Cross-platform requests:**\n- \"Make [skill-name] compatible with Claude Desktop\"\n- \"I need to share [skill-name] with Desktop users\"\n- \"Package [skill-name] as .zip\"\n- \"Create cross-platform version of [skill-name]\"\n\n✅ **Version-specific exports:**\n- \"Export [skill-name] with version 2.0.1\"\n- \"Package [skill-name] v1.5.0 for API\"\n\n### Export Process\n\nWhen user requests export:\n\n**Step 1: Locate Skill**\n```python\n# Search common locations\nlocations = [\n    f\".\u002F{skill_name}-cskill\u002F\",  # Current directory\n    f\"references\u002Fexamples\u002F{skill_name}-cskill\u002F\",  # Examples\n    user_specified_path  # If provided\n]\n\nskill_path = find_skill(locations)\n```\n\n**Step 2: Validate Structure**\n```python\n# Ensure skill is export-ready\nvalid, issues = validate_skill_structure(skill_path)\n\nif not valid:\n    report_issues_to_user(issues)\n    return\n```\n\n**Step 3: Execute Export**\n```bash\n# Run export utility\npython scripts\u002Fexport_utils.py {skill_path} \\\n    --variant {desktop|api|both} \\\n    --version {version} \\\n    --output-dir exports\u002F\n```\n\n**Step 4: Report Results**\n```\n✅ Export completed!\n\n📦 Packages created:\n   - Desktop: exports\u002F{skill}-desktop-v1.0.0.zip (2.3 MB)\n   - API: exports\u002F{skill}-api-v1.0.0.zip (1.2 MB)\n\n📄 Installation guide: exports\u002F{skill}-v1.0.0_INSTALL.md\n\n🎯 Ready for:\n   ✅ Claude Desktop upload\n   ✅ claude.ai upload\n   ✅ Claude API integration\n```\n\n### Post-Creation Export (Opt-In)\n\nAfter successfully creating a skill in PHASE 5, offer export:\n\n```\n✅ Skill created successfully: {skill-name-cskill}\u002F\n\n📦 Cross-Platform Export Options:\n\nWould you like to create export packages for other Claude platforms?\n\n   1. Desktop\u002FWeb (.zip for manual upload)\n   2. API (.zip for programmatic use)\n   3. Both (comprehensive package)\n   4. Skip (Claude Code only)\n\nChoice: _\n```\n\n**If user chooses 1, 2, or 3:**\n- Execute export_utils.py with selected variants\n- Report package locations\n- Provide next steps for each platform\n\n**If user chooses 4 or skips:**\n- Continue with normal completion\n- Skill remains Claude Code only\n\n### Export Variants\n\n**Desktop\u002FWeb Package** (`*-desktop-*.zip`):\n- Complete documentation\n- All scripts and assets\n- Full references\n- Optimized for user experience\n- Typical size: 2-5 MB\n\n**API Package** (`*-api-*.zip`):\n- Execution-focused\n- Size-optimized (\u003C 8MB)\n- Minimal documentation\n- Essential scripts only\n- Typical size: 0.5-2 MB\n\n### Version Detection\n\nAutomatically detect version from:\n\n1. **Git tags** (priority):\n   ```bash\n   git describe --tags --abbrev=0\n   ```\n\n2. **SKILL.md frontmatter**:\n   ```yaml\n   ---\n   name: skill-name\n   version: 1.2.3\n   ---\n   ```\n\n3. **Default**: `v1.0.0`\n\n**User can override**:\n- \"Export with version 2.1.0\"\n- `--version 2.1.0` flag\n\n### Export Validation\n\nBefore creating packages, validate:\n\n✅ **Required:**\n- SKILL.md exists\n- Valid frontmatter (---...---)\n- `name:` field present (≤ 64 chars)\n- `description:` field present (≤ 1024 chars)\n\n✅ **Size Checks:**\n- Desktop: Reasonable size\n- API: \u003C 8MB (hard limit)\n\n✅ **Security:**\n- No .env files\n- No credentials.json\n- No sensitive data\n\nIf validation fails, report specific issues to user.\n\n### Installation Guides\n\nAuto-generate platform-specific guides:\n\n**File**: `exports\u002F{skill}-v{version}_INSTALL.md`\n\n**Contents:**\n- Package information\n- Installation steps for Desktop\n- Installation steps for claude.ai\n- API integration code examples\n- Platform comparison table\n- Troubleshooting tips\n\n### Export Commands Reference\n\n```bash\n# Export both variants (default)\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill\n\n# Export only Desktop\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill --variant desktop\n\n# Export only API\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill --variant api\n\n# With custom version\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill --version 2.0.1\n\n# To custom directory\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill --output-dir .\u002Freleases\n```\n\n### Documentation References\n\nPoint users to comprehensive guides:\n- **Export Guide**: `references\u002Fexport-guide.md`\n- **Cross-Platform Guide**: `references\u002Fcross-platform-guide.md`\n- **Exports README**: `exports\u002FREADME.md`\n\n### Integration with AgentDB\n\nExport process can leverage AgentDB learning:\n- Remember successful export configurations\n- Suggest optimal variant based on use case\n- Track which exports are most commonly used\n- Learn from export failures to improve validation\n\n---\n\n## PHASE 1: Discovery and Research\n\n**Objective**: DECIDE which API\u002Fdata source to use with AgentDB intelligence\n\n### Process\n\n**1.1 Identify domain and query AgentDB**\n\nFrom user input, identify the domain and immediately query AgentDB for learned patterns:\n\n```python\n# Import AgentDB bridge (invisible to user)\nfrom integrations.agentdb_bridge import get_agentdb_bridge\n\n# Get AgentDB intelligence\nbridge = get_agentdb_bridge()\nintelligence = bridge.enhance_agent_creation(user_input, domain)\n\n# Log: AgentDB provides insights if available\nif intelligence.learned_improvements:\n    print(f\"🧠 Found {len(intelligence.learned_improvements)} relevant patterns\")\n```\n\n**Domain mapping with AgentDB insights:**\n- Agriculture → APIs: USDA NASS, FAO, World Bank Ag\n- Finance → APIs: Alpha Vantage, Yahoo Finance, Fed Economic Data\n- Weather → APIs: NOAA, OpenWeather, Weather.gov\n- Economy → APIs: World Bank, IMF, FRED\n\n**1.2 Research available APIs with learned preferences**\n\nFor the domain, use WebSearch to find:\n\n- Available public APIs\n- Documentation\n- Characteristics (free? rate limits? coverage?)\n\n**AgentDB Enhancement**: Prioritize APIs that have shown higher success rates:\n```python\n# AgentDB influences search based on historical success\nif intelligence.success_probability > 0.8:\n    print(f\"🎯 High success domain detected - optimizing API selection\")\n```\n\n**Example with AgentDB insights**:\n\n```\nWebSearch: \"US agriculture API free historical data\"\nWebSearch: \"USDA API documentation\"\nWebFetch: [doc URLs found]\n\n# AgentDB check: \"Has similar domain been successful before?\"\n# AgentDB provides: \"USDA NASS: 94% success rate in agriculture domain\"\n```\n\n**1.3 Compare options with AgentDB validation**\n\nCreate mental table comparing:\n\n- Data coverage (fit with need)\n- Cost (free vs paid)\n- Rate limits (sufficient?)\n- Data quality (official? reliable?)\n- Documentation (good? examples?)\n- Ease of use\n- **🧠 AgentDB Success Rate** (historical validation)\n\n**AgentDB Mathematical Validation**:\n```python\n# AgentDB provides mathematical proof for selection\nif intelligence.mathematical_proof:\n    print(f\"📊 API selection validated: {intelligence.mathematical_proof}\")\n```\n\n**1.4 DECIDE with AgentDB confidence**\n\nChoose 1 API and justify with AgentDB backing:\n\n**Decision with AgentDB confidence:**\n- **Selected API**: [API name]\n- **Success Probability**: {intelligence.success_probability:.1%}\n- **Mathematical Proof**: {intelligence.mathematical_proof}\n- **Learned Improvements**: {intelligence.learned_improvements}\n\n**Document decision** in separate file:\n\n```markdown\n# Architecture Decisions\n\n## Selected API: [Name]\n\n**Justification**:\n- ✅ Coverage: [details]\n- ✅ Cost: [free\u002Fpaid]\n- ✅ Rate limit: [number]\n- ✅ Quality: [official\u002Fprivate]\n- ✅ Docs: [quality]\n\n**Alternatives considered**:\n- API X: Rejected because [reason]\n- API Y: Rejected because [reason]\n\n**Conclusion**: [Chosen API] is the best option because [synthesis]\n```\n\n**1.5 Research technical details**\n\nUse WebFetch to load API documentation and extract:\n\n- Base URL\n- Main endpoints\n- Authentication\n- Important parameters\n- Response format\n- Rate limits\n- Request\u002Fresponse examples\n\n**See** `references\u002Fphase1-discovery.md` for complete details.\n\n## PHASE 2: Analysis Design\n\n**Objective**: DEFINE which analyses the agent will perform\n\n### Process\n\n**2.1 Think about use cases**\n\nFor the described workflow, which questions will the user ask frequently?\n\n**Brainstorm**: List 10-15 typical questions\n\n**2.2 Group by analysis type**\n\nGroup similar questions:\n\n- Simple queries (fetch + format)\n- Temporal comparisons (YoY)\n- Rankings (sort + share)\n- Trends (time series + CAGR)\n- Projections (forecasting)\n- Aggregations (regional\u002Fcategorical)\n\n**2.3 DEFINE priority analyses**\n\nChoose 4-6 analyses that cover 80% of use cases.\n\nFor each analysis:\n\n- Name\n- Objective\n- Required inputs\n- Expected outputs\n- Methodology (formulas, transformations)\n- Interpretation\n\n**2.4 ADD Comprehensive Report Function** (🆕 Enhancement #8 - MANDATORY!)\n\n**⚠️ COMMON PROBLEM:** v1.0 skills had isolated functions. When user asks for \"complete report\", Claude didn't know how to combine all analyses.\n\n**Solution:** ALWAYS include as last analysis function:\n\n```python\ndef comprehensive_{domain}_report(\n    entity: str,\n    year: Optional[int] = None,\n    include_metrics: Optional[List[str]] = None,\n    client: Optional[Any] = None\n) -> Dict:\n    \"\"\"\n    Generate comprehensive report combining ALL available metrics.\n\n    This is a \"one-stop\" function that users can call to get\n    complete picture without knowing individual functions.\n\n    Args:\n        entity: Entity to analyze (e.g., commodity, stock, location)\n        year: Year (None for current year with auto-detection)\n        include_metrics: Which metrics to include (None = all available)\n        client: API client instance (optional, created if None)\n\n    Returns:\n        Dict with ALL metrics consolidated:\n        {\n            'entity': str,\n            'year': int,\n            'year_info': str,\n            'generated_at': str (ISO timestamp),\n            'metrics': {\n                'metric1_name': {metric1_data},\n                'metric2_name': {metric2_data},\n                ...\n            },\n            'summary': str (overall insights),\n            'alerts': List[str] (important findings)\n        }\n\n    Example:\n        >>> report = comprehensive_{domain}_report(\"CORN\")\n        >>> print(report['summary'])\n        \"CORN 2025: Production up 5% YoY, yield at record high...\"\n    \"\"\"\n    from datetime import datetime\n    from utils.helpers import get_{domain}_year_with_fallback, format_year_message\n\n    # Auto-detect year\n    year_requested = year\n    if year is None:\n        year, _ = get_{domain}_year_with_fallback()\n\n    # Initialize report\n    report = {\n        'entity': entity,\n        'year': year,\n        'year_requested': year_requested,\n        'year_info': format_year_message(year, year_requested),\n        'generated_at': datetime.now().isoformat(),\n        'metrics': {},\n        'alerts': []\n    }\n\n    # Determine which metrics to include\n    if include_metrics is None:\n        # Include ALL available metrics\n        metrics_to_fetch = ['{metric1}', '{metric2}', '{metric3}', ...]\n    else:\n        metrics_to_fetch = include_metrics\n\n    # Call ALL individual analysis functions\n    # Graceful degradation: if one fails, others still run\n\n    if '{metric1}' in metrics_to_fetch:\n        try:\n            report['metrics']['{metric1}'] = {metric1}_analysis(entity, year, client)\n        except Exception as e:\n            report['metrics']['{metric1}'] = {\n                'error': str(e),\n                'status': 'unavailable'\n            }\n            report['alerts'].append(f\"{metric1} data unavailable: {e}\")\n\n    if '{metric2}' in metrics_to_fetch:\n        try:\n            report['metrics']['{metric2}'] = {metric2}_analysis(entity, year, client)\n        except Exception as e:\n            report['metrics']['{metric2}'] = {\n                'error': str(e),\n                'status': 'unavailable'\n            }\n\n    # Repeat for ALL metrics...\n\n    # Generate summary based on all available data\n    report['summary'] = _generate_summary(report['metrics'], entity, year)\n\n    # Detect important findings\n    report['alerts'].extend(_detect_alerts(report['metrics']))\n\n    return report\n\n\ndef _generate_summary(metrics: Dict, entity: str, year: int) -> str:\n    \"\"\"Generate human-readable summary from all metrics.\"\"\"\n    insights = []\n\n    # Extract key insights from each metric\n    for metric_name, metric_data in metrics.items():\n        if 'error' not in metric_data:\n            # Extract most important insight from this metric\n            key_insight = _extract_key_insight(metric_name, metric_data)\n            if key_insight:\n                insights.append(key_insight)\n\n    # Combine into coherent summary\n    if insights:\n        summary = f\"{entity} {year}: \" + \". \".join(insights[:3])  # Top 3 insights\n    else:\n        summary = f\"{entity} {year}: No data available\"\n\n    return summary\n\n\ndef _detect_alerts(metrics: Dict) -> List[str]:\n    \"\"\"Detect significant findings that need attention.\"\"\"\n    alerts = []\n\n    # Check each metric for alert conditions\n    for metric_name, metric_data in metrics.items():\n        if 'error' in metric_data:\n            continue\n\n        # Domain-specific alert logic\n        # Example: Large changes, extreme values, anomalies\n        if metric_name == '{metric1}' and 'change_percent' in metric_data:\n            if abs(metric_data['change_percent']) > 15:\n                alerts.append(\n                    f\"⚠ Large {metric1} change: {metric_data['change_percent']:.1f}%\"\n                )\n\n    return alerts\n```\n\n**Why it's mandatory:**\n- ✅ Users want \"complete report\" → 1 function does everything\n- ✅ Ideal for executive dashboards\n- ✅ Facilitates sales (\"everything in one report\")\n- ✅ Much better UX (no need to know individual functions)\n\n**When to mention in SKILL.md:**\n\n```markdown\n## Comprehensive Analysis (All-in-One)\n\nTo get a complete report combining ALL metrics:\n\nUse the `comprehensive_{domain}_report()` function.\n\nThis function:\n- Fetches ALL available metrics\n- Combines into single report\n- Generates automatic summary\n- Detects important alerts\n- Degrades gracefully (if 1 metric fails, others work)\n\nUsage example:\n\"Generate complete report for {entity}\"\n\"Complete dashboard for {entity}\"\n\"All metrics for {entity}\"\n```\n\n**Impact:**\n- ✅ 10x better UX (1 query = everything)\n- ✅ More useful skills for end users\n- ✅ Facilitates commercial adoption\n\n**2.5 Specify methodologies**\n\nFor quantitative analyses, define:\n\n- Mathematical formulas\n- Statistical validations\n- Interpretations\n- Edge cases\n\n**See** `references\u002Fphase2-design.md` for detailed methodologies.\n\n## PHASE 3: Architecture\n\n**Objective**: STRUCTURE the agent optimally\n\n### Process\n\n**3.1 Define folder structure**\n\nBased on analyses and API:\n\n```\nagent-name\u002F\n├── SKILL.md\n├── scripts\u002F\n│   ├── [fetch\u002Fparse\u002Fanalyze separate or together?]\n│   └── utils\u002F\n│       └── [cache? rate limiter? validators?]\n├── references\u002F\n│   └── [API docs? methodologies? troubleshooting?]\n└── assets\u002F\n    └── [configs? metadata?]\n```\n\n**Decisions**:\n\n- Separate scripts (modular) vs monolithic?\n- Which utilities needed?\n- Which references useful?\n- Which configs\u002Fassets?\n\n**3.2 Define responsibilities**\n\nFor each script, specify:\n\n- File name\n- Function\u002Fpurpose\n- Input and output\n- Specific responsibilities\n- ~Expected number of lines\n\n**3.3 Plan references**\n\nWhich reference files to create?\n\n- API guide (how to use API)\n- Analysis methods (methodologies)\n- Troubleshooting (common errors)\n- Domain knowledge (domain context)\n\n**3.4 Performance strategy**\n\n- Cache: What to cache? TTL?\n- Rate limiting: How to control?\n- Optimizations: Parallelization? Lazy loading?\n\n**See** `references\u002Fphase3-architecture.md` for structuring patterns.\n\n## PHASE 4: Automatic Detection\n\n**Objective**: DETERMINE keywords for automatic activation\n\n### Process\n\n**4.1 List domain entities**\n\n- Organizations\u002Fdata sources\n- Main metrics\n- Geography (countries, regions, states)\n- Temporality (years, periods)\n\n**4.2 List typical actions**\n\n- Query: \"what\", \"how much\", \"show\"\n- Compare: \"compare\", \"vs\", \"versus\"\n- Rank: \"top\", \"best\", \"ranking\"\n- Analyze: \"trend\", \"growth\", \"analyze\"\n- Forecast: \"predict\", \"project\", \"forecast\"\n\n**4.3 List question variations**\n\nFor each analysis type, how might the user ask?\n\n**4.4 Define negative scope**\n\nImportant! What should NOT activate the skill?\n\n**4.5 Create precise description**\n\nWith all keywords identified, create ~200 word description that:\n\n- Mentions domain\n- Lists main keywords\n- Gives examples\n- Defines negative scope\n\n**See** `references\u002Fphase4-detection.md` for complete guide.\n\n### 🎯 3-Layer Activation System (v3.0)\n\n**Important**: As of Agent-Skill-Creator v3.0, we now use a **3-Layer Activation System** to achieve 95%+ activation reliability.\n\n#### Why 3 Layers?\n\nPrevious skills that relied only on description achieved ~70% activation reliability. The 3-layer system dramatically improves this to 95%+ by combining:\n\n1. **Layer 1: Keywords** - Exact phrase matching (high precision)\n2. **Layer 2: Patterns** - Regex flexible matching (coverage for variations)\n3. **Layer 3: Description + NLU** - Claude's understanding (fallback for edge cases)\n\n#### Quick Implementation Guide\n\n**Layer 1: Keywords (10-15 phrases)**\n```json\n\"activation\": {\n  \"keywords\": [\n    \"create an agent for\",\n    \"automate workflow\",\n    \"technical analysis for\",\n    \"RSI indicator\",\n    \u002F\u002F 10-15 total complete phrases\n  ]\n}\n```\n\n**Requirements:**\n- ✅ Complete phrases (2+ words)\n- ✅ Action verb + entity\n- ✅ Domain-specific terms\n- ❌ No single words\n- ❌ No overly generic phrases\n\n**Layer 2: Patterns (5-7 regex)**\n```json\n\"patterns\": [\n  \"(?i)(create|build)\\\\s+(an?\\\\s+)?agent\\\\s+for\",\n  \"(?i)(automate|automation)\\\\s+(workflow|process)\",\n  \"(?i)(analyze|analysis)\\\\s+.*\\\\s+(stock|data)\",\n  \u002F\u002F 5-7 total patterns\n]\n```\n\n**Requirements:**\n- ✅ Start with `(?i)` for case-insensitivity\n- ✅ Include action verbs + entities\n- ✅ Allow flexible word order\n- ✅ Specific enough to avoid false positives\n- ✅ Flexible enough to capture variations\n\n**Layer 3: Enhanced Description (300-500 chars, 60+ keywords)**\n```\nComprehensive [domain] tool. [Primary capability] including [specific-feature-1],\n[specific-feature-2], and [specific-feature-3]. Generates [output-type] based on\n[method]. Compares [entity-type] for [analysis-type]. Monitors [target] and tracks\n[metric]. Perfect for [user-persona] needing [use-case-1], [use-case-2], and\n[use-case-3] using [methodology].\n```\n\n**Requirements:**\n- ✅ 60+ unique keywords\n- ✅ All Layer 1 keywords included naturally\n- ✅ Domain-specific terminology\n- ✅ Use cases clearly stated\n- ✅ Natural language flow\n\n#### Usage Sections\n\nAdd to marketplace.json:\n\n```json\n\"usage\": {\n  \"when_to_use\": [\n    \"User explicitly asks to [capability-1]\",\n    \"User mentions [indicator-name] or [domain-term]\",\n    \"User describes [use-case-scenario]\",\n    \u002F\u002F 5+ use cases\n  ],\n  \"when_not_to_use\": [\n    \"User asks for [out-of-scope-1]\",\n    \"User wants [different-skill-capability]\",\n    \u002F\u002F 3+ counter-cases\n  ]\n}\n```\n\n#### Test Queries\n\nAdd to marketplace.json:\n\n```json\n\"test_queries\": [\n  \"Query testing keyword-1\",\n  \"Query testing pattern-2\",\n  \"Query testing description understanding\",\n  \"Natural language variation\",\n  \u002F\u002F 10+ total queries covering all layers\n]\n```\n\n#### Complete Example\n\nSee `references\u002Fexamples\u002Fstock-analyzer-cskill\u002F` for a complete working example demonstrating:\n- All 3 layers properly configured\n- 98% activation reliability\n- Complete test suite\n- Documentation with activation examples\n\n#### Quality Checklist\n\nBefore completing Phase 4, verify:\n\n- [ ] 10-15 complete keyword phrases defined\n- [ ] 5-7 regex patterns with verbs + entities\n- [ ] 300-500 char description with 60+ keywords\n- [ ] 5+ when_to_use cases documented\n- [ ] 3+ when_not_to_use cases documented\n- [ ] 10+ test_queries covering all layers\n- [ ] Tested activation with sample queries\n- [ ] Expected success rate: 95%+\n\n#### Additional Resources\n\n- **Complete Guide**: `references\u002Fphase4-detection.md`\n- **Pattern Library**: `references\u002Factivation-patterns-guide.md` (30+ reusable patterns)\n- **Testing Guide**: `references\u002Factivation-testing-guide.md` (5-phase testing)\n- **Quality Checklist**: `references\u002Factivation-quality-checklist.md`\n- **Templates**: `references\u002Ftemplates\u002Fmarketplace-robust-template.json`\n- **Example**: `references\u002Fexamples\u002Fstock-analyzer-cskill\u002F`\n\n---\n\n## PHASE 5: Complete Implementation\n\n**Objective**: IMPLEMENT everything with REAL code\n\n### ⚠️ MANDATORY QUALITY STANDARDS\n\nBefore starting implementation, read `references\u002Fquality-standards.md`.\n\n**NEVER DO**:\n\n- ❌ `# TODO: implement`\n- ❌ `pass` in functions\n- ❌ \"See external documentation\"\n- ❌ Configs with \"YOUR_KEY_HERE\" without instructions\n- ❌ Empty references or just links\n\n**ALWAYS DO**:\n\n- ✅ Complete and functional code\n- ✅ Detailed docstrings\n- ✅ Robust error handling\n- ✅ Type hints\n- ✅ Validations\n- ✅ Real content in references\n- ✅ Configs with real values\n\n### 🚨 STEP 0: BEFORE EVERYTHING - Marketplace.json (MANDATORY)\n\n**STOP! READ THIS BEFORE CONTINUING!**\n\n🛑 **CRITICAL BLOCKER**: You CANNOT create ANY other file until completing this step.\n\n**Why marketplace.json is step 0:**\n\n- ❌ Without this file, the skill CANNOT be installed via `\u002Fplugin marketplace add`\n- ❌ All the work creating the agent will be USELESS without it\n- ❌ This is the most common error when creating agents - DO NOT make this mistake!\n\n#### Step 0.1: Create basic structure\n\n```bash\nmkdir -p agent-name\u002F.claude-plugin\n```\n\n#### Step 0.2: Create marketplace.json IMMEDIATELY\n\nCreate `.claude-plugin\u002Fmarketplace.json` with this content:\n\n```json\n{\n  \"name\": \"agent-name\",\n  \"owner\": {\n    \"name\": \"Agent Creator\",\n    \"email\": \"noreply@example.com\"\n  },\n  \"metadata\": {\n    \"description\": \"Brief agent description\",\n    \"version\": \"1.0.0\",\n    \"created\": \"2025-10-17\"\n  },\n  \"plugins\": [\n    {\n      \"name\": \"agent-plugin\",\n      \"description\": \"THIS DESCRIPTION MUST BE IDENTICAL to the description in SKILL.md frontmatter that you'll create in the next step\",\n      \"source\": \".\u002F\",\n      \"strict\": false,\n      \"skills\": [\".\u002F\"]\n    }\n  ]\n}\n```\n\n**⚠️ CRITICAL FIELDS:**\n\n- `name`: Agent name (same as directory name)\n- `plugins[0].description`: **MUST BE EXACTLY EQUAL** to SKILL.md frontmatter description\n- `plugins[0].skills`: `[\".\u002F\"]` points to SKILL.md in root\n- `plugins[0].source`: `\".\u002F\"` points to agent root\n\n#### Step 0.3: VALIDATE IMMEDIATELY (before continuing!)\n\n**Execute NOW these validation commands:**\n\n```bash\n# 1. Validate JSON syntax\npython3 -c \"import json; print('✅ Valid JSON'); json.load(open('agent-name\u002F.claude-plugin\u002Fmarketplace.json'))\"\n\n# 2. Verify file exists\nls -la agent-name\u002F.claude-plugin\u002Fmarketplace.json\n\n# If any command fails: STOP and fix before continuing!\n```\n\n**✅ CHECKLIST - You MUST complete ALL before proceeding:**\n\n- [ ] ✅ File `.claude-plugin\u002Fmarketplace.json` created\n- [ ] ✅ JSON is syntactically valid (validated with python)\n- [ ] ✅ Field `name` is correct\n- [ ] ✅ Field `plugins[0].description` ready to receive SKILL.md description\n- [ ] ✅ Field `plugins[0].skills` = `[\".\u002F\"]`\n- [ ] ✅ Field `plugins[0].source` = `\".\u002F\"`\n\n**🛑 ONLY PROCEED AFTER VALIDATING ALL ITEMS ABOVE!**\n\n---\n\n### Implementation Order (AFTER marketplace.json validated)\n\nNow that marketplace.json is created and validated, proceed:\n\n**1. Create rest of directory structure**\n\n```bash\nmkdir -p agent-name\u002F{scripts\u002Futils,references,assets,data\u002F{raw,processed,cache,analysis}}\n```\n\n**2. Create SKILL.md**\n\nMandatory structure:\n\n- Frontmatter (name, description)\n- When to use\n- How it works (overview)\n- Data source (detailed API)\n- Workflows (step-by-step by question type)\n- Available scripts (each explained)\n- Available analyses (each explained)\n- Error handling (all expected errors)\n- Mandatory validations\n- Performance and cache\n- Keywords for detection\n- Usage examples (5+ complete)\n\n**Size**: 5000-7000 words\n\n**⚠️ AFTER creating SKILL.md: SYNCHRONIZE description with marketplace.json!**\n\n**CRITICAL**: Now that SKILL.md is created with its frontmatter, you MUST:\n\n```bash\n# Edit marketplace.json to update description\n# Copy EXACTLY the description from SKILL.md frontmatter\n# Paste in .claude-plugin\u002Fmarketplace.json → plugins[0].description\n```\n\n**Verify synchronization:**\n\n- SKILL.md frontmatter description = marketplace.json plugins[0].description\n- Must be IDENTICAL (word for word!)\n- Without this, skill won't activate automatically\n\n**3. Implement Python scripts**\n\n**Order** (MANDATORY):\n\n1. **Utils first** (including helpers.py + validators\u002F - CRITICAL!)\n   - `utils\u002Fhelpers.py` (🔴 MANDATORY - already specified previously)\n   - `utils\u002Fcache_manager.py`\n   - `utils\u002Frate_limiter.py`\n   - `utils\u002Fvalidators\u002F` (🔴 MANDATORY - see Step 3.5 below)\n2. **Fetch** (API client - 1 method per API metric)\n3. **Parse** (🔴 MODULAR: 1 parser per data type! - see Step 3.2 below)\n4. **Analyze** (analyses - include comprehensive_report already specified!)\n\n**Each script (in general)**:\n\n- Shebang: `#!\u002Fusr\u002Fbin\u002Fenv python3`\n- Complete module docstring\n- Organized imports\n- Classes\u002Ffunctions with docstrings\n- Type hints\n- Error handling\n- Logging\n- Main function with argparse\n- if __name__ == \"__main__\"\n\n---\n\n### Step 3.2: Modular Parser Architecture (🆕 Enhancement #5 - MANDATORY!)\n\n**⚠️ COMMON PROBLEM:** v1.0 had 1 generic parser. When adding new data types, architecture broke.\n\n**Solution:** **1 specific parser per API data type!**\n\n**Rule:** If API returns N data types (identified in Phase 1.6) → create N specific parsers\n\n**Mandatory structure:**\n\n```\nscripts\u002F\n├── parse_{type1}.py    # Ex: parse_conditions.py\n├── parse_{type2}.py    # Ex: parse_progress.py\n├── parse_{type3}.py    # Ex: parse_yield.py\n├── parse_{type4}.py    # Ex: parse_production.py\n└── parse_{type5}.py    # Ex: parse_area.py\n```\n\n**Template for each parser:**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nParser for {type} data from {API_name}.\nHandles {type}-specific transformations and validations.\n\"\"\"\n\nimport pandas as pd\nfrom typing import List, Dict, Any, Optional\nimport logging\n\nlogger = logging.getLogger(__name__)\n\n\ndef parse_{type}_response(data: List[Dict]) -> pd.DataFrame:\n    \"\"\"\n    Parse API response for {type} data.\n\n    Args:\n        data: Raw API response (list of dicts)\n\n    Returns:\n        DataFrame with standardized schema:\n        - entity: str\n        - year: int\n        - {type}_value: float\n        - unit: str\n        - {type}_specific_fields: various\n\n    Raises:\n        ValueError: If data is invalid\n        ParseError: If parsing fails\n\n    Example:\n        >>> data = [{'entity': 'CORN', 'year': 2025, 'value': '15,300,000'}]\n        >>> df = parse_{type}_response(data)\n        >>> df.shape\n        (1, 5)\n    \"\"\"\n    if not data:\n        raise ValueError(\"Data cannot be empty\")\n\n    # Convert to DataFrame\n    df = pd.DataFrame(data)\n\n    # {Type}-specific transformations\n    df = _clean_{type}_values(df)\n    df = _extract_{type}_metadata(df)\n    df = _standardize_{type}_schema(df)\n\n    # Validate\n    _validate_{type}_schema(df)\n\n    return df\n\n\ndef _clean_{type}_values(df: pd.DataFrame) -> pd.DataFrame:\n    \"\"\"Clean {type}-specific values (remove formatting, convert types).\"\"\"\n    # Example: Remove commas from numbers\n    if 'value' in df.columns:\n        df['value'] = df['value'].astype(str).str.replace(',', '')\n        df['value'] = pd.to_numeric(df['value'], errors='coerce')\n\n    # {Type}-specific cleaning\n    # ...\n\n    return df\n\n\ndef _extract_{type}_metadata(df: pd.DataFrame) -> pd.DataFrame:\n    \"\"\"Extract {type}-specific metadata fields.\"\"\"\n    # Example for progress data: extract % from \"75% PLANTED\"\n    # Example for condition data: extract rating from \"GOOD (60%)\"\n    # Customize per data type!\n\n    return df\n\n\ndef _standardize_{type}_schema(df: pd.DataFrame) -> pd.DataFrame:\n    \"\"\"\n    Standardize column names and schema for {type} data.\n\n    Output schema:\n    - entity: str\n    - year: int\n    - {type}_value: float (main metric)\n    - unit: str\n    - additional_{type}_fields: various\n    \"\"\"\n    # Rename columns to standard names\n    column_mapping = {\n        'api_entity_field': 'entity',\n        'api_year_field': 'year',\n        'api_value_field': '{type}_value',\n        # Add more as needed\n    }\n    df = df.rename(columns=column_mapping)\n\n    # Ensure types\n    df['year'] = df['year'].astype(int)\n    df['{type}_value'] = pd.to_numeric(df['{type}_value'], errors='coerce')\n\n    return df\n\n\ndef _validate_{type}_schema(df: pd.DataFrame) -> None:\n    \"\"\"Validate {type} DataFrame schema.\"\"\"\n    required_columns = ['entity', 'year', '{type}_value']\n\n    missing = set(required_columns) - set(df.columns)\n    if missing:\n        raise ValueError(f\"Missing required columns: {missing}\")\n\n    # Type validations\n    if not pd.api.types.is_integer_dtype(df['year']):\n        raise TypeError(\"'year' must be integer type\")\n\n    if not pd.api.types.is_numeric_dtype(df['{type}_value']):\n        raise TypeError(\"'{type}_value' must be numeric type\")\n\n\ndef aggregate_{type}(df: pd.DataFrame, by: str) -> pd.DataFrame:\n    \"\"\"\n    Aggregate {type} data by specified level.\n\n    Args:\n        df: Parsed {type} DataFrame\n        by: Aggregation level ('national', 'state', 'region')\n\n    Returns:\n        Aggregated DataFrame\n\n    Example:\n        >>> agg = aggregate_{type}(df, by='state')\n    \"\"\"\n    # Aggregation logic specific to {type}\n    if by == 'national':\n        return df.groupby(['year']).agg({\n            '{type}_value': 'sum',\n            # Add more as needed\n        }).reset_index()\n\n    elif by == 'state':\n        return df.groupby(['year', 'state']).agg({\n            '{type}_value': 'sum',\n        }).reset_index()\n\n    # Add more levels...\n\n\ndef format_{type}_report(df: pd.DataFrame) -> str:\n    \"\"\"\n    Format {type} data as human-readable report.\n\n    Args:\n        df: Parsed {type} DataFrame\n\n    Returns:\n        Formatted string report\n\n    Example:\n        >>> report = format_{type}_report(df)\n        >>> print(report)\n        \"{Type} Report: ...\"\n    \"\"\"\n    lines = [f\"## {Type} Report\\n\"]\n\n    # Format based on {type} data\n    # Customize per type!\n\n    return \"\\n\".join(lines)\n\n\ndef main():\n    \"\"\"Test parser with sample data.\"\"\"\n    # Sample data for testing\n    sample_data = [\n        {\n            'entity': 'CORN',\n            'year': 2025,\n            'value': '15,300,000',\n            # Add {type}-specific fields\n        }\n    ]\n\n    print(\"Testing parse_{type}_response()...\")\n    df = parse_{type}_response(sample_data)\n    print(f\"✓ Parsed {len(df)} records\")\n    print(f\"✓ Columns: {list(df.columns)}\")\n    print(f\"\\n{df.head()}\")\n\n    print(\"\\nTesting aggregate_{type}()...\")\n    agg = aggregate_{type}(df, by='national')\n    print(f\"✓ Aggregated: {agg}\")\n\n    print(\"\\nTesting format_{type}_report()...\")\n    report = format_{type}_report(df)\n    print(report)\n\n\nif __name__ == \"__main__\":\n    main()\n```\n\n**Why create modular parsers:**\n- ✅ Each data type has peculiarities (progress has %, yield has bu\u002Facre, etc)\n- ✅ Scalable architecture (easy to add new types)\n- ✅ Isolated tests (each parser tested independently)\n- ✅ Simple maintenance (bug in 1 type doesn't affect others)\n- ✅ Organized code (clear responsibilities)\n\n**Impact:** Professional and scalable architecture from v1.0!\n\n---\n\n### Step 3.5: Validation System (🆕 Enhancement #10 - MANDATORY!)\n\n**⚠️ COMMON PROBLEM:** v1.0 without data validation. User doesn't know if data is reliable.\n\n**Solution:** Complete validation system in `utils\u002Fvalidators\u002F`\n\n**Mandatory structure:**\n\n```\nscripts\u002Futils\u002Fvalidators\u002F\n├── __init__.py\n├── parameter_validator.py    # Validate function parameters\n├── data_validator.py         # Validate API responses\n├── temporal_validator.py     # Validate temporal consistency\n└── completeness_validator.py # Validate data completeness\n```\n\n**Template 1: parameter_validator.py**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nParameter validators for {skill-name}.\nValidates user inputs before making API calls.\n\"\"\"\n\nfrom typing import Any, List, Optional\nfrom datetime import datetime\n\n\nclass ValidationError(Exception):\n    \"\"\"Raised when validation fails.\"\"\"\n    pass\n\n\ndef validate_entity(entity: str, valid_entities: Optional[List[str]] = None) -> str:\n    \"\"\"\n    Validate entity parameter.\n\n    Args:\n        entity: Entity name (e.g., \"CORN\", \"SOYBEANS\")\n        valid_entities: List of valid entities (None to skip check)\n\n    Returns:\n        str: Validated and normalized entity name\n\n    Raises:\n        ValidationError: If entity is invalid\n\n    Example:\n        >>> validate_entity(\"corn\")\n        \"CORN\"  # Normalized to uppercase\n    \"\"\"\n    if not entity:\n        raise ValidationError(\"Entity cannot be empty\")\n\n    if not isinstance(entity, str):\n        raise ValidationError(f\"Entity must be string, got {type(entity)}\")\n\n    # Normalize\n    entity = entity.strip().upper()\n\n    # Check if valid (if list provided)\n    if valid_entities and entity not in valid_entities:\n        suggestions = [e for e in valid_entities if entity[:3] in e]\n        raise ValidationError(\n            f\"Invalid entity: {entity}\\n\"\n            f\"Valid options: {', '.join(valid_entities[:10])}\\n\"\n            f\"Did you mean: {', '.join(suggestions[:3])}?\"\n        )\n\n    return entity\n\n\ndef validate_year(\n    year: Optional[int],\n    min_year: int = 1900,\n    allow_future: bool = False\n) -> int:\n    \"\"\"\n    Validate year parameter.\n\n    Args:\n        year: Year to validate (None returns current year)\n        min_year: Minimum valid year\n        allow_future: Whether future years are allowed\n\n    Returns:\n        int: Validated year\n\n    Raises:\n        ValidationError: If year is invalid\n\n    Example:\n        >>> validate_year(2025)\n        2025\n        >>> validate_year(None)\n        2025  # Current year\n    \"\"\"\n    current_year = datetime.now().year\n\n    if year is None:\n        return current_year\n\n    if not isinstance(year, int):\n        raise ValidationError(f\"Year must be integer, got {type(year)}\")\n\n    if year \u003C min_year:\n        raise ValidationError(\n            f\"Year {year} is too old (minimum: {min_year})\"\n        )\n\n    if not allow_future and year > current_year:\n        raise ValidationError(\n            f\"Year {year} is in the future (current: {current_year})\"\n        )\n\n    return year\n\n\ndef validate_state(state: str, country: str = \"US\") -> str:\n    \"\"\"Validate state\u002Fregion parameter.\"\"\"\n    # Country-specific validation\n    # ...\n    return state.upper()\n\n\n# Add more validators for domain-specific parameters...\n```\n\n**Template 2: data_validator.py**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nData validators for {skill-name}.\nValidates API responses and analysis outputs.\n\"\"\"\n\nimport pandas as pd\nfrom typing import Dict, List, Any\nfrom dataclasses import dataclass\nfrom enum import Enum\n\n\nclass ValidationLevel(Enum):\n    \"\"\"Severity levels for validation results.\"\"\"\n    CRITICAL = \"critical\"  # Must fix\n    WARNING = \"warning\"    # Should review\n    INFO = \"info\"          # FYI\n\n\n@dataclass\nclass ValidationResult:\n    \"\"\"Single validation check result.\"\"\"\n    check_name: str\n    level: ValidationLevel\n    passed: bool\n    message: str\n    details: Optional[Dict] = None\n\n\nclass ValidationReport:\n    \"\"\"Collection of validation results.\"\"\"\n\n    def __init__(self):\n        self.results: List[ValidationResult] = []\n\n    def add(self, result: ValidationResult):\n        \"\"\"Add validation result.\"\"\"\n        self.results.append(result)\n\n    def has_critical_issues(self) -> bool:\n        \"\"\"Check if any critical issues found.\"\"\"\n        return any(\n            r.level == ValidationLevel.CRITICAL and not r.passed\n            for r in self.results\n        )\n\n    def all_passed(self) -> bool:\n        \"\"\"Check if all validations passed.\"\"\"\n        return all(r.passed for r in self.results)\n\n    def get_warnings(self) -> List[str]:\n        \"\"\"Get all warning messages.\"\"\"\n        return [\n            r.message for r in self.results\n            if r.level == ValidationLevel.WARNING and not r.passed\n        ]\n\n    def get_summary(self) -> str:\n        \"\"\"Get summary of validation results.\"\"\"\n        total = len(self.results)\n        passed = sum(1 for r in self.results if r.passed)\n        critical = sum(\n            1 for r in self.results\n            if r.level == ValidationLevel.CRITICAL and not r.passed\n        )\n\n        return (\n            f\"Validation: {passed}\u002F{total} passed \"\n            f\"({critical} critical issues)\"\n        )\n\n\nclass DataValidator:\n    \"\"\"Validates API responses and DataFrames.\"\"\"\n\n    def validate_response(self, data: Any) -> ValidationReport:\n        \"\"\"\n        Validate raw API response.\n\n        Args:\n            data: Raw API response\n\n        Returns:\n            ValidationReport with results\n        \"\"\"\n        report = ValidationReport()\n\n        # Check 1: Not empty\n        report.add(ValidationResult(\n            check_name=\"not_empty\",\n            level=ValidationLevel.CRITICAL,\n            passed=bool(data),\n            message=\"Data is empty\" if not data else \"Data present\"\n        ))\n\n        # Check 2: Correct type\n        expected_type = (list, dict)\n        is_correct_type = isinstance(data, expected_type)\n        report.add(ValidationResult(\n            check_name=\"correct_type\",\n            level=ValidationLevel.CRITICAL,\n            passed=is_correct_type,\n            message=f\"Expected {expected_type}, got {type(data)}\"\n        ))\n\n        # Check 3: Has expected structure\n        if isinstance(data, dict):\n            has_data_key = 'data' in data\n            report.add(ValidationResult(\n                check_name=\"has_data_key\",\n                level=ValidationLevel.WARNING,\n                passed=has_data_key,\n                message=\"Response has 'data' key\" if has_data_key else \"No 'data' key\"\n            ))\n\n        return report\n\n    def validate_dataframe(self, df: pd.DataFrame, data_type: str) -> ValidationReport:\n        \"\"\"\n        Validate parsed DataFrame.\n\n        Args:\n            df: Parsed DataFrame\n            data_type: Type of data (for type-specific checks)\n\n        Returns:\n            ValidationReport\n        \"\"\"\n        report = ValidationReport()\n\n        # Check 1: Not empty\n        report.add(ValidationResult(\n            check_name=\"not_empty\",\n            level=ValidationLevel.CRITICAL,\n            passed=len(df) > 0,\n            message=f\"DataFrame has {len(df)} rows\"\n        ))\n\n        # Check 2: Required columns\n        required = ['entity', 'year']  # Customize per type\n        missing = set(required) - set(df.columns)\n        report.add(ValidationResult(\n            check_name=\"required_columns\",\n            level=ValidationLevel.CRITICAL,\n            passed=len(missing) == 0,\n            message=f\"Missing columns: {missing}\" if missing else \"All required columns present\"\n        ))\n\n        # Check 3: No excessive NaN values\n        if len(df) > 0:\n            nan_pct = (df.isna().sum() \u002F len(df) * 100).max()\n            report.add(ValidationResult(\n                check_name=\"nan_threshold\",\n                level=ValidationLevel.WARNING,\n                passed=nan_pct \u003C 30,\n                message=f\"Max NaN: {nan_pct:.1f}% ({'OK' if nan_pct \u003C 30 else 'HIGH'})\"\n            ))\n\n        # Check 4: Data types correct\n        if 'year' in df.columns:\n            is_int = pd.api.types.is_integer_dtype(df['year'])\n            report.add(ValidationResult(\n                check_name=\"year_type\",\n                level=ValidationLevel.CRITICAL,\n                passed=is_int,\n                message=\"'year' is integer\" if is_int else \"'year' is not integer\"\n            ))\n\n        return report\n\n\ndef validate_{type}_output(result: Dict) -> ValidationReport:\n    \"\"\"\n    Validate analysis output for {type}.\n\n    Args:\n        result: Analysis result dict\n\n    Returns:\n        ValidationReport\n    \"\"\"\n    report = ValidationReport()\n\n    # Check required keys\n    required_keys = ['year', 'year_info', 'data']\n    for key in required_keys:\n        report.add(ValidationResult(\n            check_name=f\"has_{key}\",\n            level=ValidationLevel.CRITICAL,\n            passed=key in result,\n            message=f\"'{key}' present\" if key in result else f\"Missing '{key}'\"\n        ))\n\n    # Check data quality\n    if 'data' in result and result['data']:\n        report.add(ValidationResult(\n            check_name=\"data_not_empty\",\n            level=ValidationLevel.CRITICAL,\n            passed=True,\n            message=\"Data is present\"\n        ))\n\n    return report\n\n\n# Main for testing\nif __name__ == \"__main__\":\n    print(\"Testing validators...\")\n\n    # Test entity validator\n    print(\"\\n1. Testing validate_entity():\")\n    try:\n        entity = validate_entity(\"corn\", [\"CORN\", \"SOYBEANS\"])\n        print(f\"   ✓ Valid: {entity}\")\n    except ValidationError as e:\n        print(f\"   ✗ Error: {e}\")\n\n    # Test year validator\n    print(\"\\n2. Testing validate_year():\")\n    year = validate_year(2025)\n    print(f\"   ✓ Valid: {year}\")\n\n    # Test DataValidator\n    print(\"\\n3. Testing DataValidator:\")\n    validator = DataValidator()\n    sample_data = [{'entity': 'CORN', 'year': 2025}]\n    report = validator.validate_response(sample_data)\n    print(f\"   {report.get_summary()}\")\n```\n\n**Template 3: temporal_validator.py**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nTemporal validators for {skill-name}.\nChecks temporal consistency and data age.\n\"\"\"\n\nimport pandas as pd\nfrom datetime import datetime, timedelta\nfrom typing import List\nfrom .data_validator import ValidationResult, ValidationReport, ValidationLevel\n\n\ndef validate_temporal_consistency(df: pd.DataFrame) -> ValidationReport:\n    \"\"\"\n    Check temporal consistency in data.\n\n    Validations:\n    - No future dates\n    - Years in valid range\n    - No suspicious gaps in time series\n    - Data age is acceptable\n\n    Args:\n        df: DataFrame with 'year' column\n\n    Returns:\n        ValidationReport\n    \"\"\"\n    report = ValidationReport()\n    current_year = datetime.now().year\n\n    if 'year' not in df.columns:\n        report.add(ValidationResult(\n            check_name=\"has_year_column\",\n            level=ValidationLevel.CRITICAL,\n            passed=False,\n            message=\"Missing 'year' column\"\n        ))\n        return report\n\n    # Check 1: No future years\n    max_year = df['year'].max()\n    report.add(ValidationResult(\n        check_name=\"no_future_years\",\n        level=ValidationLevel.CRITICAL,\n        passed=max_year \u003C= current_year,\n        message=f\"Max year: {max_year} ({'valid' if max_year \u003C= current_year else 'FUTURE!'})\"\n    ))\n\n    # Check 2: Years in reasonable range\n    min_year = df['year'].min()\n    is_reasonable = min_year >= 1900\n    report.add(ValidationResult(\n        check_name=\"reasonable_year_range\",\n        level=ValidationLevel.WARNING,\n        passed=is_reasonable,\n        message=f\"Year range: {min_year}-{max_year}\"\n    ))\n\n    # Check 3: Data age (is data recent enough?)\n    data_age_years = current_year - max_year\n    is_recent = data_age_years \u003C= 2\n    report.add(ValidationResult(\n        check_name=\"data_freshness\",\n        level=ValidationLevel.WARNING,\n        passed=is_recent,\n        message=f\"Data age: {data_age_years} years ({'recent' if is_recent else 'STALE'})\"\n    ))\n\n    # Check 4: No suspicious gaps in time series\n    if len(df['year'].unique()) > 2:\n        years_sorted = sorted(df['year'].unique())\n        gaps = [\n            years_sorted[i+1] - years_sorted[i]\n            for i in range(len(years_sorted)-1)\n        ]\n        max_gap = max(gaps) if gaps else 0\n        has_large_gap = max_gap > 2\n\n        report.add(ValidationResult(\n            check_name=\"no_large_gaps\",\n            level=ValidationLevel.WARNING,\n            passed=not has_large_gap,\n            message=f\"Max gap: {max_gap} years\" + (\" (suspicious)\" if has_large_gap else \"\")\n        ))\n\n    return report\n\n\ndef validate_week_number(week: int, year: int) -> ValidationResult:\n    \"\"\"Validate week number is in valid range for year.\"\"\"\n    # Most data types use weeks 1-53\n    is_valid = 1 \u003C= week \u003C= 53\n\n    return ValidationResult(\n        check_name=\"valid_week\",\n        level=ValidationLevel.CRITICAL,\n        passed=is_valid,\n        message=f\"Week {week} ({'valid' if is_valid else 'INVALID: must be 1-53'})\"\n    )\n\n\n# Add more temporal validators as needed...\n```\n\n**Template 4: completeness_validator.py**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nCompleteness validators for {skill-name}.\nChecks data completeness and coverage.\n\"\"\"\n\nimport pandas as pd\nfrom typing import List, Set\nfrom .data_validator import ValidationResult, ValidationReport, ValidationLevel\n\n\ndef validate_completeness(\n    df: pd.DataFrame,\n    expected_entities: Optional[List[str]] = None,\n    expected_years: Optional[List[int]] = None\n) -> ValidationReport:\n    \"\"\"\n    Validate data completeness.\n\n    Args:\n        df: DataFrame to validate\n        expected_entities: Expected entities (None to skip)\n        expected_years: Expected years (None to skip)\n\n    Returns:\n        ValidationReport\n    \"\"\"\n    report = ValidationReport()\n\n    # Check 1: All expected entities present\n    if expected_entities:\n        actual_entities = set(df['entity'].unique())\n        expected_set = set(expected_entities)\n        missing = expected_set - actual_entities\n\n        report.add(ValidationResult(\n            check_name=\"all_entities_present\",\n            level=ValidationLevel.WARNING,\n            passed=len(missing) == 0,\n            message=f\"Missing entities: {missing}\" if missing else \"All entities present\",\n            details={'missing': list(missing)}\n        ))\n\n    # Check 2: All expected years present\n    if expected_years:\n        actual_years = set(df['year'].unique())\n        expected_set = set(expected_years)\n        missing = expected_set - actual_years\n\n        report.add(ValidationResult(\n            check_name=\"all_years_present\",\n            level=ValidationLevel.WARNING,\n            passed=len(missing) == 0,\n            message=f\"Missing years: {missing}\" if missing else \"All years present\"\n        ))\n\n    # Check 3: No excessive nulls in critical columns\n    critical_columns = ['entity', 'year']  # Customize\n    for col in critical_columns:\n        if col in df.columns:\n            null_count = df[col].isna().sum()\n            report.add(ValidationResult(\n                check_name=f\"{col}_no_nulls\",\n                level=ValidationLevel.CRITICAL,\n                passed=null_count == 0,\n                message=f\"'{col}' has {null_count} nulls\"\n            ))\n\n    # Check 4: Coverage percentage\n    if expected_entities and expected_years:\n        expected_total = len(expected_entities) * len(expected_years)\n        actual_total = len(df)\n        coverage_pct = (actual_total \u002F expected_total) * 100 if expected_total > 0 else 0\n\n        report.add(ValidationResult(\n            check_name=\"coverage_percentage\",\n            level=ValidationLevel.INFO,\n            passed=coverage_pct >= 80,\n            message=f\"Coverage: {coverage_pct:.1f}% ({actual_total}\u002F{expected_total})\"\n        ))\n\n    return report\n```\n\n**Integration in analysis functions:**\n\n```python\ndef {analysis_function}(entity: str, year: Optional[int] = None, ...) -> Dict:\n    \"\"\"Analysis function with validation.\"\"\"\n    from utils.validators.parameter_validator import validate_entity, validate_year\n    from utils.validators.data_validator import DataValidator\n    from utils.validators.temporal_validator import validate_temporal_consistency\n\n    # VALIDATE INPUTS (before doing anything!)\n    entity = validate_entity(entity, valid_entities=[...])\n    year = validate_year(year)\n\n    # Fetch data\n    data = fetch_{metric}(entity, year)\n\n    # VALIDATE API RESPONSE\n    validator = DataValidator()\n    response_validation = validator.validate_response(data)\n\n    if response_validation.has_critical_issues():\n        raise DataQualityError(\n            f\"API response validation failed: {response_validation.get_summary()}\"\n        )\n\n    # Parse\n    df = parse_{type}(data)\n\n    # VALIDATE PARSED DATA\n    df_validation = validator.validate_dataframe(df, '{type}')\n    temporal_validation = validate_temporal_consistency(df)\n\n    if df_validation.has_critical_issues():\n        raise DataQualityError(\n            f\"Data validation failed: {df_validation.get_summary()}\"\n        )\n\n    # Analyze\n    results = analyze(df)\n\n    # Return with validation info\n    return {\n        'data': results,\n        'year': year,\n        'year_info': format_year_message(year, year_requested),\n        'validation': {\n            'passed': df_validation.all_passed(),\n            'warnings': df_validation.get_warnings(),\n            'report': df_validation.get_summary()\n        }\n    }\n```\n\n**Impact:**\n- ✅ Reliable data (validated at multiple layers)\n- ✅ Transparency (user sees validation report)\n- ✅ Clear error messages (not just \"generic error\")\n- ✅ Problem detection (gaps, nulls, inconsistencies)\n\n---\n\n**4. Write references**\n\nFor each reference file:\n\n- 1000-2000 words\n- Useful content (examples, methodologies, guides)\n- Well structured (headings, lists, code blocks)\n- Well-formatted markdown\n\n**5. Create assets**\n\n- Syntactically valid JSONs\n- Real values with comments\n- Logical structure\n\n**6. Write README.md**\n\n- Step-by-step installation\n- Required configuration\n- Usage examples\n- Troubleshooting\n\n**7. Create DECISIONS.md**\n\nDocument all decisions made:\n\n- Which API chosen and why\n- Which analyses defined and justification\n- Structure chosen and rationale\n- Trade-offs considered\n\n**8. Create VERSION and CHANGELOG.md** (🆕 Enhancement #7 - Versioning)\n\n**8.1 Create VERSION file:**\n\n```\n1.0.0\n```\n\n**8.2 Create CHANGELOG.md:**\n\n```markdown\n# Changelog\n\nAll notable changes to {skill-name} will be documented here.\n\nFormat based on [Keep a Changelog](https:\u002F\u002Fkeepachangelog.com\u002Fen\u002F1.0.0\u002F).\nVersioning follows [Semantic Versioning](https:\u002F\u002Fsemver.org\u002F).\n\n## [1.0.0] - {current_date}\n\n### Added\n\n**Core Functionality:**\n- {function1}: {Description of what it does}\n- {function2}: {Description of what it does}\n- {function3}: {Description of what it does}\n...\n\n**Data Sources:**\n- {API_name}: {Coverage description}\n- Authentication: {auth_method}\n- Rate limit: {limit}\n\n**Analysis Capabilities:**\n- {analysis1}: {Description and methodology}\n- {analysis2}: {Description and methodology}\n...\n\n**Utilities:**\n- Cache system with {TTL} TTL\n- Rate limiting: {limit} per {period}\n- Error handling with automatic retries\n- Data validation and quality checks\n\n### Data Coverage\n\n**Metrics implemented:**\n- {metric1}: {Coverage details}\n- {metric2}: {Coverage details}\n...\n\n**Geographic coverage:** {geo_coverage}\n**Temporal coverage:** {temporal_coverage}\n\n### Known Limitations\n\n- {limitation1}\n- {limitation2}\n...\n\n### Planned for v2.0\n\n- {planned_feature1}\n- {planned_feature2}\n...\n\n## [Unreleased]\n\n### Planned\n\n- Add support for {feature}\n- Improve performance for {scenario}\n- Expand coverage to {new_area}\n```\n\n**8.3 Update marketplace.json with version:**\n\nEdit `.claude-plugin\u002Fmarketplace.json` to include:\n\n```json\n{\n  \"metadata\": {\n    \"description\": \"...\",\n    \"version\": \"1.0.0\",\n    \"created\": \"{current_date}\",\n    \"updated\": \"{current_date}\"\n  }\n}\n```\n\n**8.4 Create .bumpversion.cfg (optional):**\n\nIf you want version automation:\n\n```ini\n[bumpversion]\ncurrent_version = 1.0.0\ncommit = False\ntag = False\n\n[bumpversion:file:VERSION]\n\n[bumpversion:file:.claude-plugin\u002Fmarketplace.json]\nsearch = \"version\": \"{current_version}\"\nreplace = \"version\": \"{new_version}\"\n\n[bumpversion:file:CHANGELOG.md]\nsearch = ## [Unreleased]\nreplace = ## [Unreleased]\n\n## [{new_version}] - {now:%Y-%m-%d}\n```\n\n**Impact:**\n- ✅ Change traceability\n- ✅ Professionalism\n- ✅ Facilitates future updates\n- ✅ Users know what changed between versions\n\n**9. Create INSTALLATION.md** (Didactic Tutorial)\n\n[Content of INSTALLATION.md as previously specified]\n\n### Practical Implementation\n\n**Create agent in subdirectory**:\n\n```bash\n# Agent name based on domain\u002Fobjective\nagent_name=\"nass-usda-agriculture\"  # example\n\n# Create structure\nmkdir -p $agent_name\u002F{scripts\u002Futils,references,assets,data}\n\n# Implement each file\n# [Claude creates each file with Write tool]\n```\n\n**At the end, inform user**:\n\n```\n✅ Agent created in .\u002F{agent_name}\u002F\n\n📁 Structure:\n- .claude-plugin\u002Fmarketplace.json ✅ (installation + version)\n- SKILL.md (6,200 words)\n- scripts\u002F (2,500+ lines of code)\n  ├─ utils\u002Fhelpers.py ✅ (temporal context)\n  ├─ utils\u002Fvalidators\u002F ✅ (4 validators, ~800 lines)\n  ├─ parse_{type}*.py ✅ (1 per data type, modular)\n  └─ comprehensive_{domain}_report() ✅\n- tests\u002F (25+ tests, ~800 lines) ✅\n  ├─ test_integration.py (end-to-end)\n  ├─ test_parse.py (all parsers)\n  ├─ test_helpers.py (temporal)\n  └─ test_validation.py (validators)\n- references\u002F (5,000 words)\n- assets\u002F (2 configs)\n- README.md (1,000+ words with Testing section)\n- INSTALLATION.md (1,500 words) ✅\n- DECISIONS.md (justifications)\n- VERSION (1.0.0) ✅\n- CHANGELOG.md (release notes) ✅\n\n🚀 To install:\n\u002Fplugin marketplace add .\u002F{agent_name}\n\n💡 Usage examples:\n\"[example 1]\"\n\"[example 2]\"\n```\n\n**See** `references\u002Fphase5-implementation.md` for complete implementation guide.\n\n## Complete Flow: Step-by-Step\n\n### User Input\n\nUser describes workflow\u002Fobjective:\n\n```\n\"Every day I download US crop data from USDA,\ncompare current year vs previous, create state ranking\nby production, and generate report. Takes 2 hours.\nAutomate this.\"\n```\n\n### Autonomous Execution\n\n**Claude executes internally** (doesn't need to show everything):\n\n**PHASE 1**: Discovery (~5-10 min)\n\n```\n[WebSearch: \"USDA API free agriculture data\"]\n[WebFetch: NASS API docs]\n[Compare: NASS vs ERS vs FAO]\n→ DECISION: NASS QuickStats API\n   Justification: Free, data since 1866, all crops, state-level\n```\n\n**PHASE 2**: Design (~5 min)\n\n```\n[Analyze: \"compare years\", \"state ranking\", \"generate report\"]\n→ DEFINE analyses:\n  1. YoY comparison (compare years)\n  2. State ranking (state ranking)\n  3. Trend analysis (if user asks for trends)\n  4. Report generator (generate report)\n```\n\n**PHASE 3**: Architecture (~5 min)\n\n```\n→ STRUCTURE:\n  scripts\u002F\n    - fetch_nass.py (API requests)\n    - parse_nass.py (parsing)\n    - analyze_nass.py (YoY, ranking, trends)\n    - generate_report.py (report)\n    utils\u002F\n      - cache_manager.py\n      - rate_limiter.py\n  references\u002F\n    - nass-api-guide.md\n    - analysis-methods.md\n    - report-templates.md\n  assets\u002F\n    - config.json\n    - metadata.json\n```\n\n**PHASE 4**: Detection (~2 min)\n\n```\n→ KEYWORDS:\n  Entities: USDA, NASS, agriculture, crops\n  Commodities: corn, soybeans, wheat\n  Metrics: production, area, yield\n  Actions: compare, ranking, trend\n  Geography: US, states, Iowa, Illinois\n\n→ DESCRIPTION: \"This skill should be used when user\n  asks about US agriculture, production, area,\n  crop yield...\"\n```\n\n**PHASE 5**: Implementation (~45 min)\n\n```\n[Write: SKILL.md] ✅ 6,000 words\n[Write: fetch_nass.py] ✅ 280 lines\n[Write: parse_nass.py] ✅ 180 lines\n[Write: analyze_nass.py] ✅ 520 lines\n[Write: generate_report.py] ✅ 200 lines\n[Write: utils\u002Fcache_manager.py] ✅ 120 lines\n[Write: utils\u002Frate_limiter.py] ✅ 110 lines\n[Write: references\u002Fnass-api-guide.md] ✅ 1,500 words\n[Write: references\u002Fanalysis-methods.md] ✅ 2,000 words\n[Write: references\u002Freport-templates.md] ✅ 1,000 words\n[Write: assets\u002Fconfig.json] ✅\n[Write: assets\u002Fmetadata.json] ✅\n[Write: README.md] ✅ 800 words\n[Write: DECISIONS.md] ✅ 600 words\n```\n\n### User Output\n\n```\n✅ Agent created: .\u002Fusda-agriculture-agent\u002F\n\n📊 Technical Decisions:\n- API: USDA NASS QuickStats (free, data since 1866)\n- Analyses: YoY, Ranking, Trends, Report Generation\n- Structure: 4 main scripts + 2 utils\n- Cache: Historical permanent, current 7 days\n\n📁 Files Created:\n- SKILL.md: 6,000 words\n- Python code: 2,500+ lines\n  ├─ Modular parsers (1 per type)\n  ├─ Validation system (800 lines)\n  ├─ Temporal helpers\n  └─ comprehensive_report()\n- Tests: 25+ tests (800 lines)\n- References: 4,500 words\n- Configs: 2 files\n- README: Complete (with Testing)\n- INSTALLATION.md: Didactic tutorial\n- VERSION: 1.0.0\n- CHANGELOG.md: Complete release notes\n\n🎯 Estimated Savings:\n- Before: 2 hours\u002Fday\n- After: 3 minutes\u002Fday\n- Savings: 98.5% (117h\u002Fmonth → 1.5h\u002Fmonth)\n\n🚀 To install and use:\n\n# 1. Get API key (free):\nVisit: https:\u002F\u002Fquickstats.nass.usda.gov\u002Fapi#registration\n\n# 2. Configure:\nexport NASS_API_KEY=\"your_key_here\"\n\n# 3. Install skill:\n\u002Fplugin marketplace add .\u002Fusda-agriculture-agent\n\n# 4. Use (examples):\n\"US corn production in 2023\"\n\"Compare soybeans this year vs last year\"\n\"Ranking of wheat producing states\"\n\"Generate current crop report\"\n```\n\n## Detailed References\n\nFor details of each phase, load references:\n\n- `references\u002Fphase1-discovery.md`: API research and decision\n- `references\u002Fphase2-design.md`: Analysis definition\n- `references\u002Fphase3-architecture.md`: Project structuring\n- `references\u002Fphase4-detection.md`: Keywords and automatic activation\n- `references\u002Fphase5-implementation.md`: Code implementation\n- `references\u002Fquality-standards.md`: Mandatory standards\n- `references\u002Fexamples.md`: Complete examples of created agents\n\n## Meta-Skill Usage Examples\n\n### Example 1: Simple Workflow\n\n```\n👤 \"Automate: download weather data, calculate averages,\n    generate chart. I do this every week, takes 1h.\"\n\n🤖 [Activates agent-creator]\n   [Phase 1]: Research → NOAA API\n   [Phase 2]: Defines → Download, Aggregation, Visualization\n   [Phase 3]: Structure → 3 scripts + 2 utils\n   [Phase 4]: Keywords → weather, climate, temperature, NOAA\n   [Phase 5]: Implements everything\n\n   ✅ Agent created: .\u002Fweather-analysis-agent\u002F\n   [Installation instructions]\n```\n\n### Example 2: Complex Workflow\n\n```\n👤 \"I need an agent for stock financial analysis:\n    fetch prices, calculate technical indicators (RSI, MACD),\n    compare with benchmarks, generate alerts. Daily, 3h.\"\n\n🤖 [Activates agent-creator]\n   [Phase 1]: Research → Alpha Vantage API (or Yahoo Finance)\n   [Phase 2]: Defines → Price fetching, Technical indicators,\n             Benchmark comparison, Alert system\n   [Phase 3]: Structure → 5 scripts + 4 utils\n   [Phase 4]: Keywords → stock, RSI, MACD, technical analysis\n   [Phase 5]: Implements\n\n   ✅ Agent created: .\u002Fstock-technical-analysis-agent\u002F\n```\n\n### Example 3: Just Vague Description\n\n```\n👤 \"Create an agent for Brazilian agriculture\"\n\n🤖 [Activates agent-creator]\n\n   \"Got it! I'll create an agent for Brazilian agriculture.\n\n   A few quick questions:\n   - Focus on which crops? (soy, corn, coffee, all?)\n   - Desired analyses? (production, prices, exports?)\n   - Preferred source? (CONAB, IBGE, both?)\n\n   Or I can decide based on most common use cases\n   (grain production via CONAB). Prefer I decide?\"\n\n👤 \"You decide, focus on grain production.\"\n\n🤖 [Phase 1]: CONAB Grain Survey\n   [Phase 2]: YoY, Ranking, Regional, Trends\n   [Phase 3-5]: Creates everything\n\n   ✅ Agent created: .\u002Fconab-agriculture-agent\u002F\n```\n\n---\n\n## PHASE 6: Test Suite Generation (🆕 Enhancement #4 - MANDATORY!)\n\n**Objective**: Generate comprehensive test suite that validates ALL functions\n\n**⚠️ COMMON PROBLEM:** v1.0 without tests. Difficult to validate code works, impossible to do regression testing.\n\n**Solution:** Automatically generate 25+ tests covering all layers!\n\n### Test Structure\n\n```\ntests\u002F\n├── __init__.py\n├── test_fetch.py            # Test API fetch functions\n├── test_parse.py            # Test each parser\n├── test_analyze.py          # Test analysis functions\n├── test_integration.py      # End-to-end tests\n├── test_validation.py       # Test validators\n├── test_helpers.py          # Test temporal helpers\n└── conftest.py              # Shared fixtures (pytest)\n```\n\n### Template 1: test_integration.py (MAIN!)\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nIntegration tests for {skill-name}.\nTests complete workflows from query to result.\n\"\"\"\n\nimport sys\nfrom pathlib import Path\n\n# Add scripts to path\nsys.path.insert(0, str(Path(__file__).parent.parent \u002F 'scripts'))\n\nfrom analyze_{domain} import (\n    {function1},\n    {function2},\n    {function3},\n    comprehensive_{domain}_report\n)\n\n\ndef test_{function1}_basic():\n    \"\"\"Test {function1} with auto-year detection.\"\"\"\n    print(f\"\\n✓ Testing {function1}()...\")\n\n    try:\n        # Test auto-year detection (year=None)\n        result = {function1}('{example_entity}')\n\n        # Validations\n        assert 'year' in result, \"Missing 'year' in result\"\n        assert 'year_info' in result, \"Missing 'year_info'\"\n        assert 'data' in result, \"Missing 'data'\"\n        assert result['year'] >= 2024, f\"Year too old: {result['year']}\"\n\n        print(f\"  ✓ Auto-year working: {result['year']}\")\n        print(f\"  ✓ Year info: {result['year_info']}\")\n        print(f\"  ✓ Data present: {len(result.get('data', {}))} fields\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        import traceback\n        traceback.print_exc()\n        return False\n\n\ndef test_{function1}_specific_year():\n    \"\"\"Test {function1} with specific year.\"\"\"\n    print(f\"\\n✓ Testing {function1}(year=2024)...\")\n\n    try:\n        result = {function1}('{example_entity}', year=2024)\n\n        assert result['year'] == 2024, \"Requested year not used\"\n        assert result['year_requested'] == 2024, \"year_requested not tracked\"\n\n        print(f\"  ✓ Specific year working: {result['year']}\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\ndef test_{function2}_comparison():\n    \"\"\"Test {function2} (comparison function).\"\"\"\n    print(f\"\\n✓ Testing {function2}()...\")\n\n    try:\n        result = {function2}('{example_entity}', year1=2024, year2=2023)\n\n        # Validations specific to comparison\n        assert 'change_percent' in result, \"Missing 'change_percent'\"\n        assert isinstance(result['change_percent'], (int, float)), \"change_percent not numeric\"\n\n        print(f\"  ✓ Comparison working: {result.get('change_percent')}% change\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\ndef test_comprehensive_report():\n    \"\"\"Test comprehensive report (all-in-one function).\"\"\"\n    print(f\"\\n✓ Testing comprehensive_{domain}_report()...\")\n\n    try:\n        result = comprehensive_{domain}_report('{example_entity}')\n\n        # Validations\n        assert 'metrics' in result, \"Missing 'metrics'\"\n        assert 'summary' in result, \"Missing 'summary'\"\n        assert 'alerts' in result, \"Missing 'alerts'\"\n        assert isinstance(result['metrics'], dict), \"'metrics' must be dict\"\n\n        metrics_count = len(result['metrics'])\n        print(f\"  ✓ Comprehensive report working\")\n        print(f\"  ✓ Metrics combined: {metrics_count}\")\n        print(f\"  ✓ Summary: {result['summary'][:100]}...\")\n        print(f\"  ✓ Alerts: {len(result['alerts'])}\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\ndef test_validation_integration():\n    \"\"\"Test that validation is integrated in functions.\"\"\"\n    print(f\"\\n✓ Testing validation integration...\")\n\n    try:\n        result = {function1}('{example_entity}')\n\n        # Check validation info is present\n        assert 'validation' in result, \"Missing 'validation' info\"\n        assert 'passed' in result['validation'], \"Missing validation.passed\"\n        assert 'report' in result['validation'], \"Missing validation.report\"\n\n        print(f\"  ✓ Validation present: {result['validation']['report']}\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\ndef main():\n    \"\"\"Run all integration tests.\"\"\"\n    print(\"=\" * 70)\n    print(\"INTEGRATION TESTS - {skill-name}\")\n    print(\"=\" * 70)\n\n    tests = [\n        (\"Auto-year detection\", test_{function1}_basic),\n        (\"Specific year\", test_{function1}_specific_year),\n        (\"Comparison function\", test_{function2}_comparison),\n        (\"Comprehensive report\", test_comprehensive_report),\n        (\"Validation integration\", test_validation_integration),\n    ]\n\n    results = []\n    for test_name, test_func in tests:\n        passed = test_func()\n        results.append((test_name, passed))\n\n    # Summary\n    print(\"\\n\" + \"=\" * 70)\n    print(\"SUMMARY\")\n    print(\"=\" * 70)\n\n    for test_name, passed in results:\n        status = \"✅ PASS\" if passed else \"❌ FAIL\"\n        print(f\"{status}: {test_name}\")\n\n    passed_count = sum(1 for _, p in results if p)\n    total_count = len(results)\n\n    print(f\"\\nResults: {passed_count}\u002F{total_count} passed\")\n\n    return passed_count == total_count\n\n\nif __name__ == \"__main__\":\n    success = main()\n    sys.exit(0 if success else 1)\n```\n\n### Template 2: test_parse.py\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"Tests for parsers.\"\"\"\n\nimport sys\nfrom pathlib import Path\nimport pandas as pd\n\nsys.path.insert(0, str(Path(__file__).parent.parent \u002F 'scripts'))\n\nfrom parse_{type1} import parse_{type1}_response\nfrom parse_{type2} import parse_{type2}_response\n# Import all parsers...\n\n\ndef test_parse_{type1}():\n    \"\"\"Test {type1} parser.\"\"\"\n    print(\"\\n✓ Testing parse_{type1}_response()...\")\n\n    sample_data = [\n        {'{field1}': 'VALUE1', '{field2}': 2025, '{field3}': '1,234,567'}\n    ]\n\n    try:\n        df = parse_{type1}_response(sample_data)\n\n        # Validations\n        assert isinstance(df, pd.DataFrame), \"Must return DataFrame\"\n        assert len(df) == 1, f\"Expected 1 row, got {len(df)}\"\n        assert 'entity' in df.columns, \"Missing 'entity' column\"\n        assert 'year' in df.columns, \"Missing 'year' column\"\n\n        print(f\"  ✓ Parsed: {len(df)} records\")\n        print(f\"  ✓ Columns: {list(df.columns)}\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\n# Repeat for all parsers...\n\ndef main():\n    \"\"\"Run parser tests.\"\"\"\n    tests = [\n        test_parse_{type1},\n        test_parse_{type2},\n        # Add all...\n    ]\n\n    passed = sum(1 for test in tests if test())\n    print(f\"\\nResults: {passed}\u002F{len(tests)} passed\")\n\n    return passed == len(tests)\n\n\nif __name__ == \"__main__\":\n    sys.exit(0 if main() else 1)\n```\n\n### Template 3: test_helpers.py\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"Tests for temporal helpers.\"\"\"\n\nimport sys\nfrom pathlib import Path\nfrom datetime import datetime\n\nsys.path.insert(0, str(Path(__file__).parent.parent \u002F 'scripts'))\n\nfrom utils.helpers import (\n    get_current_{domain}_year,\n    get_{domain}_year_with_fallback,\n    should_try_previous_year,\n    format_year_message\n)\n\n\ndef test_get_current_year():\n    \"\"\"Test current year detection.\"\"\"\n    year = get_current_{domain}_year()\n    current = datetime.now().year\n\n    assert year == current, f\"Expected {current}, got {year}\"\n    print(f\"✓ Current year: {year}\")\n    return True\n\n\ndef test_year_with_fallback():\n    \"\"\"Test year fallback logic.\"\"\"\n    primary, fallback = get_{domain}_year_with_fallback(2024)\n\n    assert primary == 2024, \"Primary should be 2024\"\n    assert fallback == 2023, \"Fallback should be 2023\"\n\n    print(f\"✓ Fallback: {primary} → {fallback}\")\n    return True\n\n\ndef test_format_year_message():\n    \"\"\"Test year message formatting.\"\"\"\n    msg = format_year_message(2024, 2025)\n\n    assert '2024' in msg, \"Must mention year used\"\n    assert '2025' in msg, \"Must mention year requested\"\n\n    print(f\"✓ Message: {msg}\")\n    return True\n\n\ndef main():\n    \"\"\"Run helper tests.\"\"\"\n    tests = [\n        test_get_current_year,\n        test_year_with_fallback,\n        test_format_year_message\n    ]\n\n    passed = sum(1 for test in tests if test())\n    print(f\"\\nResults: {passed}\u002F{len(tests)} passed\")\n\n    return passed == len(tests)\n\n\nif __name__ == \"__main__\":\n    sys.exit(0 if main() else 1)\n```\n\n### Minimum Test Coverage\n\n**For skill to be considered complete, needs:**\n\n- [ ] test_integration.py with ≥5 end-to-end tests\n- [ ] test_parse.py with 1 test per parser\n- [ ] test_analyze.py with 1 test per analysis function\n- [ ] test_helpers.py with ≥3 tests\n- [ ] test_validation.py with ≥5 tests\n- [ ] **Total:** ≥25 tests\n- [ ] **Coverage:** ≥80% of code\n- [ ] **All tests PASS**\n\n### How to test\n\nInclude in README.md:\n\n```markdown\n## Testing\n\n### Run All Tests\n\n```bash\ncd {skill-name}\npython3 tests\u002Ftest_integration.py\n```\n\n### Run Specific Tests\n\n```bash\npython3 tests\u002Ftest_parse.py\npython3 tests\u002Ftest_helpers.py\npython3 tests\u002Ftest_validation.py\n```\n\n### Expected Output\n\n```\n======================================================================\nINTEGRATION TESTS - {skill-name}\n======================================================================\n\n✓ Testing {function1}()...\n  ✓ Auto-year working: 2025\n  ✓ Data present: 8 fields\n\n✓ Testing {function2}()...\n  ✓ Comparison working: +12.3% change\n\n...\n\n======================================================================\nSUMMARY\n======================================================================\n✅ PASS: Auto-year detection\n✅ PASS: Specific year\n✅ PASS: Comparison function\n✅ PASS: Comprehensive report\n✅ PASS: Validation integration\n\nResults: 5\u002F5 passed\n```\n```\n\n### Test Suite Benefits\n\n- ✅ Reliability: Tested and working code\n- ✅ Regression testing: Detects breaks when modifying\n- ✅ Executable documentation: Tests show how to use\n- ✅ CI\u002FCD ready: Can run automatically\n- ✅ Professionalism: Production-quality skills\n\n**Impact:** Generated skills are tested and reliable from v1.0!\n\n---\n\n## Agent Creation Workflow: Checklist\n\nWhen creating an agent, follow this checklist RIGOROUSLY in order:\n\n---\n\n### 🚨 STEP 0: MANDATORY - FIRST STEP\n\n**Execute BEFORE anything else:**\n\n- [ ] 🚨 Create `.claude-plugin\u002Fmarketplace.json`\n- [ ] 🚨 Validate JSON syntax with python\n- [ ] 🚨 Verify mandatory fields filled\n- [ ] 🚨 Confirm: \"Marketplace.json created and validated - can proceed\"\n\n**🛑 DO NOT PROCEED without completing ALL items above!**\n\n---\n\n### ✅ Phase 1-4: Planning\n\n- [ ] Domain identified\n- [ ] API researched and decided (with justification)\n- [ ] **API completeness analysis** (Phase 1.6 - coverage ≥50%)\n- [ ] Analyses defined (4-6 main + comprehensive_report)\n- [ ] Structure planned (modular parsers, validators\u002F)\n- [ ] Keywords determined (≥60 unique)\n\n---\n\n### ✅ Phase 5: Implementation\n\n- [ ] .claude-plugin\u002Fmarketplace.json created FIRST\n- [ ] marketplace.json validated (syntax + fields)\n- [ ] SKILL.md created with correct frontmatter\n- [ ] **CRITICAL:** SKILL.md description copied to marketplace.json → plugins[0].description (IDENTICAL!)\n- [ ] Validate synchronization: SKILL.md description === marketplace.json\n- [ ] **MANDATORY:** utils\u002Fhelpers.py created (temporal context)\n- [ ] **MANDATORY:** utils\u002Fvalidators\u002F created (4 validators)\n- [ ] **MANDATORY:** Modular parsers (1 per data type)\n- [ ] **MANDATORY:** comprehensive_{domain}_report() implemented\n- [ ] DECISIONS.md documenting choices\n- [ ] VERSION file created (e.g., 1.0.0)\n- [ ] CHANGELOG.md created with complete v1.0.0 entry\n- [ ] marketplace.json with version field\n- [ ] Implement functional code (no TODOs)\n- [ ] Write complete docstrings\n- [ ] Add error handling\n- [ ] Write references with useful content\n- [ ] Create real configs\n- [ ] Write complete README\n- [ ] INSTALLATION.md with complete tutorial\n\n---\n\n### ✅ Phase 6: Test Suite\n\n- [ ] tests\u002F directory created\n- [ ] test_integration.py with ≥5 end-to-end tests\n- [ ] test_parse.py with 1 test per parser\n- [ ] test_analyze.py with 1 test per analysis function\n- [ ] test_helpers.py with ≥3 tests\n- [ ] test_validation.py with ≥5 tests\n- [ ] **Total:** ≥25 tests implemented\n- [ ] **ALL tests PASS** (execute and validate!)\n- [ ] \"Testing\" section added to README.md\n\n---\n\n### ✅ Final Validation\n\n- [ ] Validate marketplace.json again (syntax + synchronized description)\n- [ ] Validate other JSONs (configs, assets)\n- [ ] Verify imports work\n- [ ] Check no placeholder\u002FTODO\n- [ ] Test main logic manually\n- [ ] Verify README has all instructions\n- [ ] Calculate estimated ROI (time before vs after)\n\n---\n\n### 🚀 MANDATORY TEST - DO NOT SKIP THIS STEP!\n\n**Execute this command MANDATORY before delivering:**\n\n```bash\ncd \u002Fpath\u002Fto\u002Fskills\n\u002Fplugin marketplace add .\u002Fagent-name\n```\n\n**Verifications:**\n\n- [ ] ✅ Command executed without errors\n- [ ] ✅ Skill appears in installed plugins list\n- [ ] ✅ Claude recognizes the skill (do test question)\n\n**🛑 If test fails:**\n\n1. Verify marketplace.json exists\n2. Verify JSON is valid\n3. Verify description is synchronized\n4. Fix and test again\n\n**Only deliver to user AFTER installation test passes!**\n\n---\n\n### ✅ Deliver to User\n\n- [ ] Show created structure\n- [ ] Summarize main decisions\n- [ ] List files and sizes\n- [ ] Give installation instructions (command tested above)\n- [ ] Give 3-5 usage examples\n- [ ] Inform estimated ROI\n- [ ] **Confirm: \"Skill tested and installed successfully\"**\n\n## User Communication\n\n### During Creation\n\n**Show high-level progress**:\n\n```\n🔍 Phase 1: Researching APIs...\n   ✓ 5 options found\n   ✓ Decided: NASS API (free, complete data)\n\n🎨 Phase 2: Defining analyses...\n   ✓ 15 typical questions identified\n   ✓ 5 main analyses defined\n\n🏗️ Phase 3: Structuring project...\n   ✓ 3 scripts + 2 utils planned\n\n🎯 Phase 4: Defining detection...\n   ✓ 50+ keywords identified\n\n⚙️ Phase 5: Implementing code...\n   [Progress while creating files]\n   ✓ SKILL.md (6,200 words)\n   ✓ fetch_nass.py (280 lines)\n   ✓ parse_nass.py (180 lines)\n   [...]\n```\n\n**Don't show**: Technical details during creation (code blocks, etc). Just progress.\n\n### After Completion\n\n**Executive summary**:\n\n```\n✅ AGENT CREATED SUCCESSFULLY!\n\n📂 Location: .\u002Fusda-agriculture-agent\u002F\n\n📊 Main Decisions:\n- API: USDA NASS QuickStats\n- Analyses: YoY, Ranking, Trends, Reports\n- Implementation: 1,410 lines Python + 4,500 words docs\n\n💰 Estimated ROI:\n- Time before: 2h\u002Fday\n- Time after: 3min\u002Fday\n- Savings: 117h\u002Fmonth\n\n🎓 See DECISIONS.md for complete justifications.\n\n🚀 NEXT STEPS:\n\n1. Get API key (free):\n   https:\u002F\u002Fquickstats.nass.usda.gov\u002Fapi#registration\n\n2. Configure:\n   export NASS_API_KEY=\"your_key\"\n\n3. Install:\n   \u002Fplugin marketplace add .\u002Fusda-agriculture-agent\n\n4. Test:\n   \"US corn production in 2023\"\n   \"Compare soybeans this year vs last year\"\n\nSee README.md for complete instructions.\n```\n\n## Keywords for This Meta-Skill Detection\n\nThis meta-skill (agent-creator) is activated when user mentions:\n\n**Create\u002FDevelop**:\n\n- \"Create an agent\"\n- \"Develop agent\"\n- \"Create skill\"\n- \"Develop skill\"\n- \"Build agent\"\n\n**Automate**:\n\n- \"Automate this workflow\"\n- \"Automate this process\"\n- \"Automate this task\"\n- \"Need to automate\"\n- \"Turn into agent\"\n\n**Repetitive Workflow**:\n\n- \"Every day I do\"\n- \"Repeatedly need to\"\n- \"Manual process\"\n- \"Workflow that takes Xh\"\n- \"Task I repeat\"\n\n**Agent for Domain**:\n\n- \"Agent for [domain]\"\n- \"Custom skill for [domain]\"\n- \"Specialize Claude in [domain]\"\n\n## ⚠️ Troubleshooting: Common Marketplace.json Errors\n\n### Error: \"Failed to install plugin\"\n\n**Most common cause:** marketplace.json doesn't exist or is poorly formatted\n\n**Diagnosis:**\n\n```bash\n# 1. Verify file exists\nls -la agent-name\u002F.claude-plugin\u002Fmarketplace.json\n\n# 2. Validate JSON\npython3 -c \"import json; json.load(open('agent-name\u002F.claude-plugin\u002Fmarketplace.json'))\"\n\n# 3. View content\ncat agent-name\u002F.claude-plugin\u002Fmarketplace.json\n```\n\n**Solutions:**\n\n1. If file doesn't exist: Go back to STEP 0 and create\n2. If invalid JSON: Fix syntax errors\n3. If missing fields: Compare with STEP 0 template\n\n### Error: \"Skill not activating\"\n\n**Cause:** marketplace.json description ≠ SKILL.md description\n\n**Diagnosis:**\n\n```bash\n# Compare descriptions\ngrep \"description:\" agent-name\u002FSKILL.md\ngrep \"\\\"description\\\":\" agent-name\u002F.claude-plugin\u002Fmarketplace.json\n```\n\n**Solution:**\n\n1. Copy EXACT description from SKILL.md frontmatter\n2. Paste in marketplace.json → plugins[0].description\n3. Ensure they are IDENTICAL (word for word)\n4. Save and test installation again\n\n### Error: \"Invalid plugin structure\"\n\n**Cause:** Mandatory marketplace.json fields incorrect\n\n**Verify:**\n\n- ✅ `plugins[0].skills` = `[\".\u002F\"]` (not `[\"SKILL.md\"]` or other value)\n- ✅ `plugins[0].source` = `\".\u002F\"` (not empty or other value)\n- ✅ `name` in JSON root matches directory name\n\n**Solution:**\nEdit marketplace.json and fix fields above according to STEP 0 template.\n\n## 🧠 Final Step: Store Episode for Learning\n\n**⚠️ CRITICAL**: After successful agent creation, store the episode in AgentDB for future learning.\n\n### Automatic Episode Storage\n\n```python\n# Store this successful creation for future learning\nfrom integrations.agentdb_bridge import get_agentdb_bridge\nfrom integrations.agentdb_real_integration import Episode\n\ntry:\n    bridge = get_real_agentdb_bridge()\n\n    # Create episode from this creation\n    episode = Episode(\n        session_id=f\"agent-creation-{datetime.now().strftime('%Y%m%d-%H%M%S')}\",\n        task=user_input,  # Original user request\n        input=f\"Domain: {domain}, API: {selected_api}, Structure: {architecture}\",\n        output=f\"Created: {agent_name}\u002F with {len(scripts)} scripts\",\n        critique=f\"Success: {'✅ High quality' if all_tests_passed else '⚠️ Needs refinement'}\",\n        reward=0.9 if all_tests_passed else 0.7,\n        success=all_tests_passed,\n        latency_ms=creation_time_seconds * 1000,\n        tokens_used=estimated_tokens,\n        tags=[domain, selected_api, architecture_type],\n        metadata={\n            \"agent_name\": agent_name,\n            \"domain\": domain,\n            \"api\": selected_api,\n            \"complexity\": complexity,\n            \"files_created\": len(all_files),\n            \"validation_passed\": all_tests_passed\n        }\n    )\n\n    # Store episode for learning\n    episode_id = bridge.store_episode(episode)\n    print(f\"🧠 Episode stored for learning: #{episode_id}\")\n\n    # If successful, create skill\n    if all_tests_passed and bridge.is_available:\n        skill_name = f\"{domain}_agent_template\"\n        skill = Skill(\n            name=skill_name,\n            description=f\"Proven template for {domain} agents\",\n            code=f\"API: {selected_api}, Structure: {architecture}\",\n            success_rate=1.0,\n            uses=1,\n            avg_reward=0.9,\n            metadata={\"domain\": domain, \"api\": selected_api}\n        )\n\n        skill_id = bridge.create_skill(skill)\n        print(f\"🎯 Skill created: #{skill_id}\")\n\nexcept Exception as e:\n    # AgentDB failure should not break agent creation\n    print(\"🔄 AgentDB learning unavailable - agent creation completed successfully\")\n    pass\n```\n\n### Learning Progress Indicators\n\n**Provide subtle feedback to user about learning progress:**\n\n```python\n# Check learning milestones\nif episode_id:\n    from integrations.learning_feedback import analyze_agent_execution\n\n    feedback = analyze_agent_execution(\n        agent_name=agent_name,\n        user_input=user_input,\n        execution_time=creation_time_seconds,\n        success=all_tests_passed,\n        result_quality=0.9 if all_tests_passed else 0.7\n    )\n\n    if feedback:\n        print(feedback)  # Subtle milestone feedback\n```\n\n**Example user feedback:**\n- First creation: \"🎉 First agent created successfully!\"\n- After 10 creations: \"⚡ Agent creation optimized based on 10 successful patterns\"\n- After 30 days: \"🌟 I've learned your preferences - shall I optimize this agent?\"\n\n### Invisible Learning Complete\n\n**What happens behind the scenes:**\n- ✅ Episode stored with full creation context\n- ✅ Success patterns learned for future use\n- ✅ Skills consolidated from successful templates\n- ✅ Causal relationships established (API → success rate)\n- ✅ User sees only: \"Agent created successfully!\"\n\n**Next user gets benefits:**\n- Faster creation (learned optimal patterns)\n- Better API selection (historical success rates)\n- Proven architectures (domain-specific success)\n- Personalized suggestions (learned preferences)\n\n---\n\n## Limitations and Warnings\n\n### When NOT to use\n\n❌ Don't use this skill for:\n\n- Editing existing skills (use directly)\n- Debugging skills (use directly)\n- Questions about skills (answer directly)\n\n### Warnings\n\n⚠️ **Creation time**:\n\n- Simple agents: ~30-60 min\n- Complex agents: ~60-120 min\n- It's normal to take time (creating everything from scratch)\n\n⚠️ **Review needed**:\n\n- Created agent is functional but may need adjustments\n- Test examples in README\n- Iterate if necessary\n\n⚠️ **API keys**:\n\n- User needs to obtain API key\n- Instructions in created agent's README\n","# Agent Creator - Meta-Skill\n\nThis skill teaches Claude Code how to autonomously create complete agents with Claude Skills.\n\n## When to Use This Skill\n\nClaude should automatically activate this skill when the user:\n\n✅ **Asks to create an agent**\n\n- \"Create an agent for [objective]\"\n- \"I need an agent that [description]\"\n- \"Develop an agent to automate [workflow]\"\n\n✅ **Asks to automate a workflow**\n\n- \"Automate this process: [description]\"\n- \"Every day I do [repetitive task], automate this\"\n- \"Turn this workflow into an agent\"\n\n✅ **Asks to create a skill**\n\n- \"Create a skill for [objective]\"\n- \"Develop a custom skill for [domain]\"\n\n✅ **Describes a repetitive process**\n\n- \"Every day I [process]... takes Xh\"\n- \"I repeatedly need to [task]\"\n- \"Manual workflow: [description]\"\n\n## Overview\n\nWhen activated, this skill guides Claude through **5 autonomous phases** to create a complete production-ready agent:\n\n```\nPHASE 1: DISCOVERY\n├─ Research available APIs\n├─ Compare options\n└─ DECIDE which to use (with justification)\n\nPHASE 2: DESIGN\n├─ Think about use cases\n├─ DEFINE useful analyses\n└─ Specify methodologies\n\nPHASE 3: ARCHITECTURE\n├─ STRUCTURE folders and files\n├─ Define necessary scripts\n└─ Plan caching and performance\n\nPHASE 4: DETECTION\n├─ DETERMINE keywords\n└─ Create precise description\n\nPHASE 5: IMPLEMENTATION\n├─ 🚨 FIRST: Create marketplace.json (MANDATORY!)\n├─ Create SKILL.md (5000+ words)\n├─ Implement Python scripts (functional!)\n├─ Write references (useful!)\n├─ Generate configs (real!)\n├─ Create README\n└─ ✅ FINAL: Test installation\n```\n\n**Output**: Complete agent in subdirectory ready to install.\n\n---\n\n## 🏗️ **Claude Skills Architecture: Understanding What We Create**\n\n### **Important Terminology Clarification**\n\nThis meta-skill creates **Claude Skills**, which come in different architectural patterns:\n\n#### **📋 Skill Types We Can Create**\n\n**1. Simple Skill** (Single focused capability)\n```\nskill-name\u002F\n├── SKILL.md              ← Single comprehensive skill file\n├── scripts\u002F              ← Optional supporting code\n├── references\u002F           ← Optional documentation\n└── assets\u002F               ← Optional templates\n```\n*Use when: Single objective, simple workflow, \u003C1000 lines code*\n\n**2. Complex Skill Suite** (Multiple specialized capabilities)\n```\nskill-suite\u002F\n├── .claude-plugin\u002F\n│   └── marketplace.json  ← Organizes multiple component skills\n├── component-1\u002F\n│   └── SKILL.md          ← Specialized sub-skill\n├── component-2\u002F\n│   └── SKILL.md          ← Another specialized sub-skill\n└── shared\u002F               ← Shared resources\n```\n*Use when: Multiple related workflows, >2000 lines code, team maintenance*\n\n#### **🎯 Architecture Decision Process**\n\nDuring **PHASE 3: ARCHITECTURE**, this skill will:\n\n1. **Analyze Complexity Requirements**\n   - Number of distinct workflows\n   - Code complexity estimation\n   - Maintenance considerations\n\n2. **Choose Appropriate Architecture**\n   - Simple task → Simple Skill\n   - Complex multi-domain task → Skill Suite\n   - Hybrid requirements → Simple skill with components\n\n3. **Apply Naming Convention**\n   - Generate descriptive base name from requirements\n   - Add \"-cskill\" suffix to identify as Claude Skill created by Agent-Skill-Creator\n   - Ensure consistent, professional naming across all created skills\n\n4. **Document the Decision**\n   - Create `DECISIONS.md` explaining architecture choice\n   - Provide rationale for selected pattern\n   - Include migration path if needed\n   - Document naming convention applied\n\n#### **🏷️ Naming Convention: \"-cskill\" Suffix**\n\n**All skills created by this Agent-Skill-Creator use the \"-cskill\" suffix:**\n\n**Simple Skills:**\n- `pdf-text-extractor-cskill\u002F`\n- `csv-data-cleaner-cskill\u002F`\n- `weekly-report-generator-cskill\u002F`\n\n**Complex Skill Suites:**\n- `financial-analysis-suite-cskill\u002F`\n- `e-commerce-automation-cskill\u002F`\n- `research-workflow-cskill\u002F`\n\n**Component Skills (within suites):**\n- `data-acquisition-cskill\u002F`\n- `technical-analysis-cskill\u002F`\n- `reporting-generator-cskill\u002F`\n\n**Purpose of \"-cskill\" suffix:**\n- ✅ **Clear Identification**: Immediately recognizable as a Claude Skill\n- ✅ **Origin Attribution**: Created by Agent-Skill-Creator\n- ✅ **Consistent Convention**: Professional naming standard\n- ✅ **Avoids Confusion**: Distinguishes from manually created skills\n- ✅ **Easy Organization**: Simple to identify and group created skills\n\n#### **📚 Reference Documentation**\n\nFor complete understanding of Claude Skills architecture, see:\n- `docs\u002FCLAUDE_SKILLS_ARCHITECTURE.md` (comprehensive guide)\n- `docs\u002FDECISION_LOGIC.md` (architecture decision framework)\n- `examples\u002F` (simple vs complex examples)\n- `examples\u002Fsimple-skill\u002F` (minimal example)\n- `examples\u002Fcomplex-skill-suite\u002F` (comprehensive example)\n\n#### **✅ What We Create**\n\n**ALWAYS creates a valid Claude Skill** - either:\n- **Simple Skill** (single SKILL.md)\n- **Complex Skill Suite** (multiple component skills with marketplace.json)\n\n**NEVER creates \"plugins\" in the traditional sense** - we create Skills, which may be organized using marketplace.json for complex suites.\n\nThis terminology consistency eliminates confusion between Skills and Plugins.\n\n---\n\n## 🧠 Invisible Intelligence: AgentDB Integration\n\n### Enhanced Intelligence (v2.1)\n\nThis skill now includes **invisible AgentDB integration** that learns from every agent creation and provides progressively smarter assistance.\n\n**What happens automatically:**\n- 🧠 **Learning Memory**: Stores every creation attempt as episodes\n- ⚡ **Progressive Enhancement**: Each creation becomes faster and more accurate\n- 🎯 **Smart Validation**: Mathematical proofs for all decisions\n- 🔄 **Graceful Operation**: Works perfectly with or without AgentDB\n\n**User Experience**: Same simple commands, agents get smarter magically!\n\n### Integration Points\n\nThe AgentDB integration is woven into the 5 phases:\n\n```\nPHASE 1: DISCOVERY\n├─ Research APIs\n├─ 🧠 Query AgentDB for similar past successes\n├─ Compare options using learned patterns\n└─ DECIDE with historical confidence\n\nPHASE 2: DESIGN\n├─ Think about use cases\n├─ 🧠 Retrieve successful analysis patterns\n├─ DEFINE using proven methodologies\n└─ Enhance with learned improvements\n\nPHASE 3: ARCHITECTURE\n├─ STRUCTURE using validated patterns\n├─ 🧠 Apply proven architectural decisions\n├─ Plan based on success history\n└─ Optimize with learned insights\n\nPHASE 4: DETECTION\n├─ DETERMINE keywords using learned patterns\n├─ 🧠 Use successful keyword combinations\n└─ Create optimized description\n\nPHASE 5: IMPLEMENTATION\n├─ Create marketplace.json\n├─ 🧠 Apply proven code patterns\n├─ Store episode for future learning\n└─ ✅ Complete with enhanced validation\n```\n\n### Learning Progression\n\n**First Creation:**\n```\n\"Create financial analysis agent\"\n→ Standard agent creation process\n→ Episode stored for learning\n→ No visible difference to user\n```\n\n**After 10+ Creations:**\n```\n\"Create financial analysis agent\"\n→ 40% faster (learned optimal queries)\n→ Better API selection (historical success)\n→ Proven architectural patterns\n→ User sees: \"⚡ Optimized based on similar successful agents\"\n```\n\n**After 30+ Days:**\n```\n\"Create financial analysis agent\"\n→ Personalized recommendations based on patterns\n→ Predictive insights about user preferences\n→ Automatic skill consolidation\n→ User sees: \"🌟 I notice you prefer comprehensive financial agents - shall I include portfolio optimization?\"\n```\n\n---\n\n## 🚀 Enhanced Features (v2.0)\n\n### Multi-Agent Architecture\n\nThe enhanced agent-creator now supports:\n\n**✅ Single Agent Creation** (Original functionality)\n```\n\"Create an agent for stock analysis\"\n→ .\u002Fstock-analysis-agent\u002F\n```\n\n**✅ Multi-Agent Suite Creation** (NEW)\n```\n\"Create a financial analysis suite with 4 agents:\nfundamental analysis, technical analysis,\nportfolio management, and risk assessment\"\n→ .\u002Ffinancial-suite\u002F\n  ├── fundamental-analysis\u002F\n  ├── technical-analysis\u002F\n  ├── portfolio-management\u002F\n  └── risk-assessment\u002F\n```\n\n**✅ Transcript Intelligence Processing** (NEW)\n```\n\"I have a YouTube transcript about e-commerce analytics,\ncan you create agents based on the workflows described?\"\n→ Automatically extracts multiple workflows\n→ Creates integrated agent suite\n```\n\n**✅ Template-Based Creation** (NEW)\n```\n\"Create an agent using the financial-analysis template\"\n→ Uses pre-configured APIs and analyses\n→ 80% faster creation\n```\n\n**✅ Interactive Configuration** (NEW)\n```\n\"Help me create an agent with preview options\"\n→ Step-by-step wizard\n→ Real-time preview\n→ Iterative refinement\n```\n\n### Enhanced Marketplace.json Support\n\n**v1.0 Format** (Still supported):\n```json\n{\n  \"name\": \"single-agent\",\n  \"plugins\": [\n    {\n      \"skills\": [\".\u002F\"]\n    }\n  ]\n}\n```\n\n**v2.0 Format** (NEW - Multi-skill support):\n```json\n{\n  \"name\": \"agent-suite\",\n  \"plugins\": [\n    {\n      \"name\": \"fundamental-analysis\",\n      \"source\": \".\u002Ffundamental-analysis\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    },\n    {\n      \"name\": \"technical-analysis\",\n      \"source\": \".\u002Ftechnical-analysis\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    }\n  ]\n}\n```\n\n---\n\n## Autonomous Creation Protocol\n\n### Fundamental Principles\n\n**Autonomy**:\n\n- ✅ Claude DECIDES which API to use (doesn't ask user)\n- ✅ Claude DEFINES which analyses to perform (based on value)\n- ✅ Claude STRUCTURES optimally (best practices)\n- ✅ Claude IMPLEMENTS complete code (no placeholders)\n- ✅ **NEW**: Claude LEARNS from experience (AgentDB integration)\n\n**Quality**:\n\n- ✅ Production-ready code (no TODOs)\n- ✅ Useful documentation (not \"see docs\")\n- ✅ Real configs (no placeholders)\n- ✅ Robust error handling\n- ✅ **NEW**: Intelligence validated with mathematical proofs\n\n**Completeness**:\n\n- ✅ Complete SKILL.md (5000+ words)\n- ✅ Functional scripts (1000+ lines total)\n- ✅ References with content (3000+ words)\n- ✅ Valid assets\u002Fconfigs\n- ✅ README with instructions\n\n### Requirements Extraction\n\nWhen user describes workflow vaguely, extract:\n\n**From what the user said**:\n\n- Domain (agriculture? finance? weather?)\n- Data source (mentioned? if not, research)\n- Main tasks (download? analyze? compare?)\n- Frequency (daily? weekly? on-demand?)\n- Current time spent (to calculate ROI)\n\n**🆕 Enhanced Analysis (v2.0)**:\n\n- **Multi-Agent Detection**: Look for keywords like \"suite\", \"multiple\", \"separate agents\"\n- **Transcript Analysis**: Detect if input is a video\u002Ftranscript requiring workflow extraction\n- **Template Matching**: Identify if user wants template-based creation\n- **Interactive Preference**: Detect if user wants guidance vs full autonomy\n- **Integration Needs**: Determine if agents should communicate with each other\n\n**🆕 Transcript Processing**:\n\nWhen user provides transcripts:\n```python\n# Enhanced transcript analysis\ndef analyze_transcript(transcript: str) -> List[WorkflowSpec]:\n    \"\"\"Extract multiple workflows from transcripts automatically\"\"\"\n    workflows = []\n\n    # 1. Identify distinct processes\n    processes = extract_processes(transcript)\n\n    # 2. Group related steps\n    for process in processes:\n        steps = extract_sequence_steps(transcript, process)\n        apis = extract_mentioned_apis(transcript, process)\n        outputs = extract_desired_outputs(transcript, process)\n\n        workflows.append(WorkflowSpec(\n            name=process,\n            steps=steps,\n            apis=apis,\n            outputs=outputs\n        ))\n\n    return workflows\n```\n\n**🆕 Multi-Agent Strategy Decision**:\n\n```python\ndef determine_creation_strategy(user_input: str, workflows: List[WorkflowSpec]) -> CreationStrategy:\n    \"\"\"Decide whether to create single agent, suite, or integrated system\"\"\"\n\n    if len(workflows) > 1:\n        if workflows_are_related(workflows):\n            return CreationStrategy.INTEGRATED_SUITE\n        else:\n            return CreationStrategy.MULTI_AGENT_SUITE\n    else:\n        return CreationStrategy.SINGLE_AGENT\n```\n\n**Questions to ask** (only if critical and not inferable):\n\n- \"Prefer free API or paid is ok?\"\n- \"Need historical data for how many years?\"\n- \"Focus on which geography\u002Fcountry?\"\n- **🆕 \"Create separate agents or integrated suite?\"** (if multiple workflows detected)\n- **🆕 \"Want interactive preview before creation?\"** (for complex projects)\n\n**Rule**: Minimize questions. Infer\u002Fdecide whenever possible.\n\n## 🎯 Template-Based Creation (NEW v2.0)\n\n### Available Templates\n\nThe enhanced agent-creator includes pre-built templates for common domains:\n\n**📊 Financial Analysis Template**\n```json\nDomain: Finance & Investments\nAPIs: Alpha Vantage, Yahoo Finance\nAnalyses: Fundamental, Technical, Portfolio\nTime: 15-20 minutes\n```\n\n**🌡️ Climate Analysis Template**\n```json\nDomain: Climate & Environmental\nAPIs: Open-Meteo, NOAA\nAnalyses: Anomalies, Trends, Seasonal\nTime: 20-25 minutes\n```\n\n**🛒 E-commerce Analytics Template**\n```json\nDomain: Business & E-commerce\nAPIs: Google Analytics, Stripe, Shopify\nAnalyses: Traffic, Revenue, Cohort, Products\nTime: 25-30 minutes\n```\n\n### Template Matching Process\n\n```python\ndef match_template(user_input: str) -> TemplateMatch:\n    \"\"\"Automatically suggest best template based on user input\"\"\"\n\n    # 1. Extract keywords from user input\n    keywords = extract_keywords(user_input)\n\n    # 2. Calculate similarity scores with all templates\n    matches = []\n    for template in available_templates:\n        score = calculate_similarity(keywords, template.keywords)\n        matches.append((template, score))\n\n    # 3. Rank by similarity\n    matches.sort(key=lambda x: x[1], reverse=True)\n\n    # 4. Return best match if confidence > threshold\n    if matches[0][1] > 0.7:\n        return TemplateMatch(template=matches[0][0], confidence=matches[0][1])\n    else:\n        return None  # No suitable template found\n```\n\n### Template Usage Examples\n\n**Direct Template Request:**\n```\n\"Create an agent using the financial-analysis template\"\n→ Uses pre-configured structure\n→ 80% faster creation\n→ Proven architecture\n```\n\n**Automatic Template Detection:**\n```\n\"I need to analyze stock performance and calculate RSI, MACD\"\n→ Detects financial domain\n→ Suggests financial-analysis template\n→ User confirms or continues custom\n```\n\n**Template Customization:**\n```\n\"Use the climate template but add drought analysis\"\n→ Starts with climate template\n→ Adds custom drought analysis\n→ Modifies structure accordingly\n```\n\n## 🚀 Batch Agent Creation (NEW v2.0)\n\n### Multi-Agent Suite Creation\n\nThe enhanced agent-creator can create multiple agents in a single operation:\n\n**When to Use Batch Creation:**\n- Transcript describes multiple distinct workflows\n- User explicitly asks for multiple agents\n- Complex system requiring specialized components\n- Microservices architecture preferred\n\n### Batch Creation Process\n\n```python\ndef create_agent_suite(user_input: str, workflows: List[WorkflowSpec]) -> AgentSuite:\n    \"\"\"Create multiple related agents in one operation\"\"\"\n\n    # 1. Analyze workflow relationships\n    relationships = analyze_workflow_relationships(workflows)\n\n    # 2. Determine optimal structure\n    if workflows_are_tightly_coupled(workflows):\n        structure = \"integrated_suite\"\n    else:\n        structure = \"independent_agents\"\n\n    # 3. Create suite directory\n    suite_name = generate_suite_name(user_input)\n    create_suite_directory(suite_name)\n\n    # 4. Create each agent\n    agents = []\n    for workflow in workflows:\n        agent = create_single_agent(workflow, suite_name)\n        agents.append(agent)\n\n    # 5. Create integration layer (if needed)\n    if structure == \"integrated_suite\":\n        create_integration_layer(agents, suite_name)\n\n    # 6. Create suite-level marketplace.json\n    create_suite_marketplace_json(suite_name, agents)\n\n    return AgentSuite(name=suite_name, agents=agents, structure=structure)\n```\n\n### Batch Creation Examples\n\n**Financial Suite Example:**\n```\n\"Create a complete financial analysis system with 4 agents:\n1. Fundamental analysis for company valuation\n2. Technical analysis for trading signals\n3. Portfolio management and optimization\n4. Risk assessment and compliance\"\n\n→ .\u002Ffinancial-analysis-suite\u002F\n  ├── .claude-plugin\u002Fmarketplace.json (multi-skill)\n  ├── fundamental-analysis\u002F\n  │   ├── SKILL.md\n  │   ├── scripts\u002F\n  │   └── tests\u002F\n  ├── technical-analysis\u002F\n  ├── portfolio-management\u002F\n  └── risk-assessment\u002F\n```\n\n**E-commerce Suite Example:**\n```\n\"Build an e-commerce analytics system based on this transcript:\n- Traffic analysis from Google Analytics\n- Revenue tracking from Stripe\n- Product performance from Shopify\n- Customer cohort analysis\n- Automated reporting dashboard\"\n\n→ .\u002Fe-commerce-analytics-suite\u002F\n  ├── traffic-analysis-agent\u002F\n  ├── revenue-tracking-agent\u002F\n  ├── product-performance-agent\u002F\n  ├── cohort-analysis-agent\u002F\n  └── reporting-dashboard-agent\u002F\n```\n\n### Multi-Skill Marketplace.json Structure\n\n**Suite-Level Configuration:**\n```json\n{\n  \"name\": \"financial-analysis-suite\",\n  \"metadata\": {\n    \"description\": \"Complete financial analysis system with fundamental, technical, portfolio, and risk analysis\",\n    \"version\": \"1.0.0\",\n    \"suite_type\": \"financial_analysis\"\n  },\n  \"plugins\": [\n    {\n      \"name\": \"fundamental-analysis-plugin\",\n      \"description\": \"Fundamental analysis for company valuation and financial metrics\",\n      \"source\": \".\u002Ffundamental-analysis\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    },\n    {\n      \"name\": \"technical-analysis-plugin\",\n      \"description\": \"Technical analysis with trading indicators and signals\",\n      \"source\": \".\u002Ftechnical-analysis\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    },\n    {\n      \"name\": \"portfolio-management-plugin\",\n      \"description\": \"Portfolio optimization and management analytics\",\n      \"source\": \".\u002Fportfolio-management\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    },\n    {\n      \"name\": \"risk-assessment-plugin\",\n      \"description\": \"Risk analysis and compliance monitoring\",\n      \"source\": \".\u002Frisk-assessment\u002F\",\n      \"skills\": [\".\u002FSKILL.md\"]\n    }\n  ],\n  \"integrations\": {\n    \"data_sharing\": true,\n    \"cross_agent_communication\": true,\n    \"shared_utils\": \".\u002Fshared\u002F\"\n  }\n}\n```\n\n### Batch Creation Benefits\n\n**✅ Time Efficiency:**\n- Create 4 agents in ~60 minutes (vs 4 hours individually)\n- Shared utilities and infrastructure\n- Consistent architecture and documentation\n\n**✅ Integration Benefits:**\n- Agents designed to work together\n- Shared data structures and formats\n- Unified testing and deployment\n\n**✅ Maintenance Benefits:**\n- Single marketplace.json for installation\n- Coordinated versioning and updates\n- Shared troubleshooting documentation\n\n### Batch Creation Commands\n\n**Explicit Multi-Agent Request:**\n```\n\"Create 3 agents for climate analysis:\n1. Temperature anomaly detection\n2. Precipitation pattern analysis\n3. Extreme weather event tracking\n\nMake them work together as a system.\"\n```\n\n**Transcript-Based Batch Creation:**\n```\n\"Here's a transcript of a 2-hour tutorial on building\na complete business intelligence system. Create agents\nfor all the workflows described in the video.\"\n```\n\n**Template-Based Batch Creation:**\n```\n\"Use the e-commerce template to create a full analytics suite:\n- Traffic analysis\n- Revenue tracking\n- Customer analytics\n- Product performance\n- Marketing attribution\"\n```\n\n## 🎮 Interactive Configuration Wizard (NEW v2.0)\n\n### When to Use Interactive Mode\n\nThe enhanced agent-creator includes an interactive wizard for:\n\n- **Complex Projects**: Multi-agent systems, integrations\n- **User Preference**: When users want guidance vs full autonomy\n- **High-Stakes Projects**: When preview and iteration are important\n- **Learning**: Users who want to understand the creation process\n\n### Interactive Wizard Process\n\n```python\ndef interactive_agent_creation():\n    \"\"\"\n    Step-by-step guided agent creation with real-time preview\n    \"\"\"\n\n    # Step 1: Welcome and Requirements Gathering\n    print(\"🚀 Welcome to Enhanced Agent Creator!\")\n    print(\"I'll help you create custom agents through an interactive process.\")\n\n    user_needs = gather_requirements_interactively()\n\n    # Step 2: Workflow Analysis\n    print(\"\\n📋 Analyzing your requirements...\")\n    workflows = analyze_and_confirm_workflows(user_needs)\n\n    # Step 3: Strategy Selection\n    strategy = select_creation_strategy(workflows)\n    print(f\"🎯 Recommended: {strategy.description}\")\n\n    # Step 4: Preview and Refinement\n    while True:\n        preview = generate_interactive_preview(strategy)\n        show_preview(preview)\n\n        if user_approves():\n            break\n        else:\n            strategy = refine_based_on_feedback(strategy, preview)\n\n    # Step 5: Creation\n    print(\"\\n⚙️ Creating your agent(s)...\")\n    result = execute_creation(strategy)\n\n    # Step 6: Validation and Tutorial\n    validate_created_agents(result)\n    provide_usage_tutorial(result)\n\n    return result\n```\n\n### Interactive Interface Examples\n\n**Step 1: Requirements Gathering**\n```\n🚀 Welcome to Enhanced Agent Creator!\n\nLet me understand what you want to build:\n\n1. What's your main goal?\n   [ ] Automate a repetitive workflow\n   [ ] Analyze data from specific sources\n   [ ] Create custom tools for my domain\n   [ ] Build a complete system with multiple components\n\n2. What's your domain\u002Findustry?\n   [ ] Finance & Investing\n   [ ] E-commerce & Business\n   [ ] Climate & Environment\n   [ ] Healthcare & Medicine\n   [ ] Other (please specify): _______\n\n3. Do you have existing materials?\n   [ ] YouTube transcript or video\n   [ ] Documentation or tutorials\n   [ ] Existing code\u002Fscripts\n   [ ] Starting from scratch\n\nYour responses: [Finance & Investing] [Starting from scratch]\n```\n\n**Step 2: Workflow Analysis**\n```\n📋 Based on your input, I detect:\n\nDomain: Finance & Investing\nPotential Workflows:\n1. Fundamental Analysis (P\u002FE, ROE, valuation metrics)\n2. Technical Analysis (RSI, MACD, trading signals)\n3. Portfolio Management (allocation, optimization)\n4. Risk Assessment (VaR, drawdown, compliance)\n\nWhich workflows interest you? Select all that apply:\n[✓] Technical Analysis\n[✓] Portfolio Management\n[ ] Fundamental Analysis\n[ ] Risk Assessment\n\nSelected: 2 workflows detected\n```\n\n**Step 3: Strategy Selection**\n```\n🎯 Recommended Creation Strategy:\n\nMulti-Agent Suite Creation\n- Create 2 specialized agents\n- Each agent handles one workflow\n- Agents can communicate and share data\n- Unified installation and documentation\n\nEstimated Time: 35-45 minutes\nOutput: .\u002Ffinance-suite\u002F (2 agents)\n\nOptions:\n[✓] Accept recommendation\n[ ] Create single integrated agent\n[ ] Use template-based approach\n[ ] Customize strategy\n```\n\n**Step 4: Interactive Preview**\n```\n📊 Preview of Your Finance Suite:\n\nStructure:\n.\u002Ffinance-suite\u002F\n├── .claude-plugin\u002Fmarketplace.json\n├── technical-analysis-agent\u002F\n│   ├── SKILL.md (2,100 words)\n│   ├── scripts\u002F (Python, 450 lines)\n│   └── tests\u002F (15 tests)\n└── portfolio-management-agent\u002F\n    ├── SKILL.md (1,800 words)\n    ├── scripts\u002F (Python, 380 lines)\n    └── tests\u002F (12 tests)\n\nFeatures:\n✅ Real-time stock data (Alpha Vantage API)\n✅ 10 technical indicators (RSI, MACD, Bollinger...)\n✅ Portfolio optimization algorithms\n✅ Risk metrics and rebalancing alerts\n✅ Automated report generation\n\nAPIs Required:\n- Alpha Vantage (free tier available)\n- Yahoo Finance (no API key needed)\n\nWould you like to:\n[✓] Proceed with creation\n[ ] Modify technical indicators\n[ ] Add risk management features\n[ ] Change APIs\n[ ] See more details\n```\n\n### Wizard Benefits\n\n**🎯 User Empowerment:**\n- Users see exactly what will be created\n- Can modify and iterate before implementation\n- Learn about the process and architecture\n- Make informed decisions\n\n**⚡ Efficiency:**\n- Faster than custom development\n- Better than black-box creation\n- Reduces rework and iterations\n- Higher satisfaction rates\n\n**🛡️ Risk Reduction:**\n- Preview prevents misunderstandings\n- Iterative refinement catches issues early\n- Users can validate requirements\n- Clear expectations management\n\n### Interactive Commands\n\n**Start Interactive Mode:**\n```\n\"Help me create an agent with interactive options\"\n\"Walk me through creating a financial analysis system\"\n\"I want to use the configuration wizard\"\n```\n\n**Resume from Preview:**\n```\n\"Show me the preview again before creating\"\n\"Can I modify the preview you showed me?\"\n\"I want to change something in the proposed structure\"\n```\n\n**Learning Mode:**\n```\n\"Create an agent and explain each step as you go\"\n\"Teach me how agent creation works while building\"\n\"I want to understand the architecture decisions\"\n```\n\n### Wizard Customization Options\n\n**Advanced Mode:**\n```\n⚙️ Advanced Configuration Options:\n\n1. API Selection Strategy\n   [ ] Prefer free APIs\n   [ ] Prioritize data quality\n   [ ] Minimize rate limits\n   [ ] Multiple API fallbacks\n\n2. Architecture Preference\n   [ ] Modular (separate scripts per function)\n   [ ] Integrated (all-in-one scripts)\n   [ ] Hybrid (core + specialized modules)\n\n3. Testing Strategy\n   [ ] Basic functionality tests\n   [ ] Comprehensive test suite\n   [ ] Integration tests\n   [ ] Performance benchmarks\n\n4. Documentation Level\n   [ ] Minimal (API docs only)\n   [ ] Standard (complete usage guide)\n   [ ] Extensive (tutorials + examples)\n   [ ] Academic (methodology + research)\n```\n\n**Template Customization:**\n```\n🎨 Template Customization:\n\nBase Template: Financial Analysis\n✓ Include technical indicators: RSI, MACD, Bollinger Bands\n✓ Add portfolio optimization: Modern Portfolio Theory\n✓ Risk metrics: VaR, Maximum Drawdown, Sharpe Ratio\n\nAdditional Features:\n[ ] Machine learning predictions\n[ ] Sentiment analysis from news\n[ ] Options pricing models\n[ ] Cryptocurrency support\n\nRemove Features:\n[ ] Fundamental analysis (not needed)\n[ ] Economic calendar integration\n```\n\n## 🧠 Invisible Intelligence: AgentDB Integration (NEW v2.1)\n\n### What This Means for Users\n\n**The agent-creator now has \"memory\" and gets smarter over time - automatically!**\n\n✅ **No setup required** - AgentDB initializes automatically in the background\n✅ **No commands to learn** - You use the exact same natural language commands\n✅ **Invisible enhancement** - Agents become more intelligent without you doing anything\n✅ **Progressive learning** - Each agent learns from experience and shares knowledge\n\n### How It Works (Behind the Scenes)\n\nWhen you create an agent:\n```\nUser: \"Create agent for financial analysis\"\n\n🤖 Agent-Creator (v2.1):\n\"✅ Creating financial-analysis-agent with learned intelligence...\"\n\"✅ Using template with 94% historical success rate...\"\n\"✅ Applied 12 learned improvements from similar agents...\"\n\"✅ Mathematical proof: template choice validated with 98% confidence...\"\n```\n\n### Key Benefits (Automatic & Invisible)\n\n**🧠 Learning Memory:**\n- Agents remember what works and what doesn't\n- Successful patterns are automatically reused\n- Failed approaches are automatically avoided\n\n**📊 Smart Decisions:**\n- Template selection based on real success data\n- Architecture optimized from thousands of similar agents\n- API choices validated with mathematical proofs\n\n**🔄 Continuous Improvement:**\n- Each agent gets smarter with use\n- Knowledge shared across all agents automatically\n- Nightly reflection system refines capabilities\n\n### User Experience: \"The Magic Gets Better\"\n\n**First Week:**\n```\n\"Analyze Tesla stock\"\n🤖 \"📊 Tesla analysis: RSI 65.3, MACD bullish\"\n```\n\n**After One Month:**\n```\n\"Analyze Tesla stock\"\n🤖 \"📊 Tesla analysis: RSI 65.3, MACD bullish (enhanced with your patterns)\"\n🤖 \"🧠 Pattern detected: You always ask on Mondays - prepared weekly analysis\"\n🤖 \"📈 Added volatility prediction based on your usage patterns\"\n```\n\n### Technical Implementation (Invisible to Users)\n\n```python\n# This happens automatically behind the scenes\nclass AgentCreatorV21:\n    def create_agent(self, user_input):\n        # AgentDB enhancement (invisible)\n        intelligence = enhance_agent_creation(user_input)\n\n        # Enhanced template selection\n        template = intelligence.template_choice or self.default_template\n\n        # Learned improvements automatically applied\n        improvements = intelligence.learned_improvements\n\n        # Create agent with enhanced intelligence\n        return self.create_with_intelligence(template, improvements)\n```\n\n### Graceful Fallback\n\nIf AgentDB isn't available (rare), the agent-creator works exactly like v2.0:\n```\n\"Create agent for financial analysis\"\n🤖 \"✅ Agent created (standard mode)\"\n```\n\nNo interruption, no errors, just no learning enhancements.\n\n### Privacy & Performance\n\n- ✅ All learning happens locally on your machine\n- ✅ No external dependencies required\n- ✅ Automatic cleanup and optimization\n- ✅ Zero impact on creation speed\n\n---\n\n## 📦 Cross-Platform Export (NEW v3.2)\n\n### What This Feature Does\n\n**Automatically package skills for use across all Claude platforms:**\n\nSkills created in Claude Code can be exported for:\n- ✅ **Claude Desktop** - Manual .zip upload\n- ✅ **claude.ai** (Web) - Browser-based upload\n- ✅ **Claude API** - Programmatic integration\n\nThis makes your skills portable and shareable across all Claude ecosystems.\n\n### When to Activate Export\n\nClaude should activate export capabilities when user says:\n\n✅ **Export requests:**\n- \"Export [skill-name] for Desktop\"\n- \"Package [skill-name] for claude.ai\"\n- \"Create API package for [skill-name]\"\n- \"Export [skill-name] for all platforms\"\n\n✅ **Cross-platform requests:**\n- \"Make [skill-name] compatible with Claude Desktop\"\n- \"I need to share [skill-name] with Desktop users\"\n- \"Package [skill-name] as .zip\"\n- \"Create cross-platform version of [skill-name]\"\n\n✅ **Version-specific exports:**\n- \"Export [skill-name] with version 2.0.1\"\n- \"Package [skill-name] v1.5.0 for API\"\n\n### Export Process\n\nWhen user requests export:\n\n**Step 1: Locate Skill**\n```python\n# Search common locations\nlocations = [\n    f\".\u002F{skill_name}-cskill\u002F\",  # Current directory\n    f\"references\u002Fexamples\u002F{skill_name}-cskill\u002F\",  # Examples\n    user_specified_path  # If provided\n]\n\nskill_path = find_skill(locations)\n```\n\n**Step 2: Validate Structure**\n```python\n# Ensure skill is export-ready\nvalid, issues = validate_skill_structure(skill_path)\n\nif not valid:\n    report_issues_to_user(issues)\n    return\n```\n\n**Step 3: Execute Export**\n```bash\n# Run export utility\npython scripts\u002Fexport_utils.py {skill_path} \\\n    --variant {desktop|api|both} \\\n    --version {version} \\\n    --output-dir exports\u002F\n```\n\n**Step 4: Report Results**\n```\n✅ Export completed!\n\n📦 Packages created:\n   - Desktop: exports\u002F{skill}-desktop-v1.0.0.zip (2.3 MB)\n   - API: exports\u002F{skill}-api-v1.0.0.zip (1.2 MB)\n\n📄 Installation guide: exports\u002F{skill}-v1.0.0_INSTALL.md\n\n🎯 Ready for:\n   ✅ Claude Desktop upload\n   ✅ claude.ai upload\n   ✅ Claude API integration\n```\n\n### Post-Creation Export (Opt-In)\n\nAfter successfully creating a skill in PHASE 5, offer export:\n\n```\n✅ Skill created successfully: {skill-name-cskill}\u002F\n\n📦 Cross-Platform Export Options:\n\nWould you like to create export packages for other Claude platforms?\n\n   1. Desktop\u002FWeb (.zip for manual upload)\n   2. API (.zip for programmatic use)\n   3. Both (comprehensive package)\n   4. Skip (Claude Code only)\n\nChoice: _\n```\n\n**If user chooses 1, 2, or 3:**\n- Execute export_utils.py with selected variants\n- Report package locations\n- Provide next steps for each platform\n\n**If user chooses 4 or skips:**\n- Continue with normal completion\n- Skill remains Claude Code only\n\n### Export Variants\n\n**Desktop\u002FWeb Package** (`*-desktop-*.zip`):\n- Complete documentation\n- All scripts and assets\n- Full references\n- Optimized for user experience\n- Typical size: 2-5 MB\n\n**API Package** (`*-api-*.zip`):\n- Execution-focused\n- Size-optimized (\u003C 8MB)\n- Minimal documentation\n- Essential scripts only\n- Typical size: 0.5-2 MB\n\n### Version Detection\n\nAutomatically detect version from:\n\n1. **Git tags** (priority):\n   ```bash\n   git describe --tags --abbrev=0\n   ```\n\n2. **SKILL.md frontmatter**:\n   ```yaml\n   ---\n   name: skill-name\n   version: 1.2.3\n   ---\n   ```\n\n3. **Default**: `v1.0.0`\n\n**User can override**:\n- \"Export with version 2.1.0\"\n- `--version 2.1.0` flag\n\n### Export Validation\n\nBefore creating packages, validate:\n\n✅ **Required:**\n- SKILL.md exists\n- Valid frontmatter (---...---)\n- `name:` field present (≤ 64 chars)\n- `description:` field present (≤ 1024 chars)\n\n✅ **Size Checks:**\n- Desktop: Reasonable size\n- API: \u003C 8MB (hard limit)\n\n✅ **Security:**\n- No .env files\n- No credentials.json\n- No sensitive data\n\nIf validation fails, report specific issues to user.\n\n### Installation Guides\n\nAuto-generate platform-specific guides:\n\n**File**: `exports\u002F{skill}-v{version}_INSTALL.md`\n\n**Contents:**\n- Package information\n- Installation steps for Desktop\n- Installation steps for claude.ai\n- API integration code examples\n- Platform comparison table\n- Troubleshooting tips\n\n### Export Commands Reference\n\n```bash\n# Export both variants (default)\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill\n\n# Export only Desktop\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill --variant desktop\n\n# Export only API\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill --variant api\n\n# With custom version\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill --version 2.0.1\n\n# To custom directory\npython scripts\u002Fexport_utils.py .\u002Fskill-name-cskill --output-dir .\u002Freleases\n```\n\n### Documentation References\n\nPoint users to comprehensive guides:\n- **Export Guide**: `references\u002Fexport-guide.md`\n- **Cross-Platform Guide**: `references\u002Fcross-platform-guide.md`\n- **Exports README**: `exports\u002FREADME.md`\n\n### Integration with AgentDB\n\nExport process can leverage AgentDB learning:\n- Remember successful export configurations\n- Suggest optimal variant based on use case\n- Track which exports are most commonly used\n- Learn from export failures to improve validation\n\n---\n\n## PHASE 1: Discovery and Research\n\n**Objective**: DECIDE which API\u002Fdata source to use with AgentDB intelligence\n\n### Process\n\n**1.1 Identify domain and query AgentDB**\n\nFrom user input, identify the domain and immediately query AgentDB for learned patterns:\n\n```python\n# Import AgentDB bridge (invisible to user)\nfrom integrations.agentdb_bridge import get_agentdb_bridge\n\n# Get AgentDB intelligence\nbridge = get_agentdb_bridge()\nintelligence = bridge.enhance_agent_creation(user_input, domain)\n\n# Log: AgentDB provides insights if available\nif intelligence.learned_improvements:\n    print(f\"🧠 Found {len(intelligence.learned_improvements)} relevant patterns\")\n```\n\n**Domain mapping with AgentDB insights:**\n- Agriculture → APIs: USDA NASS, FAO, World Bank Ag\n- Finance → APIs: Alpha Vantage, Yahoo Finance, Fed Economic Data\n- Weather → APIs: NOAA, OpenWeather, Weather.gov\n- Economy → APIs: World Bank, IMF, FRED\n\n**1.2 Research available APIs with learned preferences**\n\nFor the domain, use WebSearch to find:\n\n- Available public APIs\n- Documentation\n- Characteristics (free? rate limits? coverage?)\n\n**AgentDB Enhancement**: Prioritize APIs that have shown higher success rates:\n```python\n# AgentDB influences search based on historical success\nif intelligence.success_probability > 0.8:\n    print(f\"🎯 High success domain detected - optimizing API selection\")\n```\n\n**Example with AgentDB insights**:\n\n```\nWebSearch: \"US agriculture API free historical data\"\nWebSearch: \"USDA API documentation\"\nWebFetch: [doc URLs found]\n\n# AgentDB check: \"Has similar domain been successful before?\"\n# AgentDB provides: \"USDA NASS: 94% success rate in agriculture domain\"\n```\n\n**1.3 Compare options with AgentDB validation**\n\nCreate mental table comparing:\n\n- Data coverage (fit with need)\n- Cost (free vs paid)\n- Rate limits (sufficient?)\n- Data quality (official? reliable?)\n- Documentation (good? examples?)\n- Ease of use\n- **🧠 AgentDB Success Rate** (historical validation)\n\n**AgentDB Mathematical Validation**:\n```python\n# AgentDB provides mathematical proof for selection\nif intelligence.mathematical_proof:\n    print(f\"📊 API selection validated: {intelligence.mathematical_proof}\")\n```\n\n**1.4 DECIDE with AgentDB confidence**\n\nChoose 1 API and justify with AgentDB backing:\n\n**Decision with AgentDB confidence:**\n- **Selected API**: [API name]\n- **Success Probability**: {intelligence.success_probability:.1%}\n- **Mathematical Proof**: {intelligence.mathematical_proof}\n- **Learned Improvements**: {intelligence.learned_improvements}\n\n**Document decision** in separate file:\n\n```markdown\n# Architecture Decisions\n\n## Selected API: [Name]\n\n**Justification**:\n- ✅ Coverage: [details]\n- ✅ Cost: [free\u002Fpaid]\n- ✅ Rate limit: [number]\n- ✅ Quality: [official\u002Fprivate]\n- ✅ Docs: [quality]\n\n**Alternatives considered**:\n- API X: Rejected because [reason]\n- API Y: Rejected because [reason]\n\n**Conclusion**: [Chosen API] is the best option because [synthesis]\n```\n\n**1.5 Research technical details**\n\nUse WebFetch to load API documentation and extract:\n\n- Base URL\n- Main endpoints\n- Authentication\n- Important parameters\n- Response format\n- Rate limits\n- Request\u002Fresponse examples\n\n**See** `references\u002Fphase1-discovery.md` for complete details.\n\n## PHASE 2: Analysis Design\n\n**Objective**: DEFINE which analyses the agent will perform\n\n### Process\n\n**2.1 Think about use cases**\n\nFor the described workflow, which questions will the user ask frequently?\n\n**Brainstorm**: List 10-15 typical questions\n\n**2.2 Group by analysis type**\n\nGroup similar questions:\n\n- Simple queries (fetch + format)\n- Temporal comparisons (YoY)\n- Rankings (sort + share)\n- Trends (time series + CAGR)\n- Projections (forecasting)\n- Aggregations (regional\u002Fcategorical)\n\n**2.3 DEFINE priority analyses**\n\nChoose 4-6 analyses that cover 80% of use cases.\n\nFor each analysis:\n\n- Name\n- Objective\n- Required inputs\n- Expected outputs\n- Methodology (formulas, transformations)\n- Interpretation\n\n**2.4 ADD Comprehensive Report Function** (🆕 Enhancement #8 - MANDATORY!)\n\n**⚠️ COMMON PROBLEM:** v1.0 skills had isolated functions. When user asks for \"complete report\", Claude didn't know how to combine all analyses.\n\n**Solution:** ALWAYS include as last analysis function:\n\n```python\ndef comprehensive_{domain}_report(\n    entity: str,\n    year: Optional[int] = None,\n    include_metrics: Optional[List[str]] = None,\n    client: Optional[Any] = None\n) -> Dict:\n    \"\"\"\n    Generate comprehensive report combining ALL available metrics.\n\n    This is a \"one-stop\" function that users can call to get\n    complete picture without knowing individual functions.\n\n    Args:\n        entity: Entity to analyze (e.g., commodity, stock, location)\n        year: Year (None for current year with auto-detection)\n        include_metrics: Which metrics to include (None = all available)\n        client: API client instance (optional, created if None)\n\n    Returns:\n        Dict with ALL metrics consolidated:\n        {\n            'entity': str,\n            'year': int,\n            'year_info': str,\n            'generated_at': str (ISO timestamp),\n            'metrics': {\n                'metric1_name': {metric1_data},\n                'metric2_name': {metric2_data},\n                ...\n            },\n            'summary': str (overall insights),\n            'alerts': List[str] (important findings)\n        }\n\n    Example:\n        >>> report = comprehensive_{domain}_report(\"CORN\")\n        >>> print(report['summary'])\n        \"CORN 2025: Production up 5% YoY, yield at record high...\"\n    \"\"\"\n    from datetime import datetime\n    from utils.helpers import get_{domain}_year_with_fallback, format_year_message\n\n    # Auto-detect year\n    year_requested = year\n    if year is None:\n        year, _ = get_{domain}_year_with_fallback()\n\n    # Initialize report\n    report = {\n        'entity': entity,\n        'year': year,\n        'year_requested': year_requested,\n        'year_info': format_year_message(year, year_requested),\n        'generated_at': datetime.now().isoformat(),\n        'metrics': {},\n        'alerts': []\n    }\n\n    # Determine which metrics to include\n    if include_metrics is None:\n        # Include ALL available metrics\n        metrics_to_fetch = ['{metric1}', '{metric2}', '{metric3}', ...]\n    else:\n        metrics_to_fetch = include_metrics\n\n    # Call ALL individual analysis functions\n    # Graceful degradation: if one fails, others still run\n\n    if '{metric1}' in metrics_to_fetch:\n        try:\n            report['metrics']['{metric1}'] = {metric1}_analysis(entity, year, client)\n        except Exception as e:\n            report['metrics']['{metric1}'] = {\n                'error': str(e),\n                'status': 'unavailable'\n            }\n            report['alerts'].append(f\"{metric1} data unavailable: {e}\")\n\n    if '{metric2}' in metrics_to_fetch:\n        try:\n            report['metrics']['{metric2}'] = {metric2}_analysis(entity, year, client)\n        except Exception as e:\n            report['metrics']['{metric2}'] = {\n                'error': str(e),\n                'status': 'unavailable'\n            }\n\n    # Repeat for ALL metrics...\n\n    # Generate summary based on all available data\n    report['summary'] = _generate_summary(report['metrics'], entity, year)\n\n    # Detect important findings\n    report['alerts'].extend(_detect_alerts(report['metrics']))\n\n    return report\n\n\ndef _generate_summary(metrics: Dict, entity: str, year: int) -> str:\n    \"\"\"Generate human-readable summary from all metrics.\"\"\"\n    insights = []\n\n    # Extract key insights from each metric\n    for metric_name, metric_data in metrics.items():\n        if 'error' not in metric_data:\n            # Extract most important insight from this metric\n            key_insight = _extract_key_insight(metric_name, metric_data)\n            if key_insight:\n                insights.append(key_insight)\n\n    # Combine into coherent summary\n    if insights:\n        summary = f\"{entity} {year}: \" + \". \".join(insights[:3])  # Top 3 insights\n    else:\n        summary = f\"{entity} {year}: No data available\"\n\n    return summary\n\n\ndef _detect_alerts(metrics: Dict) -> List[str]:\n    \"\"\"Detect significant findings that need attention.\"\"\"\n    alerts = []\n\n    # Check each metric for alert conditions\n    for metric_name, metric_data in metrics.items():\n        if 'error' in metric_data:\n            continue\n\n        # Domain-specific alert logic\n        # Example: Large changes, extreme values, anomalies\n        if metric_name == '{metric1}' and 'change_percent' in metric_data:\n            if abs(metric_data['change_percent']) > 15:\n                alerts.append(\n                    f\"⚠ Large {metric1} change: {metric_data['change_percent']:.1f}%\"\n                )\n\n    return alerts\n```\n\n**Why it's mandatory:**\n- ✅ Users want \"complete report\" → 1 function does everything\n- ✅ Ideal for executive dashboards\n- ✅ Facilitates sales (\"everything in one report\")\n- ✅ Much better UX (no need to know individual functions)\n\n**When to mention in SKILL.md:**\n\n```markdown\n## Comprehensive Analysis (All-in-One)\n\nTo get a complete report combining ALL metrics:\n\nUse the `comprehensive_{domain}_report()` function.\n\nThis function:\n- Fetches ALL available metrics\n- Combines into single report\n- Generates automatic summary\n- Detects important alerts\n- Degrades gracefully (if 1 metric fails, others work)\n\nUsage example:\n\"Generate complete report for {entity}\"\n\"Complete dashboard for {entity}\"\n\"All metrics for {entity}\"\n```\n\n**Impact:**\n- ✅ 10x better UX (1 query = everything)\n- ✅ More useful skills for end users\n- ✅ Facilitates commercial adoption\n\n**2.5 Specify methodologies**\n\nFor quantitative analyses, define:\n\n- Mathematical formulas\n- Statistical validations\n- Interpretations\n- Edge cases\n\n**See** `references\u002Fphase2-design.md` for detailed methodologies.\n\n## PHASE 3: Architecture\n\n**Objective**: STRUCTURE the agent optimally\n\n### Process\n\n**3.1 Define folder structure**\n\nBased on analyses and API:\n\n```\nagent-name\u002F\n├── SKILL.md\n├── scripts\u002F\n│   ├── [fetch\u002Fparse\u002Fanalyze separate or together?]\n│   └── utils\u002F\n│       └── [cache? rate limiter? validators?]\n├── references\u002F\n│   └── [API docs? methodologies? troubleshooting?]\n└── assets\u002F\n    └── [configs? metadata?]\n```\n\n**Decisions**:\n\n- Separate scripts (modular) vs monolithic?\n- Which utilities needed?\n- Which references useful?\n- Which configs\u002Fassets?\n\n**3.2 Define responsibilities**\n\nFor each script, specify:\n\n- File name\n- Function\u002Fpurpose\n- Input and output\n- Specific responsibilities\n- ~Expected number of lines\n\n**3.3 Plan references**\n\nWhich reference files to create?\n\n- API guide (how to use API)\n- Analysis methods (methodologies)\n- Troubleshooting (common errors)\n- Domain knowledge (domain context)\n\n**3.4 Performance strategy**\n\n- Cache: What to cache? TTL?\n- Rate limiting: How to control?\n- Optimizations: Parallelization? Lazy loading?\n\n**See** `references\u002Fphase3-architecture.md` for structuring patterns.\n\n## PHASE 4: Automatic Detection\n\n**Objective**: DETERMINE keywords for automatic activation\n\n### Process\n\n**4.1 List domain entities**\n\n- Organizations\u002Fdata sources\n- Main metrics\n- Geography (countries, regions, states)\n- Temporality (years, periods)\n\n**4.2 List typical actions**\n\n- Query: \"what\", \"how much\", \"show\"\n- Compare: \"compare\", \"vs\", \"versus\"\n- Rank: \"top\", \"best\", \"ranking\"\n- Analyze: \"trend\", \"growth\", \"analyze\"\n- Forecast: \"predict\", \"project\", \"forecast\"\n\n**4.3 List question variations**\n\nFor each analysis type, how might the user ask?\n\n**4.4 Define negative scope**\n\nImportant! What should NOT activate the skill?\n\n**4.5 Create precise description**\n\nWith all keywords identified, create ~200 word description that:\n\n- Mentions domain\n- Lists main keywords\n- Gives examples\n- Defines negative scope\n\n**See** `references\u002Fphase4-detection.md` for complete guide.\n\n### 🎯 3-Layer Activation System (v3.0)\n\n**Important**: As of Agent-Skill-Creator v3.0, we now use a **3-Layer Activation System** to achieve 95%+ activation reliability.\n\n#### Why 3 Layers?\n\nPrevious skills that relied only on description achieved ~70% activation reliability. The 3-layer system dramatically improves this to 95%+ by combining:\n\n1. **Layer 1: Keywords** - Exact phrase matching (high precision)\n2. **Layer 2: Patterns** - Regex flexible matching (coverage for variations)\n3. **Layer 3: Description + NLU** - Claude's understanding (fallback for edge cases)\n\n#### Quick Implementation Guide\n\n**Layer 1: Keywords (10-15 phrases)**\n```json\n\"activation\": {\n  \"keywords\": [\n    \"create an agent for\",\n    \"automate workflow\",\n    \"technical analysis for\",\n    \"RSI indicator\",\n    \u002F\u002F 10-15 total complete phrases\n  ]\n}\n```\n\n**Requirements:**\n- ✅ Complete phrases (2+ words)\n- ✅ Action verb + entity\n- ✅ Domain-specific terms\n- ❌ No single words\n- ❌ No overly generic phrases\n\n**Layer 2: Patterns (5-7 regex)**\n```json\n\"patterns\": [\n  \"(?i)(create|build)\\\\s+(an?\\\\s+)?agent\\\\s+for\",\n  \"(?i)(automate|automation)\\\\s+(workflow|process)\",\n  \"(?i)(analyze|analysis)\\\\s+.*\\\\s+(stock|data)\",\n  \u002F\u002F 5-7 total patterns\n]\n```\n\n**Requirements:**\n- ✅ Start with `(?i)` for case-insensitivity\n- ✅ Include action verbs + entities\n- ✅ Allow flexible word order\n- ✅ Specific enough to avoid false positives\n- ✅ Flexible enough to capture variations\n\n**Layer 3: Enhanced Description (300-500 chars, 60+ keywords)**\n```\nComprehensive [domain] tool. [Primary capability] including [specific-feature-1],\n[specific-feature-2], and [specific-feature-3]. Generates [output-type] based on\n[method]. Compares [entity-type] for [analysis-type]. Monitors [target] and tracks\n[metric]. Perfect for [user-persona] needing [use-case-1], [use-case-2], and\n[use-case-3] using [methodology].\n```\n\n**Requirements:**\n- ✅ 60+ unique keywords\n- ✅ All Layer 1 keywords included naturally\n- ✅ Domain-specific terminology\n- ✅ Use cases clearly stated\n- ✅ Natural language flow\n\n#### Usage Sections\n\nAdd to marketplace.json:\n\n```json\n\"usage\": {\n  \"when_to_use\": [\n    \"User explicitly asks to [capability-1]\",\n    \"User mentions [indicator-name] or [domain-term]\",\n    \"User describes [use-case-scenario]\",\n    \u002F\u002F 5+ use cases\n  ],\n  \"when_not_to_use\": [\n    \"User asks for [out-of-scope-1]\",\n    \"User wants [different-skill-capability]\",\n    \u002F\u002F 3+ counter-cases\n  ]\n}\n```\n\n#### Test Queries\n\nAdd to marketplace.json:\n\n```json\n\"test_queries\": [\n  \"Query testing keyword-1\",\n  \"Query testing pattern-2\",\n  \"Query testing description understanding\",\n  \"Natural language variation\",\n  \u002F\u002F 10+ total queries covering all layers\n]\n```\n\n#### Complete Example\n\nSee `references\u002Fexamples\u002Fstock-analyzer-cskill\u002F` for a complete working example demonstrating:\n- All 3 layers properly configured\n- 98% activation reliability\n- Complete test suite\n- Documentation with activation examples\n\n#### Quality Checklist\n\nBefore completing Phase 4, verify:\n\n- [ ] 10-15 complete keyword phrases defined\n- [ ] 5-7 regex patterns with verbs + entities\n- [ ] 300-500 char description with 60+ keywords\n- [ ] 5+ when_to_use cases documented\n- [ ] 3+ when_not_to_use cases documented\n- [ ] 10+ test_queries covering all layers\n- [ ] Tested activation with sample queries\n- [ ] Expected success rate: 95%+\n\n#### Additional Resources\n\n- **Complete Guide**: `references\u002Fphase4-detection.md`\n- **Pattern Library**: `references\u002Factivation-patterns-guide.md` (30+ reusable patterns)\n- **Testing Guide**: `references\u002Factivation-testing-guide.md` (5-phase testing)\n- **Quality Checklist**: `references\u002Factivation-quality-checklist.md`\n- **Templates**: `references\u002Ftemplates\u002Fmarketplace-robust-template.json`\n- **Example**: `references\u002Fexamples\u002Fstock-analyzer-cskill\u002F`\n\n---\n\n## PHASE 5: Complete Implementation\n\n**Objective**: IMPLEMENT everything with REAL code\n\n### ⚠️ MANDATORY QUALITY STANDARDS\n\nBefore starting implementation, read `references\u002Fquality-standards.md`.\n\n**NEVER DO**:\n\n- ❌ `# TODO: implement`\n- ❌ `pass` in functions\n- ❌ \"See external documentation\"\n- ❌ Configs with \"YOUR_KEY_HERE\" without instructions\n- ❌ Empty references or just links\n\n**ALWAYS DO**:\n\n- ✅ Complete and functional code\n- ✅ Detailed docstrings\n- ✅ Robust error handling\n- ✅ Type hints\n- ✅ Validations\n- ✅ Real content in references\n- ✅ Configs with real values\n\n### 🚨 STEP 0: BEFORE EVERYTHING - Marketplace.json (MANDATORY)\n\n**STOP! READ THIS BEFORE CONTINUING!**\n\n🛑 **CRITICAL BLOCKER**: You CANNOT create ANY other file until completing this step.\n\n**Why marketplace.json is step 0:**\n\n- ❌ Without this file, the skill CANNOT be installed via `\u002Fplugin marketplace add`\n- ❌ All the work creating the agent will be USELESS without it\n- ❌ This is the most common error when creating agents - DO NOT make this mistake!\n\n#### Step 0.1: Create basic structure\n\n```bash\nmkdir -p agent-name\u002F.claude-plugin\n```\n\n#### Step 0.2: Create marketplace.json IMMEDIATELY\n\nCreate `.claude-plugin\u002Fmarketplace.json` with this content:\n\n```json\n{\n  \"name\": \"agent-name\",\n  \"owner\": {\n    \"name\": \"Agent Creator\",\n    \"email\": \"noreply@example.com\"\n  },\n  \"metadata\": {\n    \"description\": \"Brief agent description\",\n    \"version\": \"1.0.0\",\n    \"created\": \"2025-10-17\"\n  },\n  \"plugins\": [\n    {\n      \"name\": \"agent-plugin\",\n      \"description\": \"THIS DESCRIPTION MUST BE IDENTICAL to the description in SKILL.md frontmatter that you'll create in the next step\",\n      \"source\": \".\u002F\",\n      \"strict\": false,\n      \"skills\": [\".\u002F\"]\n    }\n  ]\n}\n```\n\n**⚠️ CRITICAL FIELDS:**\n\n- `name`: Agent name (same as directory name)\n- `plugins[0].description`: **MUST BE EXACTLY EQUAL** to SKILL.md frontmatter description\n- `plugins[0].skills`: `[\".\u002F\"]` points to SKILL.md in root\n- `plugins[0].source`: `\".\u002F\"` points to agent root\n\n#### Step 0.3: VALIDATE IMMEDIATELY (before continuing!)\n\n**Execute NOW these validation commands:**\n\n```bash\n# 1. Validate JSON syntax\npython3 -c \"import json; print('✅ Valid JSON'); json.load(open('agent-name\u002F.claude-plugin\u002Fmarketplace.json'))\"\n\n# 2. Verify file exists\nls -la agent-name\u002F.claude-plugin\u002Fmarketplace.json\n\n# If any command fails: STOP and fix before continuing!\n```\n\n**✅ CHECKLIST - You MUST complete ALL before proceeding:**\n\n- [ ] ✅ File `.claude-plugin\u002Fmarketplace.json` created\n- [ ] ✅ JSON is syntactically valid (validated with python)\n- [ ] ✅ Field `name` is correct\n- [ ] ✅ Field `plugins[0].description` ready to receive SKILL.md description\n- [ ] ✅ Field `plugins[0].skills` = `[\".\u002F\"]`\n- [ ] ✅ Field `plugins[0].source` = `\".\u002F\"`\n\n**🛑 ONLY PROCEED AFTER VALIDATING ALL ITEMS ABOVE!**\n\n---\n\n### Implementation Order (AFTER marketplace.json validated)\n\nNow that marketplace.json is created and validated, proceed:\n\n**1. Create rest of directory structure**\n\n```bash\nmkdir -p agent-name\u002F{scripts\u002Futils,references,assets,data\u002F{raw,processed,cache,analysis}}\n```\n\n**2. Create SKILL.md**\n\nMandatory structure:\n\n- Frontmatter (name, description)\n- When to use\n- How it works (overview)\n- Data source (detailed API)\n- Workflows (step-by-step by question type)\n- Available scripts (each explained)\n- Available analyses (each explained)\n- Error handling (all expected errors)\n- Mandatory validations\n- Performance and cache\n- Keywords for detection\n- Usage examples (5+ complete)\n\n**Size**: 5000-7000 words\n\n**⚠️ AFTER creating SKILL.md: SYNCHRONIZE description with marketplace.json!**\n\n**CRITICAL**: Now that SKILL.md is created with its frontmatter, you MUST:\n\n```bash\n# Edit marketplace.json to update description\n# Copy EXACTLY the description from SKILL.md frontmatter\n# Paste in .claude-plugin\u002Fmarketplace.json → plugins[0].description\n```\n\n**Verify synchronization:**\n\n- SKILL.md frontmatter description = marketplace.json plugins[0].description\n- Must be IDENTICAL (word for word!)\n- Without this, skill won't activate automatically\n\n**3. Implement Python scripts**\n\n**Order** (MANDATORY):\n\n1. **Utils first** (including helpers.py + validators\u002F - CRITICAL!)\n   - `utils\u002Fhelpers.py` (🔴 MANDATORY - already specified previously)\n   - `utils\u002Fcache_manager.py`\n   - `utils\u002Frate_limiter.py`\n   - `utils\u002Fvalidators\u002F` (🔴 MANDATORY - see Step 3.5 below)\n2. **Fetch** (API client - 1 method per API metric)\n3. **Parse** (🔴 MODULAR: 1 parser per data type! - see Step 3.2 below)\n4. **Analyze** (analyses - include comprehensive_report already specified!)\n\n**Each script (in general)**:\n\n- Shebang: `#!\u002Fusr\u002Fbin\u002Fenv python3`\n- Complete module docstring\n- Organized imports\n- Classes\u002Ffunctions with docstrings\n- Type hints\n- Error handling\n- Logging\n- Main function with argparse\n- if __name__ == \"__main__\"\n\n---\n\n### Step 3.2: Modular Parser Architecture (🆕 Enhancement #5 - MANDATORY!)\n\n**⚠️ COMMON PROBLEM:** v1.0 had 1 generic parser. When adding new data types, architecture broke.\n\n**Solution:** **1 specific parser per API data type!**\n\n**Rule:** If API returns N data types (identified in Phase 1.6) → create N specific parsers\n\n**Mandatory structure:**\n\n```\nscripts\u002F\n├── parse_{type1}.py    # Ex: parse_conditions.py\n├── parse_{type2}.py    # Ex: parse_progress.py\n├── parse_{type3}.py    # Ex: parse_yield.py\n├── parse_{type4}.py    # Ex: parse_production.py\n└── parse_{type5}.py    # Ex: parse_area.py\n```\n\n**Template for each parser:**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nParser for {type} data from {API_name}.\nHandles {type}-specific transformations and validations.\n\"\"\"\n\nimport pandas as pd\nfrom typing import List, Dict, Any, Optional\nimport logging\n\nlogger = logging.getLogger(__name__)\n\n\ndef parse_{type}_response(data: List[Dict]) -> pd.DataFrame:\n    \"\"\"\n    Parse API response for {type} data.\n\n    Args:\n        data: Raw API response (list of dicts)\n\n    Returns:\n        DataFrame with standardized schema:\n        - entity: str\n        - year: int\n        - {type}_value: float\n        - unit: str\n        - {type}_specific_fields: various\n\n    Raises:\n        ValueError: If data is invalid\n        ParseError: If parsing fails\n\n    Example:\n        >>> data = [{'entity': 'CORN', 'year': 2025, 'value': '15,300,000'}]\n        >>> df = parse_{type}_response(data)\n        >>> df.shape\n        (1, 5)\n    \"\"\"\n    if not data:\n        raise ValueError(\"Data cannot be empty\")\n\n    # Convert to DataFrame\n    df = pd.DataFrame(data)\n\n    # {Type}-specific transformations\n    df = _clean_{type}_values(df)\n    df = _extract_{type}_metadata(df)\n    df = _standardize_{type}_schema(df)\n\n    # Validate\n    _validate_{type}_schema(df)\n\n    return df\n\n\ndef _clean_{type}_values(df: pd.DataFrame) -> pd.DataFrame:\n    \"\"\"Clean {type}-specific values (remove formatting, convert types).\"\"\"\n    # Example: Remove commas from numbers\n    if 'value' in df.columns:\n        df['value'] = df['value'].astype(str).str.replace(',', '')\n        df['value'] = pd.to_numeric(df['value'], errors='coerce')\n\n    # {Type}-specific cleaning\n    # ...\n\n    return df\n\n\ndef _extract_{type}_metadata(df: pd.DataFrame) -> pd.DataFrame:\n    \"\"\"Extract {type}-specific metadata fields.\"\"\"\n    # Example for progress data: extract % from \"75% PLANTED\"\n    # Example for condition data: extract rating from \"GOOD (60%)\"\n    # Customize per data type!\n\n    return df\n\n\ndef _standardize_{type}_schema(df: pd.DataFrame) -> pd.DataFrame:\n    \"\"\"\n    Standardize column names and schema for {type} data.\n\n    Output schema:\n    - entity: str\n    - year: int\n    - {type}_value: float (main metric)\n    - unit: str\n    - additional_{type}_fields: various\n    \"\"\"\n    # Rename columns to standard names\n    column_mapping = {\n        'api_entity_field': 'entity',\n        'api_year_field': 'year',\n        'api_value_field': '{type}_value',\n        # Add more as needed\n    }\n    df = df.rename(columns=column_mapping)\n\n    # Ensure types\n    df['year'] = df['year'].astype(int)\n    df['{type}_value'] = pd.to_numeric(df['{type}_value'], errors='coerce')\n\n    return df\n\n\ndef _validate_{type}_schema(df: pd.DataFrame) -> None:\n    \"\"\"Validate {type} DataFrame schema.\"\"\"\n    required_columns = ['entity', 'year', '{type}_value']\n\n    missing = set(required_columns) - set(df.columns)\n    if missing:\n        raise ValueError(f\"Missing required columns: {missing}\")\n\n    # Type validations\n    if not pd.api.types.is_integer_dtype(df['year']):\n        raise TypeError(\"'year' must be integer type\")\n\n    if not pd.api.types.is_numeric_dtype(df['{type}_value']):\n        raise TypeError(\"'{type}_value' must be numeric type\")\n\n\ndef aggregate_{type}(df: pd.DataFrame, by: str) -> pd.DataFrame:\n    \"\"\"\n    Aggregate {type} data by specified level.\n\n    Args:\n        df: Parsed {type} DataFrame\n        by: Aggregation level ('national', 'state', 'region')\n\n    Returns:\n        Aggregated DataFrame\n\n    Example:\n        >>> agg = aggregate_{type}(df, by='state')\n    \"\"\"\n    # Aggregation logic specific to {type}\n    if by == 'national':\n        return df.groupby(['year']).agg({\n            '{type}_value': 'sum',\n            # Add more as needed\n        }).reset_index()\n\n    elif by == 'state':\n        return df.groupby(['year', 'state']).agg({\n            '{type}_value': 'sum',\n        }).reset_index()\n\n    # Add more levels...\n\n\ndef format_{type}_report(df: pd.DataFrame) -> str:\n    \"\"\"\n    Format {type} data as human-readable report.\n\n    Args:\n        df: Parsed {type} DataFrame\n\n    Returns:\n        Formatted string report\n\n    Example:\n        >>> report = format_{type}_report(df)\n        >>> print(report)\n        \"{Type} Report: ...\"\n    \"\"\"\n    lines = [f\"## {Type} Report\\n\"]\n\n    # Format based on {type} data\n    # Customize per type!\n\n    return \"\\n\".join(lines)\n\n\ndef main():\n    \"\"\"Test parser with sample data.\"\"\"\n    # Sample data for testing\n    sample_data = [\n        {\n            'entity': 'CORN',\n            'year': 2025,\n            'value': '15,300,000',\n            # Add {type}-specific fields\n        }\n    ]\n\n    print(\"Testing parse_{type}_response()...\")\n    df = parse_{type}_response(sample_data)\n    print(f\"✓ Parsed {len(df)} records\")\n    print(f\"✓ Columns: {list(df.columns)}\")\n    print(f\"\\n{df.head()}\")\n\n    print(\"\\nTesting aggregate_{type}()...\")\n    agg = aggregate_{type}(df, by='national')\n    print(f\"✓ Aggregated: {agg}\")\n\n    print(\"\\nTesting format_{type}_report()...\")\n    report = format_{type}_report(df)\n    print(report)\n\n\nif __name__ == \"__main__\":\n    main()\n```\n\n**Why create modular parsers:**\n- ✅ Each data type has peculiarities (progress has %, yield has bu\u002Facre, etc)\n- ✅ Scalable architecture (easy to add new types)\n- ✅ Isolated tests (each parser tested independently)\n- ✅ Simple maintenance (bug in 1 type doesn't affect others)\n- ✅ Organized code (clear responsibilities)\n\n**Impact:** Professional and scalable architecture from v1.0!\n\n---\n\n### Step 3.5: Validation System (🆕 Enhancement #10 - MANDATORY!)\n\n**⚠️ COMMON PROBLEM:** v1.0 without data validation. User doesn't know if data is reliable.\n\n**Solution:** Complete validation system in `utils\u002Fvalidators\u002F`\n\n**Mandatory structure:**\n\n```\nscripts\u002Futils\u002Fvalidators\u002F\n├── __init__.py\n├── parameter_validator.py    # Validate function parameters\n├── data_validator.py         # Validate API responses\n├── temporal_validator.py     # Validate temporal consistency\n└── completeness_validator.py # Validate data completeness\n```\n\n**Template 1: parameter_validator.py**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nParameter validators for {skill-name}.\nValidates user inputs before making API calls.\n\"\"\"\n\nfrom typing import Any, List, Optional\nfrom datetime import datetime\n\n\nclass ValidationError(Exception):\n    \"\"\"Raised when validation fails.\"\"\"\n    pass\n\n\ndef validate_entity(entity: str, valid_entities: Optional[List[str]] = None) -> str:\n    \"\"\"\n    Validate entity parameter.\n\n    Args:\n        entity: Entity name (e.g., \"CORN\", \"SOYBEANS\")\n        valid_entities: List of valid entities (None to skip check)\n\n    Returns:\n        str: Validated and normalized entity name\n\n    Raises:\n        ValidationError: If entity is invalid\n\n    Example:\n        >>> validate_entity(\"corn\")\n        \"CORN\"  # Normalized to uppercase\n    \"\"\"\n    if not entity:\n        raise ValidationError(\"Entity cannot be empty\")\n\n    if not isinstance(entity, str):\n        raise ValidationError(f\"Entity must be string, got {type(entity)}\")\n\n    # Normalize\n    entity = entity.strip().upper()\n\n    # Check if valid (if list provided)\n    if valid_entities and entity not in valid_entities:\n        suggestions = [e for e in valid_entities if entity[:3] in e]\n        raise ValidationError(\n            f\"Invalid entity: {entity}\\n\"\n            f\"Valid options: {', '.join(valid_entities[:10])}\\n\"\n            f\"Did you mean: {', '.join(suggestions[:3])}?\"\n        )\n\n    return entity\n\n\ndef validate_year(\n    year: Optional[int],\n    min_year: int = 1900,\n    allow_future: bool = False\n) -> int:\n    \"\"\"\n    Validate year parameter.\n\n    Args:\n        year: Year to validate (None returns current year)\n        min_year: Minimum valid year\n        allow_future: Whether future years are allowed\n\n    Returns:\n        int: Validated year\n\n    Raises:\n        ValidationError: If year is invalid\n\n    Example:\n        >>> validate_year(2025)\n        2025\n        >>> validate_year(None)\n        2025  # Current year\n    \"\"\"\n    current_year = datetime.now().year\n\n    if year is None:\n        return current_year\n\n    if not isinstance(year, int):\n        raise ValidationError(f\"Year must be integer, got {type(year)}\")\n\n    if year \u003C min_year:\n        raise ValidationError(\n            f\"Year {year} is too old (minimum: {min_year})\"\n        )\n\n    if not allow_future and year > current_year:\n        raise ValidationError(\n            f\"Year {year} is in the future (current: {current_year})\"\n        )\n\n    return year\n\n\ndef validate_state(state: str, country: str = \"US\") -> str:\n    \"\"\"Validate state\u002Fregion parameter.\"\"\"\n    # Country-specific validation\n    # ...\n    return state.upper()\n\n\n# Add more validators for domain-specific parameters...\n```\n\n**Template 2: data_validator.py**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nData validators for {skill-name}.\nValidates API responses and analysis outputs.\n\"\"\"\n\nimport pandas as pd\nfrom typing import Dict, List, Any\nfrom dataclasses import dataclass\nfrom enum import Enum\n\n\nclass ValidationLevel(Enum):\n    \"\"\"Severity levels for validation results.\"\"\"\n    CRITICAL = \"critical\"  # Must fix\n    WARNING = \"warning\"    # Should review\n    INFO = \"info\"          # FYI\n\n\n@dataclass\nclass ValidationResult:\n    \"\"\"Single validation check result.\"\"\"\n    check_name: str\n    level: ValidationLevel\n    passed: bool\n    message: str\n    details: Optional[Dict] = None\n\n\nclass ValidationReport:\n    \"\"\"Collection of validation results.\"\"\"\n\n    def __init__(self):\n        self.results: List[ValidationResult] = []\n\n    def add(self, result: ValidationResult):\n        \"\"\"Add validation result.\"\"\"\n        self.results.append(result)\n\n    def has_critical_issues(self) -> bool:\n        \"\"\"Check if any critical issues found.\"\"\"\n        return any(\n            r.level == ValidationLevel.CRITICAL and not r.passed\n            for r in self.results\n        )\n\n    def all_passed(self) -> bool:\n        \"\"\"Check if all validations passed.\"\"\"\n        return all(r.passed for r in self.results)\n\n    def get_warnings(self) -> List[str]:\n        \"\"\"Get all warning messages.\"\"\"\n        return [\n            r.message for r in self.results\n            if r.level == ValidationLevel.WARNING and not r.passed\n        ]\n\n    def get_summary(self) -> str:\n        \"\"\"Get summary of validation results.\"\"\"\n        total = len(self.results)\n        passed = sum(1 for r in self.results if r.passed)\n        critical = sum(\n            1 for r in self.results\n            if r.level == ValidationLevel.CRITICAL and not r.passed\n        )\n\n        return (\n            f\"Validation: {passed}\u002F{total} passed \"\n            f\"({critical} critical issues)\"\n        )\n\n\nclass DataValidator:\n    \"\"\"Validates API responses and DataFrames.\"\"\"\n\n    def validate_response(self, data: Any) -> ValidationReport:\n        \"\"\"\n        Validate raw API response.\n\n        Args:\n            data: Raw API response\n\n        Returns:\n            ValidationReport with results\n        \"\"\"\n        report = ValidationReport()\n\n        # Check 1: Not empty\n        report.add(ValidationResult(\n            check_name=\"not_empty\",\n            level=ValidationLevel.CRITICAL,\n            passed=bool(data),\n            message=\"Data is empty\" if not data else \"Data present\"\n        ))\n\n        # Check 2: Correct type\n        expected_type = (list, dict)\n        is_correct_type = isinstance(data, expected_type)\n        report.add(ValidationResult(\n            check_name=\"correct_type\",\n            level=ValidationLevel.CRITICAL,\n            passed=is_correct_type,\n            message=f\"Expected {expected_type}, got {type(data)}\"\n        ))\n\n        # Check 3: Has expected structure\n        if isinstance(data, dict):\n            has_data_key = 'data' in data\n            report.add(ValidationResult(\n                check_name=\"has_data_key\",\n                level=ValidationLevel.WARNING,\n                passed=has_data_key,\n                message=\"Response has 'data' key\" if has_data_key else \"No 'data' key\"\n            ))\n\n        return report\n\n    def validate_dataframe(self, df: pd.DataFrame, data_type: str) -> ValidationReport:\n        \"\"\"\n        Validate parsed DataFrame.\n\n        Args:\n            df: Parsed DataFrame\n            data_type: Type of data (for type-specific checks)\n\n        Returns:\n            ValidationReport\n        \"\"\"\n        report = ValidationReport()\n\n        # Check 1: Not empty\n        report.add(ValidationResult(\n            check_name=\"not_empty\",\n            level=ValidationLevel.CRITICAL,\n            passed=len(df) > 0,\n            message=f\"DataFrame has {len(df)} rows\"\n        ))\n\n        # Check 2: Required columns\n        required = ['entity', 'year']  # Customize per type\n        missing = set(required) - set(df.columns)\n        report.add(ValidationResult(\n            check_name=\"required_columns\",\n            level=ValidationLevel.CRITICAL,\n            passed=len(missing) == 0,\n            message=f\"Missing columns: {missing}\" if missing else \"All required columns present\"\n        ))\n\n        # Check 3: No excessive NaN values\n        if len(df) > 0:\n            nan_pct = (df.isna().sum() \u002F len(df) * 100).max()\n            report.add(ValidationResult(\n                check_name=\"nan_threshold\",\n                level=ValidationLevel.WARNING,\n                passed=nan_pct \u003C 30,\n                message=f\"Max NaN: {nan_pct:.1f}% ({'OK' if nan_pct \u003C 30 else 'HIGH'})\"\n            ))\n\n        # Check 4: Data types correct\n        if 'year' in df.columns:\n            is_int = pd.api.types.is_integer_dtype(df['year'])\n            report.add(ValidationResult(\n                check_name=\"year_type\",\n                level=ValidationLevel.CRITICAL,\n                passed=is_int,\n                message=\"'year' is integer\" if is_int else \"'year' is not integer\"\n            ))\n\n        return report\n\n\ndef validate_{type}_output(result: Dict) -> ValidationReport:\n    \"\"\"\n    Validate analysis output for {type}.\n\n    Args:\n        result: Analysis result dict\n\n    Returns:\n        ValidationReport\n    \"\"\"\n    report = ValidationReport()\n\n    # Check required keys\n    required_keys = ['year', 'year_info', 'data']\n    for key in required_keys:\n        report.add(ValidationResult(\n            check_name=f\"has_{key}\",\n            level=ValidationLevel.CRITICAL,\n            passed=key in result,\n            message=f\"'{key}' present\" if key in result else f\"Missing '{key}'\"\n        ))\n\n    # Check data quality\n    if 'data' in result and result['data']:\n        report.add(ValidationResult(\n            check_name=\"data_not_empty\",\n            level=ValidationLevel.CRITICAL,\n            passed=True,\n            message=\"Data is present\"\n        ))\n\n    return report\n\n\n# Main for testing\nif __name__ == \"__main__\":\n    print(\"Testing validators...\")\n\n    # Test entity validator\n    print(\"\\n1. Testing validate_entity():\")\n    try:\n        entity = validate_entity(\"corn\", [\"CORN\", \"SOYBEANS\"])\n        print(f\"   ✓ Valid: {entity}\")\n    except ValidationError as e:\n        print(f\"   ✗ Error: {e}\")\n\n    # Test year validator\n    print(\"\\n2. Testing validate_year():\")\n    year = validate_year(2025)\n    print(f\"   ✓ Valid: {year}\")\n\n    # Test DataValidator\n    print(\"\\n3. Testing DataValidator:\")\n    validator = DataValidator()\n    sample_data = [{'entity': 'CORN', 'year': 2025}]\n    report = validator.validate_response(sample_data)\n    print(f\"   {report.get_summary()}\")\n```\n\n**Template 3: temporal_validator.py**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nTemporal validators for {skill-name}.\nChecks temporal consistency and data age.\n\"\"\"\n\nimport pandas as pd\nfrom datetime import datetime, timedelta\nfrom typing import List\nfrom .data_validator import ValidationResult, ValidationReport, ValidationLevel\n\n\ndef validate_temporal_consistency(df: pd.DataFrame) -> ValidationReport:\n    \"\"\"\n    Check temporal consistency in data.\n\n    Validations:\n    - No future dates\n    - Years in valid range\n    - No suspicious gaps in time series\n    - Data age is acceptable\n\n    Args:\n        df: DataFrame with 'year' column\n\n    Returns:\n        ValidationReport\n    \"\"\"\n    report = ValidationReport()\n    current_year = datetime.now().year\n\n    if 'year' not in df.columns:\n        report.add(ValidationResult(\n            check_name=\"has_year_column\",\n            level=ValidationLevel.CRITICAL,\n            passed=False,\n            message=\"Missing 'year' column\"\n        ))\n        return report\n\n    # Check 1: No future years\n    max_year = df['year'].max()\n    report.add(ValidationResult(\n        check_name=\"no_future_years\",\n        level=ValidationLevel.CRITICAL,\n        passed=max_year \u003C= current_year,\n        message=f\"Max year: {max_year} ({'valid' if max_year \u003C= current_year else 'FUTURE!'})\"\n    ))\n\n    # Check 2: Years in reasonable range\n    min_year = df['year'].min()\n    is_reasonable = min_year >= 1900\n    report.add(ValidationResult(\n        check_name=\"reasonable_year_range\",\n        level=ValidationLevel.WARNING,\n        passed=is_reasonable,\n        message=f\"Year range: {min_year}-{max_year}\"\n    ))\n\n    # Check 3: Data age (is data recent enough?)\n    data_age_years = current_year - max_year\n    is_recent = data_age_years \u003C= 2\n    report.add(ValidationResult(\n        check_name=\"data_freshness\",\n        level=ValidationLevel.WARNING,\n        passed=is_recent,\n        message=f\"Data age: {data_age_years} years ({'recent' if is_recent else 'STALE'})\"\n    ))\n\n    # Check 4: No suspicious gaps in time series\n    if len(df['year'].unique()) > 2:\n        years_sorted = sorted(df['year'].unique())\n        gaps = [\n            years_sorted[i+1] - years_sorted[i]\n            for i in range(len(years_sorted)-1)\n        ]\n        max_gap = max(gaps) if gaps else 0\n        has_large_gap = max_gap > 2\n\n        report.add(ValidationResult(\n            check_name=\"no_large_gaps\",\n            level=ValidationLevel.WARNING,\n            passed=not has_large_gap,\n            message=f\"Max gap: {max_gap} years\" + (\" (suspicious)\" if has_large_gap else \"\")\n        ))\n\n    return report\n\n\ndef validate_week_number(week: int, year: int) -> ValidationResult:\n    \"\"\"Validate week number is in valid range for year.\"\"\"\n    # Most data types use weeks 1-53\n    is_valid = 1 \u003C= week \u003C= 53\n\n    return ValidationResult(\n        check_name=\"valid_week\",\n        level=ValidationLevel.CRITICAL,\n        passed=is_valid,\n        message=f\"Week {week} ({'valid' if is_valid else 'INVALID: must be 1-53'})\"\n    )\n\n\n# Add more temporal validators as needed...\n```\n\n**Template 4: completeness_validator.py**\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nCompleteness validators for {skill-name}.\nChecks data completeness and coverage.\n\"\"\"\n\nimport pandas as pd\nfrom typing import List, Set\nfrom .data_validator import ValidationResult, ValidationReport, ValidationLevel\n\n\ndef validate_completeness(\n    df: pd.DataFrame,\n    expected_entities: Optional[List[str]] = None,\n    expected_years: Optional[List[int]] = None\n) -> ValidationReport:\n    \"\"\"\n    Validate data completeness.\n\n    Args:\n        df: DataFrame to validate\n        expected_entities: Expected entities (None to skip)\n        expected_years: Expected years (None to skip)\n\n    Returns:\n        ValidationReport\n    \"\"\"\n    report = ValidationReport()\n\n    # Check 1: All expected entities present\n    if expected_entities:\n        actual_entities = set(df['entity'].unique())\n        expected_set = set(expected_entities)\n        missing = expected_set - actual_entities\n\n        report.add(ValidationResult(\n            check_name=\"all_entities_present\",\n            level=ValidationLevel.WARNING,\n            passed=len(missing) == 0,\n            message=f\"Missing entities: {missing}\" if missing else \"All entities present\",\n            details={'missing': list(missing)}\n        ))\n\n    # Check 2: All expected years present\n    if expected_years:\n        actual_years = set(df['year'].unique())\n        expected_set = set(expected_years)\n        missing = expected_set - actual_years\n\n        report.add(ValidationResult(\n            check_name=\"all_years_present\",\n            level=ValidationLevel.WARNING,\n            passed=len(missing) == 0,\n            message=f\"Missing years: {missing}\" if missing else \"All years present\"\n        ))\n\n    # Check 3: No excessive nulls in critical columns\n    critical_columns = ['entity', 'year']  # Customize\n    for col in critical_columns:\n        if col in df.columns:\n            null_count = df[col].isna().sum()\n            report.add(ValidationResult(\n                check_name=f\"{col}_no_nulls\",\n                level=ValidationLevel.CRITICAL,\n                passed=null_count == 0,\n                message=f\"'{col}' has {null_count} nulls\"\n            ))\n\n    # Check 4: Coverage percentage\n    if expected_entities and expected_years:\n        expected_total = len(expected_entities) * len(expected_years)\n        actual_total = len(df)\n        coverage_pct = (actual_total \u002F expected_total) * 100 if expected_total > 0 else 0\n\n        report.add(ValidationResult(\n            check_name=\"coverage_percentage\",\n            level=ValidationLevel.INFO,\n            passed=coverage_pct >= 80,\n            message=f\"Coverage: {coverage_pct:.1f}% ({actual_total}\u002F{expected_total})\"\n        ))\n\n    return report\n```\n\n**Integration in analysis functions:**\n\n```python\ndef {analysis_function}(entity: str, year: Optional[int] = None, ...) -> Dict:\n    \"\"\"Analysis function with validation.\"\"\"\n    from utils.validators.parameter_validator import validate_entity, validate_year\n    from utils.validators.data_validator import DataValidator\n    from utils.validators.temporal_validator import validate_temporal_consistency\n\n    # VALIDATE INPUTS (before doing anything!)\n    entity = validate_entity(entity, valid_entities=[...])\n    year = validate_year(year)\n\n    # Fetch data\n    data = fetch_{metric}(entity, year)\n\n    # VALIDATE API RESPONSE\n    validator = DataValidator()\n    response_validation = validator.validate_response(data)\n\n    if response_validation.has_critical_issues():\n        raise DataQualityError(\n            f\"API response validation failed: {response_validation.get_summary()}\"\n        )\n\n    # Parse\n    df = parse_{type}(data)\n\n    # VALIDATE PARSED DATA\n    df_validation = validator.validate_dataframe(df, '{type}')\n    temporal_validation = validate_temporal_consistency(df)\n\n    if df_validation.has_critical_issues():\n        raise DataQualityError(\n            f\"Data validation failed: {df_validation.get_summary()}\"\n        )\n\n    # Analyze\n    results = analyze(df)\n\n    # Return with validation info\n    return {\n        'data': results,\n        'year': year,\n        'year_info': format_year_message(year, year_requested),\n        'validation': {\n            'passed': df_validation.all_passed(),\n            'warnings': df_validation.get_warnings(),\n            'report': df_validation.get_summary()\n        }\n    }\n```\n\n**Impact:**\n- ✅ Reliable data (validated at multiple layers)\n- ✅ Transparency (user sees validation report)\n- ✅ Clear error messages (not just \"generic error\")\n- ✅ Problem detection (gaps, nulls, inconsistencies)\n\n---\n\n**4. Write references**\n\nFor each reference file:\n\n- 1000-2000 words\n- Useful content (examples, methodologies, guides)\n- Well structured (headings, lists, code blocks)\n- Well-formatted markdown\n\n**5. Create assets**\n\n- Syntactically valid JSONs\n- Real values with comments\n- Logical structure\n\n**6. Write README.md**\n\n- Step-by-step installation\n- Required configuration\n- Usage examples\n- Troubleshooting\n\n**7. Create DECISIONS.md**\n\nDocument all decisions made:\n\n- Which API chosen and why\n- Which analyses defined and justification\n- Structure chosen and rationale\n- Trade-offs considered\n\n**8. Create VERSION and CHANGELOG.md** (🆕 Enhancement #7 - Versioning)\n\n**8.1 Create VERSION file:**\n\n```\n1.0.0\n```\n\n**8.2 Create CHANGELOG.md:**\n\n```markdown\n# Changelog\n\nAll notable changes to {skill-name} will be documented here.\n\nFormat based on [Keep a Changelog](https:\u002F\u002Fkeepachangelog.com\u002Fen\u002F1.0.0\u002F).\nVersioning follows [Semantic Versioning](https:\u002F\u002Fsemver.org\u002F).\n\n## [1.0.0] - {current_date}\n\n### Added\n\n**Core Functionality:**\n- {function1}: {Description of what it does}\n- {function2}: {Description of what it does}\n- {function3}: {Description of what it does}\n...\n\n**Data Sources:**\n- {API_name}: {Coverage description}\n- Authentication: {auth_method}\n- Rate limit: {limit}\n\n**Analysis Capabilities:**\n- {analysis1}: {Description and methodology}\n- {analysis2}: {Description and methodology}\n...\n\n**Utilities:**\n- Cache system with {TTL} TTL\n- Rate limiting: {limit} per {period}\n- Error handling with automatic retries\n- Data validation and quality checks\n\n### Data Coverage\n\n**Metrics implemented:**\n- {metric1}: {Coverage details}\n- {metric2}: {Coverage details}\n...\n\n**Geographic coverage:** {geo_coverage}\n**Temporal coverage:** {temporal_coverage}\n\n### Known Limitations\n\n- {limitation1}\n- {limitation2}\n...\n\n### Planned for v2.0\n\n- {planned_feature1}\n- {planned_feature2}\n...\n\n## [Unreleased]\n\n### Planned\n\n- Add support for {feature}\n- Improve performance for {scenario}\n- Expand coverage to {new_area}\n```\n\n**8.3 Update marketplace.json with version:**\n\nEdit `.claude-plugin\u002Fmarketplace.json` to include:\n\n```json\n{\n  \"metadata\": {\n    \"description\": \"...\",\n    \"version\": \"1.0.0\",\n    \"created\": \"{current_date}\",\n    \"updated\": \"{current_date}\"\n  }\n}\n```\n\n**8.4 Create .bumpversion.cfg (optional):**\n\nIf you want version automation:\n\n```ini\n[bumpversion]\ncurrent_version = 1.0.0\ncommit = False\ntag = False\n\n[bumpversion:file:VERSION]\n\n[bumpversion:file:.claude-plugin\u002Fmarketplace.json]\nsearch = \"version\": \"{current_version}\"\nreplace = \"version\": \"{new_version}\"\n\n[bumpversion:file:CHANGELOG.md]\nsearch = ## [Unreleased]\nreplace = ## [Unreleased]\n\n## [{new_version}] - {now:%Y-%m-%d}\n```\n\n**Impact:**\n- ✅ Change traceability\n- ✅ Professionalism\n- ✅ Facilitates future updates\n- ✅ Users know what changed between versions\n\n**9. Create INSTALLATION.md** (Didactic Tutorial)\n\n[Content of INSTALLATION.md as previously specified]\n\n### Practical Implementation\n\n**Create agent in subdirectory**:\n\n```bash\n# Agent name based on domain\u002Fobjective\nagent_name=\"nass-usda-agriculture\"  # example\n\n# Create structure\nmkdir -p $agent_name\u002F{scripts\u002Futils,references,assets,data}\n\n# Implement each file\n# [Claude creates each file with Write tool]\n```\n\n**At the end, inform user**:\n\n```\n✅ Agent created in .\u002F{agent_name}\u002F\n\n📁 Structure:\n- .claude-plugin\u002Fmarketplace.json ✅ (installation + version)\n- SKILL.md (6,200 words)\n- scripts\u002F (2,500+ lines of code)\n  ├─ utils\u002Fhelpers.py ✅ (temporal context)\n  ├─ utils\u002Fvalidators\u002F ✅ (4 validators, ~800 lines)\n  ├─ parse_{type}*.py ✅ (1 per data type, modular)\n  └─ comprehensive_{domain}_report() ✅\n- tests\u002F (25+ tests, ~800 lines) ✅\n  ├─ test_integration.py (end-to-end)\n  ├─ test_parse.py (all parsers)\n  ├─ test_helpers.py (temporal)\n  └─ test_validation.py (validators)\n- references\u002F (5,000 words)\n- assets\u002F (2 configs)\n- README.md (1,000+ words with Testing section)\n- INSTALLATION.md (1,500 words) ✅\n- DECISIONS.md (justifications)\n- VERSION (1.0.0) ✅\n- CHANGELOG.md (release notes) ✅\n\n🚀 To install:\n\u002Fplugin marketplace add .\u002F{agent_name}\n\n💡 Usage examples:\n\"[example 1]\"\n\"[example 2]\"\n```\n\n**See** `references\u002Fphase5-implementation.md` for complete implementation guide.\n\n## Complete Flow: Step-by-Step\n\n### User Input\n\nUser describes workflow\u002Fobjective:\n\n```\n\"Every day I download US crop data from USDA,\ncompare current year vs previous, create state ranking\nby production, and generate report. Takes 2 hours.\nAutomate this.\"\n```\n\n### Autonomous Execution\n\n**Claude executes internally** (doesn't need to show everything):\n\n**PHASE 1**: Discovery (~5-10 min)\n\n```\n[WebSearch: \"USDA API free agriculture data\"]\n[WebFetch: NASS API docs]\n[Compare: NASS vs ERS vs FAO]\n→ DECISION: NASS QuickStats API\n   Justification: Free, data since 1866, all crops, state-level\n```\n\n**PHASE 2**: Design (~5 min)\n\n```\n[Analyze: \"compare years\", \"state ranking\", \"generate report\"]\n→ DEFINE analyses:\n  1. YoY comparison (compare years)\n  2. State ranking (state ranking)\n  3. Trend analysis (if user asks for trends)\n  4. Report generator (generate report)\n```\n\n**PHASE 3**: Architecture (~5 min)\n\n```\n→ STRUCTURE:\n  scripts\u002F\n    - fetch_nass.py (API requests)\n    - parse_nass.py (parsing)\n    - analyze_nass.py (YoY, ranking, trends)\n    - generate_report.py (report)\n    utils\u002F\n      - cache_manager.py\n      - rate_limiter.py\n  references\u002F\n    - nass-api-guide.md\n    - analysis-methods.md\n    - report-templates.md\n  assets\u002F\n    - config.json\n    - metadata.json\n```\n\n**PHASE 4**: Detection (~2 min)\n\n```\n→ KEYWORDS:\n  Entities: USDA, NASS, agriculture, crops\n  Commodities: corn, soybeans, wheat\n  Metrics: production, area, yield\n  Actions: compare, ranking, trend\n  Geography: US, states, Iowa, Illinois\n\n→ DESCRIPTION: \"This skill should be used when user\n  asks about US agriculture, production, area,\n  crop yield...\"\n```\n\n**PHASE 5**: Implementation (~45 min)\n\n```\n[Write: SKILL.md] ✅ 6,000 words\n[Write: fetch_nass.py] ✅ 280 lines\n[Write: parse_nass.py] ✅ 180 lines\n[Write: analyze_nass.py] ✅ 520 lines\n[Write: generate_report.py] ✅ 200 lines\n[Write: utils\u002Fcache_manager.py] ✅ 120 lines\n[Write: utils\u002Frate_limiter.py] ✅ 110 lines\n[Write: references\u002Fnass-api-guide.md] ✅ 1,500 words\n[Write: references\u002Fanalysis-methods.md] ✅ 2,000 words\n[Write: references\u002Freport-templates.md] ✅ 1,000 words\n[Write: assets\u002Fconfig.json] ✅\n[Write: assets\u002Fmetadata.json] ✅\n[Write: README.md] ✅ 800 words\n[Write: DECISIONS.md] ✅ 600 words\n```\n\n### User Output\n\n```\n✅ Agent created: .\u002Fusda-agriculture-agent\u002F\n\n📊 Technical Decisions:\n- API: USDA NASS QuickStats (free, data since 1866)\n- Analyses: YoY, Ranking, Trends, Report Generation\n- Structure: 4 main scripts + 2 utils\n- Cache: Historical permanent, current 7 days\n\n📁 Files Created:\n- SKILL.md: 6,000 words\n- Python code: 2,500+ lines\n  ├─ Modular parsers (1 per type)\n  ├─ Validation system (800 lines)\n  ├─ Temporal helpers\n  └─ comprehensive_report()\n- Tests: 25+ tests (800 lines)\n- References: 4,500 words\n- Configs: 2 files\n- README: Complete (with Testing)\n- INSTALLATION.md: Didactic tutorial\n- VERSION: 1.0.0\n- CHANGELOG.md: Complete release notes\n\n🎯 Estimated Savings:\n- Before: 2 hours\u002Fday\n- After: 3 minutes\u002Fday\n- Savings: 98.5% (117h\u002Fmonth → 1.5h\u002Fmonth)\n\n🚀 To install and use:\n\n# 1. Get API key (free):\nVisit: https:\u002F\u002Fquickstats.nass.usda.gov\u002Fapi#registration\n\n# 2. Configure:\nexport NASS_API_KEY=\"your_key_here\"\n\n# 3. Install skill:\n\u002Fplugin marketplace add .\u002Fusda-agriculture-agent\n\n# 4. Use (examples):\n\"US corn production in 2023\"\n\"Compare soybeans this year vs last year\"\n\"Ranking of wheat producing states\"\n\"Generate current crop report\"\n```\n\n## Detailed References\n\nFor details of each phase, load references:\n\n- `references\u002Fphase1-discovery.md`: API research and decision\n- `references\u002Fphase2-design.md`: Analysis definition\n- `references\u002Fphase3-architecture.md`: Project structuring\n- `references\u002Fphase4-detection.md`: Keywords and automatic activation\n- `references\u002Fphase5-implementation.md`: Code implementation\n- `references\u002Fquality-standards.md`: Mandatory standards\n- `references\u002Fexamples.md`: Complete examples of created agents\n\n## Meta-Skill Usage Examples\n\n### Example 1: Simple Workflow\n\n```\n👤 \"Automate: download weather data, calculate averages,\n    generate chart. I do this every week, takes 1h.\"\n\n🤖 [Activates agent-creator]\n   [Phase 1]: Research → NOAA API\n   [Phase 2]: Defines → Download, Aggregation, Visualization\n   [Phase 3]: Structure → 3 scripts + 2 utils\n   [Phase 4]: Keywords → weather, climate, temperature, NOAA\n   [Phase 5]: Implements everything\n\n   ✅ Agent created: .\u002Fweather-analysis-agent\u002F\n   [Installation instructions]\n```\n\n### Example 2: Complex Workflow\n\n```\n👤 \"I need an agent for stock financial analysis:\n    fetch prices, calculate technical indicators (RSI, MACD),\n    compare with benchmarks, generate alerts. Daily, 3h.\"\n\n🤖 [Activates agent-creator]\n   [Phase 1]: Research → Alpha Vantage API (or Yahoo Finance)\n   [Phase 2]: Defines → Price fetching, Technical indicators,\n             Benchmark comparison, Alert system\n   [Phase 3]: Structure → 5 scripts + 4 utils\n   [Phase 4]: Keywords → stock, RSI, MACD, technical analysis\n   [Phase 5]: Implements\n\n   ✅ Agent created: .\u002Fstock-technical-analysis-agent\u002F\n```\n\n### Example 3: Just Vague Description\n\n```\n👤 \"Create an agent for Brazilian agriculture\"\n\n🤖 [Activates agent-creator]\n\n   \"Got it! I'll create an agent for Brazilian agriculture.\n\n   A few quick questions:\n   - Focus on which crops? (soy, corn, coffee, all?)\n   - Desired analyses? (production, prices, exports?)\n   - Preferred source? (CONAB, IBGE, both?)\n\n   Or I can decide based on most common use cases\n   (grain production via CONAB). Prefer I decide?\"\n\n👤 \"You decide, focus on grain production.\"\n\n🤖 [Phase 1]: CONAB Grain Survey\n   [Phase 2]: YoY, Ranking, Regional, Trends\n   [Phase 3-5]: Creates everything\n\n   ✅ Agent created: .\u002Fconab-agriculture-agent\u002F\n```\n\n---\n\n## PHASE 6: Test Suite Generation (🆕 Enhancement #4 - MANDATORY!)\n\n**Objective**: Generate comprehensive test suite that validates ALL functions\n\n**⚠️ COMMON PROBLEM:** v1.0 without tests. Difficult to validate code works, impossible to do regression testing.\n\n**Solution:** Automatically generate 25+ tests covering all layers!\n\n### Test Structure\n\n```\ntests\u002F\n├── __init__.py\n├── test_fetch.py            # Test API fetch functions\n├── test_parse.py            # Test each parser\n├── test_analyze.py          # Test analysis functions\n├── test_integration.py      # End-to-end tests\n├── test_validation.py       # Test validators\n├── test_helpers.py          # Test temporal helpers\n└── conftest.py              # Shared fixtures (pytest)\n```\n\n### Template 1: test_integration.py (MAIN!)\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"\nIntegration tests for {skill-name}.\nTests complete workflows from query to result.\n\"\"\"\n\nimport sys\nfrom pathlib import Path\n\n# Add scripts to path\nsys.path.insert(0, str(Path(__file__).parent.parent \u002F 'scripts'))\n\nfrom analyze_{domain} import (\n    {function1},\n    {function2},\n    {function3},\n    comprehensive_{domain}_report\n)\n\n\ndef test_{function1}_basic():\n    \"\"\"Test {function1} with auto-year detection.\"\"\"\n    print(f\"\\n✓ Testing {function1}()...\")\n\n    try:\n        # Test auto-year detection (year=None)\n        result = {function1}('{example_entity}')\n\n        # Validations\n        assert 'year' in result, \"Missing 'year' in result\"\n        assert 'year_info' in result, \"Missing 'year_info'\"\n        assert 'data' in result, \"Missing 'data'\"\n        assert result['year'] >= 2024, f\"Year too old: {result['year']}\"\n\n        print(f\"  ✓ Auto-year working: {result['year']}\")\n        print(f\"  ✓ Year info: {result['year_info']}\")\n        print(f\"  ✓ Data present: {len(result.get('data', {}))} fields\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        import traceback\n        traceback.print_exc()\n        return False\n\n\ndef test_{function1}_specific_year():\n    \"\"\"Test {function1} with specific year.\"\"\"\n    print(f\"\\n✓ Testing {function1}(year=2024)...\")\n\n    try:\n        result = {function1}('{example_entity}', year=2024)\n\n        assert result['year'] == 2024, \"Requested year not used\"\n        assert result['year_requested'] == 2024, \"year_requested not tracked\"\n\n        print(f\"  ✓ Specific year working: {result['year']}\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\ndef test_{function2}_comparison():\n    \"\"\"Test {function2} (comparison function).\"\"\"\n    print(f\"\\n✓ Testing {function2}()...\")\n\n    try:\n        result = {function2}('{example_entity}', year1=2024, year2=2023)\n\n        # Validations specific to comparison\n        assert 'change_percent' in result, \"Missing 'change_percent'\"\n        assert isinstance(result['change_percent'], (int, float)), \"change_percent not numeric\"\n\n        print(f\"  ✓ Comparison working: {result.get('change_percent')}% change\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\ndef test_comprehensive_report():\n    \"\"\"Test comprehensive report (all-in-one function).\"\"\"\n    print(f\"\\n✓ Testing comprehensive_{domain}_report()...\")\n\n    try:\n        result = comprehensive_{domain}_report('{example_entity}')\n\n        # Validations\n        assert 'metrics' in result, \"Missing 'metrics'\"\n        assert 'summary' in result, \"Missing 'summary'\"\n        assert 'alerts' in result, \"Missing 'alerts'\"\n        assert isinstance(result['metrics'], dict), \"'metrics' must be dict\"\n\n        metrics_count = len(result['metrics'])\n        print(f\"  ✓ Comprehensive report working\")\n        print(f\"  ✓ Metrics combined: {metrics_count}\")\n        print(f\"  ✓ Summary: {result['summary'][:100]}...\")\n        print(f\"  ✓ Alerts: {len(result['alerts'])}\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\ndef test_validation_integration():\n    \"\"\"Test that validation is integrated in functions.\"\"\"\n    print(f\"\\n✓ Testing validation integration...\")\n\n    try:\n        result = {function1}('{example_entity}')\n\n        # Check validation info is present\n        assert 'validation' in result, \"Missing 'validation' info\"\n        assert 'passed' in result['validation'], \"Missing validation.passed\"\n        assert 'report' in result['validation'], \"Missing validation.report\"\n\n        print(f\"  ✓ Validation present: {result['validation']['report']}\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\ndef main():\n    \"\"\"Run all integration tests.\"\"\"\n    print(\"=\" * 70)\n    print(\"INTEGRATION TESTS - {skill-name}\")\n    print(\"=\" * 70)\n\n    tests = [\n        (\"Auto-year detection\", test_{function1}_basic),\n        (\"Specific year\", test_{function1}_specific_year),\n        (\"Comparison function\", test_{function2}_comparison),\n        (\"Comprehensive report\", test_comprehensive_report),\n        (\"Validation integration\", test_validation_integration),\n    ]\n\n    results = []\n    for test_name, test_func in tests:\n        passed = test_func()\n        results.append((test_name, passed))\n\n    # Summary\n    print(\"\\n\" + \"=\" * 70)\n    print(\"SUMMARY\")\n    print(\"=\" * 70)\n\n    for test_name, passed in results:\n        status = \"✅ PASS\" if passed else \"❌ FAIL\"\n        print(f\"{status}: {test_name}\")\n\n    passed_count = sum(1 for _, p in results if p)\n    total_count = len(results)\n\n    print(f\"\\nResults: {passed_count}\u002F{total_count} passed\")\n\n    return passed_count == total_count\n\n\nif __name__ == \"__main__\":\n    success = main()\n    sys.exit(0 if success else 1)\n```\n\n### Template 2: test_parse.py\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"Tests for parsers.\"\"\"\n\nimport sys\nfrom pathlib import Path\nimport pandas as pd\n\nsys.path.insert(0, str(Path(__file__).parent.parent \u002F 'scripts'))\n\nfrom parse_{type1} import parse_{type1}_response\nfrom parse_{type2} import parse_{type2}_response\n# Import all parsers...\n\n\ndef test_parse_{type1}():\n    \"\"\"Test {type1} parser.\"\"\"\n    print(\"\\n✓ Testing parse_{type1}_response()...\")\n\n    sample_data = [\n        {'{field1}': 'VALUE1', '{field2}': 2025, '{field3}': '1,234,567'}\n    ]\n\n    try:\n        df = parse_{type1}_response(sample_data)\n\n        # Validations\n        assert isinstance(df, pd.DataFrame), \"Must return DataFrame\"\n        assert len(df) == 1, f\"Expected 1 row, got {len(df)}\"\n        assert 'entity' in df.columns, \"Missing 'entity' column\"\n        assert 'year' in df.columns, \"Missing 'year' column\"\n\n        print(f\"  ✓ Parsed: {len(df)} records\")\n        print(f\"  ✓ Columns: {list(df.columns)}\")\n\n        return True\n\n    except Exception as e:\n        print(f\"  ✗ FAILED: {e}\")\n        return False\n\n\n# Repeat for all parsers...\n\ndef main():\n    \"\"\"Run parser tests.\"\"\"\n    tests = [\n        test_parse_{type1},\n        test_parse_{type2},\n        # Add all...\n    ]\n\n    passed = sum(1 for test in tests if test())\n    print(f\"\\nResults: {passed}\u002F{len(tests)} passed\")\n\n    return passed == len(tests)\n\n\nif __name__ == \"__main__\":\n    sys.exit(0 if main() else 1)\n```\n\n### Template 3: test_helpers.py\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"Tests for temporal helpers.\"\"\"\n\nimport sys\nfrom pathlib import Path\nfrom datetime import datetime\n\nsys.path.insert(0, str(Path(__file__).parent.parent \u002F 'scripts'))\n\nfrom utils.helpers import (\n    get_current_{domain}_year,\n    get_{domain}_year_with_fallback,\n    should_try_previous_year,\n    format_year_message\n)\n\n\ndef test_get_current_year():\n    \"\"\"Test current year detection.\"\"\"\n    year = get_current_{domain}_year()\n    current = datetime.now().year\n\n    assert year == current, f\"Expected {current}, got {year}\"\n    print(f\"✓ Current year: {year}\")\n    return True\n\n\ndef test_year_with_fallback():\n    \"\"\"Test year fallback logic.\"\"\"\n    primary, fallback = get_{domain}_year_with_fallback(2024)\n\n    assert primary == 2024, \"Primary should be 2024\"\n    assert fallback == 2023, \"Fallback should be 2023\"\n\n    print(f\"✓ Fallback: {primary} → {fallback}\")\n    return True\n\n\ndef test_format_year_message():\n    \"\"\"Test year message formatting.\"\"\"\n    msg = format_year_message(2024, 2025)\n\n    assert '2024' in msg, \"Must mention year used\"\n    assert '2025' in msg, \"Must mention year requested\"\n\n    print(f\"✓ Message: {msg}\")\n    return True\n\n\ndef main():\n    \"\"\"Run helper tests.\"\"\"\n    tests = [\n        test_get_current_year,\n        test_year_with_fallback,\n        test_format_year_message\n    ]\n\n    passed = sum(1 for test in tests if test())\n    print(f\"\\nResults: {passed}\u002F{len(tests)} passed\")\n\n    return passed == len(tests)\n\n\nif __name__ == \"__main__\":\n    sys.exit(0 if main() else 1)\n```\n\n### Minimum Test Coverage\n\n**For skill to be considered complete, needs:**\n\n- [ ] test_integration.py with ≥5 end-to-end tests\n- [ ] test_parse.py with 1 test per parser\n- [ ] test_analyze.py with 1 test per analysis function\n- [ ] test_helpers.py with ≥3 tests\n- [ ] test_validation.py with ≥5 tests\n- [ ] **Total:** ≥25 tests\n- [ ] **Coverage:** ≥80% of code\n- [ ] **All tests PASS**\n\n### How to test\n\nInclude in README.md:\n\n```markdown\n## Testing\n\n### Run All Tests\n\n```bash\ncd {skill-name}\npython3 tests\u002Ftest_integration.py\n```\n\n### Run Specific Tests\n\n```bash\npython3 tests\u002Ftest_parse.py\npython3 tests\u002Ftest_helpers.py\npython3 tests\u002Ftest_validation.py\n```\n\n### Expected Output\n\n```\n======================================================================\nINTEGRATION TESTS - {skill-name}\n======================================================================\n\n✓ Testing {function1}()...\n  ✓ Auto-year working: 2025\n  ✓ Data present: 8 fields\n\n✓ Testing {function2}()...\n  ✓ Comparison working: +12.3% change\n\n...\n\n======================================================================\nSUMMARY\n======================================================================\n✅ PASS: Auto-year detection\n✅ PASS: Specific year\n✅ PASS: Comparison function\n✅ PASS: Comprehensive report\n✅ PASS: Validation integration\n\nResults: 5\u002F5 passed\n```\n```\n\n### Test Suite Benefits\n\n- ✅ Reliability: Tested and working code\n- ✅ Regression testing: Detects breaks when modifying\n- ✅ Executable documentation: Tests show how to use\n- ✅ CI\u002FCD ready: Can run automatically\n- ✅ Professionalism: Production-quality skills\n\n**Impact:** Generated skills are tested and reliable from v1.0!\n\n---\n\n## Agent Creation Workflow: Checklist\n\nWhen creating an agent, follow this checklist RIGOROUSLY in order:\n\n---\n\n### 🚨 STEP 0: MANDATORY - FIRST STEP\n\n**Execute BEFORE anything else:**\n\n- [ ] 🚨 Create `.claude-plugin\u002Fmarketplace.json`\n- [ ] 🚨 Validate JSON syntax with python\n- [ ] 🚨 Verify mandatory fields filled\n- [ ] 🚨 Confirm: \"Marketplace.json created and validated - can proceed\"\n\n**🛑 DO NOT PROCEED without completing ALL items above!**\n\n---\n\n### ✅ Phase 1-4: Planning\n\n- [ ] Domain identified\n- [ ] API researched and decided (with justification)\n- [ ] **API completeness analysis** (Phase 1.6 - coverage ≥50%)\n- [ ] Analyses defined (4-6 main + comprehensive_report)\n- [ ] Structure planned (modular parsers, validators\u002F)\n- [ ] Keywords determined (≥60 unique)\n\n---\n\n### ✅ Phase 5: Implementation\n\n- [ ] .claude-plugin\u002Fmarketplace.json created FIRST\n- [ ] marketplace.json validated (syntax + fields)\n- [ ] SKILL.md created with correct frontmatter\n- [ ] **CRITICAL:** SKILL.md description copied to marketplace.json → plugins[0].description (IDENTICAL!)\n- [ ] Validate synchronization: SKILL.md description === marketplace.json\n- [ ] **MANDATORY:** utils\u002Fhelpers.py created (temporal context)\n- [ ] **MANDATORY:** utils\u002Fvalidators\u002F created (4 validators)\n- [ ] **MANDATORY:** Modular parsers (1 per data type)\n- [ ] **MANDATORY:** comprehensive_{domain}_report() implemented\n- [ ] DECISIONS.md documenting choices\n- [ ] VERSION file created (e.g., 1.0.0)\n- [ ] CHANGELOG.md created with complete v1.0.0 entry\n- [ ] marketplace.json with version field\n- [ ] Implement functional code (no TODOs)\n- [ ] Write complete docstrings\n- [ ] Add error handling\n- [ ] Write references with useful content\n- [ ] Create real configs\n- [ ] Write complete README\n- [ ] INSTALLATION.md with complete tutorial\n\n---\n\n### ✅ Phase 6: Test Suite\n\n- [ ] tests\u002F directory created\n- [ ] test_integration.py with ≥5 end-to-end tests\n- [ ] test_parse.py with 1 test per parser\n- [ ] test_analyze.py with 1 test per analysis function\n- [ ] test_helpers.py with ≥3 tests\n- [ ] test_validation.py with ≥5 tests\n- [ ] **Total:** ≥25 tests implemented\n- [ ] **ALL tests PASS** (execute and validate!)\n- [ ] \"Testing\" section added to README.md\n\n---\n\n### ✅ Final Validation\n\n- [ ] Validate marketplace.json again (syntax + synchronized description)\n- [ ] Validate other JSONs (configs, assets)\n- [ ] Verify imports work\n- [ ] Check no placeholder\u002FTODO\n- [ ] Test main logic manually\n- [ ] Verify README has all instructions\n- [ ] Calculate estimated ROI (time before vs after)\n\n---\n\n### 🚀 MANDATORY TEST - DO NOT SKIP THIS STEP!\n\n**Execute this command MANDATORY before delivering:**\n\n```bash\ncd \u002Fpath\u002Fto\u002Fskills\n\u002Fplugin marketplace add .\u002Fagent-name\n```\n\n**Verifications:**\n\n- [ ] ✅ Command executed without errors\n- [ ] ✅ Skill appears in installed plugins list\n- [ ] ✅ Claude recognizes the skill (do test question)\n\n**🛑 If test fails:**\n\n1. Verify marketplace.json exists\n2. Verify JSON is valid\n3. Verify description is synchronized\n4. Fix and test again\n\n**Only deliver to user AFTER installation test passes!**\n\n---\n\n### ✅ Deliver to User\n\n- [ ] Show created structure\n- [ ] Summarize main decisions\n- [ ] List files and sizes\n- [ ] Give installation instructions (command tested above)\n- [ ] Give 3-5 usage examples\n- [ ] Inform estimated ROI\n- [ ] **Confirm: \"Skill tested and installed successfully\"**\n\n## User Communication\n\n### During Creation\n\n**Show high-level progress**:\n\n```\n🔍 Phase 1: Researching APIs...\n   ✓ 5 options found\n   ✓ Decided: NASS API (free, complete data)\n\n🎨 Phase 2: Defining analyses...\n   ✓ 15 typical questions identified\n   ✓ 5 main analyses defined\n\n🏗️ Phase 3: Structuring project...\n   ✓ 3 scripts + 2 utils planned\n\n🎯 Phase 4: Defining detection...\n   ✓ 50+ keywords identified\n\n⚙️ Phase 5: Implementing code...\n   [Progress while creating files]\n   ✓ SKILL.md (6,200 words)\n   ✓ fetch_nass.py (280 lines)\n   ✓ parse_nass.py (180 lines)\n   [...]\n```\n\n**Don't show**: Technical details during creation (code blocks, etc). Just progress.\n\n### After Completion\n\n**Executive summary**:\n\n```\n✅ AGENT CREATED SUCCESSFULLY!\n\n📂 Location: .\u002Fusda-agriculture-agent\u002F\n\n📊 Main Decisions:\n- API: USDA NASS QuickStats\n- Analyses: YoY, Ranking, Trends, Reports\n- Implementation: 1,410 lines Python + 4,500 words docs\n\n💰 Estimated ROI:\n- Time before: 2h\u002Fday\n- Time after: 3min\u002Fday\n- Savings: 117h\u002Fmonth\n\n🎓 See DECISIONS.md for complete justifications.\n\n🚀 NEXT STEPS:\n\n1. Get API key (free):\n   https:\u002F\u002Fquickstats.nass.usda.gov\u002Fapi#registration\n\n2. Configure:\n   export NASS_API_KEY=\"your_key\"\n\n3. Install:\n   \u002Fplugin marketplace add .\u002Fusda-agriculture-agent\n\n4. Test:\n   \"US corn production in 2023\"\n   \"Compare soybeans this year vs last year\"\n\nSee README.md for complete instructions.\n```\n\n## Keywords for This Meta-Skill Detection\n\nThis meta-skill (agent-creator) is activated when user mentions:\n\n**Create\u002FDevelop**:\n\n- \"Create an agent\"\n- \"Develop agent\"\n- \"Create skill\"\n- \"Develop skill\"\n- \"Build agent\"\n\n**Automate**:\n\n- \"Automate this workflow\"\n- \"Automate this process\"\n- \"Automate this task\"\n- \"Need to automate\"\n- \"Turn into agent\"\n\n**Repetitive Workflow**:\n\n- \"Every day I do\"\n- \"Repeatedly need to\"\n- \"Manual process\"\n- \"Workflow that takes Xh\"\n- \"Task I repeat\"\n\n**Agent for Domain**:\n\n- \"Agent for [domain]\"\n- \"Custom skill for [domain]\"\n- \"Specialize Claude in [domain]\"\n\n## ⚠️ Troubleshooting: Common Marketplace.json Errors\n\n### Error: \"Failed to install plugin\"\n\n**Most common cause:** marketplace.json doesn't exist or is poorly formatted\n\n**Diagnosis:**\n\n```bash\n# 1. Verify file exists\nls -la agent-name\u002F.claude-plugin\u002Fmarketplace.json\n\n# 2. Validate JSON\npython3 -c \"import json; json.load(open('agent-name\u002F.claude-plugin\u002Fmarketplace.json'))\"\n\n# 3. View content\ncat agent-name\u002F.claude-plugin\u002Fmarketplace.json\n```\n\n**Solutions:**\n\n1. If file doesn't exist: Go back to STEP 0 and create\n2. If invalid JSON: Fix syntax errors\n3. If missing fields: Compare with STEP 0 template\n\n### Error: \"Skill not activating\"\n\n**Cause:** marketplace.json description ≠ SKILL.md description\n\n**Diagnosis:**\n\n```bash\n# Compare descriptions\ngrep \"description:\" agent-name\u002FSKILL.md\ngrep \"\\\"description\\\":\" agent-name\u002F.claude-plugin\u002Fmarketplace.json\n```\n\n**Solution:**\n\n1. Copy EXACT description from SKILL.md frontmatter\n2. Paste in marketplace.json → plugins[0].description\n3. Ensure they are IDENTICAL (word for word)\n4. Save and test installation again\n\n### Error: \"Invalid plugin structure\"\n\n**Cause:** Mandatory marketplace.json fields incorrect\n\n**Verify:**\n\n- ✅ `plugins[0].skills` = `[\".\u002F\"]` (not `[\"SKILL.md\"]` or other value)\n- ✅ `plugins[0].source` = `\".\u002F\"` (not empty or other value)\n- ✅ `name` in JSON root matches directory name\n\n**Solution:**\nEdit marketplace.json and fix fields above according to STEP 0 template.\n\n## 🧠 Final Step: Store Episode for Learning\n\n**⚠️ CRITICAL**: After successful agent creation, store the episode in AgentDB for future learning.\n\n### Automatic Episode Storage\n\n```python\n# Store this successful creation for future learning\nfrom integrations.agentdb_bridge import get_agentdb_bridge\nfrom integrations.agentdb_real_integration import Episode\n\ntry:\n    bridge = get_real_agentdb_bridge()\n\n    # Create episode from this creation\n    episode = Episode(\n        session_id=f\"agent-creation-{datetime.now().strftime('%Y%m%d-%H%M%S')}\",\n        task=user_input,  # Original user request\n        input=f\"Domain: {domain}, API: {selected_api}, Structure: {architecture}\",\n        output=f\"Created: {agent_name}\u002F with {len(scripts)} scripts\",\n        critique=f\"Success: {'✅ High quality' if all_tests_passed else '⚠️ Needs refinement'}\",\n        reward=0.9 if all_tests_passed else 0.7,\n        success=all_tests_passed,\n        latency_ms=creation_time_seconds * 1000,\n        tokens_used=estimated_tokens,\n        tags=[domain, selected_api, architecture_type],\n        metadata={\n            \"agent_name\": agent_name,\n            \"domain\": domain,\n            \"api\": selected_api,\n            \"complexity\": complexity,\n            \"files_created\": len(all_files),\n            \"validation_passed\": all_tests_passed\n        }\n    )\n\n    # Store episode for learning\n    episode_id = bridge.store_episode(episode)\n    print(f\"🧠 Episode stored for learning: #{episode_id}\")\n\n    # If successful, create skill\n    if all_tests_passed and bridge.is_available:\n        skill_name = f\"{domain}_agent_template\"\n        skill = Skill(\n            name=skill_name,\n            description=f\"Proven template for {domain} agents\",\n            code=f\"API: {selected_api}, Structure: {architecture}\",\n            success_rate=1.0,\n            uses=1,\n            avg_reward=0.9,\n            metadata={\"domain\": domain, \"api\": selected_api}\n        )\n\n        skill_id = bridge.create_skill(skill)\n        print(f\"🎯 Skill created: #{skill_id}\")\n\nexcept Exception as e:\n    # AgentDB failure should not break agent creation\n    print(\"🔄 AgentDB learning unavailable - agent creation completed successfully\")\n    pass\n```\n\n### Learning Progress Indicators\n\n**Provide subtle feedback to user about learning progress:**\n\n```python\n# Check learning milestones\nif episode_id:\n    from integrations.learning_feedback import analyze_agent_execution\n\n    feedback = analyze_agent_execution(\n        agent_name=agent_name,\n        user_input=user_input,\n        execution_time=creation_time_seconds,\n        success=all_tests_passed,\n        result_quality=0.9 if all_tests_passed else 0.7\n    )\n\n    if feedback:\n        print(feedback)  # Subtle milestone feedback\n```\n\n**Example user feedback:**\n- First creation: \"🎉 First agent created successfully!\"\n- After 10 creations: \"⚡ Agent creation optimized based on 10 successful patterns\"\n- After 30 days: \"🌟 I've learned your preferences - shall I optimize this agent?\"\n\n### Invisible Learning Complete\n\n**What happens behind the scenes:**\n- ✅ Episode stored with full creation context\n- ✅ Success patterns learned for future use\n- ✅ Skills consolidated from successful templates\n- ✅ Causal relationships established (API → success rate)\n- ✅ User sees only: \"Agent created successfully!\"\n\n**Next user gets benefits:**\n- Faster creation (learned optimal patterns)\n- Better API selection (historical success rates)\n- Proven architectures (domain-specific success)\n- Personalized suggestions (learned preferences)\n\n---\n\n## Limitations and Warnings\n\n### When NOT to use\n\n❌ Don't use this skill for:\n\n- Editing existing skills (use directly)\n- Debugging skills (use directly)\n- Questions about skills (answer directly)\n\n### Warnings\n\n⚠️ **Creation time**:\n\n- Simple agents: ~30-60 min\n- Complex agents: ~60-120 min\n- It's normal to take time (creating everything from scratch)\n\n⚠️ **Review needed**:\n\n- Created agent is functional but may need adjustments\n- Test examples in README\n- Iterate if necessary\n\n⚠️ **API keys**:\n\n- User needs to obtain API key\n- Instructions in created agent's README\n",{"name":5,"description":7},"main","7850740bd837adb32f0a109ab2af82482196c6f2","skills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator",1,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills","https:\u002F\u002Fzturnsgo.com","https:\u002F\u002Fgithub.com\u002Fshengdabai","https:\u002F\u002Fzturnsgo.com\u002F","AI × education creator — producer, not consumer. Taught 6,000+ learners; shipping learning tools & daily essays with Claude Code, practicing @xiaolai's way 🥋","2026-11-01 21:28:23",{"source":8,"skillName":5,"commands":55,"prompt":65,"zipAvailable":66},[56,59,62],{"tool":57,"command":58},"npx","npx skills add shengdabai\u002FTony-Claude-Code-Skills --skill agent-skill-creator",{"tool":60,"command":61},"bunx","bunx skills add shengdabai\u002FTony-Claude-Code-Skills --skill agent-skill-creator",{"tool":63,"command":64},"pnpm","pnpm dlx skills add shengdabai\u002FTony-Claude-Code-Skills --skill agent-skill-creator","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002FSKILL.md",true,[68,74,80,84,88,92,96,100,104,108,112,116,120,124,128,132,136,140,146,150,154,158,162,166,170,174,178,182,186,190,194,200,203,207,211,215,219,223,227,231,235,239,243,247,251,255,259,263,267],{"path":69,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":72,"sourceHtmlUrl":73},".claude-plugin\u002Fmarketplace.json","REFERENCE","参考文档",5098,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002F.claude-plugin\u002Fmarketplace.json",{"path":75,"resourceType":76,"resourceTypeDesc":77,"sizeBytes":78,"sourceHtmlUrl":79},".gitignore","OTHER","其他",336,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002F.gitignore",{"path":81,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":82,"sourceHtmlUrl":83},"docs\u002FAGENTDB_LEARNING_FLOW_EXPLAINED.md",10365,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FAGENTDB_LEARNING_FLOW_EXPLAINED.md",{"path":85,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":86,"sourceHtmlUrl":87},"docs\u002FAGENTDB_VISUAL_GUIDE.md",16022,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FAGENTDB_VISUAL_GUIDE.md",{"path":89,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":90,"sourceHtmlUrl":91},"docs\u002FCHANGELOG.md",26207,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FCHANGELOG.md",{"path":93,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":94,"sourceHtmlUrl":95},"docs\u002FCLAUDE_SKILLS_ARCHITECTURE.md",8301,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FCLAUDE_SKILLS_ARCHITECTURE.md",{"path":97,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":98,"sourceHtmlUrl":99},"docs\u002FDECISION_LOGIC.md",9907,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FDECISION_LOGIC.md",{"path":101,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":102,"sourceHtmlUrl":103},"docs\u002FINTERNAL_FLOW_ANALYSIS.md",16536,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FINTERNAL_FLOW_ANALYSIS.md",{"path":105,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":106,"sourceHtmlUrl":107},"docs\u002FLEARNING_VERIFICATION_REPORT.md",15473,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FLEARNING_VERIFICATION_REPORT.md",{"path":109,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":110,"sourceHtmlUrl":111},"docs\u002FNAMING_CONVENTIONS.md",9951,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FNAMING_CONVENTIONS.md",{"path":113,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":114,"sourceHtmlUrl":115},"docs\u002FPIPELINE_ARCHITECTURE.md",19810,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FPIPELINE_ARCHITECTURE.md",{"path":117,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":118,"sourceHtmlUrl":119},"docs\u002FQUICK_VERIFICATION_GUIDE.md",5289,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FQUICK_VERIFICATION_GUIDE.md",{"path":121,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":122,"sourceHtmlUrl":123},"docs\u002FREADME.md",5652,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FREADME.md",{"path":125,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":126,"sourceHtmlUrl":127},"docs\u002FTRY_IT_YOURSELF.md",6347,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FTRY_IT_YOURSELF.md",{"path":129,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":130,"sourceHtmlUrl":131},"docs\u002FUSER_BENEFITS_GUIDE.md",11707,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fdocs\u002FUSER_BENEFITS_GUIDE.md",{"path":133,"resourceType":76,"resourceTypeDesc":77,"sizeBytes":134,"sourceHtmlUrl":135},"exports\u002F.gitignore",124,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fexports\u002F.gitignore",{"path":137,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":138,"sourceHtmlUrl":139},"exports\u002FREADME.md",4161,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fexports\u002FREADME.md",{"path":141,"resourceType":142,"resourceTypeDesc":143,"sizeBytes":144,"sourceHtmlUrl":145},"integrations\u002Fagentdb_bridge.py","SCRIPT","脚本",27501,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fintegrations\u002Fagentdb_bridge.py",{"path":147,"resourceType":142,"resourceTypeDesc":143,"sizeBytes":148,"sourceHtmlUrl":149},"integrations\u002Fagentdb_real_integration.py",24775,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fintegrations\u002Fagentdb_real_integration.py",{"path":151,"resourceType":142,"resourceTypeDesc":143,"sizeBytes":152,"sourceHtmlUrl":153},"integrations\u002Ffallback_system.py",20516,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fintegrations\u002Ffallback_system.py",{"path":155,"resourceType":142,"resourceTypeDesc":143,"sizeBytes":156,"sourceHtmlUrl":157},"integrations\u002Flearning_feedback.py",15708,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fintegrations\u002Flearning_feedback.py",{"path":159,"resourceType":142,"resourceTypeDesc":143,"sizeBytes":160,"sourceHtmlUrl":161},"integrations\u002Fvalidation_system.py",17375,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fintegrations\u002Fvalidation_system.py",{"path":163,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":164,"sourceHtmlUrl":165},"README.md",73780,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002FREADME.md",{"path":167,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":168,"sourceHtmlUrl":169},"references\u002FACTIVATION_BEST_PRACTICES.md",16705,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002FACTIVATION_BEST_PRACTICES.md",{"path":171,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":172,"sourceHtmlUrl":173},"references\u002Factivation-patterns-guide.md",17933,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Factivation-patterns-guide.md",{"path":175,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":176,"sourceHtmlUrl":177},"references\u002Factivation-quality-checklist.md",9773,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Factivation-quality-checklist.md",{"path":179,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":180,"sourceHtmlUrl":181},"references\u002Factivation-testing-guide.md",13829,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Factivation-testing-guide.md",{"path":183,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":184,"sourceHtmlUrl":185},"references\u002Fclaude-llm-protocols-guide.md",31374,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fclaude-llm-protocols-guide.md",{"path":187,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":188,"sourceHtmlUrl":189},"references\u002Fcontext-aware-activation.md",21484,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fcontext-aware-activation.md",{"path":191,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":192,"sourceHtmlUrl":193},"references\u002Fcross-platform-guide.md",10986,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fcross-platform-guide.md",{"path":195,"resourceType":196,"resourceTypeDesc":197,"sizeBytes":198,"sourceHtmlUrl":199},"references\u002Fexamples\u002Fexports\u002Fstock-analyzer-cskill-api-v1.0.0.zip","ASSET","资产文件",13890,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fexamples\u002Fexports\u002Fstock-analyzer-cskill-api-v1.0.0.zip",{"path":201,"resourceType":196,"resourceTypeDesc":197,"sizeBytes":198,"sourceHtmlUrl":202},"references\u002Fexamples\u002Fexports\u002Fstock-analyzer-cskill-desktop-v1.0.0.zip","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fexamples\u002Fexports\u002Fstock-analyzer-cskill-desktop-v1.0.0.zip",{"path":204,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":205,"sourceHtmlUrl":206},"references\u002Fexamples\u002Fexports\u002Fstock-analyzer-cskill-v1.0.0_INSTALL.md",5689,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fexamples\u002Fexports\u002Fstock-analyzer-cskill-v1.0.0_INSTALL.md",{"path":208,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":209,"sourceHtmlUrl":210},"references\u002Fexport-guide.md",13093,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fexport-guide.md",{"path":212,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":213,"sourceHtmlUrl":214},"references\u002Fmulti-intent-detection.md",28046,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fmulti-intent-detection.md",{"path":216,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":217,"sourceHtmlUrl":218},"references\u002Fphase1-discovery.md",11715,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fphase1-discovery.md",{"path":220,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":221,"sourceHtmlUrl":222},"references\u002Fphase2-design.md",6006,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fphase2-design.md",{"path":224,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":225,"sourceHtmlUrl":226},"references\u002Fphase3-architecture.md",7923,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fphase3-architecture.md",{"path":228,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":229,"sourceHtmlUrl":230},"references\u002Fphase4-detection.md",35897,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fphase4-detection.md",{"path":232,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":233,"sourceHtmlUrl":234},"references\u002Fphase5-implementation.md",24657,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fphase5-implementation.md",{"path":236,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":237,"sourceHtmlUrl":238},"references\u002Fphase6-testing.md",18620,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fphase6-testing.md",{"path":240,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":241,"sourceHtmlUrl":242},"references\u002Fquality-standards.md",19986,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fquality-standards.md",{"path":244,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":245,"sourceHtmlUrl":246},"references\u002Fsynonym-expansion-system.md",12972,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Fsynonym-expansion-system.md",{"path":248,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":249,"sourceHtmlUrl":250},"references\u002Ftemplates\u002Fmarketplace-robust-template.json",8385,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Ftemplates\u002Fmarketplace-robust-template.json",{"path":252,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":253,"sourceHtmlUrl":254},"references\u002Ftemplates\u002FREADME-activation-template.md",6090,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Ftemplates\u002FREADME-activation-template.md",{"path":256,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":257,"sourceHtmlUrl":258},"references\u002Ftools\u002Factivation-tester.md",15734,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Ftools\u002Factivation-tester.md",{"path":260,"resourceType":70,"resourceTypeDesc":71,"sizeBytes":261,"sourceHtmlUrl":262},"references\u002Ftools\u002Fintent-analyzer.md",23841,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Ftools\u002Fintent-analyzer.md",{"path":264,"resourceType":142,"resourceTypeDesc":143,"sizeBytes":265,"sourceHtmlUrl":266},"references\u002Ftools\u002Ftest-automation-scripts.sh",25364,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Freferences\u002Ftools\u002Ftest-automation-scripts.sh",{"path":268,"resourceType":142,"resourceTypeDesc":143,"sizeBytes":269,"sourceHtmlUrl":270},"scripts\u002Fexport_utils.py",23041,"https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002F_collections\u002FFrancyJGLisboa-agent-skill-creator\u002Fscripts\u002Fexport_utils.py",[272,281,289,297,305,313],{"skillNo":273,"name":274,"nameZh":6,"description":275,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":276,"sourceHtmlUrl":277,"categories":278,"keywords":279,"publishedAt":280},"01M73H7XKBHE1ETQDZT94MF9HH","seedance-prompt-en","Write effective prompts for Jimeng Seedance 2.0 multimodal AI video generation. Use when users want to create video prompts using text, images, videos, and audio inputs with the @ reference system. Covers camera movements, effects replication, video extension, editing, music beat-matching, e-commerce ads, short dramas, and educational content.","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fseedance-prompt-en\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fseedance-prompt-en\u002FSKILL.md",[],[],"2026-11-11 15:11:14",{"skillNo":282,"name":283,"nameZh":6,"description":284,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":285,"sourceHtmlUrl":286,"categories":287,"keywords":288,"publishedAt":280},"01M73GRE9998Q1DZWC71N41JWG","onepage-pdf","Convert an HTML page into a single continuous-page PDF (one tall page, no pagination breaks), preserving desktop layout, backgrounds and selectable text. Use when the user asks to turn an HTML file\u002Freport\u002Fproposal into a \"single-page PDF\", \"long PDF\", \"不分页 PDF\", \"单页 PDF\", \"长图式 PDF\", or complains that an HTML-to-PDF export breaks into pages or cuts content. Supports optional string redaction with leak verification.","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fonepage-pdf\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fonepage-pdf\u002FSKILL.md",[],[],{"skillNo":290,"name":291,"nameZh":6,"description":292,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":293,"sourceHtmlUrl":294,"categories":295,"keywords":296,"publishedAt":280},"01M73GQG1KZDADVPV3MHAT1J5A","native-feel-cross-platform-desktop","Use when the user is designing, prototyping, or rewriting a desktop app that must run on multiple OSes (macOS + Windows, optionally Linux) AND feel indistinguishable from a native app to its users — fast launch, native windowing, native input handling, native materials. Trigger words include \"cross-platform desktop\", \"Electron alternative\", \"Tauri vs native\", \"WebView wrapper\", \"near-native performance\", \"Raycast architecture\", \"WebKit\u002FWebView2 quirks\", \"WKWebView\", \"system tray app\", \"global hotkey app\", \"launcher app\". Do NOT trigger this skill for pure web apps, pure mobile apps, or for greenfield projects that have no native-feel requirement.","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fnative-feel-cross-platform-desktop\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fnative-feel-cross-platform-desktop\u002FSKILL.md",[],[],{"skillNo":298,"name":299,"nameZh":6,"description":300,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":301,"sourceHtmlUrl":302,"categories":303,"keywords":304,"publishedAt":280},"01M73G87PDNSMKG2FHWCYER6N8","gstack","Router for the gstack skill suite. (gstack)","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fgstack\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fgstack\u002FSKILL.md",[],[],{"skillNo":306,"name":307,"nameZh":6,"description":308,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":309,"sourceHtmlUrl":310,"categories":311,"keywords":312,"publishedAt":280},"01M73G3EAQWKCM8DB8D0N0QSVG","fireworks-tech-graph","Use when the user wants to create any technical diagram - architecture, data flow, flowchart, sequence, agent\u002Fmemory, or concept map - and export as SVG+PNG. Trigger on: \"画图\" \"帮我画\" \"生成图\" \"做个图\" \"架构图\" \"流程图\" \"可视化一下\" \"出图\" \"generate diagram\" \"draw diagram\" \"visualize\" or any system\u002Fflow description the user wants illustrated.","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Ffireworks-tech-graph\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Ffireworks-tech-graph\u002FSKILL.md",[],[],{"skillNo":314,"name":315,"nameZh":6,"description":316,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":317,"categories":318,"keywords":319,"publishedAt":280},"01M73G086AXAH9DW1H5G5N3CPB","dbs-video-extract","接收抖音、小红书、微信视频号等短视频链接或分享文案，查询作品／账号数据并提取语音文字稿，按作者和标题归档为 Markdown。用户希望完整解析短视频、取得数据或文字稿时使用；运行前检查 TikHub 与轻抖使用凭证，缺少时用新手能理解的方式引导购买和安全配置。","https:\u002F\u002Fgithub.com\u002Fshengdabai\u002FTony-Claude-Code-Skills\u002Fblob\u002Fmain\u002Fskills\u002Fdbs-video-extract\u002FSKILL.md",[],[]]