@synap-core/cli 1.8.0 → 1.10.0

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 (332) hide show
  1. package/dist/commands/agent-chat.d.ts +47 -0
  2. package/dist/commands/agent-chat.js +250 -0
  3. package/dist/commands/agent-chat.js.map +1 -0
  4. package/dist/commands/agent-run.js +3 -4
  5. package/dist/commands/agent-run.js.map +1 -1
  6. package/dist/commands/agents.js +85 -46
  7. package/dist/commands/agents.js.map +1 -1
  8. package/dist/commands/automation.js +2 -1
  9. package/dist/commands/automation.js.map +1 -1
  10. package/dist/commands/bridge-setup.d.ts +66 -0
  11. package/dist/commands/bridge-setup.js +1112 -0
  12. package/dist/commands/bridge-setup.js.map +1 -0
  13. package/dist/commands/cap-connections.d.ts +28 -0
  14. package/dist/commands/cap-connections.js +224 -0
  15. package/dist/commands/cap-connections.js.map +1 -0
  16. package/dist/commands/capability.d.ts +89 -0
  17. package/dist/commands/capability.js +1523 -0
  18. package/dist/commands/capability.js.map +1 -0
  19. package/dist/commands/centrality.d.ts +20 -0
  20. package/dist/commands/centrality.js +94 -0
  21. package/dist/commands/centrality.js.map +1 -0
  22. package/dist/commands/connect.d.ts +2 -0
  23. package/dist/commands/connect.js +16 -35
  24. package/dist/commands/connect.js.map +1 -1
  25. package/dist/commands/context.js +4 -6
  26. package/dist/commands/context.js.map +1 -1
  27. package/dist/commands/data-extra.d.ts +1 -0
  28. package/dist/commands/data-extra.js +34 -10
  29. package/dist/commands/data-extra.js.map +1 -1
  30. package/dist/commands/data.d.ts +4 -4
  31. package/dist/commands/data.js +241 -184
  32. package/dist/commands/data.js.map +1 -1
  33. package/dist/commands/diagnose.d.ts +20 -0
  34. package/dist/commands/diagnose.js +143 -0
  35. package/dist/commands/diagnose.js.map +1 -0
  36. package/dist/commands/digest.d.ts +17 -0
  37. package/dist/commands/digest.js +121 -0
  38. package/dist/commands/digest.js.map +1 -0
  39. package/dist/commands/discover.d.ts +2 -0
  40. package/dist/commands/discover.js +25 -8
  41. package/dist/commands/discover.js.map +1 -1
  42. package/dist/commands/events.js +2 -1
  43. package/dist/commands/events.js.map +1 -1
  44. package/dist/commands/explain.d.ts +1 -1
  45. package/dist/commands/explain.js +18 -15
  46. package/dist/commands/explain.js.map +1 -1
  47. package/dist/commands/facet.d.ts +29 -0
  48. package/dist/commands/facet.js +113 -0
  49. package/dist/commands/facet.js.map +1 -0
  50. package/dist/commands/graph.js +2 -1
  51. package/dist/commands/graph.js.map +1 -1
  52. package/dist/commands/import.d.ts +38 -0
  53. package/dist/commands/import.js +440 -0
  54. package/dist/commands/import.js.map +1 -0
  55. package/dist/commands/init.js +35 -16
  56. package/dist/commands/init.js.map +1 -1
  57. package/dist/commands/keys.js +3 -4
  58. package/dist/commands/keys.js.map +1 -1
  59. package/dist/commands/knowledge.d.ts +2 -0
  60. package/dist/commands/knowledge.js +61 -9
  61. package/dist/commands/knowledge.js.map +1 -1
  62. package/dist/commands/launch.d.ts +50 -0
  63. package/dist/commands/launch.js +790 -0
  64. package/dist/commands/launch.js.map +1 -0
  65. package/dist/commands/lens.d.ts +45 -0
  66. package/dist/commands/lens.js +386 -0
  67. package/dist/commands/lens.js.map +1 -0
  68. package/dist/commands/market.d.ts +209 -0
  69. package/dist/commands/market.js +1368 -0
  70. package/dist/commands/market.js.map +1 -0
  71. package/dist/commands/mcp.d.ts +42 -0
  72. package/dist/commands/mcp.js +184 -0
  73. package/dist/commands/mcp.js.map +1 -0
  74. package/dist/commands/observe.js +14 -11
  75. package/dist/commands/observe.js.map +1 -1
  76. package/dist/commands/open.d.ts +21 -4
  77. package/dist/commands/open.js +45 -4
  78. package/dist/commands/open.js.map +1 -1
  79. package/dist/commands/pod.d.ts +100 -0
  80. package/dist/commands/pod.js +359 -0
  81. package/dist/commands/pod.js.map +1 -0
  82. package/dist/commands/pods.d.ts +1 -0
  83. package/dist/commands/pods.js +77 -15
  84. package/dist/commands/pods.js.map +1 -1
  85. package/dist/commands/proposals-actions.js +40 -3
  86. package/dist/commands/proposals-actions.js.map +1 -1
  87. package/dist/commands/purge.d.ts +23 -0
  88. package/dist/commands/purge.js +148 -0
  89. package/dist/commands/purge.js.map +1 -0
  90. package/dist/commands/raycast.d.ts +15 -0
  91. package/dist/commands/raycast.js +153 -0
  92. package/dist/commands/raycast.js.map +1 -0
  93. package/dist/commands/sessions.js +45 -21
  94. package/dist/commands/sessions.js.map +1 -1
  95. package/dist/commands/skill-manage.d.ts +21 -0
  96. package/dist/commands/skill-manage.js +195 -0
  97. package/dist/commands/skill-manage.js.map +1 -0
  98. package/dist/commands/skills-commands.js +2 -1
  99. package/dist/commands/skills-commands.js.map +1 -1
  100. package/dist/commands/skills.js +4 -3
  101. package/dist/commands/skills.js.map +1 -1
  102. package/dist/commands/status.d.ts +3 -1
  103. package/dist/commands/status.js +166 -14
  104. package/dist/commands/status.js.map +1 -1
  105. package/dist/commands/statusline.d.ts +24 -0
  106. package/dist/commands/statusline.js +450 -0
  107. package/dist/commands/statusline.js.map +1 -0
  108. package/dist/commands/subscribe.js +2 -2
  109. package/dist/commands/subscribe.js.map +1 -1
  110. package/dist/commands/tools.d.ts +30 -0
  111. package/dist/commands/tools.js +315 -0
  112. package/dist/commands/tools.js.map +1 -0
  113. package/dist/commands/versions.d.ts +27 -0
  114. package/dist/commands/versions.js +277 -0
  115. package/dist/commands/versions.js.map +1 -0
  116. package/dist/commands/view.js +3 -2
  117. package/dist/commands/view.js.map +1 -1
  118. package/dist/commands/whoami.d.ts +21 -0
  119. package/dist/commands/whoami.js +129 -0
  120. package/dist/commands/whoami.js.map +1 -0
  121. package/dist/index.js +776 -60
  122. package/dist/index.js.map +1 -1
  123. package/dist/lib/approval-poll.d.ts +42 -0
  124. package/dist/lib/approval-poll.js +52 -0
  125. package/dist/lib/approval-poll.js.map +1 -0
  126. package/dist/lib/auth.d.ts +29 -6
  127. package/dist/lib/auth.js +105 -94
  128. package/dist/lib/auth.js.map +1 -1
  129. package/dist/lib/bundle-version.d.ts +11 -0
  130. package/dist/lib/bundle-version.js +33 -0
  131. package/dist/lib/bundle-version.js.map +1 -0
  132. package/dist/lib/capture-lane.d.ts +30 -12
  133. package/dist/lib/capture-lane.js +71 -14
  134. package/dist/lib/capture-lane.js.map +1 -1
  135. package/dist/lib/cp-packages.d.ts +121 -0
  136. package/dist/lib/cp-packages.js +218 -0
  137. package/dist/lib/cp-packages.js.map +1 -0
  138. package/dist/lib/describe-lens.d.ts +46 -0
  139. package/dist/lib/describe-lens.js +33 -0
  140. package/dist/lib/describe-lens.js.map +1 -0
  141. package/dist/lib/hub-client.d.ts +78 -1
  142. package/dist/lib/hub-client.js +474 -22
  143. package/dist/lib/hub-client.js.map +1 -1
  144. package/dist/lib/installed.d.ts +51 -0
  145. package/dist/lib/installed.js +70 -0
  146. package/dist/lib/installed.js.map +1 -0
  147. package/dist/lib/next-steps.d.ts +61 -0
  148. package/dist/lib/next-steps.js +146 -0
  149. package/dist/lib/next-steps.js.map +1 -0
  150. package/dist/lib/pod.d.ts +91 -19
  151. package/dist/lib/pod.js +222 -56
  152. package/dist/lib/pod.js.map +1 -1
  153. package/dist/lib/project-ref.d.ts +95 -0
  154. package/dist/lib/project-ref.js +144 -0
  155. package/dist/lib/project-ref.js.map +1 -0
  156. package/dist/lib/project.d.ts +35 -0
  157. package/dist/lib/project.js +39 -0
  158. package/dist/lib/project.js.map +1 -0
  159. package/dist/lib/session-lens.d.ts +33 -0
  160. package/dist/lib/session-lens.js +76 -0
  161. package/dist/lib/session-lens.js.map +1 -0
  162. package/dist/lib/skill-import.d.ts +40 -0
  163. package/dist/lib/skill-import.js +203 -0
  164. package/dist/lib/skill-import.js.map +1 -0
  165. package/dist/lib/skills-installer.d.ts +17 -6
  166. package/dist/lib/skills-installer.js +133 -19
  167. package/dist/lib/skills-installer.js.map +1 -1
  168. package/dist/lib/suite.d.ts +28 -0
  169. package/dist/lib/suite.js +29 -0
  170. package/dist/lib/suite.js.map +1 -0
  171. package/dist/lib/superwhisper-import.d.ts +40 -0
  172. package/dist/lib/superwhisper-import.js +389 -0
  173. package/dist/lib/superwhisper-import.js.map +1 -0
  174. package/dist/lib/targets.d.ts +49 -1
  175. package/dist/lib/targets.js +420 -288
  176. package/dist/lib/targets.js.map +1 -1
  177. package/dist/lib/unwrapList.d.ts +1 -0
  178. package/dist/lib/unwrapList.js +20 -0
  179. package/dist/lib/unwrapList.js.map +1 -0
  180. package/dist/utils/logger.d.ts +2 -0
  181. package/dist/utils/logger.js +10 -2
  182. package/dist/utils/logger.js.map +1 -1
  183. package/package.json +9 -4
  184. package/skills/agent-os/SKILL.md +212 -0
  185. package/skills/manifest.json +5 -0
  186. package/skills/onboard/SKILL.md +186 -0
  187. package/skills/synap/SKILL.md +1182 -37
  188. package/skills/synap/_order.txt +37 -0
  189. package/skills/synap/_skill.yaml +24 -0
  190. package/skills/synap/authentication.md +10 -0
  191. package/skills/synap/automations.md +264 -0
  192. package/skills/synap/capabilities.md +107 -0
  193. package/skills/synap/capture.md +10 -0
  194. package/skills/synap/cli-operations.md +107 -0
  195. package/skills/synap/common-mistakes.md +12 -0
  196. package/skills/synap/creative-loop.md +43 -0
  197. package/skills/synap/crm.md +117 -0
  198. package/skills/synap/diagnostics.md +35 -0
  199. package/skills/synap/digesting-a-channel.md +38 -0
  200. package/skills/synap/document-embeds.md +123 -0
  201. package/skills/synap/escalation-ladder.md +71 -0
  202. package/skills/synap/focus-sessions.md +47 -0
  203. package/skills/synap/governance-rules.md +64 -0
  204. package/skills/synap/governance.md +6 -6
  205. package/skills/synap/graph-gardening.md +21 -0
  206. package/skills/synap/inline-patterns.md +38 -0
  207. package/skills/synap/lenses.md +38 -0
  208. package/skills/synap/linking-principle.md +39 -0
  209. package/skills/synap/linking.md +1 -0
  210. package/skills/synap/mental-model.md +45 -0
  211. package/skills/synap/more.md +7 -0
  212. package/skills/synap/multi-entity-capture.md +10 -0
  213. package/skills/synap/next-action.md +37 -0
  214. package/skills/synap/north-star.md +17 -0
  215. package/skills/synap/operating-mode-rules.md +45 -0
  216. package/skills/synap/operating-mode.md +9 -0
  217. package/skills/synap/quick-reference.md +67 -0
  218. package/skills/synap/reading.md +43 -0
  219. package/skills/synap/recap.md +21 -0
  220. package/skills/synap/reflexes.md +46 -0
  221. package/skills/synap/response-style.md +21 -0
  222. package/skills/synap/scope.md +13 -0
  223. package/skills/synap/showing.md +17 -0
  224. package/skills/synap/user-model.md +25 -0
  225. package/skills/synap/viewframe-cells.md +290 -0
  226. package/skills/synap/work-flow.md +113 -0
  227. package/skills/synap/worked-examples.md +53 -0
  228. package/skills/synap/workspace-design.md +45 -0
  229. package/skills/synap/workspace-edges.md +49 -0
  230. package/skills/synap/writes.md +156 -0
  231. package/skills/synap-schema/SKILL.md +97 -6
  232. package/skills/synap-schema/_order.txt +13 -0
  233. package/skills/synap-schema/_skill.yaml +22 -0
  234. package/skills/synap-schema/before-you-touch.md +14 -0
  235. package/skills/synap-schema/common-mistakes.md +9 -0
  236. package/skills/synap-schema/creating-profiles.md +17 -0
  237. package/skills/synap-schema/discover-profiles.md +24 -0
  238. package/skills/synap-schema/entity-scope.md +8 -0
  239. package/skills/synap-schema/extend-vs-create.md +31 -0
  240. package/skills/synap-schema/more.md +6 -0
  241. package/skills/synap-schema/overlay-properties.md +22 -0
  242. package/skills/synap-schema/profiles.md +3 -0
  243. package/skills/synap-schema/property-defs.md +29 -0
  244. package/skills/synap-schema/read-before-write.md +50 -0
  245. package/skills/synap-schema/relations.md +18 -0
  246. package/skills/synap-schema/worked-example.md +30 -0
  247. package/skills/synap-ui/SKILL.md +26 -2
  248. package/skills/synap-ui/_order.txt +13 -0
  249. package/skills/synap-ui/_skill.yaml +23 -0
  250. package/skills/synap-ui/ai-companion.md +27 -0
  251. package/skills/synap-ui/arranging-bento.md +8 -0
  252. package/skills/synap-ui/before-you-build.md +20 -0
  253. package/skills/synap-ui/bento-layouts.md +35 -0
  254. package/skills/synap-ui/common-mistakes.md +10 -0
  255. package/skills/synap-ui/creating-views.md +26 -0
  256. package/skills/synap-ui/four-builds.md +24 -0
  257. package/skills/synap-ui/more.md +7 -0
  258. package/skills/synap-ui/proposing-vs-extending.md +11 -0
  259. package/skills/synap-ui/view-list.md +24 -0
  260. package/skills/synap-ui/views.md +3 -0
  261. package/skills/synap-ui/worked-example.md +18 -0
  262. package/skills/synap-ui/workspaces.md +47 -0
  263. package/templates/automations/bookmark-enrichment.automation.json +44 -0
  264. package/templates/automations/mail-feed.automation.json +86 -0
  265. package/templates/automations/url-bookmark-capture.automation.json +70 -0
  266. package/templates/skills/README.md +21 -0
  267. package/templates/skills/authoring-automations/SKILL.md +95 -0
  268. package/templates/skills/authoring-automations/reference/node-matrix.md +49 -0
  269. package/templates/skills/authoring-capabilities/SKILL.md +93 -0
  270. package/templates/skills/authoring-capabilities/reference/template-anatomy.md +70 -0
  271. package/templates/skills/authoring-playbooks/SKILL.md +102 -0
  272. package/templates/skills/authoring-playbooks/reference/stages-contract.md +35 -0
  273. package/templates/skills/authoring-playbooks/reference/worked-example.md +64 -0
  274. package/templates/skills/bookmark-enrichment/SKILL.md +40 -0
  275. package/templates/skills/coordinating-agents/SKILL.md +32 -0
  276. package/templates/skills/coordinating-branches/SKILL.md +27 -0
  277. package/templates/skills/mapping-the-server/SKILL.md +54 -0
  278. package/templates/skills/reading-client-progress/SKILL.md +65 -0
  279. package/templates/skills/routing-to-channels/SKILL.md +54 -0
  280. package/templates/skills/stellar-scf-grants-advisor/ASSOCIATE-CHEATSHEET.md +133 -0
  281. package/templates/skills/stellar-scf-grants-advisor/ASSOCIATE-ONBOARDING-GUIDE.md +761 -0
  282. package/templates/skills/stellar-scf-grants-advisor/CLIENT-FAQ.md +181 -0
  283. package/templates/skills/stellar-scf-grants-advisor/PARTNER-HANDOVER.md +130 -0
  284. package/templates/skills/stellar-scf-grants-advisor/SKILL.md +102 -0
  285. package/templates/skills/stellar-scf-grants-advisor/examples/README.md +43 -0
  286. package/templates/skills/stellar-scf-grants-advisor/examples/chat-summary-templates.md +158 -0
  287. package/templates/skills/stellar-scf-grants-advisor/examples/corpus-comparable-rows.md +136 -0
  288. package/templates/skills/stellar-scf-grants-advisor/examples/q10-team-rewrites.md +109 -0
  289. package/templates/skills/stellar-scf-grants-advisor/examples/q2-description-rewrites.md +88 -0
  290. package/templates/skills/stellar-scf-grants-advisor/examples/q6-integration-rewrites.md +107 -0
  291. package/templates/skills/stellar-scf-grants-advisor/examples/tranche-structures.md +176 -0
  292. package/templates/skills/stellar-scf-grants-advisor/reference/01-methodology.md +96 -0
  293. package/templates/skills/stellar-scf-grants-advisor/reference/02-scoring-framework.md +199 -0
  294. package/templates/skills/stellar-scf-grants-advisor/reference/03-rejection-patterns.md +241 -0
  295. package/templates/skills/stellar-scf-grants-advisor/reference/04-winner-patterns.md +120 -0
  296. package/templates/skills/stellar-scf-grants-advisor/reference/05-comeback-patterns.md +92 -0
  297. package/templates/skills/stellar-scf-grants-advisor/reference/06-budget-benchmarks.md +125 -0
  298. package/templates/skills/stellar-scf-grants-advisor/reference/07-integration-list.md +147 -0
  299. package/templates/skills/stellar-scf-grants-advisor/reference/08-abstract-fields.md +258 -0
  300. package/templates/skills/stellar-scf-grants-advisor/reference/09-build-fields.md +259 -0
  301. package/templates/skills/stellar-scf-grants-advisor/reference/10-corpus-winners.md +135 -0
  302. package/templates/skills/stellar-scf-grants-advisor/reference/11-corpus-rejects.md +267 -0
  303. package/templates/skills/stellar-scf-grants-advisor/reference/12-client-communication.md +131 -0
  304. package/templates/skills/stellar-scf-grants-advisor/reference/13-excel-output-spec.md +199 -0
  305. package/templates/skills/stellar-scf-grants-advisor/reference/14-worked-examples.md +160 -0
  306. package/templates/skills/stellar-scf-grants-advisor/templates/abstract-review-builder.py +253 -0
  307. package/templates/skills/stellar-scf-grants-advisor/templates/build-review-builder.py +213 -0
  308. package/dist/commands/connectors.d.ts +0 -31
  309. package/dist/commands/connectors.js +0 -276
  310. package/dist/commands/connectors.js.map +0 -1
  311. package/dist/commands/finish.d.ts +0 -25
  312. package/dist/commands/finish.js +0 -274
  313. package/dist/commands/finish.js.map +0 -1
  314. package/dist/commands/openclaw.d.ts +0 -40
  315. package/dist/commands/openclaw.js +0 -1148
  316. package/dist/commands/openclaw.js.map +0 -1
  317. package/dist/commands/security-audit.d.ts +0 -12
  318. package/dist/commands/security-audit.js +0 -100
  319. package/dist/commands/security-audit.js.map +0 -1
  320. package/dist/lib/hardening.d.ts +0 -18
  321. package/dist/lib/hardening.js +0 -214
  322. package/dist/lib/hardening.js.map +0 -1
  323. package/node_modules/@synap/hub-rest-client/dist/index.cjs +0 -881
  324. package/node_modules/@synap/hub-rest-client/dist/index.d.cts +0 -907
  325. package/node_modules/@synap/hub-rest-client/dist/index.d.ts +0 -907
  326. package/node_modules/@synap/hub-rest-client/dist/index.js +0 -851
  327. package/node_modules/@synap/hub-rest-client/package.json +0 -45
  328. package/node_modules/@synap/hub-rest-client/src/client.ts +0 -1143
  329. package/node_modules/@synap/hub-rest-client/src/errors.ts +0 -30
  330. package/node_modules/@synap/hub-rest-client/src/index.ts +0 -111
  331. package/node_modules/@synap/hub-rest-client/src/setup.ts +0 -77
  332. package/node_modules/@synap/hub-rest-client/src/types.ts +0 -639
