$npx -y skills add parcadei/Continuous-Claude-v3 --skill implement_plan_microImplement technical plans from thoughts/shared/plans with verification
| 1 | # Formal Specification |
| 2 | |
| 3 | ## Multimodal Logic Integration |
| 4 | |
| 5 | Five modal logics via fusion with bridge principles: |
| 6 | - **JL**: Justification Logic - evidence-backed claims |
| 7 | - **IEL**: Inferential Erotetic Logic - question handling |
| 8 | - **TEL**: Temporal Epistemic Logic - phase sequencing |
| 9 | - **SDL**: Standard Deontic Logic - obligations/permissions |
| 10 | - **DEL**: Dynamic Epistemic Logic - action modalities |
| 11 | |
| 12 | ## Justification Logic (JL) |
| 13 | |
| 14 | ``` |
| 15 | # Justification terms |
| 16 | [h]:context(task_n) # Handoff h justifies task context |
| 17 | [v]:verified(phase_n) # Verification v justifies completion |
| 18 | [p]:plan(tasks) # Plan p justifies task list |
| 19 | |
| 20 | # Evidence production |
| 21 | [read(f)]exists e. [e]:content(f) |
| 22 | [verify(c)]exists v. [v]:pass(c) | [v]:fail(c) |
| 23 | |
| 24 | # Handoff chain: evidence propagates |
| 25 | [h_n]:complete(task_n) -> [h_{n+1}]:context(task_{n+1}) |
| 26 | proceed(task) <-> exists h. [h]:validated |
| 27 | ``` |
| 28 | |
| 29 | ## Inferential Erotetic Logic (IEL) |
| 30 | |
| 31 | ``` |
| 32 | # Mode and blocker questions |
| 33 | ?{direct, orchestration} # Mode selection |
| 34 | ?{continue, retry, ask_user} # Blocker resolution |
| 35 | mismatch(plan, reality) -> ?{how_proceed} |
| 36 | no_validation -> ?{run_validation_first} |
| 37 | ``` |
| 38 | |
| 39 | ## Temporal Epistemic Logic (TEL) |
| 40 | |
| 41 | ``` |
| 42 | # File reading constraints |
| 43 | [](mentioned(f) -> <>read_fully(f)) # Eventually read |
| 44 | [](mentioned(f) -> not spawn U read_fully(f)) # No spawn until read |
| 45 | [](partial_read(f) -> false) # Partial reads forbidden |
| 46 | |
| 47 | # Phase sequencing |
| 48 | [](phase(n) -> P(phase(n-1) & verified(n-1))) # Verified before next |
| 49 | [](automated_pass -> <>manual_verify) # Automated gates manual |
| 50 | [](manual_pass(n) -> <>phase(n+1)) # Manual gates next phase |
| 51 | |
| 52 | # Handoff persistence |
| 53 | [](handoff_created(h) -> []exists_on_disk(h)) # Survives compaction |
| 54 | |
| 55 | # Termination |
| 56 | <>(all_complete | abandoned) |
| 57 | ``` |
| 58 | |
| 59 | ## Standard Deontic Logic (SDL) |
| 60 | |
| 61 | ``` |
| 62 | # Reading obligations |
| 63 | O(read_fully(plan)) |
| 64 | O(read_fully(f)) <- mentioned_in_plan(f) |
| 65 | O(check_existing_checkmarks) |
| 66 | F(partial_read) |
| 67 | |
| 68 | # Verification obligations |
| 69 | O(run_automated) <- impl_complete |
| 70 | O(pause_for_manual) <- automated_pass |
| 71 | O(present_manual_checklist) |
| 72 | F(checkoff_manual) <- not user_confirmed |
| 73 | |
| 74 | # Mode selection |
| 75 | O(orchestration) <- tasks >= 4 |
| 76 | P(direct) <- tasks <= 3 |
| 77 | O(respect_user_preference) |
| 78 | |
| 79 | # Orchestration obligations |
| 80 | O(read_previous_handoff) <- exists_handoff(task_{n-1}) |
| 81 | O(create_handoff) <- agent_completes |
| 82 | O(update_ledger) <- task_complete |
| 83 | F(batch_tasks) # One agent per task |
| 84 | F(proceed_on_mismatch) <- not user_guidance |
| 85 | ``` |
| 86 | |
| 87 | ## Dynamic Epistemic Logic (DEL) |
| 88 | |
| 89 | ``` |
| 90 | # Implementation actions |
| 91 | [read(plan)]K(tasks) & K(phases) & K(criteria) |
| 92 | [read(handoff_n)]K(context_{n+1}) |
| 93 | [spawn(agent, task)]<>result(agent) |
| 94 | [verify(c)](K(pass) | K(fail)) |
| 95 | |
| 96 | # Composed workflows |
| 97 | [select_direct][implement ; verify_auto ; present_manual ; wait]* |
| 98 | [select_orchestration][prepare ; spawn ; wait ; read_handoff ; update]* |
| 99 | |
| 100 | # Recovery |
| 101 | [compaction ; read_ledger ; list_handoffs ; read_last]resume |
| 102 | |
| 103 | # Mismatch |
| 104 | [detect_mismatch ; stop ; present ; wait]proceed_or_abort |
| 105 | ``` |
| 106 | |
| 107 | ## Bridge Principles |
| 108 | |
| 109 | ``` |
| 110 | # Evidence persistence (JL-TEL) |
| 111 | [h]:context(n) -> [][h]:context(n) |
| 112 | |
| 113 | # Evidence obligations (JL-SDL) |
| 114 | O(exists h. [h]:validated) <- pre_implement |
| 115 | O(exists v. [v]:pass(auto)) <- pre_manual |
| 116 | |
| 117 | # Handoff chain (full integration) |
| 118 | [h_n]:complete(n) -> O([spawn]<>[h_{n+1}]:context(n+1)) |
| 119 | compaction -> (forall h. persists(h)) |
| 120 | ``` |
| 121 | |
| 122 | ## State Machine |
| 123 | |
| 124 | ``` |
| 125 | INIT --> READ_PLAN --> MODE_SELECT --+--> DIRECT: [IMPL -> AUTO -> MANUAL -> WAIT]* |
| 126 | | |
| 127 | +--> ORCHESTRATION: [PREP -> SPAWN -> WAIT -> HANDOFF]* |
| 128 | | |
| 129 | v |
| 130 | COMPLETE |
| 131 | ``` |
| 132 | |
| 133 | ## Output Schema |
| 134 | |
| 135 | ```yaml |
| 136 | handoff_path: "thoughts/handoffs/<session>/task-[NN]-[desc].md" |
| 137 | schema: |
| 138 | required: [status, task_desc, files_modified[], verification_results, context_for_next] |
| 139 | optional: [blocker, decisions[], open_questions[]] |
| 140 | tracking: |
| 141 | plan: "- [x] Task N: description" |
| 142 | ledger: "[x] Task N" |
| 143 | ``` |
| 144 | |
| 145 | --- |
| 146 | |
| 147 | # Prose (Where Logic Insufficient) |
| 148 | |
| 149 | ## Mode Selection |
| 150 | |
| 151 | | Tasks | Context Critical | Mode | |
| 152 | |-------|------------------|------| |
| 153 | | 1-3 | No | Direct | |
| 154 | | 1-3 | Yes | Orchestration | |
| 155 | | 4+ | Any | Orchestration | |
| 156 | |
| 157 | User preference overrides. |
| 158 | |
| 159 | ## Templates |
| 160 | |
| 161 | **Mismatch:** |
| 162 | ``` |
| 163 | Issue in Phase [N]: |
| 164 | Expected: [plan says] |
| 165 | Found: [actual] |
| 166 | How should I proceed? |
| 167 | ``` |
| 168 | |
| 169 | **Manual Verification Pause:** |
| 170 | ``` |
| 171 | Phase [N] Complete - Ready for Manual Verification |
| 172 | Automated passed: [list] |
| 173 | Please verify: [manual items from plan] |
| 174 | Let me know when done. |
| 175 | ``` |
| 176 | |
| 177 | **Agent Spawn:** |
| 178 | ``` |
| 179 | Task(subagent_type="general-purpose", model="claude-opus-4-5-202511 |