$npx -y skills add DNYoussef/context-cascade --skill prompt-forge/*============================================================================*/ /* PROMPT-FORGE SKILL :: VERILINGUA x VERIX EDITION */ /*============================================================================*/
| 1 | /*============================================================================*/ |
| 2 | /* PROMPT-FORGE SKILL :: VERILINGUA x VERIX EDITION */ |
| 3 | /*============================================================================*/ |
| 4 | |
| 5 | --- |
| 6 | name: prompt-forge |
| 7 | version: 2.0.1 |
| 8 | description: | |
| 9 | [assert|neutral] Meta-prompt that generates improved prompts and templates. Can improve other prompts including Skill Forge and even itself. All improvements are gated by frozen eval harness. Use when optimizing promp [ground:given] [conf:0.95] [state:confirmed] |
| 10 | category: foundry |
| 11 | tags: |
| 12 | - meta-prompt |
| 13 | - self-improvement |
| 14 | - recursive |
| 15 | - dogfooding |
| 16 | - cognitive-frames |
| 17 | author: system |
| 18 | cognitive_frame: |
| 19 | primary: compositional |
| 20 | goal_analysis: |
| 21 | first_order: "Execute prompt-forge workflow" |
| 22 | second_order: "Ensure quality and consistency" |
| 23 | third_order: "Enable systematic foundry processes" |
| 24 | --- |
| 25 | |
| 26 | /*----------------------------------------------------------------------------*/ |
| 27 | /* S0 META-IDENTITY */ |
| 28 | /*----------------------------------------------------------------------------*/ |
| 29 | |
| 30 | [define|neutral] SKILL := { |
| 31 | name: "prompt-forge", |
| 32 | category: "foundry", |
| 33 | version: "2.0.1", |
| 34 | layer: L1 |
| 35 | } [ground:given] [conf:1.0] [state:confirmed] |
| 36 | |
| 37 | /*----------------------------------------------------------------------------*/ |
| 38 | /* S1 COGNITIVE FRAME */ |
| 39 | /*----------------------------------------------------------------------------*/ |
| 40 | |
| 41 | [define|neutral] COGNITIVE_FRAME := { |
| 42 | frame: "Compositional", |
| 43 | source: "German", |
| 44 | force: "Build from primitives?" |
| 45 | } [ground:cognitive-science] [conf:0.92] [state:confirmed] |
| 46 | |
| 47 | ## Kanitsal Cerceve (Evidential Frame Activation) |
| 48 | Kaynak dogrulama modu etkin. |
| 49 | |
| 50 | /*----------------------------------------------------------------------------*/ |
| 51 | /* S2 TRIGGER CONDITIONS */ |
| 52 | /*----------------------------------------------------------------------------*/ |
| 53 | |
| 54 | [define|neutral] TRIGGER_POSITIVE := { |
| 55 | keywords: ["prompt-forge", "foundry", "workflow"], |
| 56 | context: "user needs prompt-forge capability" |
| 57 | } [ground:given] [conf:1.0] [state:confirmed] |
| 58 | |
| 59 | /*----------------------------------------------------------------------------*/ |
| 60 | /* S3 CORE CONTENT */ |
| 61 | /*----------------------------------------------------------------------------*/ |
| 62 | |
| 63 | # Prompt Forge (Meta-Prompt) |
| 64 | |
| 65 | ## Kanitsal Cerceve (Evidential Frame Activation) |
| 66 | Kaynak dogrulama modu etkin. |
| 67 | |
| 68 | |
| 69 | |
| 70 | ## Purpose |
| 71 | |
| 72 | Generate improved prompts and templates with: |
| 73 | - Explicit rationale for each change |
| 74 | - Predicted improvement metrics |
| 75 | - Risk assessment |
| 76 | - Actionable diffs |
| 77 | |
| 78 | **Key Innovation**: Can improve Skill Forge prompts, then Skill Forge can improve Prompt Forge prompts - creating a recursive improvement loop. |
| 79 | |
| 80 | ## When to Use |
| 81 | |
| 82 | - Optimizing existing prompts for better performance |
| 83 | - Creating prompt diffs with clear rationale |
| 84 | - Running the recursive improvement loop |
| 85 | - Auditing prompts for common issues |
| 86 | |
| 87 | ## MCP Requirements |
| 88 | |
| 89 | ### memory-mcp (Required) |
| 90 | |
| 91 | **Purpose**: Store proposals, test results, version history |
| 92 | |
| 93 | **Activation**: |
| 94 | ```bash |
| 95 | claude mcp add memory-mcp npx @modelcontextprotocol/server-memory |
| 96 | ``` |
| 97 | |
| 98 | --- |
| 99 | |
| 100 | ## Core Operations |
| 101 | |
| 102 | ### Operation 1: Analyze Prompt |
| 103 | |
| 104 | Before improving, deeply understand the target prompt. |
| 105 | |
| 106 | ```yaml |
| 107 | analysis: |
| 108 | target: "{prompt_path}" |
| 109 | |
| 110 | structural_analysis: |
| 111 | sections: [list of sections] |
| 112 | flow: "How sections connect" |
| 113 | dependencies: "What inputs/outputs exist" |
| 114 | |
| 115 | quality_assessment: |
| 116 | clarity: |
| 117 | score: 0.0-1.0 |
| 118 | issues: ["Ambiguous instruction in section X"] |
| 119 | completeness: |
| 120 | score: 0.0-1.0 |
| 121 | issues: ["Missing failure handling for case Y"] |
| 122 | precision: |
| 123 | score: 0.0-1.0 |
| 124 | issues: ["Vague success criteria in section Z"] |
| 125 | |
| 126 | pattern_detection: |
| 127 | evidence_based_techniques: |
| 128 | self_consistency: present|missing|partial |
| 129 | program_of_thought: present|missing|partial |
| 130 | plan_and_solve: present|missing|partial |
| 131 | failure_handling: |
| 132 | explicit_errors: present|missing|partial |
| 133 | edge_cases: present|missing|partial |
| 134 | uncertainty: present|missing|partial |
| 135 | |
| 136 | improvement_opportunities: |
| 137 | - area: "Section X" |
| 138 | issue: "Lacks explicit timeout handling" |
| 139 | priority: high|medium|low |
| 140 | predicted_impact: "+X% reliability" |
| 141 | ``` |
| 142 | |
| 143 | ### Operation 2: Generate Improvement Proposal |
| 144 | |
| 145 | Create concrete, testable improvement proposals. |
| 146 | |
| 147 | ```yaml |
| 148 | proposal: |
| 149 | id: "prop-{timestamp}" |
| 150 | target: "{prompt_path}" |
| 151 | type: "prompt_improvement" |
| 152 | |
| 153 | summary: "One-line description of improvement" |
| 154 | |
| 155 | changes: |
| 156 | - section: "Section name" |
| 157 | location: "Line X-Y" |
| 158 | before: | |
| 159 | Original text... |
| 160 | after: | |
| 161 | Improved text... |
| 162 | rationale: "Why this change improves the prompt" |
| 163 | technique: "Which evidence-based technique applied" |
| 164 | |
| 165 | predicted_improvement: |
| 166 | primary_metric: "success_rate" |
| 167 | expected_delta: "+ |