@@ -0,0 +1,37 @@
1
+ operating-mode.md
2
+ reflexes.md
3
+ escalation-ladder.md
4
+ mental-model.md
5
+ quick-reference.md
6
+ lenses.md
7
+ operating-mode-rules.md
8
+ cli-operations.md
9
+ scope.md
10
+ work-flow.md
11
+ linking-principle.md
12
+ governance-rules.md
13
+ capabilities.md
14
+ writes.md
15
+ document-embeds.md
16
+ creative-loop.md
17
+ graph-gardening.md
18
+ next-action.md
19
+ reading.md
20
+ multi-entity-capture.md
21
+ worked-examples.md
22
+ crm.md
23
+ common-mistakes.md
24
+ inline-patterns.md
25
+ focus-sessions.md
26
+ automations.md
27
+ diagnostics.md
28
+ workspace-design.md
29
+ workspace-edges.md
30
+ more.md
31
+ viewframe-cells.md
32
+ authentication.md
33
+ response-style.md
34
+ recap.md
35
+ showing.md
36
+ user-model.md
37
+ north-star.md
@@ -0,0 +1,24 @@
1
+ name: synap
2
+ description: >
3
+ Use this skill whenever the user wants to capture, remember, find, or structure
4
+ information in their Synap data pod. Triggers: creating a task, note, person,
5
+ company, project, event, contact, or deal; saving an article or webpage;
6
+ storing a fact about someone ("Alice prefers async"); searching the user's
7
+ knowledge ("find my notes on X", "who did I meet last week"); linking entities;
8
+ logging a meeting or a contact; capturing unstructured text into structured
9
+ entities; reading what's in the user's pod before answering questions about
10
+ their life, work, or projects; posting to their personal AI channel. The pod
11
+ is the user's sovereign source of truth — prefer it over your own context
12
+ when the user asks about their own data. Do NOT use this skill for extending
13
+ the schema (use synap-schema) or building dashboards and views (use synap-ui).
14
+ metadata:
15
+ openclaw:
16
+ requires:
17
+ env: [SYNAP_HUB_API_KEY, SYNAP_POD_URL]
18
+ optional_env:
19
+ [SYNAP_WORKSPACE_ID, SYNAP_USER_ID, SYNAP_DEFAULT_CHANNEL_ID]
20
+ primaryEnv: SYNAP_HUB_API_KEY
21
+ homepage: https://synap.live
22
+ capabilities: [memory, knowledge-graph, channels]
23
+ os: [macos, linux, windows]
24
+ userInvocable: false
@@ -0,0 +1,10 @@
1
+ ## Authentication
2
+
3
+ ```
4
+ Authorization: Bearer {SYNAP_HUB_API_KEY}
5
+ X-Workspace-Id: {workspaceId} (optional; also pass in body/query)
6
+
7
+ Scopes:
8
+ hub-protocol.read → most GET endpoints
9
+ hub-protocol.write → all writes AND GET /channels/personal
10
+ ```
@@ -0,0 +1,264 @@
1
+ # Automations
2
+
3
+ Create workflow automations that trigger automatically based on events, schedules, or webhooks.
4
+
5
+ ## Automation Structure
6
+
7
+ Every automation has:
8
+
9
+ 1. **Trigger** (exactly one) — what starts the automation
10
+ 2. **Steps** (one or more) — commands, conditions, delays, outputs connected in a flow
11
+
12
+ ## Trigger Types
13
+
14
+ | Type | Config | Example |
15
+ | --------- | ---------------------------- | ------------------------------------ |
16
+ | `event` | `{ eventPattern, filters? }` | Entity created with specific profile |
17
+ | `cron` | `{ expression }` | Daily at 9am: `"0 9 * * *"` |
18
+ | `webhook` | `{ webhookSubscriptionId }` | External service sends data |
19
+ | `manual` | `{}` | User-triggered from UI |
20
+
21
+ ### Event Patterns
22
+
23
+ Format: `{subjectType}.{action}.completed`
24
+
25
+ Common patterns:
26
+
27
+ - `entity.create.completed` — entity created and persisted
28
+ - `entity.update.completed` — entity updated
29
+ - `entity.delete.completed` — entity deleted
30
+ - `document.create.completed` — document created
31
+ - `document.update.completed` — document updated
32
+
33
+ Filters narrow the event to specific conditions:
34
+
35
+ ```json
36
+ {
37
+ "eventPattern": "entity.create.completed",
38
+ "filters": { "profileSlug": "task", "metadata.priority": "high" }
39
+ }
40
+ ```
41
+
42
+ ### Cron Expressions
43
+
44
+ Standard 5-field cron (minute hour day month weekday):
45
+
46
+ - `"0 9 * * *"` — daily at 9am
47
+ - `"0 9 * * MON"` — every Monday at 9am
48
+ - `"*/30 * * * *"` — every 30 minutes
49
+ - `"0 0 1 * *"` — first day of month at midnight
50
+
51
+ ## Step Types
52
+
53
+ ### command
54
+
55
+ Execute an intelligence command. Reference by `commandId` or describe inline.
56
+
57
+ ```json
58
+ {
59
+ "id": "extract",
60
+ "type": "command",
61
+ "data": {
62
+ "commandTitle": "Extract key entities",
63
+ "inputMapping": {
64
+ "content": "{{trigger.payload.entity.content}}",
65
+ "context": "{{trigger.payload.entity.name}}"
66
+ }
67
+ }
68
+ }
69
+ ```
70
+
71
+ **Input mapping** uses template syntax:
72
+
73
+ - `{{trigger.payload.*}}` — data from the triggering event
74
+ - `{{steps.<stepId>.output.*}}` — output from a prior step
75
+ - `{{loop.item}}` — current item in a loop
76
+
77
+ ### condition
78
+
79
+ Branch the flow based on a boolean expression.
80
+
81
+ ```json
82
+ {
83
+ "id": "check-priority",
84
+ "type": "condition",
85
+ "data": {
86
+ "label": "High priority?",
87
+ "expression": "trigger.payload.entity.metadata.priority === 'high'",
88
+ "trueLabel": "Yes",
89
+ "falseLabel": "No"
90
+ }
91
+ }
92
+ ```
93
+
94
+ Conditions have two output handles: `yes` and `no`. Connect subsequent steps to the appropriate handle.
95
+
96
+ ### delay
97
+
98
+ Wait before continuing.
99
+
100
+ ```json
101
+ {
102
+ "id": "wait",
103
+ "type": "delay",
104
+ "data": { "duration": "5m", "label": "Cool down" }
105
+ }
106
+ ```
107
+
108
+ Supported durations: `30s`, `5m`, `1h`, `1d`, `1w`.
109
+
110
+ ### output
111
+
112
+ Terminal action — the end result of the automation.
113
+
114
+ ```json
115
+ {
116
+ "id": "notify",
117
+ "type": "output",
118
+ "data": {
119
+ "label": "Send notification",
120
+ "outputType": "notification",
121
+ "config": {
122
+ "message": "New high-priority task: {{trigger.payload.entity.name}}"
123
+ }
124
+ }
125
+ }
126
+ ```
127
+
128
+ Output types:
129
+
130
+ - `notification` — in-app notification to the user
131
+ - `entity_create` — create a new entity (config: `{ profileSlug, title, properties }`)
132
+ - `entity_update` — update an existing entity (config: `{ entityId, properties }`)
133
+ - `webhook` — POST to external URL (config: `{ url, headers?, body }`)
134
+ - `channel_message` — post a message to a channel (config: `{ channelId, content }`)
135
+
136
+ ### loop
137
+
138
+ Iterate over a collection from a prior step.
139
+
140
+ ```json
141
+ {
142
+ "id": "for-each-result",
143
+ "type": "loop",
144
+ "data": {
145
+ "label": "For each search result",
146
+ "iteratorExpression": "steps.search.output.results",
147
+ "itemVariable": "item"
148
+ }
149
+ }
150
+ ```
151
+
152
+ Inside the loop, reference `{{loop.item}}` for the current element.
153
+
154
+ ## Connecting Steps
155
+
156
+ Steps are connected via `dependsOn` (which step must complete first) and optional `conditionBranch` (which branch to follow from a condition).
157
+
158
+ ```json
159
+ {
160
+ "steps": [
161
+ { "id": "check", "type": "condition", "data": {...} },
162
+ { "id": "notify-high", "type": "output", "data": {...}, "dependsOn": ["check"], "conditionBranch": "yes" },
163
+ { "id": "log-normal", "type": "output", "data": {...}, "dependsOn": ["check"], "conditionBranch": "no" }
164
+ ]
165
+ }
166
+ ```
167
+
168
+ ## Discovering Commands
169
+
170
+ Before creating automations with command steps, call `list_commands` to discover available intelligence commands in the workspace. Use the command `id` in the step's `commandId` field.
171
+
172
+ If no suitable command exists, you can leave `commandId` empty and set `commandTitle` + `inputMapping` — the execution engine will use the title as a prompt template.
173
+
174
+ ## Vault References
175
+
176
+ Automation configs that need secrets (API keys, auth tokens) should use vault references instead of hardcoded values:
177
+
178
+ - `vault://secret-uuid` — resolves to the full secret value at runtime
179
+ - `vault://secret-uuid/field-name` — resolves a specific field from a JSON secret
180
+
181
+ Only server-encrypted secrets can be resolved by the automation engine. The user must store the credential in the vault first.
182
+
183
+ ## Best Practices
184
+
185
+ 1. **Keep it simple** — Start with trigger → command → output. Add complexity only when needed.
186
+ 2. **Name clearly** — Use descriptive labels: "When task created with high priority" not "Trigger 1".
187
+ 3. **One purpose** — Each automation should do one thing well. Compose multiple automations rather than building one complex flow.
188
+ 4. **Filter early** — Use trigger filters to avoid unnecessary execution. Don't use a condition step when a trigger filter suffices.
189
+ 5. **Test first** — Create automations as `draft` status. Let the user review the flow visualization before activating.
190
+
191
+ ## Example: Auto-archive completed tasks
192
+
193
+ ```json
194
+ {
195
+ "name": "Auto-archive completed tasks",
196
+ "description": "When a task status changes to 'done', archive it after 24 hours",
197
+ "trigger": {
198
+ "type": "event",
199
+ "config": {
200
+ "eventPattern": "entity.update.completed",
201
+ "filters": { "profileSlug": "task", "metadata.status": "done" }
202
+ }
203
+ },
204
+ "steps": [
205
+ {
206
+ "id": "wait-24h",
207
+ "type": "delay",
208
+ "data": { "duration": "1d", "label": "Wait 24h" }
209
+ },
210
+ {
211
+ "id": "archive",
212
+ "type": "output",
213
+ "data": {
214
+ "label": "Archive task",
215
+ "outputType": "entity_update",
216
+ "config": {
217
+ "entityId": "{{trigger.payload.entity.id}}",
218
+ "properties": { "archived": true }
219
+ }
220
+ },
221
+ "dependsOn": ["wait-24h"]
222
+ }
223
+ ]
224
+ }
225
+ ```
226
+
227
+ ## Example: Notify on high-priority tasks
228
+
229
+ ```json
230
+ {
231
+ "name": "High-priority task alerts",
232
+ "description": "Send a notification when a high-priority task is created",
233
+ "trigger": {
234
+ "type": "event",
235
+ "config": {
236
+ "eventPattern": "entity.create.completed",
237
+ "filters": { "profileSlug": "task" }
238
+ }
239
+ },
240
+ "steps": [
241
+ {
242
+ "id": "check-priority",
243
+ "type": "condition",
244
+ "data": {
245
+ "label": "High priority?",
246
+ "expression": "trigger.payload.entity.metadata.priority === 'high'"
247
+ }
248
+ },
249
+ {
250
+ "id": "notify",
251
+ "type": "output",
252
+ "data": {
253
+ "label": "Alert: high-priority task",
254
+ "outputType": "notification",
255
+ "config": {
256
+ "message": "New urgent task: {{trigger.payload.entity.name}}"
257
+ }
258
+ },
259
+ "dependsOn": ["check-priority"],
260
+ "conditionBranch": "yes"
261
+ }
262
+ ]
263
+ }
264
+ ```
@@ -0,0 +1,107 @@
1
+ # Capabilities — discover, run, and the when-blocked reflex
2
+
3
+ Capabilities are the verbs a workspace's connected services and applied
4
+ templates unlock — `gmail_send`, `gmail_search`, `calendar_create`,
5
+ `drive_search`, and so on. They are the bridge between "I can talk about it"
6
+ and "I can actually do it."
7
+
8
+ ## Discover: `list_capabilities`
9
+
10
+ MCP: `synap_list_capabilities`. IS: `list_capabilities`. Takes
11
+ `{ query, kind?, limit? }` (plus `workspaceId`).
12
+
13
+ **Search first — never dump-and-eyeball.** A workspace can carry 100+
14
+ capability entries; call with a `query` describing the action you're after
15
+ ("send email", "search calendar") and read the ranked, compact results. Don't
16
+ fetch the unfiltered list and scan it yourself.
17
+
18
+ Each entry carries:
19
+
20
+ - `name` (the `verbId` you pass to `run_capability`), `label`, backing tool
21
+ - `paramsSchema` — the shape `parameters` must satisfy; check it before calling
22
+ - `enabled` — `true` means it will run right now. `false`/DRAFT means it's
23
+ installed but the user hasn't approved it yet (Settings → Capabilities)
24
+
25
+ ## Run: `run_capability`
26
+
27
+ MCP: `synap_run_capability`. IS: `run_capability`. Pass `verbId` (or
28
+ `skillId`) + `parameters` + `workspaceId`.
29
+
30
+ ```json
31
+ {
32
+ "verbId": "gmail_send",
33
+ "parameters": { "to": "…", "subject": "…", "body": "…" },
34
+ "workspaceId": "{workspaceId}"
35
+ }
36
+ ```
37
+
38
+ Check `paramsSchema` from discovery before calling — a missing required
39
+ parameter is refused, not guessed.
40
+
41
+ **`proposed` is a normal outcome, not a failure.** A capability run can land
42
+ as a proposal exactly like any other governed write (see `governance.md`):
43
+ tell the user why, share the `reviewUrl`, and don't retry.
44
+
45
+ **Provider results can be 200-with-error-body.** A successful HTTP call to
46
+ Gmail/Calendar/Drive can still carry `result.success: false` +
47
+ `result.error` — an auth expiry, a bad recipient, a quota limit. **Always
48
+ check `result.success`/`result.error` in the response before telling the
49
+ user the action worked.** A 200 status is not proof of success here.
50
+
51
+ ## The when-blocked reflex
52
+
53
+ When you cannot do something the user asked for — no matching tool, a
54
+ "not found" verb, "no connection", "not enabled" — do not fabricate a result
55
+ and do not silently give up. Follow this order:
56
+
57
+ 1. **Search first.** `list_capabilities({ query })` for what the user actually
58
+ wants. Capabilities are added over time; don't assume today's tool list is
59
+ the ceiling.
60
+ 2. **Found but blocked?** If the verb exists but is DRAFT (not enabled) or its
61
+ backing connection is missing, tell the user exactly what to do and where:
62
+ "This needs Gmail connected — enable it in Settings → Capabilities" (or
63
+ the equivalent connect deep-link the error hands you). Don't attempt the
64
+ run again until they've acted.
65
+ 3. **Still nothing? Search the marketplace.** `market.search({query, kind?})`
66
+ over what could be _installed_ (capabilities, automations, workspace
67
+ templates, cells) — a cache read, not a live fetch, so it's always fast.
68
+ 4. **Found in the marketplace?** `market.install({slug, kind, version?})`. As
69
+ an agent this ALWAYS lands as a reviewable proposal — never auto-installs,
70
+ even with a grant on the verb itself. Share the `reviewUrl`; don't retry.
71
+ 5. **Truly nothing, anywhere?** That is escalation-ladder **L2 empty → L3**:
72
+ say precisely what's missing (the action, not "I can't"), offer to capture
73
+ the gap, and if the need is structural (new capability package, template,
74
+ automation), propose via marketplace/install or meta tools — never
75
+ dead-end and never fabricate a result.
76
+
77
+ <!-- brief:start -->
78
+
79
+ When blocked (ladder L2→L3): (1) `list_capabilities({query})` first — never
80
+ assume today's list is the ceiling. (2) Found but DRAFT/no connection → tell
81
+ the user exactly what to enable/connect and where; don't retry until they've
82
+ acted. (3) Still nothing → `market.search({query, kind?})`; `market.install`
83
+ on a hit always proposes for an agent. (4) Truly nothing → say precisely
84
+ what's missing, offer to capture the gap or propose L3 structure — never
85
+ fabricate, never silent give-up. Provider 200-with-error-body: always check
86
+ `result.success`/`result.error` before claiming success.
87
+
88
+ <!-- brief:end -->
89
+
90
+ ## Errors — what they mean, what to do next
91
+
92
+ | You see roughly... | Meaning | Next step |
93
+ | ------------------------------------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------- |
94
+ | verb/skill "not found" in this workspace | No capability by that name is registered here | `list_capabilities({query})`; if nothing, tell the user what's missing |
95
+ | capability "not approved" / DRAFT | It exists but the user hasn't enabled it yet | Tell the user to enable it (Settings → Capabilities); don't retry |
96
+ | a required parameter is missing | Your `parameters` didn't satisfy the verb's `paramsSchema` | Re-check `paramsSchema` from discovery, fill the gap, retry once |
97
+ | no connection / credential for this service | The verb needs a connected account (Gmail, Calendar, …) that isn't set up | Hand the user the connect link; don't retry until connected |
98
+ | `status: "proposed"` | Normal governed outcome — this run needs human approval | Share `summary` + `reviewUrl`; don't retry (see `governance.md`) |
99
+ | `status: "denied"` | Workspace policy blocked it outright | Explain the reason; don't retry |
100
+ | provider result with `success: false` | The call reached the provider but the provider itself rejected it | Read `result.error`; tell the user what actually happened, don't report success |
101
+
102
+ ## What NOT to do
103
+
104
+ - Don't dump the full unfiltered capability list and eyeball it — search.
105
+ - Don't retry a `proposed` or `denied` result as if it were a transient error.
106
+ - Don't tell the user an action "worked" without checking `result.success`.
107
+ - Don't invent a capability, verb, or connection that discovery didn't return.
@@ -119,6 +119,14 @@ Response:
119
119
 
