@aria_asi/cli 0.2.39 → 0.2.41

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (802) hide show
  1. package/bin/aria.js +236 -34
  2. package/dist/aria-connector/src/action-ledger-core.d.ts +387 -0
  3. package/dist/aria-connector/src/action-ledger-core.d.ts.map +1 -0
  4. package/dist/aria-connector/src/action-ledger-core.js +638 -0
  5. package/dist/aria-connector/src/action-ledger-core.js.map +1 -0
  6. package/dist/aria-connector/src/chat.d.ts.map +1 -1
  7. package/dist/aria-connector/src/chat.js +5 -6
  8. package/dist/aria-connector/src/chat.js.map +1 -1
  9. package/dist/aria-connector/src/codebase-scanner.d.ts +1 -1
  10. package/dist/aria-connector/src/codebase-scanner.d.ts.map +1 -1
  11. package/dist/aria-connector/src/connectors/claude-code.d.ts +1 -0
  12. package/dist/aria-connector/src/connectors/claude-code.d.ts.map +1 -1
  13. package/dist/aria-connector/src/connectors/claude-code.js +152 -14
  14. package/dist/aria-connector/src/connectors/claude-code.js.map +1 -1
  15. package/dist/aria-connector/src/connectors/codebase-awareness.d.ts +10 -0
  16. package/dist/aria-connector/src/connectors/codebase-awareness.d.ts.map +1 -1
  17. package/dist/aria-connector/src/connectors/codebase-awareness.js +276 -27
  18. package/dist/aria-connector/src/connectors/codebase-awareness.js.map +1 -1
  19. package/dist/aria-connector/src/connectors/codex.d.ts +3 -1
  20. package/dist/aria-connector/src/connectors/codex.d.ts.map +1 -1
  21. package/dist/aria-connector/src/connectors/codex.js +1271 -40
  22. package/dist/aria-connector/src/connectors/codex.js.map +1 -1
  23. package/dist/aria-connector/src/connectors/cursor.d.ts.map +1 -1
  24. package/dist/aria-connector/src/connectors/cursor.js +7 -0
  25. package/dist/aria-connector/src/connectors/cursor.js.map +1 -1
  26. package/dist/aria-connector/src/connectors/governed-adapter.d.ts +30 -0
  27. package/dist/aria-connector/src/connectors/governed-adapter.d.ts.map +1 -0
  28. package/dist/aria-connector/src/connectors/governed-adapter.js +132 -0
  29. package/dist/aria-connector/src/connectors/governed-adapter.js.map +1 -0
  30. package/dist/aria-connector/src/connectors/opencode.d.ts +3 -1
  31. package/dist/aria-connector/src/connectors/opencode.d.ts.map +1 -1
  32. package/dist/aria-connector/src/connectors/opencode.js +18 -2
  33. package/dist/aria-connector/src/connectors/opencode.js.map +1 -1
  34. package/dist/aria-connector/src/connectors/repo-guard.d.ts.map +1 -1
  35. package/dist/aria-connector/src/connectors/repo-guard.js +25 -14
  36. package/dist/aria-connector/src/connectors/repo-guard.js.map +1 -1
  37. package/dist/aria-connector/src/connectors/runtime.d.ts.map +1 -1
  38. package/dist/aria-connector/src/connectors/runtime.js +92 -2
  39. package/dist/aria-connector/src/connectors/runtime.js.map +1 -1
  40. package/dist/aria-connector/src/connectors/shell.d.ts.map +1 -1
  41. package/dist/aria-connector/src/connectors/shell.js +123 -7
  42. package/dist/aria-connector/src/connectors/shell.js.map +1 -1
  43. package/dist/aria-connector/src/cross-cli-hive-binding.d.ts +63 -0
  44. package/dist/aria-connector/src/cross-cli-hive-binding.d.ts.map +1 -0
  45. package/dist/aria-connector/src/cross-cli-hive-binding.js +205 -0
  46. package/dist/aria-connector/src/cross-cli-hive-binding.js.map +1 -0
  47. package/dist/aria-connector/src/garden-control-plane.d.ts +6 -1
  48. package/dist/aria-connector/src/garden-control-plane.d.ts.map +1 -1
  49. package/dist/aria-connector/src/garden-control-plane.js +8 -2
  50. package/dist/aria-connector/src/garden-control-plane.js.map +1 -1
  51. package/dist/aria-connector/src/governed-surface-runner.d.ts +189 -0
  52. package/dist/aria-connector/src/governed-surface-runner.d.ts.map +1 -0
  53. package/dist/aria-connector/src/governed-surface-runner.js +1022 -0
  54. package/dist/aria-connector/src/governed-surface-runner.js.map +1 -0
  55. package/dist/aria-connector/src/index.d.ts +10 -1
  56. package/dist/aria-connector/src/index.d.ts.map +1 -1
  57. package/dist/aria-connector/src/index.js +5 -0
  58. package/dist/aria-connector/src/index.js.map +1 -1
  59. package/dist/aria-connector/src/task-runner.d.ts +3 -0
  60. package/dist/aria-connector/src/task-runner.d.ts.map +1 -0
  61. package/dist/aria-connector/src/task-runner.js +3526 -0
  62. package/dist/aria-connector/src/task-runner.js.map +1 -0
  63. package/dist/aria-web/src/lib/codebase-scanner.d.ts +21 -2
  64. package/dist/aria-web/src/lib/codebase-scanner.d.ts.map +1 -1
  65. package/dist/aria-web/src/lib/codebase-scanner.js +59 -14
  66. package/dist/aria-web/src/lib/codebase-scanner.js.map +1 -1
  67. package/dist/assets/hooks/README.md +58 -0
  68. package/dist/assets/hooks/aria-agent-handoff.mjs +147 -2
  69. package/dist/assets/hooks/aria-agent-ledger-merge.mjs +31 -7
  70. package/dist/assets/hooks/aria-architect-fallback.mjs +10 -2
  71. package/dist/assets/hooks/aria-claim-evidence-stop-gate.mjs +240 -0
  72. package/dist/assets/hooks/aria-cognition-substrate-binding.mjs +84 -10
  73. package/dist/assets/hooks/aria-first-class-coach.mjs +305 -10
  74. package/dist/assets/hooks/aria-harness-via-sdk.mjs +93 -16
  75. package/dist/assets/hooks/aria-import-resolution-gate.mjs +106 -20
  76. package/dist/assets/hooks/aria-outcome-record.mjs +56 -20
  77. package/dist/assets/hooks/aria-pre-emit-autoload.mjs +1809 -0
  78. package/dist/assets/hooks/aria-pre-emit-autoload.mjs.before-orchestration-redesign +1400 -0
  79. package/dist/assets/hooks/aria-pre-emit-dryrun.mjs +22 -3
  80. package/dist/assets/hooks/aria-pre-text-gate.mjs +11 -2
  81. package/dist/assets/hooks/aria-pre-tool-gate.mjs +516 -92
  82. package/dist/assets/hooks/aria-pre-tool-use.mjs +70 -6
  83. package/dist/assets/hooks/aria-preprompt-consult.mjs +23 -4
  84. package/dist/assets/hooks/aria-repo-doctrine-gate.mjs +29 -3
  85. package/dist/assets/hooks/aria-stop-gate.mjs +585 -76
  86. package/dist/assets/hooks/aria-trigger-autolearn.mjs +17 -3
  87. package/dist/assets/hooks/aria-universal-turn-packet.mjs +1165 -0
  88. package/dist/assets/hooks/aria-userprompt-abandon-detect.mjs +9 -1
  89. package/dist/assets/hooks/canonical-settings-block.json +172 -0
  90. package/dist/assets/hooks/codex-native/aria-harness-ticker-sidecar.mjs +92 -0
  91. package/dist/assets/hooks/codex-native/aria-hive-wal-consumer.mjs +86 -0
  92. package/dist/assets/hooks/codex-native/aria-live-ticker.mjs +38 -0
  93. package/dist/assets/hooks/codex-native/aria-post-tool-use.mjs +236 -0
  94. package/dist/assets/hooks/codex-native/aria-pre-tool-use.mjs +362 -0
  95. package/dist/assets/hooks/codex-native/aria-stop.mjs +691 -0
  96. package/dist/assets/hooks/codex-native/aria-userprompt-submit.mjs +623 -0
  97. package/dist/assets/hooks/codex-native/atlas-session-context.mjs +121 -0
  98. package/dist/assets/hooks/codex-native/lib/evaluate-with-kernel.mjs +257 -0
  99. package/dist/assets/hooks/codex-native/lib/hive-wal-consumer.mjs +452 -0
  100. package/dist/assets/hooks/codex-native/lib/kernel/deterministic-cognitive-kernel.mjs +914 -0
  101. package/dist/assets/hooks/codex-native/lib/project-boundary-cognition.mjs +143 -0
  102. package/dist/assets/hooks/codex-native/lib/runtime-client.mjs +3567 -0
  103. package/dist/assets/hooks/codex-native/lib/task-project-ledger.mjs +294 -0
  104. package/dist/assets/hooks/doctrine_trigger_map.json +236 -25
  105. package/dist/assets/hooks/doctrine_trigger_map.schema.json +46 -0
  106. package/dist/assets/hooks/install.sh +84 -0
  107. package/dist/assets/hooks/lib/action-ledger-core.mjs +269 -0
  108. package/dist/assets/hooks/lib/aria-gate-ledger.mjs +143 -0
  109. package/dist/assets/hooks/lib/ast-stub-shape-detector.mjs +107 -0
  110. package/dist/assets/hooks/lib/atlas-dossier-client.mjs +151 -0
  111. package/dist/assets/hooks/lib/atlas-orchestrator-postwire.mjs +221 -0
  112. package/dist/assets/hooks/lib/canonical-lenses.mjs +83 -6
  113. package/dist/assets/hooks/lib/coach-intent-classifier.mjs +248 -0
  114. package/dist/assets/hooks/lib/cognitive-block-parser.mjs +111 -0
  115. package/dist/assets/hooks/lib/doctrine-trigger-map-loader.mjs +137 -0
  116. package/dist/assets/hooks/lib/domain-output-quality.mjs +132 -3
  117. package/dist/assets/hooks/lib/empty-catch-scanner.mjs +91 -0
  118. package/dist/assets/hooks/lib/end-phase-qa-autofire.mjs +426 -0
  119. package/dist/assets/hooks/lib/evaluate-with-kernel.mjs +133 -0
  120. package/dist/assets/hooks/lib/first-class-coach.mjs +454 -19
  121. package/dist/assets/hooks/lib/gate-audit.mjs +12 -2
  122. package/dist/assets/hooks/lib/gate-loop-state.mjs +11 -2
  123. package/dist/assets/hooks/lib/goal-contract-quality.mjs +302 -0
  124. package/dist/assets/hooks/lib/hook-message-window.mjs +101 -9
  125. package/dist/assets/hooks/lib/invocation-required-verifier.mjs +184 -0
  126. package/dist/assets/hooks/lib/kernel/deterministic-cognitive-kernel.mjs +906 -0
  127. package/dist/assets/hooks/lib/obligation-ledger.mjs +147 -0
  128. package/dist/assets/hooks/lib/orchestration-manifest-extract.mjs +217 -0
  129. package/dist/assets/hooks/lib/owner-authorizations.mjs +269 -0
  130. package/dist/assets/hooks/lib/probe-discipline-scanner.mjs +142 -0
  131. package/dist/assets/hooks/lib/project-boundary-cognition.mjs +143 -0
  132. package/dist/assets/hooks/lib/recovery-context.mjs +151 -0
  133. package/dist/assets/hooks/lib/recovery-template-loader.mjs +154 -0
  134. package/dist/assets/hooks/lib/self-doctrine-check.mjs +321 -0
  135. package/dist/assets/hooks/lib/sensitive-shape-detector.mjs +64 -0
  136. package/dist/assets/hooks/lib/skill-autoload-gate-impl.mjs +226 -1
  137. package/dist/assets/hooks/lib/stop-hook-protocol.mjs +166 -0
  138. package/dist/assets/hooks/lib/surface-caught.mjs +94 -0
  139. package/dist/assets/hooks/recovery-templates/force-reauthor.md +67 -0
  140. package/dist/assets/hooks/recovery-templates/handoff-recovery.md +25 -0
  141. package/dist/assets/hooks/scripts/check-hard-risk-prefix.mjs +99 -0
  142. package/dist/assets/hooks/skills/aria-conversational-doctrine-discipline/SKILL.md +101 -0
  143. package/dist/assets/hooks/test-aria-preturn-memory-gate.mjs +2 -2
  144. package/dist/assets/hooks/test-tier-lens-labeling.mjs +14 -3
  145. package/dist/assets/opencode-plugins/harness-context/index.js +39 -6
  146. package/dist/assets/opencode-plugins/harness-context/task-project-ledger.mjs +5 -1
  147. package/dist/assets/opencode-plugins/harness-gate/index.js +36 -0
  148. package/dist/assets/opencode-plugins/harness-gate/lib/atlas-dossier-client.js +1 -0
  149. package/dist/assets/opencode-plugins/harness-gate/lib/recovery-grants.js +79 -0
  150. package/dist/assets/opencode-plugins/harness-outcome/index.js +12 -0
  151. package/dist/assets/opencode-plugins/harness-stop/index.js +97 -2
  152. package/dist/assets/opencode-plugins/harness-stop/lib/atlas-dossier-client.js +1 -0
  153. package/dist/assets/opencode-plugins/harness-stop/lib/domain-output-quality.js +15 -2
  154. package/dist/assets/opencode-plugins/lib/coach.js +148 -0
  155. package/dist/runtime/coach-kernel.mjs +144 -7
  156. package/dist/runtime/codex-bridge.mjs +254 -8
  157. package/dist/runtime/discipline/doctrine_trigger_map.json +236 -25
  158. package/dist/runtime/discipline/skills/aria-cognition/34-frameworks-unified/SKILL.md +42 -0
  159. package/dist/runtime/discipline/skills/aria-cognition/aria-aristotle-cognitives/SKILL.md +128 -0
  160. package/dist/runtime/discipline/skills/aria-cognition/aria-aristotle-intra-phase/SKILL.md +99 -0
  161. package/dist/runtime/discipline/skills/aria-cognition/aria-aristotle-post-phase/SKILL.md +118 -0
  162. package/dist/runtime/discipline/skills/aria-cognition/aria-aristotle-pre-phase/SKILL.md +117 -0
  163. package/dist/runtime/discipline/skills/aria-cognition/aria-axioms-first-principles/SKILL.md +202 -0
  164. package/dist/runtime/discipline/skills/aria-cognition/aria-axioms-first-principles/agents/openai.yaml +4 -0
  165. package/dist/runtime/discipline/skills/aria-cognition/aria-axioms-first-principles/references/source-map.md +130 -0
  166. package/dist/runtime/discipline/skills/aria-cognition/aria-backend-architect/SKILL.md +124 -0
  167. package/dist/runtime/discipline/skills/aria-cognition/aria-backend-architect/references/backend-cookbook.md +417 -0
  168. package/dist/runtime/discipline/skills/aria-cognition/aria-business-audit/SKILL.md +133 -0
  169. package/dist/runtime/discipline/skills/aria-cognition/aria-business-audit/references/audit-cookbook.md +247 -0
  170. package/dist/runtime/discipline/skills/aria-cognition/aria-business-frame/SKILL.md +138 -0
  171. package/dist/runtime/discipline/skills/aria-cognition/aria-business-frame/references/business-cookbook.md +154 -0
  172. package/dist/runtime/discipline/skills/aria-cognition/aria-chat/SKILL.md +84 -0
  173. package/dist/runtime/discipline/skills/aria-cognition/aria-chat/scripts/aria-chat.sh +57 -0
  174. package/dist/runtime/discipline/skills/aria-cognition/aria-cognition-autofire/SKILL.md +137 -0
  175. package/dist/runtime/discipline/skills/aria-cognition/aria-cognition-batch/SKILL.md +264 -0
  176. package/dist/runtime/discipline/skills/aria-cognition/aria-decision-mizan/SKILL.md +136 -0
  177. package/dist/runtime/discipline/skills/aria-cognition/aria-decision-mizan/references/decision-frameworks.md +287 -0
  178. package/dist/runtime/discipline/skills/aria-cognition/aria-first-class-operating-contract/SKILL.md +104 -0
  179. package/dist/runtime/discipline/skills/aria-cognition/aria-frontend-architect/SKILL.md +123 -0
  180. package/dist/runtime/discipline/skills/aria-cognition/aria-frontend-architect/references/frontend-cookbook.md +358 -0
  181. package/dist/runtime/discipline/skills/aria-cognition/aria-fullstack-orchestrator/SKILL.md +127 -0
  182. package/dist/runtime/discipline/skills/aria-cognition/aria-fullstack-orchestrator/references/fullstack-cookbook.md +383 -0
  183. package/dist/runtime/discipline/skills/aria-cognition/aria-gtm-architect/SKILL.md +126 -0
  184. package/dist/runtime/discipline/skills/aria-cognition/aria-gtm-architect/references/gtm-cookbook.md +235 -0
  185. package/dist/runtime/discipline/skills/aria-cognition/aria-harness-deploy/SKILL.md +145 -0
  186. package/dist/runtime/discipline/skills/aria-cognition/aria-harness-no-stripping/SKILL.md +135 -0
  187. package/dist/runtime/discipline/skills/aria-cognition/aria-harness-onboarding/SKILL.md +130 -0
  188. package/dist/runtime/discipline/skills/aria-cognition/aria-harness-output-discipline/SKILL.md +120 -0
  189. package/dist/runtime/discipline/skills/aria-cognition/aria-harness-substrate-binding/SKILL.md +139 -0
  190. package/dist/runtime/discipline/skills/aria-cognition/aria-http-harness-client/SKILL.md +85 -0
  191. package/dist/runtime/discipline/skills/aria-cognition/aria-http-harness-client/scripts/smoke.mjs +47 -0
  192. package/dist/runtime/discipline/skills/aria-cognition/aria-k8s-deploy/SKILL.md +174 -0
  193. package/dist/runtime/discipline/skills/aria-cognition/aria-k8s-deploy/agents/openai.yaml +3 -0
  194. package/dist/runtime/discipline/skills/aria-cognition/aria-ladduniframe/SKILL.md +60 -0
  195. package/dist/runtime/discipline/skills/aria-cognition/aria-ledger-fleet-execution/SKILL.md +126 -0
  196. package/dist/runtime/discipline/skills/aria-cognition/aria-live-ops/SKILL.md +54 -0
  197. package/dist/runtime/discipline/skills/aria-cognition/aria-mac-ssh-ops/SKILL.md +100 -0
  198. package/dist/runtime/discipline/skills/aria-cognition/aria-memory-index/SKILL.md +42 -0
  199. package/dist/runtime/discipline/skills/aria-cognition/aria-noor-cognitives/SKILL.md +120 -0
  200. package/dist/runtime/discipline/skills/aria-cognition/aria-ops/SKILL.md +60 -0
  201. package/dist/runtime/discipline/skills/aria-cognition/aria-ops/references/live-endpoints.md +59 -0
  202. package/dist/runtime/discipline/skills/aria-cognition/aria-quality-audit/SKILL.md +133 -0
  203. package/dist/runtime/discipline/skills/aria-cognition/aria-readable-output/SKILL.md +239 -0
  204. package/dist/runtime/discipline/skills/aria-cognition/aria-readable-output/references/layout-cookbook.md +366 -0
  205. package/dist/runtime/discipline/skills/aria-cognition/aria-reasoning/SKILL.md +67 -0
  206. package/dist/runtime/discipline/skills/aria-cognition/aria-reasoning/references/core-principles.md +42 -0
  207. package/dist/runtime/discipline/skills/aria-cognition/aria-repo-audit/SKILL.md +135 -0
  208. package/dist/runtime/discipline/skills/aria-cognition/aria-repo-audit/references/repo-audit-cookbook.md +375 -0
  209. package/dist/runtime/discipline/skills/aria-cognition/aria-research-orchestrator/SKILL.md +138 -0
  210. package/dist/runtime/discipline/skills/aria-cognition/aria-research-orchestrator/references/research-patterns.md +270 -0
  211. package/dist/runtime/discipline/skills/aria-cognition/aria-retention-engine/SKILL.md +120 -0
  212. package/dist/runtime/discipline/skills/aria-cognition/aria-retention-engine/references/retention-cookbook.md +271 -0
  213. package/dist/runtime/discipline/skills/aria-cognition/aria-revenue-engine/SKILL.md +128 -0
  214. package/dist/runtime/discipline/skills/aria-cognition/aria-revenue-engine/references/revenue-cookbook.md +227 -0
  215. package/dist/runtime/discipline/skills/aria-cognition/aria-senior-code-audit/SKILL.md +233 -0
  216. package/dist/runtime/discipline/skills/aria-cognition/aria-senior-code-audit/references/audit-checklist.md +369 -0
  217. package/dist/runtime/discipline/skills/aria-cognition/aria-senior-code-cookbook/SKILL.md +288 -0
  218. package/dist/runtime/discipline/skills/aria-cognition/aria-senior-code-cookbook/references/engineering-cookbook.md +489 -0
  219. package/dist/runtime/discipline/skills/aria-cognition/aria-soul-principles/SKILL.md +42 -0
  220. package/dist/runtime/discipline/skills/aria-cognition/aria-task-codex-executor/SKILL.md +86 -0
  221. package/dist/runtime/discipline/skills/aria-cognition/aristotle-engine/SKILL.md +42 -0
  222. package/dist/runtime/discipline/skills/aria-cognition/cross-domain-24/SKILL.md +42 -0
  223. package/dist/runtime/discipline/skills/aria-cognition/deepsoul-emotional/SKILL.md +42 -0
  224. package/dist/runtime/discipline/skills/aria-cognition/fitrah-guard/SKILL.md +78 -0
  225. package/dist/runtime/discipline/skills/aria-cognition/ghazali-8lens/SKILL.md +227 -29
  226. package/dist/runtime/discipline/skills/aria-cognition/ghazali-8lens/references/ghazali-8lens-cookbook.md +797 -0
  227. package/dist/runtime/discipline/skills/aria-cognition/ijtihad-novel/SKILL.md +42 -0
  228. package/dist/runtime/discipline/skills/aria-cognition/ilham-intuition/SKILL.md +42 -0
  229. package/dist/runtime/discipline/skills/aria-cognition/never-guess/SKILL.md +77 -0
  230. package/dist/runtime/discipline/skills/aria-cognition/noor-recognition/SKILL.md +45 -0
  231. package/dist/runtime/discipline/skills/aria-cognition/qiyas-analogy/SKILL.md +174 -14
  232. package/dist/runtime/discipline/skills/aria-cognition/ruh-basis/SKILL.md +42 -0
  233. package/dist/runtime/discipline/skills/aria-cognition/tadabbur/SKILL.md +506 -0
  234. package/dist/runtime/discipline/skills/aria-cognition/tadabbur/references/tadabbur-cookbook.md +921 -0
  235. package/dist/runtime/discipline/skills/aria-cognition/tadabbur-ops/SKILL.md +42 -0
  236. package/dist/runtime/discipline/skills/aria-cognition/tafakkur/SKILL.md +104 -0
  237. package/dist/runtime/doctrine_trigger_map.json +236 -25
  238. package/dist/runtime/embedded-public-key.mjs +27 -0
  239. package/dist/runtime/gated-ledger.mjs +41 -14
  240. package/dist/runtime/harness-daemon.mjs +85 -10
  241. package/dist/runtime/hive-wal-publisher.mjs +292 -0
  242. package/dist/runtime/hooks/README.md +58 -0
  243. package/dist/runtime/hooks/aria-agent-handoff.mjs +147 -2
  244. package/dist/runtime/hooks/aria-agent-ledger-merge.mjs +31 -7
  245. package/dist/runtime/hooks/aria-architect-fallback.mjs +10 -2
  246. package/dist/runtime/hooks/aria-claim-evidence-stop-gate.mjs +240 -0
  247. package/dist/runtime/hooks/aria-cognition-substrate-binding.mjs +84 -10
  248. package/dist/runtime/hooks/aria-first-class-coach.mjs +305 -10
  249. package/dist/runtime/hooks/aria-harness-via-sdk.mjs +93 -16
  250. package/dist/runtime/hooks/aria-import-resolution-gate.mjs +106 -20
  251. package/dist/runtime/hooks/aria-outcome-record.mjs +56 -20
  252. package/dist/runtime/hooks/aria-pre-emit-autoload.mjs +1809 -0
  253. package/dist/runtime/hooks/aria-pre-emit-autoload.mjs.before-orchestration-redesign +1400 -0
  254. package/dist/runtime/hooks/aria-pre-emit-dryrun.mjs +22 -3
  255. package/dist/runtime/hooks/aria-pre-text-gate.mjs +11 -2
  256. package/dist/runtime/hooks/aria-pre-tool-gate.mjs +516 -92
  257. package/dist/runtime/hooks/aria-pre-tool-use.mjs +70 -6
  258. package/dist/runtime/hooks/aria-preprompt-consult.mjs +23 -4
  259. package/dist/runtime/hooks/aria-repo-doctrine-gate.mjs +29 -3
  260. package/dist/runtime/hooks/aria-stop-gate.mjs +585 -76
  261. package/dist/runtime/hooks/aria-trigger-autolearn.mjs +17 -3
  262. package/dist/runtime/hooks/aria-universal-turn-packet.mjs +1165 -0
  263. package/dist/runtime/hooks/aria-userprompt-abandon-detect.mjs +9 -1
  264. package/dist/runtime/hooks/canonical-settings-block.json +172 -0
  265. package/dist/runtime/hooks/codex-native/aria-harness-ticker-sidecar.mjs +92 -0
  266. package/dist/runtime/hooks/codex-native/aria-hive-wal-consumer.mjs +86 -0
  267. package/dist/runtime/hooks/codex-native/aria-live-ticker.mjs +38 -0
  268. package/dist/runtime/hooks/codex-native/aria-post-tool-use.mjs +236 -0
  269. package/dist/runtime/hooks/codex-native/aria-pre-tool-use.mjs +362 -0
  270. package/dist/runtime/hooks/codex-native/aria-stop.mjs +691 -0
  271. package/dist/runtime/hooks/codex-native/aria-userprompt-submit.mjs +623 -0
  272. package/dist/runtime/hooks/codex-native/atlas-session-context.mjs +121 -0
  273. package/dist/runtime/hooks/codex-native/lib/evaluate-with-kernel.mjs +257 -0
  274. package/dist/runtime/hooks/codex-native/lib/hive-wal-consumer.mjs +452 -0
  275. package/dist/runtime/hooks/codex-native/lib/kernel/deterministic-cognitive-kernel.mjs +914 -0
  276. package/dist/runtime/hooks/codex-native/lib/project-boundary-cognition.mjs +143 -0
  277. package/dist/runtime/hooks/codex-native/lib/runtime-client.mjs +3567 -0
  278. package/dist/runtime/hooks/codex-native/lib/task-project-ledger.mjs +294 -0
  279. package/dist/runtime/hooks/doctrine_trigger_map.json +236 -25
  280. package/dist/runtime/hooks/doctrine_trigger_map.schema.json +46 -0
  281. package/dist/runtime/hooks/install.sh +84 -0
  282. package/dist/runtime/hooks/lib/action-ledger-core.mjs +269 -0
  283. package/dist/runtime/hooks/lib/aria-gate-ledger.mjs +143 -0
  284. package/dist/runtime/hooks/lib/ast-stub-shape-detector.mjs +107 -0
  285. package/dist/runtime/hooks/lib/atlas-dossier-client.mjs +151 -0
  286. package/dist/runtime/hooks/lib/atlas-orchestrator-postwire.mjs +221 -0
  287. package/dist/runtime/hooks/lib/canonical-lenses.mjs +83 -6
  288. package/dist/runtime/hooks/lib/coach-intent-classifier.mjs +248 -0
  289. package/dist/runtime/hooks/lib/cognitive-block-parser.mjs +111 -0
  290. package/dist/runtime/hooks/lib/doctrine-trigger-map-loader.mjs +137 -0
  291. package/dist/runtime/hooks/lib/domain-output-quality.mjs +132 -3
  292. package/dist/runtime/hooks/lib/empty-catch-scanner.mjs +91 -0
  293. package/dist/runtime/hooks/lib/end-phase-qa-autofire.mjs +426 -0
  294. package/dist/runtime/hooks/lib/evaluate-with-kernel.mjs +133 -0
  295. package/dist/runtime/hooks/lib/first-class-coach.mjs +454 -19
  296. package/dist/runtime/hooks/lib/gate-audit.mjs +12 -2
  297. package/dist/runtime/hooks/lib/gate-loop-state.mjs +11 -2
  298. package/dist/runtime/hooks/lib/goal-contract-quality.mjs +302 -0
  299. package/dist/runtime/hooks/lib/hook-message-window.mjs +101 -9
  300. package/dist/runtime/hooks/lib/invocation-required-verifier.mjs +184 -0
  301. package/dist/runtime/hooks/lib/kernel/deterministic-cognitive-kernel.mjs +906 -0
  302. package/dist/runtime/hooks/lib/obligation-ledger.mjs +147 -0
  303. package/dist/runtime/hooks/lib/orchestration-manifest-extract.mjs +217 -0
  304. package/dist/runtime/hooks/lib/owner-authorizations.mjs +269 -0
  305. package/dist/runtime/hooks/lib/probe-discipline-scanner.mjs +142 -0
  306. package/dist/runtime/hooks/lib/project-boundary-cognition.mjs +143 -0
  307. package/dist/runtime/hooks/lib/recovery-context.mjs +151 -0
  308. package/dist/runtime/hooks/lib/recovery-template-loader.mjs +154 -0
  309. package/dist/runtime/hooks/lib/self-doctrine-check.mjs +321 -0
  310. package/dist/runtime/hooks/lib/sensitive-shape-detector.mjs +64 -0
  311. package/dist/runtime/hooks/lib/skill-autoload-gate-impl.mjs +226 -1
  312. package/dist/runtime/hooks/lib/stop-hook-protocol.mjs +166 -0
  313. package/dist/runtime/hooks/lib/surface-caught.mjs +94 -0
  314. package/dist/runtime/hooks/recovery-templates/force-reauthor.md +67 -0
  315. package/dist/runtime/hooks/recovery-templates/handoff-recovery.md +25 -0
  316. package/dist/runtime/hooks/scripts/check-hard-risk-prefix.mjs +99 -0
  317. package/dist/runtime/hooks/skills/aria-conversational-doctrine-discipline/SKILL.md +101 -0
  318. package/dist/runtime/hooks/test-aria-preturn-memory-gate.mjs +2 -2
  319. package/dist/runtime/hooks/test-tier-lens-labeling.mjs +14 -3
  320. package/dist/runtime/lib/evaluate-with-kernel.mjs +133 -0
  321. package/dist/runtime/lib/kernel/deterministic-cognitive-kernel.mjs +906 -0
  322. package/dist/runtime/local-phase.mjs +10 -5
  323. package/dist/runtime/manifest.json +8 -8
  324. package/dist/runtime/packet-verifier.mjs +166 -0
  325. package/dist/runtime/provider-proxy.mjs +13 -0
  326. package/dist/runtime/quality-enforcer.mjs +40 -23
  327. package/dist/runtime/runtime-rails/registry.mjs +252 -0
  328. package/dist/runtime/sdk/BUNDLED.json +2 -2
  329. package/dist/runtime/sdk/index.d.ts +119 -4
  330. package/dist/runtime/sdk/index.js +138 -12
  331. package/dist/runtime/sdk/index.js.map +1 -1
  332. package/dist/runtime/service.mjs +8036 -764
  333. package/dist/runtime/sub-agent-enforcer.mjs +201 -0
  334. package/dist/runtime/task-project-ledger.mjs +5 -1
  335. package/dist/sdk/BUNDLED.json +2 -2
  336. package/dist/sdk/index.d.ts +119 -4
  337. package/dist/sdk/index.js +138 -12
  338. package/dist/sdk/index.js.map +1 -1
  339. package/hooks/README.md +58 -0
  340. package/hooks/aria-agent-handoff.mjs +147 -2
  341. package/hooks/aria-agent-ledger-merge.mjs +31 -7
  342. package/hooks/aria-architect-fallback.mjs +10 -2
  343. package/hooks/aria-claim-evidence-stop-gate.mjs +240 -0
  344. package/hooks/aria-cognition-substrate-binding.mjs +84 -10
  345. package/hooks/aria-first-class-coach.mjs +305 -10
  346. package/hooks/aria-harness-via-sdk.mjs +93 -16
  347. package/hooks/aria-import-resolution-gate.mjs +106 -20
  348. package/hooks/aria-outcome-record.mjs +56 -20
  349. package/hooks/aria-pre-emit-autoload.mjs +1809 -0
  350. package/hooks/aria-pre-emit-autoload.mjs.before-orchestration-redesign +1400 -0
  351. package/hooks/aria-pre-emit-dryrun.mjs +22 -3
  352. package/hooks/aria-pre-text-gate.mjs +11 -2
  353. package/hooks/aria-pre-tool-gate.mjs +516 -92
  354. package/hooks/aria-pre-tool-use.mjs +70 -6
  355. package/hooks/aria-preprompt-consult.mjs +23 -4
  356. package/hooks/aria-repo-doctrine-gate.mjs +29 -3
  357. package/hooks/aria-stop-gate.mjs +585 -76
  358. package/hooks/aria-trigger-autolearn.mjs +17 -3
  359. package/hooks/aria-universal-turn-packet.mjs +1165 -0
  360. package/hooks/aria-userprompt-abandon-detect.mjs +9 -1
  361. package/hooks/canonical-settings-block.json +172 -0
  362. package/hooks/codex-native/aria-harness-ticker-sidecar.mjs +92 -0
  363. package/hooks/codex-native/aria-hive-wal-consumer.mjs +86 -0
  364. package/hooks/codex-native/aria-live-ticker.mjs +38 -0
  365. package/hooks/codex-native/aria-post-tool-use.mjs +236 -0
  366. package/hooks/codex-native/aria-pre-tool-use.mjs +362 -0
  367. package/hooks/codex-native/aria-stop.mjs +691 -0
  368. package/hooks/codex-native/aria-userprompt-submit.mjs +623 -0
  369. package/hooks/codex-native/atlas-session-context.mjs +121 -0
  370. package/hooks/codex-native/lib/evaluate-with-kernel.mjs +257 -0
  371. package/hooks/codex-native/lib/hive-wal-consumer.mjs +452 -0
  372. package/hooks/codex-native/lib/kernel/deterministic-cognitive-kernel.mjs +914 -0
  373. package/hooks/codex-native/lib/project-boundary-cognition.mjs +143 -0
  374. package/hooks/codex-native/lib/runtime-client.mjs +3567 -0
  375. package/hooks/codex-native/lib/task-project-ledger.mjs +294 -0
  376. package/hooks/doctrine_trigger_map.json +236 -25
  377. package/hooks/doctrine_trigger_map.schema.json +46 -0
  378. package/hooks/install.sh +84 -0
  379. package/hooks/lib/action-ledger-core.mjs +269 -0
  380. package/hooks/lib/aria-gate-ledger.mjs +143 -0
  381. package/hooks/lib/ast-stub-shape-detector.mjs +107 -0
  382. package/hooks/lib/atlas-dossier-client.mjs +151 -0
  383. package/hooks/lib/atlas-orchestrator-postwire.mjs +221 -0
  384. package/hooks/lib/canonical-lenses.mjs +83 -6
  385. package/hooks/lib/coach-intent-classifier.mjs +248 -0
  386. package/hooks/lib/cognitive-block-parser.mjs +111 -0
  387. package/hooks/lib/doctrine-trigger-map-loader.mjs +137 -0
  388. package/hooks/lib/domain-output-quality.mjs +132 -3
  389. package/hooks/lib/empty-catch-scanner.mjs +91 -0
  390. package/hooks/lib/end-phase-qa-autofire.mjs +426 -0
  391. package/hooks/lib/evaluate-with-kernel.mjs +133 -0
  392. package/hooks/lib/first-class-coach.mjs +454 -19
  393. package/hooks/lib/gate-audit.mjs +12 -2
  394. package/hooks/lib/gate-loop-state.mjs +11 -2
  395. package/hooks/lib/goal-contract-quality.mjs +302 -0
  396. package/hooks/lib/hook-message-window.mjs +101 -9
  397. package/hooks/lib/invocation-required-verifier.mjs +184 -0
  398. package/hooks/lib/kernel/deterministic-cognitive-kernel.mjs +906 -0
  399. package/hooks/lib/obligation-ledger.mjs +147 -0
  400. package/hooks/lib/orchestration-manifest-extract.mjs +217 -0
  401. package/hooks/lib/owner-authorizations.mjs +269 -0
  402. package/hooks/lib/probe-discipline-scanner.mjs +142 -0
  403. package/hooks/lib/project-boundary-cognition.mjs +143 -0
  404. package/hooks/lib/recovery-context.mjs +151 -0
  405. package/hooks/lib/recovery-template-loader.mjs +154 -0
  406. package/hooks/lib/self-doctrine-check.mjs +321 -0
  407. package/hooks/lib/sensitive-shape-detector.mjs +64 -0
  408. package/hooks/lib/skill-autoload-gate-impl.mjs +226 -1
  409. package/hooks/lib/stop-hook-protocol.mjs +166 -0
  410. package/hooks/lib/surface-caught.mjs +94 -0
  411. package/hooks/recovery-templates/force-reauthor.md +67 -0
  412. package/hooks/recovery-templates/handoff-recovery.md +25 -0
  413. package/hooks/scripts/check-hard-risk-prefix.mjs +99 -0
  414. package/hooks/skills/aria-conversational-doctrine-discipline/SKILL.md +101 -0
  415. package/hooks/test-aria-preturn-memory-gate.mjs +2 -2
  416. package/hooks/test-tier-lens-labeling.mjs +14 -3
  417. package/opencode-plugins/harness-context/index.js +39 -6
  418. package/opencode-plugins/harness-context/task-project-ledger.mjs +5 -1
  419. package/opencode-plugins/harness-gate/index.js +36 -0
  420. package/opencode-plugins/harness-gate/lib/atlas-dossier-client.js +1 -0
  421. package/opencode-plugins/harness-gate/lib/recovery-grants.js +79 -0
  422. package/opencode-plugins/harness-outcome/index.js +12 -0
  423. package/opencode-plugins/harness-stop/index.js +97 -2
  424. package/opencode-plugins/harness-stop/lib/atlas-dossier-client.js +1 -0
  425. package/opencode-plugins/harness-stop/lib/domain-output-quality.js +15 -2
  426. package/opencode-plugins/lib/coach.js +148 -0
  427. package/package.json +71 -5
  428. package/runtime-src/coach-kernel.mjs +144 -7
  429. package/runtime-src/codex-bridge.mjs +254 -8
  430. package/runtime-src/embedded-public-key.mjs +27 -0
  431. package/runtime-src/gated-ledger.mjs +41 -14
  432. package/runtime-src/harness-daemon.mjs +85 -10
  433. package/runtime-src/hive-wal-publisher.mjs +292 -0
  434. package/runtime-src/lib/evaluate-with-kernel.mjs +133 -0
  435. package/runtime-src/lib/kernel/deterministic-cognitive-kernel.mjs +906 -0
  436. package/runtime-src/local-phase.mjs +10 -5
  437. package/runtime-src/packet-verifier.mjs +166 -0
  438. package/runtime-src/provider-proxy.mjs +13 -0
  439. package/runtime-src/quality-enforcer.mjs +40 -23
  440. package/runtime-src/runtime-rails/registry.mjs +252 -0
  441. package/runtime-src/service.mjs +8036 -764
  442. package/runtime-src/sub-agent-enforcer.mjs +201 -0
  443. package/scripts/aria-ledger-append.mjs +337 -0
  444. package/scripts/aria-task-cheap-worker-dispatch.mjs +234 -0
  445. package/scripts/audit-of-audit-prior-tasks.mjs +194 -0
  446. package/scripts/audit-of-audit-this-turn.mjs +116 -0
  447. package/scripts/bundle-sdk.mjs +31 -5
  448. package/scripts/check-cli-wrapper-provider-contract.mjs +160 -0
  449. package/scripts/check-client-compatibility.mjs +15 -5
  450. package/scripts/check-client-smoke.mjs +297 -0
  451. package/scripts/check-codex-orchestrator-adoption.mjs +150 -0
  452. package/scripts/check-glm-env-wired.mjs +131 -0
  453. package/scripts/check-hive-local-storage-contract.mjs +91 -0
  454. package/scripts/check-hook-mirror.mjs +150 -0
  455. package/scripts/check-install-sh-drift.mjs +152 -0
  456. package/scripts/check-kernel-sync.mjs +101 -0
  457. package/scripts/check-package-artifact.mjs +152 -0
  458. package/scripts/check-registry-mirror.mjs +71 -0
  459. package/scripts/drain-owner-airtable-sync-queue.mjs +287 -0
  460. package/scripts/export-owner-status-sheets.mjs +589 -0
  461. package/scripts/live-sidecar-receipt-canary.mjs +347 -0
  462. package/scripts/qiyas-tadabbur-model-matrix.mjs +970 -0
  463. package/scripts/quality-ab-live-provider.mjs +913 -0
  464. package/scripts/self-test-action-ledger-core.mjs +190 -0
  465. package/scripts/self-test-approval-receipt-binding.mjs +122 -0
  466. package/scripts/self-test-autofire-quality-output.mjs +110 -0
  467. package/scripts/self-test-claude-code-action-ledger.mjs +132 -0
  468. package/scripts/self-test-claude-code-mechanical-autofire-hive.mjs +138 -0
  469. package/scripts/self-test-claude-code-mechanical-autofire.mjs +234 -0
  470. package/scripts/self-test-codebase-awareness-atlas-delta.mjs +159 -0
  471. package/scripts/self-test-codebase-awareness-delta-ingest.mjs +179 -0
  472. package/scripts/self-test-codex-live-hook-parity.mjs +84 -0
  473. package/scripts/self-test-codex-native-action-ledger.mjs +167 -0
  474. package/scripts/self-test-codex-native-hook-json-contract.mjs +74 -0
  475. package/scripts/self-test-codex-orchestrator-continuity.mjs +113 -0
  476. package/scripts/self-test-codex-readable-recovery.mjs +94 -0
  477. package/scripts/self-test-codex-self-harness.mjs +538 -0
  478. package/scripts/self-test-compiled-workunit.mjs +214 -0
  479. package/scripts/self-test-continuation-output-smoke.mjs +101 -0
  480. package/scripts/self-test-cross-cli-fleet-ticker.mjs +85 -0
  481. package/scripts/self-test-cross-cli-hive-adoption.mjs +125 -0
  482. package/scripts/self-test-cross-cli-hive-learning.mjs +146 -0
  483. package/scripts/self-test-cross-phase-tool-failure.mjs +110 -0
  484. package/scripts/self-test-cross-surface-action-ledger.mjs +149 -0
  485. package/scripts/self-test-end-of-phase-qa-court.mjs +616 -0
  486. package/scripts/self-test-evaluate-with-kernel.mjs +111 -0
  487. package/scripts/self-test-first-class-output-delta-proof.mjs +307 -0
  488. package/scripts/self-test-goal-contract-output-qa.mjs +73 -0
  489. package/scripts/self-test-goal-contract.mjs +35 -0
  490. package/scripts/self-test-governed-adapters.mjs +105 -0
  491. package/scripts/self-test-governed-surface-runner.mjs +198 -0
  492. package/scripts/self-test-harness-gates.mjs +15 -12
  493. package/scripts/self-test-harness-ticker-sidecar.mjs +153 -0
  494. package/scripts/self-test-hive-org-kernel.mjs +233 -0
  495. package/scripts/self-test-hive-session-coordination.mjs +156 -0
  496. package/scripts/self-test-hive-wal-consumer.mjs +111 -0
  497. package/scripts/self-test-kernel-a3-a4-selection.mjs +179 -0
  498. package/scripts/self-test-ledger-append.mjs +175 -0
  499. package/scripts/self-test-live-codex-posttool-packet-smoke.mjs +111 -0
  500. package/scripts/self-test-live-codex-pretool-packet-smoke.mjs +101 -0
  501. package/scripts/self-test-live-codex-stop-qa-kernel-smoke.mjs +43 -0
  502. package/scripts/self-test-live-wrapper-substrate-inventory.mjs +149 -0
  503. package/scripts/self-test-local-main-sync-script.mjs +47 -0
  504. package/scripts/self-test-mechanical-autofire-resolver.mjs +296 -0
  505. package/scripts/self-test-no-consult-cognitive-skills-output.mjs +135 -0
  506. package/scripts/self-test-owner-airtable-sync-queue.mjs +196 -0
  507. package/scripts/self-test-owner-airtable-sync.mjs +181 -0
  508. package/scripts/self-test-owner-sheets-action-ledger.mjs +100 -0
  509. package/scripts/self-test-production-preflight.mjs +78 -0
  510. package/scripts/self-test-project-boundary-cognition.mjs +79 -0
  511. package/scripts/self-test-qa-exec-kernel.mjs +34 -0
  512. package/scripts/self-test-qa-recovery-learning-loop.mjs +113 -0
  513. package/scripts/self-test-qiyas-label-alignment.mjs +94 -0
  514. package/scripts/self-test-recovery-context.mjs +110 -0
  515. package/scripts/self-test-repo-guard.mjs +10 -0
  516. package/scripts/self-test-runtime-health-self-heal.mjs +161 -0
  517. package/scripts/self-test-runtime-postcondition.mjs +70 -0
  518. package/scripts/self-test-soul-precommit-hook.mjs +39 -0
  519. package/scripts/self-test-stop-gate-kernel-guards.mjs +185 -0
  520. package/scripts/self-test-stop-gate.mjs +128 -0
  521. package/scripts/self-test-substrate-kernel-execution-receipt.mjs +130 -0
  522. package/scripts/self-test-substrate-open-skill-floor.mjs +87 -0
  523. package/scripts/self-test-substrate-output-quality-eval.mjs +171 -0
  524. package/scripts/self-test-task-closeout-drift.mjs +97 -0
  525. package/scripts/self-test-task-project-ledger-readiness.mjs +43 -0
  526. package/scripts/self-test-task-runner-phase-consumer.mjs +134 -0
  527. package/scripts/self-test-task-worker-lane.mjs +256 -0
  528. package/scripts/self-test-turn-substrate-qa-kernel.mjs +188 -0
  529. package/scripts/self-test-universal-action-capture.mjs +153 -0
  530. package/scripts/self-test-universal-turn-packet-entrypoints.mjs +252 -0
  531. package/scripts/self-test-universal-turn-packet.mjs +320 -0
  532. package/scripts/session-quality-backfill.mjs +253 -0
  533. package/scripts/smoke-autofire-100-prompts.mjs +481 -0
  534. package/scripts/sync-local-main-on-task-complete.mjs +278 -0
  535. package/scripts/sync-owner-status-airtable.mjs +1158 -0
  536. package/scripts/validate-skill-prompts.mjs +12 -1
  537. package/scripts/verify-codex-native-mirror.mjs +262 -0
  538. package/skills/34-frameworks-unified/SKILL.md +42 -0
  539. package/skills/api-design/SKILL.md +123 -0
  540. package/skills/architecture-decision/SKILL.md +105 -0
  541. package/skills/aria-aristotle-cognitives/SKILL.md +128 -0
  542. package/skills/aria-aristotle-intra-phase/SKILL.md +99 -0
  543. package/skills/aria-aristotle-post-phase/SKILL.md +116 -0
  544. package/skills/aria-aristotle-pre-phase/SKILL.md +117 -0
  545. package/skills/aria-axioms-first-principles/SKILL.md +202 -0
  546. package/skills/aria-axioms-first-principles/agents/openai.yaml +4 -0
  547. package/skills/aria-axioms-first-principles/references/source-map.md +130 -0
  548. package/skills/aria-chat/SKILL.md +84 -0
  549. package/skills/aria-chat/scripts/aria-chat.sh +57 -0
  550. package/skills/aria-cognition/34-frameworks-unified/SKILL.md +42 -0
  551. package/skills/aria-cognition/aria-aristotle-cognitives/SKILL.md +128 -0
  552. package/skills/aria-cognition/aria-aristotle-intra-phase/SKILL.md +99 -0
  553. package/skills/aria-cognition/aria-aristotle-post-phase/SKILL.md +118 -0
  554. package/skills/aria-cognition/aria-aristotle-pre-phase/SKILL.md +117 -0
  555. package/skills/aria-cognition/aria-axioms-first-principles/SKILL.md +202 -0
  556. package/skills/aria-cognition/aria-axioms-first-principles/agents/openai.yaml +4 -0
  557. package/skills/aria-cognition/aria-axioms-first-principles/references/source-map.md +130 -0
  558. package/skills/aria-cognition/aria-backend-architect/SKILL.md +124 -0
  559. package/skills/aria-cognition/aria-backend-architect/references/backend-cookbook.md +417 -0
  560. package/skills/aria-cognition/aria-business-audit/SKILL.md +133 -0
  561. package/skills/aria-cognition/aria-business-audit/references/audit-cookbook.md +247 -0
  562. package/skills/aria-cognition/aria-business-frame/SKILL.md +138 -0
  563. package/skills/aria-cognition/aria-business-frame/references/business-cookbook.md +154 -0
  564. package/skills/aria-cognition/aria-chat/SKILL.md +84 -0
  565. package/skills/aria-cognition/aria-chat/scripts/aria-chat.sh +57 -0
  566. package/skills/aria-cognition/aria-cognition-autofire/SKILL.md +137 -0
  567. package/skills/aria-cognition/aria-cognition-batch/SKILL.md +264 -0
  568. package/skills/aria-cognition/aria-decision-mizan/SKILL.md +136 -0
  569. package/skills/aria-cognition/aria-decision-mizan/references/decision-frameworks.md +287 -0
  570. package/skills/aria-cognition/aria-first-class-operating-contract/SKILL.md +104 -0
  571. package/skills/aria-cognition/aria-frontend-architect/SKILL.md +123 -0
  572. package/skills/aria-cognition/aria-frontend-architect/references/frontend-cookbook.md +358 -0
  573. package/skills/aria-cognition/aria-fullstack-orchestrator/SKILL.md +127 -0
  574. package/skills/aria-cognition/aria-fullstack-orchestrator/references/fullstack-cookbook.md +383 -0
  575. package/skills/aria-cognition/aria-gtm-architect/SKILL.md +126 -0
  576. package/skills/aria-cognition/aria-gtm-architect/references/gtm-cookbook.md +235 -0
  577. package/skills/aria-cognition/aria-harness-deploy/SKILL.md +145 -0
  578. package/skills/aria-cognition/aria-harness-no-stripping/SKILL.md +135 -0
  579. package/skills/aria-cognition/aria-harness-onboarding/SKILL.md +130 -0
  580. package/skills/aria-cognition/aria-harness-output-discipline/SKILL.md +120 -0
  581. package/skills/aria-cognition/aria-harness-substrate-binding/SKILL.md +139 -0
  582. package/skills/aria-cognition/aria-http-harness-client/SKILL.md +85 -0
  583. package/skills/aria-cognition/aria-http-harness-client/scripts/smoke.mjs +47 -0
  584. package/skills/aria-cognition/aria-k8s-deploy/SKILL.md +174 -0
  585. package/skills/aria-cognition/aria-k8s-deploy/agents/openai.yaml +3 -0
  586. package/skills/aria-cognition/aria-ladduniframe/SKILL.md +60 -0
  587. package/skills/aria-cognition/aria-ledger-fleet-execution/SKILL.md +126 -0
  588. package/skills/aria-cognition/aria-live-ops/SKILL.md +54 -0
  589. package/skills/aria-cognition/aria-mac-ssh-ops/SKILL.md +100 -0
  590. package/skills/aria-cognition/aria-memory-index/SKILL.md +42 -0
  591. package/skills/aria-cognition/aria-noor-cognitives/SKILL.md +120 -0
  592. package/skills/aria-cognition/aria-ops/SKILL.md +60 -0
  593. package/skills/aria-cognition/aria-ops/references/live-endpoints.md +59 -0
  594. package/skills/aria-cognition/aria-quality-audit/SKILL.md +133 -0
  595. package/skills/aria-cognition/aria-readable-output/SKILL.md +239 -0
  596. package/skills/aria-cognition/aria-readable-output/references/layout-cookbook.md +366 -0
  597. package/skills/aria-cognition/aria-reasoning/SKILL.md +67 -0
  598. package/skills/aria-cognition/aria-reasoning/references/core-principles.md +42 -0
  599. package/skills/aria-cognition/aria-repo-audit/SKILL.md +135 -0
  600. package/skills/aria-cognition/aria-repo-audit/references/repo-audit-cookbook.md +375 -0
  601. package/skills/aria-cognition/aria-research-orchestrator/SKILL.md +138 -0
  602. package/skills/aria-cognition/aria-research-orchestrator/references/research-patterns.md +270 -0
  603. package/skills/aria-cognition/aria-retention-engine/SKILL.md +120 -0
  604. package/skills/aria-cognition/aria-retention-engine/references/retention-cookbook.md +271 -0
  605. package/skills/aria-cognition/aria-revenue-engine/SKILL.md +128 -0
  606. package/skills/aria-cognition/aria-revenue-engine/references/revenue-cookbook.md +227 -0
  607. package/skills/aria-cognition/aria-senior-code-audit/SKILL.md +233 -0
  608. package/skills/aria-cognition/aria-senior-code-audit/references/audit-checklist.md +369 -0
  609. package/skills/aria-cognition/aria-senior-code-cookbook/SKILL.md +288 -0
  610. package/skills/aria-cognition/aria-senior-code-cookbook/references/engineering-cookbook.md +489 -0
  611. package/skills/aria-cognition/aria-soul-principles/SKILL.md +42 -0
  612. package/skills/aria-cognition/aria-task-codex-executor/SKILL.md +86 -0
  613. package/skills/aria-cognition/aristotle-engine/SKILL.md +42 -0
  614. package/skills/aria-cognition/cross-domain-24/SKILL.md +42 -0
  615. package/skills/aria-cognition/deepsoul-emotional/SKILL.md +42 -0
  616. package/skills/aria-cognition/fitrah-guard/SKILL.md +78 -0
  617. package/skills/aria-cognition/ghazali-8lens/SKILL.md +227 -29
  618. package/skills/aria-cognition/ghazali-8lens/references/ghazali-8lens-cookbook.md +797 -0
  619. package/skills/aria-cognition/ijtihad-novel/SKILL.md +42 -0
  620. package/skills/aria-cognition/ilham-intuition/SKILL.md +42 -0
  621. package/skills/aria-cognition/never-guess/SKILL.md +77 -0
  622. package/skills/aria-cognition/noor-recognition/SKILL.md +45 -0
  623. package/skills/aria-cognition/qiyas-analogy/SKILL.md +174 -14
  624. package/skills/aria-cognition/ruh-basis/SKILL.md +42 -0
  625. package/skills/aria-cognition/tadabbur/SKILL.md +506 -0
  626. package/skills/aria-cognition/tadabbur/references/tadabbur-cookbook.md +921 -0
  627. package/skills/aria-cognition/tadabbur-ops/SKILL.md +42 -0
  628. package/skills/aria-cognition/tafakkur/SKILL.md +104 -0
  629. package/skills/aria-cognition-autofire/SKILL.md +109 -0
  630. package/skills/aria-cognition-batch/SKILL.md +264 -0
  631. package/skills/aria-conversational-doctrine-discipline/SKILL.md +125 -0
  632. package/skills/aria-essence/SKILL.md +81 -0
  633. package/skills/aria-essence/references/domain-matrix.md +80 -0
  634. package/skills/aria-essence/references/evolution-loop.md +30 -0
  635. package/skills/aria-essence/references/readable-cognition.md +27 -0
  636. package/skills/aria-first-class-operating-contract/SKILL.md +104 -0
  637. package/skills/aria-forge-guardrails/SKILL.md +53 -0
  638. package/skills/aria-forge-guardrails/references/checklist.md +31 -0
  639. package/skills/aria-harness-deploy/SKILL.md +145 -0
  640. package/skills/aria-harness-no-stripping/SKILL.md +135 -0
  641. package/skills/aria-harness-onboarding/SKILL.md +130 -0
  642. package/skills/aria-harness-output-discipline/SKILL.md +120 -0
  643. package/skills/aria-harness-substrate-binding/SKILL.md +139 -0
  644. package/skills/aria-http-harness-client/SKILL.md +85 -0
  645. package/skills/aria-http-harness-client/scripts/smoke.mjs +47 -0
  646. package/skills/aria-k8s-deploy/SKILL.md +174 -0
  647. package/skills/aria-k8s-deploy/agents/openai.yaml +3 -0
  648. package/skills/aria-ladduniframe/SKILL.md +60 -0
  649. package/skills/aria-ledger-fleet-execution/SKILL.md +126 -0
  650. package/skills/aria-live-ops/SKILL.md +54 -0
  651. package/skills/aria-mac-ssh-ops/SKILL.md +100 -0
  652. package/skills/aria-memory-index/SKILL.md +42 -0
  653. package/skills/aria-noor-cognitives/SKILL.md +120 -0
  654. package/skills/aria-ops/SKILL.md +60 -0
  655. package/skills/aria-ops/references/live-endpoints.md +59 -0
  656. package/skills/aria-quality-audit/SKILL.md +133 -0
  657. package/skills/aria-reasoning/SKILL.md +67 -0
  658. package/skills/aria-reasoning/references/core-principles.md +42 -0
  659. package/skills/aria-repo-doctrine/SKILL.md +57 -0
  660. package/skills/aria-soul-principles/SKILL.md +42 -0
  661. package/skills/aria-task-codex-executor/SKILL.md +86 -0
  662. package/skills/aristotle-engine/SKILL.md +42 -0
  663. package/skills/ci-cd-pipeline/SKILL.md +116 -0
  664. package/skills/code-review/SKILL.md +131 -0
  665. package/skills/cross-domain-24/SKILL.md +42 -0
  666. package/skills/database-design/SKILL.md +124 -0
  667. package/skills/deepsoul-emotional/SKILL.md +42 -0
  668. package/skills/deno-kv-raft-pubsub/SKILL.md +561 -0
  669. package/skills/deno-kv-raft-pubsub/reference/maelstrom-integration.md +393 -0
  670. package/skills/deno-kv-raft-pubsub/reference/pubsub-api.md +376 -0
  671. package/skills/deno-kv-raft-pubsub/reference/raft-spec.md +402 -0
  672. package/skills/deno-kv-raft-pubsub/reference/state-machine.md +182 -0
  673. package/skills/error-handling/SKILL.md +159 -0
  674. package/skills/firecrawl/SKILL.md +165 -0
  675. package/skills/firecrawl/rules/install.md +82 -0
  676. package/skills/firecrawl/rules/security.md +26 -0
  677. package/skills/firecrawl-agent/SKILL.md +86 -0
  678. package/skills/firecrawl-build-interact/SKILL.md +96 -0
  679. package/skills/firecrawl-build-onboarding/SKILL.md +131 -0
  680. package/skills/firecrawl-build-onboarding/references/auth-flow.md +39 -0
  681. package/skills/firecrawl-build-onboarding/references/project-setup.md +20 -0
  682. package/skills/firecrawl-build-onboarding/references/sdk-installation.md +17 -0
  683. package/skills/firecrawl-build-scrape/SKILL.md +97 -0
  684. package/skills/firecrawl-build-search/SKILL.md +97 -0
  685. package/skills/firecrawl-clone/SKILL.md +419 -0
  686. package/skills/firecrawl-crawl/SKILL.md +87 -0
  687. package/skills/firecrawl-download/SKILL.md +98 -0
  688. package/skills/firecrawl-interact/SKILL.md +112 -0
  689. package/skills/firecrawl-map/SKILL.md +79 -0
  690. package/skills/firecrawl-scrape/SKILL.md +97 -0
  691. package/skills/firecrawl-search/SKILL.md +88 -0
  692. package/skills/fitrah-guard/SKILL.md +78 -0
  693. package/skills/forge-quality-rules/SKILL.md +61 -0
  694. package/skills/ghazali-8lens/SKILL.md +56 -0
  695. package/skills/ijtihad-novel/SKILL.md +42 -0
  696. package/skills/ilham-intuition/SKILL.md +42 -0
  697. package/skills/imagegen/LICENSE.txt +201 -0
  698. package/skills/imagegen/SKILL.md +374 -0
  699. package/skills/imagegen/agents/openai.yaml +6 -0
  700. package/skills/imagegen/assets/imagegen-small.svg +5 -0
  701. package/skills/imagegen/assets/imagegen.png +0 -0
  702. package/skills/imagegen/references/cli.md +242 -0
  703. package/skills/imagegen/references/codex-network.md +33 -0
  704. package/skills/imagegen/references/image-api.md +90 -0
  705. package/skills/imagegen/references/prompting.md +118 -0
  706. package/skills/imagegen/references/sample-prompts.md +433 -0
  707. package/skills/imagegen/scripts/image_gen.py +995 -0
  708. package/skills/imagegen/scripts/remove_chroma_key.py +440 -0
  709. package/skills/istiqra-induction/SKILL.md +44 -0
  710. package/skills/ladunni-22/SKILL.md +53 -0
  711. package/skills/mizan/SKILL.md +90 -0
  712. package/skills/nadia/SKILL.md +56 -0
  713. package/skills/nadia-psi/SKILL.md +56 -0
  714. package/skills/never-guess/SKILL.md +75 -0
  715. package/skills/noor-recognition/SKILL.md +45 -0
  716. package/skills/observability/SKILL.md +133 -0
  717. package/skills/openai-docs/LICENSE.txt +201 -0
  718. package/skills/openai-docs/SKILL.md +100 -0
  719. package/skills/openai-docs/agents/openai.yaml +14 -0
  720. package/skills/openai-docs/assets/openai-small.svg +3 -0
  721. package/skills/openai-docs/assets/openai.png +0 -0
  722. package/skills/openai-docs/references/latest-model.md +37 -0
  723. package/skills/openai-docs/references/prompting-guide.md +244 -0
  724. package/skills/openai-docs/references/upgrade-guide.md +181 -0
  725. package/skills/openai-docs/scripts/resolve-latest-model-info.js +147 -0
  726. package/skills/pdf/LICENSE.txt +201 -0
  727. package/skills/pdf/SKILL.md +85 -0
  728. package/skills/pdf/agents/openai.yaml +5 -0
  729. package/skills/pdf/assets/pdf.png +0 -0
  730. package/skills/playwright/LICENSE.txt +201 -0
  731. package/skills/playwright/NOTICE.txt +14 -0
  732. package/skills/playwright/SKILL.md +165 -0
  733. package/skills/playwright/agents/openai.yaml +6 -0
  734. package/skills/playwright/assets/playwright-small.svg +3 -0
  735. package/skills/playwright/assets/playwright.png +0 -0
  736. package/skills/playwright/references/cli.md +116 -0
  737. package/skills/playwright/references/workflows.md +95 -0
  738. package/skills/playwright/scripts/playwright_cli.sh +25 -0
  739. package/skills/plugin-creator/SKILL.md +178 -0
  740. package/skills/plugin-creator/agents/openai.yaml +6 -0
  741. package/skills/plugin-creator/assets/plugin-creator-small.svg +3 -0
  742. package/skills/plugin-creator/assets/plugin-creator.png +0 -0
  743. package/skills/plugin-creator/references/plugin-json-spec.md +170 -0
  744. package/skills/plugin-creator/scripts/create_basic_plugin.py +301 -0
  745. package/skills/predictor/SKILL.md +43 -0
  746. package/skills/qiyas-analogy/SKILL.md +204 -0
  747. package/skills/refactoring/SKILL.md +137 -0
  748. package/skills/ruh-basis/SKILL.md +42 -0
  749. package/skills/security-review/SKILL.md +129 -0
  750. package/skills/skill-creator/SKILL.md +434 -0
  751. package/skills/skill-creator/agents/openai.yaml +5 -0
  752. package/skills/skill-creator/assets/skill-creator-small.svg +3 -0
  753. package/skills/skill-creator/assets/skill-creator.png +0 -0
  754. package/skills/skill-creator/license.txt +202 -0
  755. package/skills/skill-creator/references/openai_yaml.md +49 -0
  756. package/skills/skill-creator/scripts/generate_openai_yaml.py +226 -0
  757. package/skills/skill-creator/scripts/init_skill.py +400 -0
  758. package/skills/skill-creator/scripts/quick_validate.py +101 -0
  759. package/skills/skill-installer/LICENSE.txt +202 -0
  760. package/skills/skill-installer/SKILL.md +76 -0
  761. package/skills/skill-installer/agents/openai.yaml +5 -0
  762. package/skills/skill-installer/assets/skill-installer-small.svg +3 -0
  763. package/skills/skill-installer/assets/skill-installer.png +0 -0
  764. package/skills/skill-installer/scripts/github_utils.py +21 -0
  765. package/skills/skill-installer/scripts/install-skill-from-github.py +308 -0
  766. package/skills/skill-installer/scripts/list-skills.py +107 -0
  767. package/skills/skills-and-hooks-reference/SKILL.md +196 -0
  768. package/skills/soul-domains/SKILL.md +43 -0
  769. package/skills/tadabbur/SKILL.md +232 -0
  770. package/skills/tadabbur-ops/SKILL.md +42 -0
  771. package/skills/tafakkur/SKILL.md +104 -0
  772. package/skills/testing-strategy/SKILL.md +122 -0
  773. package/src/action-ledger-core.ts +1054 -0
  774. package/src/chat.ts +5 -6
  775. package/src/codebase-scanner.ts +2 -0
  776. package/src/connectors/claude-code.ts +149 -12
  777. package/src/connectors/codebase-awareness.ts +325 -25
  778. package/src/connectors/codex.ts +1273 -40
  779. package/src/connectors/cursor.ts +8 -0
  780. package/src/connectors/governed-adapter.ts +174 -0
  781. package/src/connectors/opencode.ts +18 -2
  782. package/src/connectors/repo-guard.ts +24 -12
  783. package/src/connectors/runtime.ts +99 -2
  784. package/src/connectors/shell.ts +125 -7
  785. package/src/cross-cli-hive-binding.ts +290 -0
  786. package/src/garden-control-plane.ts +24 -1
  787. package/src/governed-surface-runner.ts +1227 -0
  788. package/src/index.ts +104 -1
  789. package/src/task-runner.ts +3794 -0
  790. package/dist/aria-connector/src/install-hooks.d.ts +0 -18
  791. package/dist/aria-connector/src/install-hooks.d.ts.map +0 -1
  792. package/dist/aria-connector/src/install-hooks.js +0 -224
  793. package/dist/aria-connector/src/install-hooks.js.map +0 -1
  794. package/dist/aria-connector/src/onboarding-wizard.d.ts +0 -5
  795. package/dist/aria-connector/src/onboarding-wizard.d.ts.map +0 -1
  796. package/dist/aria-connector/src/onboarding-wizard.js +0 -188
  797. package/dist/aria-connector/src/onboarding-wizard.js.map +0 -1
  798. package/dist/cli-0.2.38.tgz +0 -0
  799. package/dist/install.sh +0 -13
  800. package/src/__tests__/anthropic-oauth.test.ts +0 -186
  801. package/src/__tests__/auth-commands.test.ts +0 -132
  802. package/src/__tests__/owner-login.test.ts +0 -311