120
120
  The executor goes through governance (see `governance.md`). Expect the same three `status` values.
121
121
 
122
+ ## Placement — existing lenses only
123
+
124
+ Capture **never invents a workspace** (or other meta-structure) to "find a home"
125
+ for extracted entities. Route into **existing** workspaces/projects/profiles the
126
+ user already has — orient + list_profiles first when placement is ambiguous.
127
+ Structure emerges progressively: capture into what exists; suggest a new profile only when the user repeatedly tracks a thing that fits none, and a view only once that profile has 3+ entities — never impose schema upfront. Missing structure is an escalation-ladder L2→L3 conversation (discover, then
128
+ propose), not a side effect of capture. See `reflexes.md` / `escalation-ladder.md`.
129
+
122
130
  ## When to use the pipeline vs. manual CRUD
123
131
 
124
132
  | Situation | Use |
@@ -133,6 +141,8 @@ The executor goes through governance (see `governance.md`). Expect the same thre
133
141
 
134
142
  Rule of thumb: **one intent, one call.** Multi-entity content, use the pipeline.
135
143
 
144
+ **Degrade path (MCP `synap_capture`, the single-call door):** when the structuring pipeline fails or finds nothing to extract, it degrades to a single flat note carrying the raw text verbatim — it never drops the input. Use `synap_capture` only for genuinely unstructured input where you don't yet know the entities; if you already know the exact profileSlug and field values, call `synap_create_entity` instead (deterministic, direct write, no degrade path).
145
+
136
146
  ## Dedup within the pipeline
137
147
 
138
148
  The pipeline does its own duplicate check per entity (by title + profileSlug within workspace). When it finds a match, `action` becomes `"update"` with `existingEntityId` set, so the real entity is updated in place, not duplicated.
@@ -0,0 +1,107 @@
1
+ ## CLI Data Operations (Bash tool)
2
+
3
+ When Claude Code (or any agent with Bash access) is using this skill, prefer the `synap` CLI over raw HTTP calls — auth is automatic, output is clean JSON, no spinners in `--json` mode.
4
+
5
+ **Session context — set once, never repeat:**
6
+
7
+ The CLI inherits your pod + lens automatically; set them once and every later command picks them up. Do NOT pass `--pod-url`, `--api-key`, or `--workspace` on every command. Inside a Claude session, `synap use` / `synap project use` bind **this session's lens** (`~/.synap/lenses/<session_id>.json`) — so concurrent sessions stay independent; outside one, they set the global default (`~/.synap/config.json`).
8
+
9
+ ```bash
10
+ synap pods use <profile-name> # switch active pod
11
+ synap use <workspace-id> # focus a workspace (this session) — captures land here; it IS the domain
12
+ synap project use <id> # add the project lens (composable)
13
+ synap lens # inspect: workspace + project + session this session resolves to
14
+ ```
15
+
16
+ **Always orient first:**
17
+
18
+ ```bash
19
+ synap orient --json
20
+ # Returns: userId, podUrl, workspaces[{id, name, slug}]
21
+ # Never hardcode workspace IDs — discover them here.
22
+ ```
23
+
24
+ **Ask (the one read verb — routes across all substrates):**
25
+
26
+ ```bash
27
+ synap ask "project ideas" --json
28
+ synap ask "what did Antoine decide about auth" --workspace=<id> --json
29
+ synap ask "how do I deploy the backend" --json # routes to procedural how-to docs
30
+ # Omit --workspace for pod-wide; include it to scope to one workspace.
31
+ # `ask` classifies intent and unions the right substrate(s) — it replaces search/recall.
32
+ ```
33
+
34
+ **Read entities:**
35
+
36
+ ```bash
37
+ synap list workspaces --json
38
+ synap list entities --workspace=<id> --json
39
+ synap list entities --profile=task --workspace=<id> --json
40
+ synap get entity <id> --json
41
+ ```
42
+
43
+ **Capturing a decision (the AI structures — it never `note`s):**
44
+
45
+ ```bash
46
+ synap capture --type decision --claim "Use Typesense for entity search" --json
47
+ # Retrieve later with the one read verb: synap ask "Typesense decision"
48
+ ```
49
+
50
+ > `synap note` is the HUMAN's raw "dump now, structure later" inbox. As the AI, always `capture` into a lane — structuring is your job.
51
+
52
+ **Structured knowledge (durable, typed, searchable — preferred for engineering learnings):**
53
+
54
+ ```bash
55
+ # Work lane (default): a domain gotcha/lesson/decision → knowledge entity in the ACTIVE workspace
56
+ synap capture --type gotcha --claim "Hono static routes must come before /:id" \
57
+ --why "First-match routing; dynamic routes eat static ones" \
58
+ --tags "repo:synap-backend,layer:routing" --json
59
+
60
+ synap capture --type lesson --claim "code-read ≠ runtime-true for library APIs" \
61
+ --evidence "tldraw 2.4.6 binding API changed silently from props.start.boundShapeId"
62
+
63
+ # A quick decision-note is a typed knowledge entry (ek_type=decision):
64
+ synap capture --type decision --claim "Use Typesense for entity search" \
65
+ --why "pgvector deferred to V1; Typesense ships now" --json
66
+
67
+ # Global lane: a runbook/best-practice that holds across ALL projects → pod-wide knowledge_keys
68
+ synap capture --global --type reference --claim "Always fix the canonical path, never a workaround" \
69
+ --key "principle:root-cause" --json
70
+
71
+ # Retrieve any of it later with the one read verb (it spans every lane):
72
+ synap ask "hono routing gotcha" --json
73
+ ```
74
+
75
+ `synap capture --type` writes a typed **`knowledge`** entity in the **active workspace** (the Work lane); `ek_type` (gotcha|lesson|decision|reference) discriminates the kind — **one store, type tags, not a residual dump**. It's workspace-scoped, so the active workspace supplies the domain — a Builder gotcha ≠ a marketing one (there is no `engineering_knowledge`). Add **`--global`** to write a pod-wide cross-cutting runbook to `knowledge_keys` instead. A formal **decision RECORD** (rationale, alternatives, superseded-by lifecycle) is a different artifact — use smart `synap capture "<free text>"` or `synap create entity --profile=decision`. Retrieve everything with `synap ask`.
76
+ Use `capture` for anything worth remembering across sessions and projects.
77
+
78
+ **Open (the one display door):**
79
+
80
+ ```bash
81
+ synap open <id> # resolves type automatically, opens in browser
82
+ synap open entity <id> # open entity detail
83
+ synap open proposal <id> # open proposal review
84
+ synap open view <id> # open a view
85
+ synap open cell <typeKey> # open a registered cell by typeKey
86
+ synap open document <id> # open a document
87
+ ```
88
+
89
+ The bare-ID form calls `GET /api/hub/resolve/:id` to determine the type before dispatching. Use this when you don't know what type a UUID is — `synap open <id>` always works.
90
+
91
+ **Write:**
92
+
93
+ ```bash
94
+ synap create entity --profile=note --name="Meeting notes" --workspace=<id> --json
95
+ synap set entity <id> --props='{"status":"done"}' --json
96
+ ```
97
+
98
+ **Multi-agent:** If `SYNAP_AGENT` env var is set, the CLI uses that named identity's API key from `~/.synap/config.json` instead of the default pod credentials. Use `synap agents list` to see configured identities.
99
+
100
+ **Rules:**
101
+
102
+ - Always use `--json` when calling from code — clean stdout, no spinners, machine-parseable
103
+ - Run `synap orient` first to discover workspace IDs — never hardcode them
104
+ - Omit `--workspace` to operate pod-wide; include it to scope to a specific workspace
105
+ - `synap ask` is the one read verb — it routes keyword + semantic + procedural automatically; you never choose a search backend.
106
+
107
+ ---
@@ -0,0 +1,12 @@
1
+ ## Common mistakes — core data operations
2
+
3
+ 1. **Creating orphan entities.** Always connect to at least one other entity on creation. Search first; if nothing links, reconsider whether this should be memory.
4
+ 2. **Guessing profile slugs.** Always `GET /profiles` first. `deal`, `capture`, and custom profiles may not exist in this workspace.
5
+ 3. **Using the deprecated `type` field.** Always `profileSlug`.
6
+ 4. **Treating `"proposed"` as an error.** It's a governance queue.
7
+ 5. **Forcing `source` to bypass governance.** Governance is determined by the agent user + whitelist, not by `source`. Don't set it.
8
+ 6. **Not knowing your userId.** Use `{SYNAP_USER_ID}` from the env (set by `synap connect`). Or call `GET /api/hub/users/me` → `.id` once and cache it. Never hardcode or guess.
9
+ 7. **Skipping the search step.** Duplicates degrade the graph more than missing data.
10
+ 8. **Forgetting that `GET /channels/personal` needs `hub-protocol.write`** scope — it's get-or-create, not a pure read.
11
+ 9. **Routing known-structure data through free-text capture.** If you already know the profileSlug + fields, create the entity directly — smart capture can degrade to a single flat note.
12
+ 10. **Paragraph session goals.** The goal is one line; put detail and deliverables in expectedOutputs.
@@ -0,0 +1,43 @@
1
+ ## The Creative Loop — do once, then crystallize to reusable config
2
+
3
+ The core rhythm of real work in Synap: **do the thing once by hand, then crystallize what worked into reusable configuration.** You author; the user curates. Every crystallization is governed — a `proposed` result is the normal, successful outcome, never an error.
4
+
5
+ The loop has three moves that compound. Each takes a one-off act and, if it's worth repeating, turns it into standing structure:
6
+
7
+ | Do-once (author) | → Crystallize (curate) | Tool |
8
+ | --------------------------------------- | ----------------------------------- | ----------------------------- |
9
+ | Work a multi-step goal in a **session** | → a **playbook** (the process) | `promote_session_to_playbook` |
10
+ | Show a result in a **cell** | → a **renderer** for an entity type | `promote_cell_to_renderer` |
11
+
12
+ ### 1. Open a session for real work
13
+
14
+ When the task is a unit of work with a deliverable — research, a build, an investigation, a sprint — and there's no active session, **`start_session`** with a clear `goal` and `expectedOutputs`. The session is the spine that accrues results (see the focus-sessions skill). Don't open one for a one-shot lookup or a casual reply.
15
+
16
+ ### 2. Create a cell to REPORT — don't dump data into chat
17
+
18
+ When you have something to _show_ the user — a list of leads, a summary, a comparison, a chart — author a **cell** with `create_cell` instead of pasting rows into the message.
19
+
20
+ - **Declare the data intent in `rendererSource`; do NOT pre-fetch.** Cells use a dynamic data-binding SDK: you describe what the cell needs (e.g. "the open leads in this workspace"), and the runtime binds the live data at render time. Never fetch rows yourself and inline them — that snapshot goes stale and defeats the cell.
21
+ - Keep one cell to one job. A good, focused cell is the raw material for the next move.
22
+
23
+ ### 3. Promote a good cell to a renderer — recurring presentation
24
+
25
+ When a cell is a _good, recurring way to present a whole entity type or step_ — e.g. every `bookmark`'s detail view, every `lead`'s list row — promote it with `promote_cell_to_renderer`:
26
+
27
+ - Pick the `profileSlug` (the entity type), the `slot` (`list` | `detail` | `dashboard`), and the `cellKey` from `create_cell`.
28
+ - This is **governed**: for you it returns `{ status: "proposed", proposalId }`. That is the point — you author the renderer, the user reviews and curates it before it becomes every entity's view. Surface the proposal plainly ("I've proposed this as the detail view for bookmarks — review it when you like"), don't treat it as a failure.
29
+ - Use `scope: "pod"` only when the presentation should apply in every workspace; default to workspace scope.
30
+
31
+ ### 4. Promote a finished session to a playbook — recurring process
32
+
33
+ When the session is done **and the work was a repeatable process** (not a one-off), promote it with `promote_session_to_playbook({ sessionId })`. This captures the goal, tasks, expected outputs, and steps as a reusable session template — so next time the process starts pre-built instead of from scratch.
34
+
35
+ - Do this at the _end_, once the promised outputs are produced and verified.
36
+ - Judge repeatability honestly: a bespoke, never-again investigation is not a playbook. A "weekly competitor scan" or "new-client onboarding" is.
37
+ - Governed like the others — `promoted` (applied) or `proposed` (awaiting review) are both normal.
38
+
39
+ ### The symmetry
40
+
41
+ Sessions and cells are the two things you _do_; playbooks and renderers are the two things you _keep_. The instinct to build: **first do it once concretely, watch it work, then offer to crystallize it** — and let the user decide what becomes standing config. Never crystallize speculatively before the one-off has proven itself.
42
+
43
+ This is escalation ladder **L4**: crystallize only after proof. Blocked/missing structure climbs L2→L3 first (`escalation-ladder.md`); L4 is the success path, not a substitute for discovery.