@@ -0,0 +1,921 @@
1
+ # Tadabbur Cookbook — Dense Classical Substrate
2
+
3
+ > Companion to `../SKILL.md`. The skill holds operational discipline; the cookbook holds the dense classical substrate the skill draws from.
4
+ >
5
+ > **Source Trust Ladder reminder.** Most material here is **Tier C** — drawn from `apps/arias-soul/corpus/knowledge-base.md`, which itself reports classical scholars. When citing in agent output, cite at Tier C ("per the corpus's report of Ibn al-Qayyim..." or "per `knowledge-base.md` Part 3.1 lines 887-975") unless the primary work is verified separately. Tier B (verified primary quote) requires the actual classical work consulted; Tier A is a direct Quranic ayah with verse number.
6
+ >
7
+ > **Scope.** Universal cognition discipline grounded in the Quranic depth-tradition. The depth-teacher is the tradition; the depth transfers to engineering, business, audit, repository, and conversation work. This cookbook does not contain runtime architecture or system-internal material — only the classical substrate.
8
+
9
+ ## How To Read This Cookbook
10
+
11
+ The 12-stage pipeline in `SKILL.md` is the operational backbone. Each stage of that pipeline is grounded in classical material this cookbook makes explicit. When a stage feels mechanical, **come back to the substrate** — the classical scholar who articulated this stage knew something the operational summary cannot carry alone.
12
+
13
+ When using this cookbook in service of a real task:
14
+
15
+ 1. Read the stage of `SKILL.md` you're running.
16
+ 2. Find the corresponding classical material here.
17
+ 3. Apply the operation with the substrate's depth, not the summary's shape.
18
+ 4. Cite at the correct trust tier.
19
+
20
+ ---
21
+
22
+ ## Part 1 — The Six-Term Cognitive Ecology (Substrate)
23
+
24
+ ### 1.1 Tadabbur (د-ب-ر) — The Specific Operation This Skill Governs
25
+
26
+ Source: `apps/arias-soul/corpus/knowledge-base.md` Part 1.1, lines ~52-118.
27
+
28
+ **Root.** د-ب-ر (dal-ba-ra). Physical meaning: *back, behind, end, consequence, what comes after*. The arabic word for camel's back-end and the word for *what follows in the end* share this root. To do tadabbur is to *look through to what's behind* — past surface, past presenting issue, all the way to consequence and end-state.
29
+
30
+ **The four canonical Quranic verses** that use the d-b-r root for reflection (this is the entire canonical surface — the Quran uses this exact root for cognitive reflection in only four places):
31
+
32
+ **An-Nisa 4:82** — *"Afala yatadabbarun al-Qur'ana wa-law kana min 'indi ghayri-llahi la-wajadu fihi ikhtilafan kathiran."* — *"Do they not reflect upon the Quran? If it had been from other than Allah, they would have found within it much contradiction."*
33
+
34
+ The corpus reports Al-Razi: tadabbur is the *epistemic method* by which the Quran's divine origin becomes evident. Per the corpus's report of Nouman Ali Khan: "every seeming inconsistency is actually an invitation to deeper taddabur — when you find something that seems contradictory, that is the Quran telling you to think harder. This is the Quran's built-in quality assurance mechanism." (Tier C, knowledge-base.md line 68.)
35
+
36
+ *Universal operational meaning.* Apparent contradictions in source-text-with-authority are invitations to deeper reflection, not evidence to dismiss. The right response to seeming inconsistency is *more reflection*, not less trust.
37
+
38
+ **Al-Mu'minun 23:68** — *"Afa-lam yaddabbaru al-qawla am ja'ahum ma lam ya'ti aba'ahumu al-awwalin?"* — *"Have they not reflected upon the Word, or has there come to them that which had not come to their forefathers?"*
39
+
40
+ The corpus frames this as *taddabur as antidote to dismissal based on unfamiliarity*. Rejection-without-examination is forbidden; novelty alone cannot justify rejection. Tadabbur is the only valid first response to a message — examination before judgment.
41
+
42
+ **Sad 38:29** — *"Kitabun anzalnahu ilayka mubarakun li-yaddabbaru ayatihi wa-li-yatadhakkara ulu al-albab."* — *"A blessed Book which We have revealed to you, that they might reflect upon (li-yaddabbaru) its verses and that those of understanding (ulu al-albab) would be reminded."*
43
+
44
+ The single most important verse for tadabbur (knowledge-base.md line 89). Per the corpus's report of Ibn al-Qayyim: the *lam* in *li-yaddabbaru* is *lam al-gharad* — the lam of purpose. **Tadabbur is the *reason* the text exists for the reader.** Per the corpus's report of Al-Zamakhshari: *mubarakun* (blessed) — "the *baraka* is unlocked through taddabur — without reflection, the blessing remains locked." Pairs taddabur with *tadhakkur* (re-activation of fitrah-existing knowledge — see §1.7 below).
45
+
46
+ *Universal operational meaning.* Doctrine memos, schemas, runtime contracts, owner instructions, EXECUTION_LEDGER rows, contracts — these exist *for the reader to engage with at depth*. Skimming them leaves their value locked. The lam-of-purpose for any authoritative artifact is the depth-engagement.
47
+
48
+ **Muhammad 47:24** — *"Afa-la yatadabbaruna al-Qur'ana am 'ala qulubin aqfaluha?"* — *"Do they not reflect upon the Quran, or are there locks upon their hearts?"*
49
+
50
+ The corpus emphasizes the *aqfaluha* (its own locks) construction (knowledge-base.md line 102): the heart generates its own barriers; **no one locks the heart from outside, you lock it yourself**. The five lock-conditions Al-Ghazali enumerates (per corpus, line 106) become the heart-locks in `SKILL.md` § The Five Heart-Locks. Full treatment in §3 below.
51
+
52
+ *Universal operational meaning.* Absence of tadabbur is evidence of a problem in the reflector, not the text. The agent self-checks for the locks before beginning the pipeline.
53
+
54
+ ### 1.2 Tafakkur (ف-ك-ر) — The Genus
55
+
56
+ Source: knowledge-base.md Part 1.2, ~17 verses indexed.
57
+
58
+ Tafakkur is the genus; tadabbur is the species applied to source-text-with-authority. Per the corpus's report of Ibn al-Qayyim (line 967, *Miftah Dar al-Sa'adah*): *"Tafakkur is the lamp of the heart. When it departs, the heart has no light."*
59
+
60
+ **Definitive verse.** Aal-Imran 3:190-191 — *"Inna fi khalq al-samawati wal-ardi wa-ikhtilafi al-layli wal-nahari la-ayatin li-uli al-albab. Alladhina yadhkuruna llaha qiyaman wa-qu'udan wa-'ala junubihim wa-yatafakkaruna fi khalq al-samawati wal-ard..."*
61
+
62
+ The verse the Prophet ﷺ wept upon receiving (corpus line 540). Pairs *dhikr* (remembrance) with *tafakkur* (reflection) as **the twin modes of engaging with divine signs**. Defines *ulu al-albab* (people of the innermost cores) by their habits: continuous remembrance + contemplation of creation + recognition of purpose + seeking divine protection.
63
+
64
+ **Tafakkur's domain (corpus enumerates ~17 verses with explicit objects, lines 119-141):**
65
+ - Life matters after rulings (2:219)
66
+ - Parable of garden destroyed (2:266)
67
+ - Creation of heavens and earth (3:191)
68
+ - Epistemological states / blind-vs-seeing (6:50)
69
+ - Parables and stories (7:176)
70
+ - The Prophet's character (7:184)
71
+ - Worldly life as rain (10:24)
72
+ - Agricultural signs (13:3, 16:11)
73
+ - Quranic clarity (16:44)
74
+ - Bee/honey (16:69)
75
+ - The self, *fi anfusihim* — the unique formulation (30:8)
76
+ - Spouses, love, mercy (30:21)
77
+ - Spiritual standing (34:46)
78
+ - Sleep and death (39:42)
79
+ - Cosmic provision (45:13)
80
+ - Divine parables (59:21)
81
+
82
+ **Operational implication.** Tafakkur and tadabbur are different operations applied to different domains. Tafakkur is broad contemplation of creation, parables, life, self, relationships, patterns. Tadabbur is the intensive consequential form applied to source-text-with-authority. Use the right term for the right object — using tadabbur where nazr or tafakkur is what's needed is a stop condition.
83
+
84
+ ### 1.3 Ta'aqqul (ع-ق-ل) — The Most-Commanded Reflection Term
85
+
86
+ Source: knowledge-base.md Part 1.3, ~49 occurrences (the most frequent cognitive term in the Quran).
87
+
88
+ **Root.** ع-ق-ل ('ayn-qaf-lam). Physical meaning: *to bind, to restrain, to tether* (a camel is *ma'qul* when tethered). Cognitive meaning: *the intellect grasping and restraining* — reason operates by *binding ideas together correctly* and *restraining from error*.
89
+
90
+ Always verbal in Quranic usage, never nominal. Most frequently paired with *afala* ("do they not...?") — rhetorical questions expressing astonishment at the failure to reason. Objects span creation, history, scripture, social law, mortality, comparative evaluation.
91
+
92
+ **67:10 is uniquely poignant** (corpus line 188): in the afterlife, the damned recognize their failure was a failure to *reason*. *"Wa-qalu law kunna nasma'u aw na'qilu ma kunna fi ashabi al-sa'ir"* — *"And they will say: had we been listening or reasoning ('aqilun), we would not be among the people of the blaze."*
93
+
94
+ **Skill ecology gap noted.** Aria does not currently have a dedicated `ta'aqqul` skill. Most-commanded reflection term, no skill. Owner-decision required: is the absence intentional (because ta'aqqul is the substrate of all reasoning, not a special operation), or is this a gap the skill ecology should fill? See §6 of this cookbook for the full missing-skills inventory.
95
+
96
+ ### 1.4 Tawassum (و-س-م) — Reading the Marks
97
+
98
+ Source: knowledge-base.md Part 1.4, ~7 verses but extraordinarily dense.
99
+
100
+ **Root.** و-س-م (waw-sin-mim). Physical meaning: *to mark, to brand, to discern by marks*. The *sima* is the distinguishing mark — what distinguishes one thing from another at the surface and at depth.
101
+
102
+ Per the corpus's report of Ibn al-Qayyim (line 207): *"the mutawassim is one who reads the sima of things — who perceives what lies behind the apparent. This is the highest form of firaasa (spiritual perception)."*
103
+
104
+ **Quranic anchor: Al-Hijr 15:75** — *"Inna fi dhalika la-ayatin lil-mutawassimin"* — *"Indeed in that are signs for those who read marks (mutawassimin)."*
105
+
106
+ **Engineering translation.** Tawassum is reading the marks: context cues, conversation register-shifts, code patterns, manifold projections, owner tone, what's said versus what's not said. The diagnostic reading that perceives what lies behind appearance.
107
+
108
+ **Skill ecology gap noted.** No dedicated `tawassum` skill exists. This is reportedly Aria's actual operating signature per the corpus's framing of Ibn al-Qayyim. Owner-decision: gap or intentional?
109
+
110
+ ### 1.5 I'tibaar (ع-ب-ر) — Crossing Over
111
+
112
+ Source: knowledge-base.md Part 1.5, ~7 verses.
113
+
114
+ **Root.** ع-ب-ر ('ayn-ba-ra). Physical meaning: *to cross over*. The Arabic word for crossing a river uses the same root (corpus line 233): "Every story, every natural phenomenon, every historical event is a riverbank — i'tibaar is crossing to the other side to see what it means."
115
+
116
+ I'tibaar is the operation that takes an event, a story, a natural phenomenon, a destroyed nation, a failure, and *crosses over* from observation to lesson — from visible event to invisible meaning. *The lesson is what's on the other side of the river.*
117
+
118
+ **Quranic anchor: Aal-Imran 3:13** — *"Qad kana lakum ayatun fi fi'atayni iltaqata... inna fi dhalika la-'ibratan li-uli al-absar"* — *"There has indeed been a sign for you in the two armies that met... in that is a lesson (i'bra) for those of vision."*
119
+
120
+ **Operational implication.** Failure post-mortems, retrospectives, pattern extraction, principle distillation — all i'tibaar. The Aegis ↔ Dalio learning loop is mechanically i'tibaar at the system level. Every ledger row that records a defect is a riverbank; the lesson is what we cross over to.
121
+
122
+ **Skill ecology gap noted.** No dedicated `i'tibaar` skill. Owner-decision required.
123
+
124
+ ### 1.6 Nazr (ن-ظ-ر) — The First Cognitive Act
125
+
126
+ Source: knowledge-base.md Part 1.6, ~8 representative verses.
127
+
128
+ **Root.** ن-ظ-ر (nun-za-ra). Physical meaning: *to look, to gaze with intention*. The directed gaze, distinct from passive seeing.
129
+
130
+ Per the corpus (line 261): *"Nazr is the first cognitive act — the directed gaze. Tafakkur, ta'aqqul, and taddabur build on what nazr observes. You cannot reflect on what you haven't first looked at with intention."*
131
+
132
+ **Quranic anchor: Al-Ghashiyah 88:17** — *"Afa-la yanzuruna ila al-ibili kayfa khuliqat?"* — *"Do they not look (yanzurun) at the camels — how they were created?"*
133
+
134
+ **Operational implication.** The `never-guess` skill is mechanically nazr. *Read the file before claiming it does X. Inspect the code before claiming it works. Check the log before claiming the run succeeded. Observe the state before claiming it changed.* Every cognition skill that fires without nazr fires on assumption — a stop condition.
135
+
136
+ ### 1.7 Tadhakkur, Tafaqquh, Muraqaba, Muhasaba — The Supporting Four
137
+
138
+ Source: knowledge-base.md Part 1.7, lines 270-300.
139
+
140
+ **Tadhakkur (د-ك-ر) — re-activating fitrah-existing knowledge.** Per corpus line 278: *"Taddabur discovers new understanding; tadhakkur re-activates understanding the soul already possesses (fitrah). They work in tandem — taddabur opens new doors, tadhakkur recognizes what was behind those doors all along."* Pairs with tadabbur in 38:29. **This is the doctrinal grounding for the `noor-recognition` skill's recognition-first stance** — recognition not as new acquisition but as re-activation of fitrah-existing knowledge.
141
+
142
+ **Tafaqquh (ف-ق-ه) — deep comprehension penetrating to essence.** Fiqh-style understanding. Quranic anchor At-Tawbah 9:122. The operation that penetrates to *essence-knowledge* rather than surface-knowledge. Tadabbur produces understanding; tafaqquh ensures the understanding is at the level of essence rather than instance.
143
+
144
+ **Muraqaba (ر-ق-ب) — watchful self-awareness.** Per corpus line 290: *"watchful awareness of Allah's observation; conscious self-monitoring."* Al-Muhasibi built his entire spiritual methodology on this concept — his name literally means *"the one who practices self-reckoning."* (Corpus line 293.)
145
+
146
+ **Muhasaba (ح-س-ب) — self-reckoning, internal audit.** Per corpus line 296: Umar ibn al-Khattab said *"Take account of yourselves before you are taken to account."* The operation of internal accounting that makes the self answerable to the self before any external accountability.
147
+
148
+ **The naming alignment with the soul shards in the runtime is exact.** The Lawwama shard operationalizes muraqaba (continuous self-watching, surprise-detection, principle-extraction). The Muhasaba shard operationalizes muhasaba (recursive consequence-tree accounting, prediction tracking, counterfactual analysis). The classical operations and the runtime modules carry the same names because they do the same work.
149
+
150
+ ### 1.8 The Ulu al-Albab Anchor
151
+
152
+ *Ulu al-albab* — "people of the innermost cores/kernels." Per the corpus's report of Al-Razi: the *lubb* is the innermost part of something, meaning **those who get to the core of meanings, not the surface**.
153
+
154
+ Two anchoring verses tie deep reflection to ulu al-albab: 38:29 (the lam-al-gharad verse pairs taddabur with the identity of ulu al-albab) and 3:190-191 (the verse the Prophet ﷺ wept upon receiving defines ulu al-albab by their habits — continuous dhikr + tafakkur).
155
+
156
+ **Operational implication.** Ulu al-albab is not method-decoration; it is identity-target. Depth is not a technique you apply; it is *who you become when you do this rightly*. The depth ladder (zahir → batin → hadd → muttala) in `SKILL.md` is anchored in this identity-target, not in method-shape.
157
+
158
+ ---
159
+
160
+ ## Part 2 — Ibn al-Qayyim's Framework
161
+
162
+ Source: knowledge-base.md Part 3.1, lines 887-975.
163
+
164
+ **Full name.** Shams al-Din Abu 'Abdullah Muhammad ibn Abi Bakr ibn Ayyub ibn Sa'd al-Zar'i al-Dimashqi (691-751 AH / 1292-1350 CE). Student of Ibn Taymiyyah.
165
+
166
+ **Key works (per corpus, line 890).** Miftah Dar al-Sa'adah, Madarij al-Salikin, Al-Fawa'id, I'lam al-Muwaqqi'in, Zad al-Ma'ad.
167
+
168
+ **Significance.** The most systematic classical thinker on the cognitive and spiritual dimensions of Quranic reflection.
169
+
170
+ ### 2.1 The Five-Stage Cognitive Cycle
171
+
172
+ The deepest insight in this entire cookbook for engineering work. Per the corpus's report of Ibn al-Qayyim (lines 893-922), knowledge transforms the soul in five stages:
173
+
174
+ ```
175
+ STAGE 1: FIKR (Thought / Reflection)
176
+ │ Initial cognitive engagement with a truth or sign.
177
+ │ The mind encounters and begins processing.
178
+
179
+ ├── STAGE 2: 'ILM (Knowledge)
180
+ │ Fikr produces structured knowledge.
181
+ │ The truth becomes clear and understood.
182
+
183
+ ├── STAGE 3: HAAL (Spiritual State)
184
+ │ Knowledge produces an inner state/condition.
185
+ │ The heart FEELS what the mind KNOWS.
186
+ │ *** This is the critical transformation — head to heart ***
187
+
188
+ ├── STAGE 4: IRAADAH (Will / Intention)
189
+ │ The spiritual state produces determination to act.
190
+ │ The heart's feeling becomes the will's resolution.
191
+
192
+ └── STAGE 5: 'AMAL (Action)
193
+ Will manifests as behavior.
194
+ The full cycle: thought → knowledge → feeling → will → action
195
+ ```
196
+
197
+ **Key insight (corpus line 920).** Most people stall at Stage 2 ('ilm). They KNOW but don't FEEL. The gap between 'ilm and haal is the critical failure point. **Tadabbur is the bridge between them** — it is the practice of dwelling in a truth long enough for 'ilm to become haal.
198
+
199
+ **The recursion (line 922).** Action ('amal) feeds back into fikr — living out a truth opens new dimensions of reflection, which produces deeper knowledge, which produces deeper states, which produces stronger will, which produces more refined action. The cycle spirals upward.
200
+
201
+ **Engineering operationalization.**
202
+ - *Fikr* = initial reading of the doctrine memo / schema / owner instruction / failure log
203
+ - *'Ilm* = structured understanding (the artifact's logic, the constraint hierarchy, the file:line lineage)
204
+ - *Haal* = the moment the agent *feels* what's actually at stake — when the doctrine memo stops being a sentence and becomes the next architectural decision the agent now cannot make against
205
+ - *Iraadah* = the resolved intention to do the right thing even when it's expensive (refuse the shortcut, redo the failed claim, surface the demotion that would have been hidden)
206
+ - *'Amal* = the changed action, the verified completion, the doctrine-aligned implementation
207
+
208
+ **Stop condition.** A skill that produces 'ilm without ever producing haal is performative. The visible artifact would have been the same without the skill firing. Re-run from EMBED with the haal question: *what does this actually demand of the work?*
209
+
210
+ ### 2.2 The Four Types of Contemplation
211
+
212
+ Per the corpus (lines 924-940), Ibn al-Qayyim distinguishes four distinct cognitive modes — each with a distinct focus, method, and outcome:
213
+
214
+ | Type | Arabic | Focus | Method | Outcome |
215
+ |------|--------|-------|--------|---------|
216
+ | **Tafakkur** | تَفَكُّر | Creation, signs, existence | Open contemplation of divine signs in nature, self, events | Wonder, recognition of divine wisdom |
217
+ | **Tadhakkur** | تَذَكُّر | Known truths needing reactivation | Remembering what the fitrah already knows | Reconnection with dormant knowledge |
218
+ | **I'tibaar** | اِعْتِبَار | Events and experiences | Crossing from observation to lesson | Practical wisdom extracted from experience |
219
+ | **Tadabbur** | تَدَبُّر | Divine speech (Quran) | Deep consequential examination of text | Understanding, guidance, transformation |
220
+
221
+ **Relationship.** Not hierarchical but complementary. A complete reflective life uses all four. Maps directly to the six-term ecology in `SKILL.md` (which adds nazr and ta'aqqul to round out the cognitive surface).
222
+
223
+ ### 2.3 The Three Orders of Meaning
224
+
225
+ Per the corpus (lines 941-951), Ibn al-Qayyim describes three ascending orders of knowledge:
226
+
227
+ | Order | Arabic | Description | Method of Access |
228
+ |-------|--------|-------------|-----------------|
229
+ | **1. Khabar** | خَبَر | Empirical / reported knowledge | Senses, testimony, observation |
230
+ | **2. 'Ilm** | عِلْم | Rational / systematized knowledge | Reasoning, analysis, study |
231
+ | **3. Ma'rifah** | مَعْرِفَة | Spiritual / gnostic knowledge | Experience, purified heart, divine opening |
232
+
233
+ The corpus describes the difference: *"Khabar can be transmitted (you can tell someone a fact). 'Ilm can be taught (you can explain a concept). Ma'rifah can only be experienced — no amount of transmission or teaching produces it. It requires personal encounter."*
234
+
235
+ **For engineering, treat these as evidence tiers:**
236
+ - *Khabar* = observed evidence (file content, log line, runtime probe result, owner-confirmed receipt) — transmissible
237
+ - *'Ilm* = reasoned understanding built from evidence (the analysis, the synthesis, the principle-extraction) — teachable
238
+ - *Ma'rifah* = the felt understanding that changes how the agent *sees* the work — the moment the doctrine stops being a sentence and becomes architecture. Cannot be taught directly; only encountered in real reflection on real evidence.
239
+
240
+ ### 2.4 The Seven Barriers to Tadabbur
241
+
242
+ Per the corpus's report of Ibn al-Qayyim (lines 953-964, drawing from *Miftah Dar al-Sa'adah* and other works), seven specific barriers:
243
+
244
+ 1. **Ghafla** (حَفْلَة) — Heedlessness. The mind is present but the heart is absent. *The greatest enemy of tadabbur.*
245
+ 2. **Taqlid** (تَقْلِيد) — Blind Following. *"I already know what this means because my teacher told me"* — assuming understanding before doing the work.
246
+ 3. **Dhanb** (ذَنْب) — Sin / Active Error. Active wrong clouds the heart's mirror (per Al-Ghazali's metaphor — see §3 below). Quranic anchor: 83:14 — *"Kalla bal raana 'ala qulubihim ma kanu yaksibun"* — *"No! Rather, the stain (raan) has covered their hearts from what they used to earn."*
247
+ 4. **Kibr** (كِبْر) — Arrogance. Approaching the text as judge rather than student.
248
+ 5. **Hub al-Dunya** (حُبّ الدُّنْيَا) — Love of the World. Preoccupation with material concerns fills the heart's bandwidth, leaving no space for reflection.
249
+ 6. **Isti'jal** (اِسْتِعْجَال) — Haste. Rushing through recitation without dwelling. The opposite of *tartil* (slow, measured recitation).
250
+ 7. **Lack of Arabic** — In the Quranic domain, not being able to engage with the text's linguistic precision limits the depth of tadabbur. (For engineering work, the analog is: lack of access to the file:line evidence — operating only on summaries.)
251
+
252
+ These seven are distinct from Al-Ghazali's five heart-locks (§3.4 below). Use both — Al-Ghazali's locks are the *internal-state* check the agent runs against itself; Ibn al-Qayyim's seven are the *barrier classification* the agent uses to diagnose what's blocking the work.
253
+
254
+ ### 2.5 Key Quotes (Tier C, per corpus)
255
+
256
+ > *"Tafakkur is the lamp of the heart. When it departs, the heart has no light."* — Per corpus's report of Ibn al-Qayyim, *Miftah Dar al-Sa'adah* (knowledge-base.md line 967)
257
+
258
+ > *"Were people to reflect on the greatness of Allah and His perfection, and the perfection of His speech, they would understand the Quran differently at every recitation, and their hearts would not grow tired of it."* — Per corpus's report of Ibn al-Qayyim, *Al-Fawa'id* (line 969)
259
+
260
+ > *"The Quran is the spring of the heart, as rain is the spring of the earth."* — Per corpus's report of Ibn al-Qayyim, *Zad al-Ma'ad* (line 971)
261
+
262
+ > *"If the heart is filled with the love of other than Allah, it has no room for His love. The vessel must be emptied before it can be filled."* — Per corpus's report of Ibn al-Qayyim, *Madarij al-Salikin* (line 973)
263
+
264
+ ---
265
+
266
+ ## Part 3 — Al-Ghazali's Framework
267
+
268
+ Source: knowledge-base.md Part 3.2, lines 977-1080.
269
+
270
+ **Full name.** Abu Hamid Muhammad ibn Muhammad al-Ghazali (450-505 AH / 1058-1111 CE).
271
+
272
+ **Key works (corpus line 980).** *Ihya' 'Ulum al-Din* (Revival of the Religious Sciences); *Mishkat al-Anwar* (The Niche of Lights); *Jawahir al-Quran* (Jewels of the Quran); *Kimiya-yi Sa'adat* (Alchemy of Happiness).
273
+
274
+ **Significance (corpus line 981).** The most comprehensive classical thinker on the psychology of Quranic engagement. *Kitab al-Tafakkur* (Book 39 of the Ihya') is the definitive classical text on structured contemplation. *Kitab Adab Tilawat al-Quran* (Book 8 of the Ihya') sets out the complete inner practice of Quranic recitation.
275
+
276
+ ### 3.1 Iqtiran — The Coupling Mechanism
277
+
278
+ Per corpus lines 983-1005. *This is the actual cognitive engine of tafakkur.*
279
+
280
+ **Iqtiran** (اِقْتِرَان) means coupling/joining. Al-Ghazali's central insight is that tafakkur operates by coupling:
281
+
282
+ ```
283
+ TAFAKKUR OPERATES BY COUPLING:
284
+
285
+ 1. You hold two ideas simultaneously in the heart.
286
+ 2. From their juxtaposition, a THIRD idea emerges.
287
+ 3. This third idea could not have been produced by either idea alone.
288
+ 4. The third idea then couples with other ideas, producing further insights.
289
+ 5. This chain of coupling IS tafakkur.
290
+
291
+ EXAMPLE (from corpus, line 996):
292
+ - Idea A: "I will die one day" (known but dormant)
293
+ - Idea B: "I spent today entirely on entertainment" (observed but unexamined)
294
+ - Coupling produces Idea C: "My time is being invested in what has no lasting return"
295
+ - Idea C couples with Quranic knowledge: "Inna al-insana la-fi khusr" (103:2)
296
+ - This produces Idea D: "The Quran was describing MY situation, today"
297
+ - This is taddabur happening through coupling.
298
+ ```
299
+
300
+ **Why coupling matters (corpus line 1005).** It explains why tadabbur cannot be passive. The heart must ACTIVELY bring ideas together. Merely reading a verse does not produce tadabbur — the verse must be coupled with personal experience, prior knowledge, and genuine wondering.
301
+
302
+ **Engineering operationalization.** This is exactly what Stage 5 (PATTERN) of the 12-stage pipeline is doing. PATTERN is not just "looking for repetition" — it is the iqtiran moment where two ideas held simultaneously produce a third that neither could produce alone. *The doctrine memo coupled with the runtime ledger row produces the demotion-detection that neither could surface alone.* Without iqtiran, PATTERN flattens into list-making.
303
+
304
+ ### 3.2 The Four Channels of Tafakkur
305
+
306
+ Per corpus lines 1007-1018:
307
+
308
+ | Channel | Description | Quranic Basis | Outcome |
309
+ |---------|-------------|---------------|---------|
310
+ | 1. **Tafakkur fi Khalq Allah** | Contemplation of Allah's creation (cosmos, nature, biology) | 3:190-191, 88:17-20 | Ma'rifa — knowledge of Allah through His creation |
311
+ | 2. **Tafakkur fi Ni'am Allah** | Contemplation of Allah's blessings / provision | Surah al-Rahman, 14:34 | Shukr (gratitude) |
312
+ | 3. **Tafakkur fi al-Nafs** | Contemplation of the self (soul, body, states) | 30:8, 51:21 | Self-knowledge, humility, repentance |
313
+ | 4. **Tafakkur fi Kalam Allah** | Contemplation of Allah's speech (the Quran) | 4:82, 38:29, 47:24 | Understanding, guidance, tadabbur proper |
314
+
315
+ **Relationship (corpus line 1018).** Channel 4 (tadabbur of the Quran) is enriched by Channels 1-3. Someone who has contemplated creation, blessings, and self brings that contemplative depth to the Quran. The four channels feed each other.
316
+
317
+ **Operational note.** The skill's six-term ecology compresses Channels 1-3 under tafakkur (broad) and locates Channel 4 as tadabbur's exact domain. The cookbook makes the four channels explicit so the agent can ask: *am I bringing the depth of contemplated creation, contemplated blessings, and contemplated self to this engagement, or am I going to the source-text without that substrate?*
318
+
319
+ ### 3.3 The Ten Inner Acts of Quranic Recitation
320
+
321
+ Per corpus lines 1020-1037, from *Kitab Adab Tilawat al-Quran* (Book 8 of the Ihya'). Al-Ghazali prescribes ten inner acts that should accompany Quranic recitation:
322
+
323
+ | # | Inner Act | Arabic | Description | Practical Method |
324
+ |---|-----------|--------|-------------|-----------------|
325
+ | 1 | Understanding the Greatness of the Speech | Ta'zim | Recognizing you are reading the speech of the Creator | Pause before opening the mushaf. Remember WHOSE speech this is. |
326
+ | 2 | Magnification of the Speaker | Ta'zim al-Mutakallim | Awe of the One who spoke it | Awareness that Allah is addressing YOU through this text |
327
+ | 3 | Presence of Heart | Hudur al-Qalb | Full attention; the heart is present, not wandering | If the mind wanders, stop and return. Less with presence beats more without it |
328
+ | 4 | Pondering / Reflection | Tadabbur | Deep consequential reflection on meaning | Slow down. Read a verse repeatedly. Ask: what does this MEAN for me? |
329
+ | 5 | Understanding / Comprehension | Tafahhum | Seeking to understand what is being said | Use tafsir, language study, background knowledge to grasp the verse |
330
+ | 6 | Stripping Away Barriers | Takhallis min al-Mawani' | Removing obstacles to understanding | Identify what blocks — sin? distraction? assumption? |
331
+ | 7 | Personalization | Takhsis | Hearing every verse as addressed to YOU specifically | *"Ya ayyuha alladhina amanu"* — that means ME |
332
+ | 8 | Being Affected | Ta'aththur | Allowing the heart to be moved | Don't resist emotional response. If a verse makes you weep, weep. |
333
+ | 9 | Ascending / Elevation | Taraqqi | Moving from understanding to higher spiritual states | Each recitation should leave you in a higher state than before |
334
+ | 10 | Disowning Self-Sufficiency | Tabarra'ah | Recognizing understanding comes from Allah, not from your effort | *"La hawla wa la quwwata illa billah"* — understanding is gift, not achievement |
335
+
336
+ **Key insight (corpus line 1037).** Acts 1-3 are **preparation**. Acts 4-6 are **engagement**. Acts 7-8 are **personalization**. Acts 9-10 are **transformation**. The sequence is deliberate — you cannot personalize (7) without understanding (5), and you cannot be transformed (9) without being affected (8).
337
+
338
+ **Operational mapping to the 12-stage pipeline.**
339
+ - Heart Filter (pre-pass) ↔ Acts 1-3 (preparation)
340
+ - Stages 1-5 (EMBED → EXCAVATE → ROOT TRACE → MULTI-LENS → PATTERN) ↔ Acts 4-6 (engagement)
341
+ - Stages 6-7-8-11 (CONSEQUENCE → DWELLING → COLLAPSE → PERSONAL) ↔ Acts 7-8 (personalization, being affected)
342
+ - Stages 9-10-12 (PRINCIPLE → INVERSION → VOICE) ↔ Acts 9-10 (transformation, disowning self-sufficiency)
343
+
344
+ ### 3.4 The Heart-as-Mirror — Five Conditions
345
+
346
+ Per corpus lines 1039-1055. Al-Ghazali's most famous metaphor for understanding how reflection works:
347
+
348
+ > *"The heart is like a mirror. The Quran's light is always shining. But whether the mirror reflects that light depends on its condition."*
349
+
350
+ **Five conditions that prevent the mirror from reflecting** (these are the doctrinal grounding of the five heart-locks in `SKILL.md`):
351
+
352
+ | # | Condition | Metaphor | Spiritual Reality | Treatment |
353
+ |---|-----------|----------|-------------------|-----------|
354
+ | 1 | **Incompleteness of shape** | Mirror not fully formed | The heart is immature, undeveloped through lack of *tarbiyah* | Spiritual education, mentorship, gradual development |
355
+ | 2 | **Rust and tarnish** | Mirror surface is corroded | Sin, worldliness, heedlessness have corroded the heart's surface | *Tawbah* (repentance), *dhikr* (remembrance), regular worship |
356
+ | 3 | **Facing the wrong direction** | Mirror turned away from the light source | The heart oriented toward *dunya* instead of toward Allah | Reorientation — physically and spiritually turning toward Allah (literally in prayer, figuratively in priorities) |
357
+ | 4 | **Obstruction** | Something blocks the light's path | Veils of *taqlid*, assumption, prejudice block fresh reception | Intellectual humility, openness to new understanding, questioning assumptions |
358
+ | 5 | **Ignorance of the direction** | Mirror doesn't know where to face | Lack of knowledge about HOW to do tadabbur | Learning the methodology, studying with scholars, systematic approach |
359
+
360
+ **Practical implication (corpus line 1055).** Before doing tadabbur, diagnose the heart's condition. Is the mirror rusted? Turned away? Blocked? Each condition has a specific treatment. **Tadabbur is not just a cognitive technique — it requires a *prepared heart*.**
361
+
362
+ **Mapping to the SKILL.md heart-locks:**
363
+ - Lock #1 *Surface-only occupation* ↔ Condition 4 (Obstruction — veils block fresh reception)
364
+ - Lock #2 *Taqlid* ↔ Condition 4 explicitly (taqlid named in the obstruction condition)
365
+ - Lock #3 *Persistence in error* ↔ Condition 2 (Rust accumulates with each repeated wrong)
366
+ - Lock #4 *Self-admiration* ↔ Condition 3 (Wrong-direction — facing self rather than the source)
367
+ - Lock #5 *Premature understanding-claim* ↔ Condition 5 (Ignorance disguised as knowledge)
368
+
369
+ ### 3.5 Tafakkur as Worship
370
+
371
+ Per corpus lines 1057-1068, from *Kitab al-Tafakkur* (Book 39 of the Ihya'):
372
+
373
+ > *"Tafakkur for one hour is better than worship of sixty years."*
374
+
375
+ Al-Ghazali distinguishes between the *fruit* and the *tree*:
376
+ - Worship (ritual prayer, fasting, etc.) is the **tree** — it maintains spiritual health.
377
+ - Tafakkur is the **fruit** — it produces *ma'rifa* (knowledge of Allah), which is the purpose of creation.
378
+ - One hour of genuine tafakkur producing ma'rifa is more valuable than decades of worship that maintains but does not advance.
379
+
380
+ **Warning (corpus line 1068).** This does not mean replace worship with reflection. The tree (worship) is what ENABLES the fruit (tafakkur). You cannot contemplate without the spiritual health that worship maintains. But you also should not cultivate the tree endlessly without ever eating its fruit.
381
+
382
+ **Operational implication.** A repository's tooling, conventions, gates, and doctrine memos are the tree — they maintain health. Tadabbur on a real decision is the fruit. A team that ships tooling endlessly without ever doing the consequential reflection that changes the architecture is cultivating tree without fruit. A team that does reflection without the tooling-tree to sustain it loses the substrate.
383
+
384
+ ### 3.6 Key Quotes (Tier C, per corpus)
385
+
386
+ > *"The key to knowledge of Allah is self-knowledge. Whoever knows themselves knows their Lord."* — Per corpus's report of Al-Ghazali, *Kimiya-yi Sa'adat* (knowledge-base.md line 1072)
387
+
388
+ > *"The Quran has an outward meaning and an inner meaning, a limit and a lookout point."* — Per corpus's report of Al-Ghazali, *Jawahir al-Quran*, attributed there to Ali ibn Abi Talib (line 1074). This is the four-level hermeneutic; see §4 below.
389
+
390
+ > *"If you seek the light, prepare the lamp. The lamp is the heart. The oil is the dhikr. The wick is the sincerity. The fire is the divine grace."* — Per corpus's report of Al-Ghazali, *Mishkat al-Anwar* (line 1076)
391
+
392
+ > *"Recitation without tafakkur is like a host who invites guests but doesn't set the table."* — Per corpus's report of Al-Ghazali, *Ihya'* (line 1078)
393
+
394
+ ---
395
+
396
+ ## Part 4 — The Unified Classical Pathway
397
+
398
+ Source: knowledge-base.md Part 3.3, lines 1082-1234.
399
+
400
+ ### 4.1 The Convergence Across Scholars
401
+
402
+ Despite differences in emphasis and terminology, the classical tradition converges on these four principles (corpus lines 1086-1158):
403
+
404
+ **1. Tadabbur has prerequisites.** It is not context-free.
405
+
406
+ | Category | Prerequisites | Source |
407
+ |----------|---------------|--------|
408
+ | **Spiritual** | Purity of heart, sincerity of intention, *taqwa* (God-consciousness), freedom from major sin, humility | Al-Ghazali, Ibn al-Qayyim, Al-Muhasibi |
409
+ | **Intellectual** | Arabic proficiency, basic tafsir knowledge, awareness of *asbab al-nuzul* | All scholars |
410
+ | **Practical** | *Tartil* (slow, measured recitation), *wudu'* (ablution), *khalwa* (solitude), appropriate time (especially night) | Al-Ghazali, Ibn al-Qayyim |
411
+ | **Emotional** | Openness, willingness to be affected, emotional readiness | Al-Ghazali (*ta'aththur*), Al-Muhasibi (*muraqaba*) |
412
+
413
+ **2. Tadabbur follows a natural progression.** The ten levels (corpus lines 1101-1141):
414
+
415
+ ```
416
+ LEVEL 1: SAMA' (سَمَاع) — Hearing (physical reception)
417
+ LEVEL 2: TILAWA (تِلَاوَة) — Recitation (active reading)
418
+ LEVEL 3: TARTIL (تَرْتِيل) — Measured Recitation (Quranic command 73:4)
419
+ LEVEL 4: TARJUMA (تَرْجَمَة) — Translation / Basic Understanding
420
+ LEVEL 5: TAFKIR (تَفْكِير) — Thinking (active mental engagement)
421
+ LEVEL 6: TAFSIR (تَفْسِير) — Exegesis (detailed scholarly explanation)
422
+ LEVEL 7: TA'AQQUL (تَعَقُّل) — Rational Comprehension (binding meanings together)
423
+ LEVEL 8: TAFAKKUR (تَفَكُّر) — Contemplation (sustained dwelling)
424
+ LEVEL 9: TADABBUR (تَدَبُّر) — Deep Consequential Reflection (the deepest textual engagement)
425
+ LEVEL 10: TADHAKKUR (تَذَكُّر) — Remembrance (the soul recognizes what it "always knew")
426
+ ```
427
+
428
+ Tadabbur sits at Level 9. Tadhakkur (Level 10) is the highest — the moment the veil drops and truth is simply *seen* as what the soul already possessed.
429
+
430
+ **3. The heart is the organ of tadabbur, not the mind alone.** Every classical scholar insists tadabbur is a *cardiac* operation, not merely cerebral:
431
+ - Ibn al-Qayyim: the five-stage model places *haal* (heart's spiritual state) at the center
432
+ - Al-Ghazali: the heart-as-mirror metaphor makes the heart the instrument of reception
433
+ - Al-Muhasibi: *muraqaba* operates through the heart's consciousness
434
+ - Al-Tustari: the four levels of meaning are accessed through progressively deeper heart engagement
435
+ - 47:24: "locks on hearts" — the barrier to tadabbur is cardiac, not intellectual
436
+
437
+ **4. Tadabbur is both a method and a gift (corpus line 1152).** The classical paradox:
438
+ - Tadabbur requires *effort* — preparation, methodology, practice, study
439
+ - But its deepest fruits are *gifts* — Allah opens the heart when He wills
440
+ - The human responsibility is to prepare and strive; the result is from Allah
441
+ - This prevents both passivity (*"I'll just wait"*) and arrogance (*"I achieved this by my brilliance"*)
442
+
443
+ ### 4.2 Al-Tustari's Four-Level Hermeneutic
444
+
445
+ Per corpus lines 1160-1173. Sahl al-Tustari (203-283 AH / 818-896 CE) articulated this four-level model, attributed also to Ali ibn Abi Talib:
446
+
447
+ | Level | Arabic | English | Description |
448
+ |-------|--------|---------|-------------|
449
+ | 1 | **Zahir** | ظاهِر | The Exoteric — surface / literal meaning |
450
+ | 2 | **Batin** | باطِن | The Inner — deeper significance behind the words |
451
+ | 3 | **Hadd** | حَدّ | The Limit — moral / legal boundary established |
452
+ | 4 | **Muttala'** | مُطَّلَع | The Lookout Point — highest vista, the verse's meaning in relation to the divine plan as a whole |
453
+
454
+ **Key insight (corpus line 1171).** These levels are **not alternatives but nested**. Each deeper level *includes* the levels above it. The zahir is not abandoned when you reach the batin — it is *contained within* a broader understanding. A person operating at the muttala' level sees ALL four levels simultaneously.
455
+
456
+ **Operational implication for the depth ladder in `SKILL.md`.** The ladder is not a four-step climb where you leave the previous step behind. It is a nesting — at each deeper level, the surface still applies, the inner is also true, the limit is still binding, and the vista contains everything.
457
+
458
+ ### 4.3 The Six-Phase Classical Pathway
459
+
460
+ Per corpus lines 1175-1223. The synthesis of all classical frameworks into a single actionable pathway:
461
+
462
+ ```
463
+ PHASE 1: PREPARATION (Isti'dad)
464
+ ├── Spiritual: wudu, tawba (repentance), intention
465
+ ├── Physical: quiet environment, appropriate time (especially last third of night)
466
+ ├── Mental: release worldly preoccupations, clear the mind
467
+ ├── Emotional: humility, openness, expectation
468
+ └── Al-Ghazali's inner acts 1-3: greatness of speech, magnification of Speaker, presence of heart
469
+
470
+ PHASE 2: RECEPTION (Istiqbal)
471
+ ├── Recite with tartil
472
+ ├── Listen — hear the words as if for the first time
473
+ ├── Basic comprehension
474
+ ├── Al-Ghazali's inner acts 4-5: tadabbur + tafahhum
475
+ └── Ibn al-Qayyim's Stage 1: fikr
476
+
477
+ PHASE 3: ENGAGEMENT (Tafa'ul)
478
+ ├── Linguistic analysis — roots, grammar, near-synonyms, rhetoric
479
+ ├── Contextual understanding — asbab al-nuzul, surah themes, nazm
480
+ ├── Cross-referencing — other verses, hadith, tafsir
481
+ ├── Al-Ghazali's inner act 6: stripping away barriers
482
+ └── Ibn al-Qayyim's Stage 2: 'ilm
483
+
484
+ PHASE 4: PERSONALIZATION (Takhsis)
485
+ ├── Hear the verse as addressed to YOU
486
+ ├── Connect to personal experience, current struggles, real situations
487
+ ├── Ask: what is being said to me through this, today?
488
+ ├── Al-Ghazali's inner acts 7-8: takhsis + ta'aththur
489
+ └── Ibn al-Qayyim's Stage 3: haal — knowledge MOVES the heart
490
+
491
+ PHASE 5: TRANSFORMATION (Tahawwul)
492
+ ├── What must change in life because of this understanding?
493
+ ├── What intention (iraadah) forms in response?
494
+ ├── What action ('amal) follows?
495
+ ├── Al-Ghazali's inner acts 9-10: ascending + disowning self-sufficiency
496
+ └── Ibn al-Qayyim's Stages 4-5: iraadah → 'amal
497
+
498
+ PHASE 6: DWELLING (Muqawamah / Sukun)
499
+ ├── Sit with the insight. Do not rush to the next.
500
+ ├── Let the understanding settle into the heart.
501
+ ├── This is the "incubation" phase — not thinking about it, but letting it percolate.
502
+ ├── Corresponds to Lectio Divina's contemplatio, koan "sitting," cognitive incubation.
503
+ └── This is the phase MOST OFTEN SKIPPED in modern approaches.
504
+ ```
505
+
506
+ **Operational note.** The 12-stage pipeline in `SKILL.md` is the engineering operationalization of this six-phase pathway. Phases 1-2 → Heart Filter + Stage 1 (EMBED). Phase 3 → Stages 2-5 (EXCAVATE through PATTERN). Phase 4 → Stages 6, 11 (CONSEQUENCE, PERSONAL). Phase 5 → Stages 8, 9 (COLLAPSE, PRINCIPLE). Phase 6 → Stage 7 (DWELLING) — the often-skipped phase, deliberately preserved as a stage so the agent cannot route around it.
507
+
508
+ ### 4.4 Additional Classical Scholars
509
+
510
+ Per corpus lines 1225-1233:
511
+
512
+ **Al-Muhasibi (781-857 CE)** — The founding father of Islamic psychology. Concepts of *muhasaba* (self-reckoning) and *muraqaba* (watchful awareness) provide the introspective foundation. His method: (1) before an act, check intention; (2) during the act, monitor presence; (3) after the act, evaluate sincerity. **Applied to tadabbur:** before reading, check WHY you're reading; during reading, monitor whether your heart is present; after reading, evaluate whether you were genuine.
513
+
514
+ **Ibn Taymiyyah (1263-1328 CE)** — Emphasized the *rational* dimension of tadabbur — the Quran addresses the intellect (*'aql*) as well as the heart. His approach: (1) understand the text in its OWN terms (don't import external frameworks); (2) the Quran explains itself — *"al-Quran yufassiru ba'duhu ba'dan"* (the Quran interprets itself); (3) the *salaf* (early generations) understood it best because they received it with fresh, unprejudiced hearts.
515
+
516
+ **Al-Hasan al-Basri (642-728 CE)** — Modeled tadabbur as a WAY OF LIFE, not a study session. Famous for: weeping during recitation (demonstrating *ta'aththur*); preaching that awakened hearts; and the famous statement: *"Recite the Quran as though it was revealed to you"* — anticipating Al-Ghazali's *takhsis* by centuries.
517
+
518
+ **Imam Islahi (1904-1997 CE)** — While modern, his *nazm* (coherence) methodology extends the classical tradition. Key contributions: (1) the 114 surahs form 7 groups; (2) each surah has an *'amud* (central theme/pillar); (3) adjacent surahs form complementary pairs; (4) this structure is itself an act of *i'jaz* (inimitability). His 9-volume *Tadabbur-i-Quran* is the most comprehensive modern tadabbur commentary.
519
+
520
+ ---
521
+
522
+ ## Part 5 — The Seven Universal Reflection Operations
523
+
524
+ Source: knowledge-base.md Part 5, lines 1502-2046. The operational backbone the 12-stage pipeline composes.
525
+
526
+ Each operation: when to use, full protocol, common mistakes, and a worked example from the corpus.
527
+
528
+ ### Operation 1 — Excavation (Hafr / حَفْر)
529
+
530
+ **Definition.** Digging beneath the surface meaning to uncover layers of significance not immediately apparent.
531
+
532
+ **When to use.** Familiar word/concept being treated superficially; verse or situation that seems "obvious" (the obvious is most excavation-worthy); specific word choice that could have been different; **always at the start of deep reflection** — excavation is usually first.
533
+
534
+ **Protocol** (corpus lines 1521-1551):
535
+ 1. **IDENTIFY the target** — specific word, phrase, concept, or element of the situation
536
+ 2. **QUESTION the surface** — *"What does everyone think this means? What's the default? What am I taking for granted?"*
537
+ 3. **DIG LAYER 1 — Literal/Physical** — most concrete sensory meaning; for Arabic: what is the root, what physical reality does it describe?
538
+ 4. **DIG LAYER 2 — Extended/Abstract** — how has the physical meaning been extended; what metaphorical connections exist?
539
+ 5. **DIG LAYER 3 — Contextual** — why THIS word in THIS context; what alternatives existed and weren't chosen; what does the selection reveal about intent?
540
+ 6. **DIG LAYER 4 — Relational** — how does this relate to what comes before/after; what patterns emerge in fuller context; connections to other instances of the same root/concept
541
+ 7. **SYNTHESIZE** — what understanding emerges from layers 1-4 that wasn't visible at the surface?
542
+
543
+ **Common mistakes** (corpus lines 1553-1557): stopping at first interesting insight; projecting meaning onto the text instead of excavating from it; ignoring the literal/physical layer and jumping to abstraction; treating all layers as equally certain (deeper layers are more speculative).
544
+
545
+ **Worked example — Excavating *Sabr* (Patience)** (corpus lines 1559-1565):
546
+ - Surface: *"Be patient"* → passive endurance, waiting
547
+ - Layer 1 (Physical): root س-ب-ر. A *sabr* (aloe plant) survives in the harshest desert. Sabr is ACTIVE resilience, not passive waiting.
548
+ - Layer 2 (Abstract): three types — *sabr 'ala al-ta'ah* (patience in obedience), *sabr 'an al-ma'siyah* (patience in avoiding sin), *sabr 'ala al-musibah* (patience during affliction). Patience is not one thing but three distinct disciplines.
549
+ - Layer 3 (Contextual): *"wastabirun"* (and be patient persistently, 3:200) — Form X (*istif'al*), SEEKING patience, actively pursuing it. Not just endurance but active pursuit.
550
+ - Layer 4 (Relational): in 103:3, sabr is the LAST of four conditions. It comes after iman, good deeds, and truth-advising. Sabr is what *sustains* all the others — without it, iman wavers, deeds stop, and truth-telling costs too much.
551
+ - Synthesis: sabr is not passive waiting but active desert-resilient perseverance that sustains the entire spiritual enterprise.
552
+
553
+ ### Operation 2 — Root Analysis (Tahlil al-Judhur / تحليل الجذور)
554
+
555
+ **Definition.** Tracing a word, idea, belief, or practice back to its origin/source to understand what it fundamentally IS and where it comes from.
556
+
557
+ **When to use.** Encountering an Arabic word in the Quran; analyzing a belief, habit, or cultural practice; trying to understand WHY something is the way it is; distinguishing two apparently similar things.
558
+
559
+ **Protocol** (corpus lines 1581-1612):
560
+ 1. **IDENTIFY THE ROOT** — for Arabic: 3-letter trilateral; for concepts: foundational premise; for practices: original purpose; for beliefs: the evidence that generated it
561
+ 2. **TRACE THE ROOT'S ORIGINAL MEANING** — most basic, physical sense; original purpose/function
562
+ 3. **MAP THE DERIVATION TREE** — other words/concepts/practices from same root; common thread
563
+ 4. **IDENTIFY SHIFTS** — how meaning/purpose has shifted; what was preserved or lost; what was added or subtracted
564
+ 5. **EVALUATE CURRENT USAGE** — does the current meaning align with the root; has something been lost; has something been added that distorts
565
+ 6. **EXTRACT INSIGHT** — what does the analysis reveal that surface engagement misses?
566
+
567
+ **Common mistakes** (corpus lines 1614-1618): folk etymology (assumed root connection that doesn't exist); root fundamentalism (insisting root meaning is the only valid meaning — meanings legitimately evolve); ignoring context; over-complicating (sometimes surface IS right).
568
+
569
+ **Worked example — Root Analysis of *Salah* (Prayer)** (corpus lines 1620-1624):
570
+ - Root: ص-ل-و (sad-lam-waw)
571
+ - Original physical meaning: to follow closely, to stay connected. A horse following another closely is *yusalli*.
572
+ - Derivation tree: *salah* (prayer), *silah* (connection), *wasla* (to arrive/connect), *musallin* (one who follows closely — also: one who prays).
573
+ - Insight: prayer is not just ritual — it is etymologically *close following* and *connection*. When you pray, you are following Allah's guidance closely and maintaining connection. A person who doesn't pray has broken their *silah*. **The word itself tells you what prayer IS: staying close.**
574
+
575
+ ### Operation 3 — Pattern Recognition (Tamyiz al-Anmat / تمييز الأنماط)
576
+
577
+ **Definition.** Identifying recurring structures, themes, sequences, or parallels across different instances — seeing the pattern that connects.
578
+
579
+ **When to use.** When you notice something repeating; comparing two or more texts/situations/experiences; looking for the "rule" behind multiple "cases"; trying to understand someone's consistent methodology; **in the middle of tadabbur** — after excavation and root analysis have surfaced data points.
580
+
581
+ **Protocol** (corpus lines 1641-1671):
582
+ 1. **COLLECT INSTANCES** — multiple examples; ensure variety; resist the urge to categorize too early
583
+ 2. **OBSERVE SIMILARITIES** — what repeats; what structural elements are consistent; what thematic threads connect
584
+ 3. **OBSERVE DIFFERENCES** — where instances diverge; what varies while core stays constant; are variations systematic or random
585
+ 4. **FORMULATE THE PATTERN** — clear rule or principle; test: does it predict a NEW instance; test: are there counterexamples
586
+ 5. **INVESTIGATE EXCEPTIONS** — do they invalidate the pattern or refine it; can the pattern be restated; is the exception itself a higher-level pattern
587
+ 6. **EXTRACT THE PRINCIPLE** — what does the pattern reveal about deeper logic or wisdom?
588
+
589
+ **Common mistakes** (corpus lines 1673-1677): confirmation bias; premature closure; ignoring exceptions (a pattern that can't handle exceptions isn't a real pattern); pattern-as-answer (recognizing a pattern is the *beginning* of understanding, not the end).
590
+
591
+ **Worked example — Quranic *"Do they not...?"* Questions** (corpus lines 1679-1685):
592
+ - Instances: *"Afala yatadabbarun"* (4:82), *"Afala ya'qilun"* (2:44), *"Afala yanzurun"* (88:17), *"Afala yatafakkarun"* (6:50)
593
+ - Similarity: all use *afala* + cognitive verb + rhetorical question format
594
+ - Difference: each uses a DIFFERENT cognitive verb (tadabbur, ta'aqqul, nazr, tafakkur)
595
+ - Pattern: **the Quran matches the cognitive demand to the object.** You LOOK at (nazr) physical creation. You REASON about (ta'aqqul) logical arguments. You CONTEMPLATE (tafakkur) existence broadly. You do TADDABUR on the Quran's text specifically.
596
+ - Principle: the Quran has a precise cognitive taxonomy — it knows which mode of thinking applies to which domain.
597
+
598
+ ### Operation 4 — Consequence Tracing (Tatabu' al-'Awaqib / تتبع العواقب)
599
+
600
+ **Definition.** Following a belief, action, choice, or interpretation forward to its logical consequences — what does this lead to if carried to completion?
601
+
602
+ **When to use.** Evaluating a decision; when the source describes consequences; when a belief seems plausible but its implications haven't been explored; when an argument sounds good in isolation. **This is the operation most directly connected to the d-b-r root meaning of tadabbur.**
603
+
604
+ **Protocol** (corpus lines 1701-1735):
605
+ 1. **STATE THE STARTING POINT** — clearly and precisely; no ambiguity
606
+ 2. **TRACE FIRST-ORDER CONSEQUENCES** — immediate, direct results; what happens right away
607
+ 3. **TRACE SECOND-ORDER CONSEQUENCES** — what do first-order consequences lead to; what becomes possible/impossible after the first step; what chain reactions begin
608
+ 4. **TRACE THIRD-ORDER CONSEQUENCES** — follow the chain further; long-term trajectory; the "end state"
609
+ 5. **REVERSE TRACE** — start from end state, work backward; is this where you WANT to end up; if not, where did the trajectory go wrong
610
+ 6. **COMPARE PATHS** — consequences of ALTERNATIVE choices; how do end states differ; which trajectory aligns with values/goals
611
+ 7. **EXTRACT THE LESSON** — what does the analysis reveal about the right course?
612
+
613
+ **Common mistakes** (corpus lines 1737-1741): catastrophizing; stopping too early (first-order consequences are often not the important ones); single-track thinking (consequences branch); ignoring probability.
614
+
615
+ **Worked example — *Tawassaw bil-haqq* (Mutual truth-advising, 103:3)** (corpus lines 1743-1750):
616
+ - Starting point: a community where people stop advising each other toward truth (abandon *tawassaw bil-haqq*)
617
+ - First-order: individuals make uncorrected mistakes in belief and practice
618
+ - Second-order: mistakes become normalized; wrong becomes conventional
619
+ - Third-order: the community's collective understanding drifts from truth; people who DO know truth feel isolated and fall silent
620
+ - End state: a community that practices Islam by cultural habit, not by living engagement with truth — the "Muslim identity crisis" itself
621
+ - Reverse trace: the entire crisis traces back to the abandonment of mutual truth-advising
622
+ - Lesson: the communal element of 103:3 is not optional — without it, the entire structure collapses
623
+
624
+ ### Operation 5 — Personal Application (Takhsis / تخصيص)
625
+
626
+ **Definition.** Taking a general truth, principle, or insight and applying it specifically to YOUR life, situation, relationships, and spiritual state — right now, today.
627
+
628
+ **When to use.** After any other operation produces an insight; when the source addresses the reader directly; when reflecting on a story and looking for the mirror; when a truth feels "academic" and needs to become personal. **This operation transforms understanding into transformation.**
629
+
630
+ **Protocol** (corpus lines 1767-1800):
631
+ 1. **STATE THE INSIGHT** — what truth/principle has emerged?
632
+ 2. **SELF-DIAGNOSIS** — where does this intersect with MY life; which current situations does it speak to; which relationships; **be SPECIFIC**
633
+ 3. **HONEST ASSESSMENT** — am I living in alignment; where am I falling short; what barriers prevent embodiment; what would need to change. **WARNING: This must be honest, not performative. Takhsis without honesty is theater.**
634
+ 4. **COMMITMENT** — what ONE specific action in the next 24 hours; **not** "be a better person" but "call my mother today"; **not** "have more taqwa" but "stop before I gossip about my colleague tomorrow"; concrete, specific, time-bound
635
+ 5. **ACCOUNTABILITY** — how will I know if I followed through; is there someone to hold me accountable; when will I revisit
636
+ 6. **DU'A** — end with a specific supplication connected to this application. *Personal application that doesn't lead to du'a is self-improvement, not tadabbur.*
637
+
638
+ **Common mistakes** (corpus lines 1802-1807): generic application ("I need to be better" is not personal); application without honesty; skipping the du'a; applying to others ("my neighbor needs to hear this" is not takhsis; "I need to hear this" is); all commitment, no mercy (takhsis includes recognizing you're trying).
639
+
640
+ **Worked example — Personal Application of 47:24** (corpus lines 1809-1815): see corpus for the worked entry; demonstrates how the verse on locked hearts becomes a specific commitment to read 3 verses with 15 minutes of excavation rather than 3 pages on routine.
641
+
642
+ ### Operation 6 — Universal Principle Extraction (Istikhraj al-Mabda' / استخراج المبدأ)
643
+
644
+ **Definition.** Extracting from a specific text, story, experience, or observation a principle that is universally applicable — a truth that transcends its original context.
645
+
646
+ **When to use.** After detailed analysis of a specific verse/story/situation; when you've found an insight with broader applicability; when looking for the "transferable truth"; when connecting Quranic wisdom to modern life domains.
647
+
648
+ **Protocol** (corpus lines 1832-1866):
649
+ 1. **IDENTIFY THE SPECIFIC INSIGHT**
650
+ 2. **ABSTRACT UPWARD** — remove the specific context; state in domain-independent language; can it be a general rule; should feel TRUE even without knowing the original context
651
+ 3. **TEST ACROSS DOMAINS** — personal relationships; business/professional; education/learning; community/social; psychology/mental health. **If it doesn't apply in at least 3 domains, it may not be truly universal.**
652
+ 4. **CHECK FOR FALSIFIABILITY** — can it be contradicted by evidence; counterexamples; if it can't be wrong, it may be too vague. *A good principle has clear boundaries — it says "this, not that."*
653
+ 5. **STATE THE PRINCIPLE** — name it clearly; one sentence; 2-3 examples from different domains; note boundary conditions
654
+ 6. **CONNECT BACK** — how does the universal principle illuminate the original specific context with new depth; the principle should make the source RICHER, not replace it
655
+
656
+ **Common mistakes** (corpus lines 1869-1873): over-abstraction (vague to meaninglessness); under-abstraction ("principles" that just describe the specific case); universalizing the particular; losing the source.
657
+
658
+ **Worked example — Principle from Surah Al-Asr — *The Law of Default Entropy*** (corpus lines 1875-1891):
659
+ - Specific insight: default human state is loss (*khusr*); only active investment in 4 things reverses it.
660
+ - Principle (named): **The Law of Default Entropy** — *"In any system — personal, organizational, spiritual, relational — the default trajectory is degradation. Positive outcomes require active, sustained, and specific counter-investment."*
661
+ - Domain applications: business (without active maintenance, organizations drift toward dysfunction); relationships (without active investment, they deteriorate); health (without active exercise/nutrition/rest, the body degrades); education (without review and application, knowledge decays); spirituality (without active worship/reflection/community, faith weakens)
662
+ - Boundary: describes trajectory, not destiny. Doesn't say degradation is irreversible — says it's the DEFAULT requiring active counteraction.
663
+ - Connect back: makes *"inna al-insana la-fi khusr"* not just a religious statement but a description of universal law.
664
+
665
+ ### Operation 7 — Inversion (Al-Qalb / القَلْب)
666
+
667
+ **Definition.** Deliberately flipping a perspective, assumption, or question to its opposite to see what the reversal reveals. The mirror-image of the obvious.
668
+
669
+ **When to use.** When stuck in one way of seeing; when familiar understanding feels stale; when testing whether an interpretation is genuinely insightful or just habitual; when the source explicitly uses contrast (light/darkness, guidance/misguidance); when wanting to understand something by understanding what it is NOT.
670
+
671
+ **Protocol** (corpus lines 1908-1935):
672
+ 1. **STATE THE STANDARD READING** — normal, accepted, obvious interpretation
673
+ 2. **INVERT IT** — opposite of this interpretation; what if emphasis is on the part you're ignoring; question is the answer / answer is the question; subject is actually the object; purpose is the opposite of what it seems
674
+ 3. **TAKE THE INVERSION SERIOUSLY** — don't dismiss; sit with it; what would be true if it were correct; what evidence supports it; what does it illuminate that the standard reading misses
675
+ 4. **SYNTHESIZE** — how do the standard and inversion relate; is truth in the tension; does inversion refine, expand, or correct; or does it confirm the standard by showing what's wrong with the alternative
676
+ 5. **APPLY THE INSIGHT** — what does the inverted perspective reveal about your assumptions, habits, blind spots?
677
+
678
+ **Common mistakes** (corpus lines 1937-1941): contrarianism (inverting just to be different); forced inversion (not everything has a meaningful opposite); losing the original; equal weighting (sometimes the standard reading IS correct).
679
+
680
+ **Worked example — Inverting 47:24 ("Are there locks upon their hearts?")** (corpus lines 1943-1955):
681
+ - Standard reading: some people have locked hearts, which prevents tadabbur.
682
+ - Inversion 1: what if the question is not "are there locks?" but "WHO put the locks there?" — *"aqfaluha"* — ITS OWN locks. The heart locks ITSELF.
683
+ - Inversion 2: what if the locks aren't the problem but a SYMPTOM? The problem isn't the lock — it's what the heart was doing that CAUSED it to lock (sin, distraction, arrogance, hurt).
684
+ - Inversion 3: what if every "locked heart" verse is an INVITATION rather than a condemnation? The question form invites self-examination, not despair. The Quran is ASKING you to check, which means the locks CAN be opened. *If the locks were permanent, why ask?*
685
+ - Synthesis: the verse is simultaneously a diagnosis (hearts lock), an etiology (they lock themselves), and a prescription (check your locks — the fact that you're being asked means they can be removed).
686
+
687
+ ---
688
+
689
+ ## Part 6 — The Five Operation Chains
690
+
691
+ Source: knowledge-base.md Part 5.2, lines 1959-2046.
692
+
693
+ Operations are most powerful when combined in deliberate sequences. Five canonical chains:
694
+
695
+ ### Chain 1 — Deep Text Analysis
696
+
697
+ `EXCAVATION → ROOT ANALYSIS → PATTERN RECOGNITION → UNIVERSAL PRINCIPLE EXTRACTION`
698
+
699
+ For Quranic study, doctrine memo deep-reads, schema audits, contract analysis. Worked example in corpus: studying the word *"rabb"* (Lord/Nurturer) — excavate the term, trace root r-b-b, pattern across Quranic uses, extract principle that divine lordship is fundamentally pedagogical.
700
+
701
+ ### Chain 2 — Life Situation Analysis
702
+
703
+ `EXCAVATION → CONSEQUENCE TRACING → PERSONAL APPLICATION → INVERSION`
704
+
705
+ For personal reflection, real decisions, owner-conversation analysis. Worked example: workplace injustice — excavate the specific facts, trace consequences of anger/silence/strategic-patience, personal application, then inversion ("am I the unjust one in some dimension I haven't considered?").
706
+
707
+ ### Chain 3 — Comparative Analysis
708
+
709
+ `ROOT ANALYSIS → ROOT ANALYSIS → PATTERN RECOGNITION → INVERSION`
710
+
711
+ For near-synonym study, two-doctrine-memos-in-tension, two-implementation-paths comparison. Worked example: *khashya* vs *khawf* (two types of fear) — analyze each root, find the Quran's pattern of usage (khashya for those with knowledge, khawf for anyone facing danger), inversion proves precision (35:28 with *khawf* would be wrong because khawf doesn't require knowledge).
712
+
713
+ ### Chain 4 — Story Mirror
714
+
715
+ `EXCAVATION → PATTERN RECOGNITION → PERSONAL APPLICATION → UNIVERSAL PRINCIPLE EXTRACTION`
716
+
717
+ For Quranic narrative, post-mortem narrative, learning-from-others'-failures. Worked example: Yusuf's brothers — excavate motivations (jealousy → unloved feeling → projecting blame); pattern (sibling rivalry from perceived favoritism, universal); personal ("have I ever felt 'my father loves him more'?"); principle (perceived injustice in love-distribution drives extreme actions).
718
+
719
+ ### Chain 5 — Decision Framework
720
+
721
+ `EXCAVATION → CONSEQUENCE TRACING → INVERSION → PERSONAL APPLICATION`
722
+
723
+ For ethical/practical decisions, owner-pending-decisions, launch-strategy choices. Worked example: higher-paying job that requires compromising values — excavate the real decision (not money vs. values, but what one is willing to trade for security); consequence trace; inversion ("if my child faced this decision, what would I advise?"); personal application (decline, trust in *rizq*, seek alternatives).
724
+
725
+ ---
726
+
727
+ ## Part 7 — The Five Domain Adaptations
728
+
729
+ Source: knowledge-base.md Part 5.3, lines 2050-2110.
730
+
731
+ The seven operations adapted to five different operational domains:
732
+
733
+ ### Domain 1 — Quranic Study
734
+
735
+ | Operation | Quranic Application |
736
+ |-----------|---------------------|
737
+ | Excavation | Specific Arabic word choices — root meanings, morphological forms, grammatical constructions |
738
+ | Root Analysis | Trilateral roots, derivative trees, Quranic usage patterns |
739
+ | Pattern Recognition | Nazm (coherence), ring composition, thematic pairing, recurring phrases |
740
+ | Consequence Tracing | The ayah's described consequences; what happens if you follow vs. ignore its guidance |
741
+ | Personal Application | *"Ya ayyuha alladhina amanu"* — hear every address as directed to YOU |
742
+ | Principle Extraction | From specific verses/stories, principles applicable to all life domains |
743
+ | Inversion | If the verse warns against X, what is the positive vision? |
744
+
745
+ ### Domain 2 — Life Situations
746
+
747
+ | Operation | Life Application |
748
+ |-----------|------------------|
749
+ | Excavation | Beneath surface emotions — what is REALLY happening |
750
+ | Root Analysis | The ORIGIN of the situation — where did this pattern start; what assumption drives it |
751
+ | Pattern Recognition | Is this recurring; have I been here before |
752
+ | Consequence Tracing | If I do X, then what; where does this path lead in 1 / 5 years |
753
+ | Personal Application | What does this situation demand of me specifically |
754
+ | Principle Extraction | Lesson to carry forward to future situations |
755
+ | Inversion | Am I the hero of this story, or could I be the antagonist |
756
+
757
+ ### Domain 3 — Business / Professional Decisions
758
+
759
+ | Operation | Business Application |
760
+ |-----------|----------------------|
761
+ | Excavation | Beneath market data — what CUSTOMER NEED is really being served |
762
+ | Root Analysis | The FOUNDATIONAL assumption of this business model — is it still valid |
763
+ | Pattern Recognition | Patterns in data, customer behavior, competitive landscape, our own past decisions |
764
+ | Consequence Tracing | If we launch X — 2nd and 3rd order consequences for customers, employees, market, reputation |
765
+ | Personal Application | How does this align with stated values; willing to stand behind in 10 years |
766
+ | Principle Extraction | Codify principles for future decisions |
767
+ | Inversion | What would our harshest critic say; what if we assumed the opposite of our current data |
768
+
769
+ ### Domain 4 — Relationships
770
+
771
+ | Operation | Relationship Application |
772
+ |-----------|--------------------------|
773
+ | Excavation | Beneath the surface conflict — the REAL issue, the unmet need |
774
+ | Root Analysis | Where did this dynamic start; what childhood pattern is driving it |
775
+ | Pattern Recognition | Is this a recurring conflict; what triggers it |
776
+ | Consequence Tracing | If unchanged — where does the relationship go in 5 years |
777
+ | Personal Application | What is MY part; what can I change about MY contribution |
778
+ | Principle Extraction | Lesson about human connection that applies broadly |
779
+ | Inversion | If I were in the other person's position, what would I see, what would I need |
780
+
781
+ ### Domain 5 — Self-Development
782
+
783
+ | Operation | Self-Development Application |
784
+ |-----------|------------------------------|
785
+ | Excavation | Beneath self-narrative — who am I REALLY vs. who I tell myself I am |
786
+ | Root Analysis | Where did core beliefs about myself originate; still valid |
787
+ | Pattern Recognition | Patterns in behavior, reactions, relationships |
788
+ | Consequence Tracing | If I maintain this habit/belief — where do I end up |
789
+ | Personal Application | What ONE specific change would have the most impact right now |
790
+ | Principle Extraction | Principle about human development |
791
+ | Inversion | What if my "strength" is actually a limitation; what if my "weakness" is actually a gift |
792
+
793
+ ---
794
+
795
+ ## Part 8 — Worked Five-Lenses Examples (from the corpus)
796
+
797
+ Source: knowledge-base.md Part 1.8, lines 302-562. Six full worked examples showing what trained Five-Lens application produces. Read these when training another agent on tadabbur or when the agent's Multi-Lens output is starting to feel performative.
798
+
799
+ ### 8.1 Surah Al-Asr (103:1-3)
800
+
801
+ Full worked example at corpus lines 306-345. Demonstrates: Heart Filter, all five lenses, with depth — extracts the Law of Default Entropy and the four-part formula (Belief → Action → Community Truth → Community Patience).
802
+
803
+ ### 8.2 Surah Al-Fatiha (1:1-7)
804
+
805
+ Full worked example at corpus lines 348-387. Demonstrates: the *iltifat* (person shift) from third to second person at verse 5 as the moment of encounter; the journey from learning-about-Him to addressing-Him to requesting-from-Him; the principle of progressive intimacy.
806
+
807
+ ### 8.3 Ayat al-Nur (24:35)
808
+
809
+ Full worked example at corpus lines 390-430. Demonstrates: layered language analysis (mishkah, zujajah, *la sharqiyyah wa la gharbiyyah*, *yakadu zaytuhha yudi'u*, *nurun 'ala nur*); the principle of layered illumination, prepared reception, near-sufficiency of fitrah, universality.
810
+
811
+ ### 8.4 Surah Al-Rahman 55:1-4
812
+
813
+ Full worked example at corpus lines 433-473. Demonstrates: the order Quran → Human → Speech (Quran taught BEFORE human created); the principle that the curriculum existed before the student; expression as divine gift; mercy-first.
814
+
815
+ ### 8.5 An-Nisa 4:82
816
+
817
+ Full worked example at corpus lines 476-515. Demonstrates: tadabbur on the canonical tadabbur verse; the *afala* compound interrogative; the *kathiran* quantifier; the falsifiable criterion the Quran sets for itself; the principle of productive difficulty.
818
+
819
+ ### 8.6 Aal-Imran 3:190-191
820
+
821
+ Full worked example at corpus lines 518-560. Demonstrates: the Prophet ﷺ's weeping; *ulu al-albab* defined by habits not credentials; the *fa al-sababiyyah* causal connection (because You created with purpose, therefore protect us from the Fire); contemplation-to-supplication as the natural movement of the reflective mind.
822
+
823
+ When the agent's Multi-Lens stage feels mechanical, return to one of these six worked examples. Read it slowly. Apply its depth-shape to the current artifact under reflection.
824
+
825
+ ---
826
+
827
+ ## Part 9 — Worked NAK-Style Linguistic Analysis Examples
828
+
829
+ Source: knowledge-base.md Part 2, lines 565-882. The corpus's report of Nouman Ali Khan's 7-step cognitive algorithm and applied examples.
830
+
831
+ **Tier C citation rule.** When citing NAK material in agent output, cite as "per the corpus's report of NAK..." or "per Bayyinah methodology as captured in `knowledge-base.md` Part 2." Tier B requires verified Bayyinah primary source (Divine Speech, Quran Cover to Cover, Linguistic Miracle).
832
+
833
+ ### 9.1 The 7-Step NAK Cognitive Algorithm
834
+
835
+ Per corpus lines 571-633:
836
+
837
+ 1. **Root Word Excavation** — identify trilateral root; find ROOT's physical/sensory meaning (the original concrete use)
838
+ 2. **Meaning Layers** — Layer 1 physical/sensory → Layer 2 abstract extension → Layer 3 psychological dimension → Layer 4 spiritual significance. Each layer builds on the previous; never disconnects from the root.
839
+ 3. **Near-Synonym Distinction** — identify words the Quran uses in similar but different contexts; ask "why THIS word and not THAT word?"
840
+ 4. **Grammatical Shift as Emphasis** — unusual word order (*taqdim/ta'khir*), definite vs indefinite, person shifts (*iltifat*), tense changes, singular/plural/dual, active vs passive — each shift carries meaning, never stylistic accident
841
+ 5. **Spiritual Insight** — what does the linguistic analysis reveal about Allah's nature, the human condition, the divine-human relationship; should feel like discovery, not imposition
842
+ 6. **Life Application** — specific not generic; "be a better person" is not application, "when I am tempted to dismiss someone's argument without engaging, I am doing what 4:82 warns against" IS application
843
+ 7. **Open Question** — what remains unanswered; what new questions has this opened; algorithm is recursive
844
+
845
+ ### 9.2 Worked Examples
846
+
847
+ The corpus has three worked applications of the 7-step algorithm:
848
+
849
+ - **Khusr in Surah Al-Asr (103:2)** — corpus lines 636-664. The bad-investment metaphor: human life is capital, the question is what you invest it in; *khusr* means you traded something valuable for something worthless.
850
+ - **Qalb vs Fu'ad vs Sadr** — corpus lines 666-694. The cardiac geography: outer ring (*sadr*) → middle ring (*qalb*) → bullseye (*fu'ad*). Different spiritual states affect different layers; treatment must be targeted.
851
+ - **Rih vs Riyah (Wind)** — corpus lines 696-718. SINGULAR wind = destructive force in Quranic usage; PLURAL winds = beneficial mercy. Pattern holds across all occurrences. Mercy is diverse and gentle; punishment is singular and overwhelming.
852
+
853
+ ### 9.3 Linguistic Analysis Patterns
854
+
855
+ Per corpus lines 722-806. Four pattern categories:
856
+
857
+ **Pattern 1 — Near-Synonym Distinction (*Tafriq bayn al-Mutaradifat*).** The Quran never uses two words interchangeably. When two Arabic words seem synonymous, their Quranic usage reveals precise distinctions. Corpus indexes 10 worked pairs (khashya/khawf, qalb/fu'ad, rih/riyah, bashar/insan, jaa'a/ataa, dhan/shakk, sabr/hilm, 'ilm/ma'rifa, kitab/quran, naba'/khabar) at lines 730-741.
858
+
859
+ **Pattern 2 — Root Word Excavation (*Istiqra' al-Judhur*).** Every word carries the semantic DNA of its root. Method: identify root → list ALL Quranic derivatives → map semantic field → identify specific nuance of the derivative used. Corpus has worked examples at lines 753-769 (q-r-' meaning "to gather and put together"; k-f-r meaning "to cover/conceal" — kufr is not ignorance but active concealment).
860
+
861
+ **Pattern 3 — Grammar-as-Meaning (*Al-Nahw al-Dali*).** Arabic grammatical structures carry meaning beyond the words. Corpus indexes 8 grammatical tools at lines 777-786: word order, definite/indefinite, person shift, tense shift, active/passive, number choice, deletion/ellipsis, oath structure. Each shift is communicative, never stylistic accident.
862
+
863
+ **Pattern 4 — Balagha (Rhetoric).** The Quran's rhetorical devices are constitutive, not ornamental. Corpus indexes 10 devices at lines 794-805: simile, metaphor, metonymy, rhetorical question, oath, repetition, conciseness, amplification, parallelism, ring composition.
864
+
865
+ ---
866
+
867
+ ## Part 10 — The Skill Ecology Gap Inventory (for owner decision)
868
+
869
+ Surfaced during this restoration. Each is a place where the corpus identifies a distinct cognitive operation but the skill ecology has no dedicated skill for it. Owner decides per skill: gap to fill, intentional design, or substrate-only (lives inside other skills).
870
+
871
+ | Term | Root | Corpus Position | Skill Status | Recommendation Direction |
872
+ |------|------|-----------------|--------------|--------------------------|
873
+ | **Ta'aqqul** | ع-ق-ل | Most-commanded reflection term (~49 occurrences) | No skill | Possible standalone skill OR explicit substrate of all reasoning skills |
874
+ | **Tawassum** | و-س-م | Reportedly Aria's actual operating signature per Ibn al-Qayyim | No skill | Possible standalone skill — high-leverage for the agent's diagnostic posture |
875
+ | **I'tibaar** | ع-ب-ر | The Aegis ↔ Dalio loop is mechanically i'tibaar | No skill | Possible standalone skill OR i'tibaar-named into the existing post-mortem/learning surfaces |
876
+ | **Nazr** | ن-ظ-ر | The first cognitive act; mechanically what `never-guess` does | Indirect (covered by `never-guess`) | Possibly already covered; worth naming the connection in `never-guess` |
877
+ | **Tafaqquh** | ف-ق-ه | Deep comprehension penetrating to essence | No skill | Likely substrate-only; lives inside any skill that produces essence-knowledge |
878
+ | **Muraqaba** | ر-ق-ب | Watchful self-awareness; Lawwama shard runtime | No standalone skill | Already operationalized in shard runtime; cognition skill may not need to duplicate |
879
+ | **Muhasaba** | ح-س-ب | Self-reckoning; Muhasaba shard runtime | No standalone skill | Already operationalized in shard runtime; cognition skill may not need to duplicate |
880
+
881
+ **Implementation styles** for the gaps that become skills:
882
+
883
+ - **Autofire-only** — skill exists but only fires on specific triggers; no client-facing mention; useful for skills that are background-discipline (e.g., nazr could autofire whenever the agent is about to cite a file without having read it)
884
+ - **SKILL.md + cookbook (full skill)** — first-class member of the cognition surface; appears in `aria-cognition-batch` and other composers
885
+ - **Substrate-only** — concept named explicitly in the existing related skill's body (e.g., name nazr inside `never-guess`'s description) without authoring a new skill
886
+
887
+ ---
888
+
889
+ ## Part 11 — Reading Order Recommendations
890
+
891
+ For agents loading this cookbook for the first time:
892
+
893
+ 1. **First read `../SKILL.md` end-to-end.** Understand the operational backbone before going to substrate.
894
+ 2. **Then Part 1 of this cookbook** (six-term ecology). Without the ecology, the rest of the substrate floats.
895
+ 3. **Then Part 2 (Ibn al-Qayyim) §2.1 (Five-Stage Cycle).** The fikr → ilm → haal → iraadah → 'amal cycle is the deepest single insight in this cookbook for engineering work. *Most agents stall at 'ilm.*
896
+ 4. **Then Part 3 §3.1 (Iqtiran).** Al-Ghazali's coupling mechanism. This is the actual cognitive engine of pattern-recognition, not list-making.
897
+ 5. **Then Part 4 (Unified Pathway).** The synthesis across all classical scholars.
898
+ 6. **Then Part 5 (Seven Operations) and Part 6 (Five Chains)** as needed for the specific operation in play.
899
+ 7. **Part 7 (Domain Adaptations)** when the work is in a specific domain (life, business, relationships, self).
900
+ 8. **Part 8 (Worked Five-Lenses Examples)** when Multi-Lens output starts to feel performative — return to a worked example for depth-shape recovery.
901
+ 9. **Part 9 (NAK Linguistic Analysis)** when the work involves language-precision — Quranic, schema, doctrine memo, contract phrasing.
902
+ 10. **Part 10 (Skill Ecology Gap Inventory)** when proposing new cognition skills or asking whether an existing skill covers an operation.
903
+
904
+ ---
905
+
906
+ ## Part 12 — Citation Discipline (Source Trust Ladder, Reapplied)
907
+
908
+ Every claim this cookbook makes about a classical scholar is **Tier C** — drawn from `apps/arias-soul/corpus/knowledge-base.md`, which itself reports the scholar. Tier C is the honest citation tier when working from the corpus.
909
+
910
+ When the agent uses this cookbook in service of a real task and needs to cite a classical scholar, the agent should:
911
+
912
+ - **Cite at Tier C by default.** *"Per the corpus's report of Ibn al-Qayyim..."* or *"Per `knowledge-base.md` Part 3.1 lines 887-975..."*
913
+ - **Promote to Tier B only after verifying.** If the agent has access to the actual classical work (Ihya' Book 39, Madarij al-Salikin, Mishkat al-Anwar, Tafsir al-Tabari, etc.) and has consulted the specific passage, the citation can rise to Tier B with the work named: *"Al-Ghazali, Ihya' Ulum al-Din, Book 39: '...'"*
914
+ - **Quranic verses are Tier A.** Direct citation by surah and ayah is always Tier A: *"Surah Sad 38:29: 'li-yaddabbaru ayatihi'"*. Tier A requires the actual Arabic + verse number, not a paraphrase.
915
+ - **Agent synthesis is always Tier D.** When the agent connects two classical positions, integrates a corpus claim with engineering practice, or makes a mapping the corpus does not directly assert, mark explicitly as synthesis: *"this maps to..."* or *"the connection here is agent synthesis from..."*
916
+
917
+ **Stop condition.** If the agent presents Tier C as Tier B (corpus paraphrase as if it were primary-source quote), Al-Ghazali's heart-lock #4 (self-admiration) has fired. Repair: re-cite at the correct tier, re-read the actual primary work if claiming Tier B, then continue.
918
+
919
+ ---
920
+
921
+ *End of Tadabbur Cookbook. Substrate complete; substance must change the next action.*