@aitne-sh/aitne 0.1.8 → 0.1.9

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 (276) hide show
  1. package/README.md +218 -161
  2. package/agent-assets/agent-profiles/_safety.md +3 -3
  3. package/agent-assets/agent-profiles/browser-task.md +108 -0
  4. package/agent-assets/agent-profiles/conversational.md +3 -3
  5. package/agent-assets/agent-profiles/profile-importer.md +2 -2
  6. package/agent-assets/agent-profiles/routine-fetch-window.md +30 -19
  7. package/agent-assets/agents/context-index-reconcile/agent.md +52 -0
  8. package/agent-assets/agents/evening-review/agent.md +53 -0
  9. package/agent-assets/agents/hourly-check/agent.md +62 -0
  10. package/agent-assets/agents/monthly-review/agent.md +55 -0
  11. package/agent-assets/agents/morning-routine/agent.md +78 -0
  12. package/agent-assets/agents/roadmap-maintenance/agent.md +52 -0
  13. package/agent-assets/agents/skill-curation/agent.md +52 -0
  14. package/agent-assets/agents/user-profile-sweep-evening/agent.md +48 -0
  15. package/agent-assets/agents/user-profile-sweep-morning/agent.md +53 -0
  16. package/agent-assets/agents/weekly-review/agent.md +51 -0
  17. package/agent-assets/docs/concepts/agent-day.md +13 -11
  18. package/agent-assets/docs/concepts/auth-health.md +47 -10
  19. package/agent-assets/docs/concepts/backends-and-tiers.md +66 -31
  20. package/agent-assets/docs/concepts/costs-and-quotas.md +50 -15
  21. package/agent-assets/docs/concepts/delegated-mode.md +52 -13
  22. package/agent-assets/docs/concepts/memory-model.md +72 -32
  23. package/agent-assets/docs/concepts/observations.md +49 -11
  24. package/agent-assets/docs/concepts/process-keys.md +56 -22
  25. package/agent-assets/docs/concepts/routines.md +60 -33
  26. package/agent-assets/docs/concepts/safety-and-execution.md +50 -21
  27. package/agent-assets/docs/concepts/safety-model.md +42 -34
  28. package/agent-assets/docs/concepts/skills.md +33 -17
  29. package/agent-assets/docs/features/integrations/browser-history.md +195 -0
  30. package/agent-assets/docs/features/integrations/calendar.md +39 -29
  31. package/agent-assets/docs/features/integrations/git.md +18 -7
  32. package/agent-assets/docs/features/integrations/github.md +84 -33
  33. package/agent-assets/docs/features/integrations/mail.md +59 -16
  34. package/agent-assets/docs/features/integrations/notion.md +18 -6
  35. package/agent-assets/docs/features/integrations/obsidian.md +28 -5
  36. package/agent-assets/docs/features/lifestyle/git.md +42 -38
  37. package/agent-assets/docs/features/lifestyle/reading.md +50 -22
  38. package/agent-assets/docs/features/lifestyle/receipts.md +51 -21
  39. package/agent-assets/docs/features/lifestyle/travel-bookings.md +76 -14
  40. package/agent-assets/docs/features/memory-files/agent-journal.md +111 -50
  41. package/agent-assets/docs/features/memory-files/projects.md +71 -17
  42. package/agent-assets/docs/features/memory-files/roadmap.md +50 -10
  43. package/agent-assets/docs/features/memory-files/schedule.md +113 -70
  44. package/agent-assets/docs/features/memory-files/today.md +46 -21
  45. package/agent-assets/docs/features/memory-files/user-profile.md +63 -33
  46. package/agent-assets/docs/features/messaging/bang-commands.md +113 -36
  47. package/agent-assets/docs/features/messaging/dashboard-chat.md +43 -21
  48. package/agent-assets/docs/features/messaging/discord.md +35 -4
  49. package/agent-assets/docs/features/messaging/overview.md +37 -19
  50. package/agent-assets/docs/features/messaging/pairing-and-magic-phrase.md +94 -27
  51. package/agent-assets/docs/features/messaging/slack.md +67 -14
  52. package/agent-assets/docs/features/messaging/telegram.md +18 -5
  53. package/agent-assets/docs/features/messaging/whatsapp.md +71 -17
  54. package/agent-assets/docs/features/operations/activity-and-conversations.md +44 -15
  55. package/agent-assets/docs/features/operations/approvals.md +48 -16
  56. package/agent-assets/docs/features/operations/backend-routing.md +68 -16
  57. package/agent-assets/docs/features/operations/cost-tracking.md +84 -17
  58. package/agent-assets/docs/features/operations/managed-chromium.md +221 -0
  59. package/agent-assets/docs/features/operations/notifications.md +52 -11
  60. package/agent-assets/docs/features/operations/quiet-hours.md +63 -40
  61. package/agent-assets/docs/features/operations/schedule-approaching.md +54 -24
  62. package/agent-assets/docs/features/routines/custom-routines.md +88 -20
  63. package/agent-assets/docs/features/routines/evening-review.md +74 -21
  64. package/agent-assets/docs/features/routines/hourly-check.md +149 -29
  65. package/agent-assets/docs/features/routines/morning-routine.md +53 -35
  66. package/agent-assets/docs/features/routines/weekly-review.md +40 -21
  67. package/agent-assets/docs/features/wiki/commands.md +26 -16
  68. package/agent-assets/docs/features/wiki/cost-and-approval.md +240 -0
  69. package/agent-assets/docs/features/wiki/dashboard.md +255 -0
  70. package/agent-assets/docs/features/wiki/overview.md +68 -10
  71. package/agent-assets/docs/features/wiki/search.md +248 -0
  72. package/agent-assets/docs/features/wiki/workspaces.md +254 -0
  73. package/agent-assets/docs/getting-started/01-what-is-this.md +34 -23
  74. package/agent-assets/docs/getting-started/02-first-steps.md +13 -8
  75. package/agent-assets/docs/getting-started/03-what-can-this-do.md +25 -14
  76. package/agent-assets/docs/getting-started/04-first-day.md +38 -20
  77. package/agent-assets/docs/glossary.md +235 -24
  78. package/agent-assets/docs/guides/add-a-custom-routine.md +63 -23
  79. package/agent-assets/docs/guides/backup-and-restore.md +80 -16
  80. package/agent-assets/docs/guides/budget-and-cost-for-wiki.md +56 -25
  81. package/agent-assets/docs/guides/build-your-wiki.md +22 -9
  82. package/agent-assets/docs/guides/change-which-model-handles-x.md +64 -10
  83. package/agent-assets/docs/guides/connect-a-new-mail-account.md +64 -15
  84. package/agent-assets/docs/guides/explore-with-trace-and-connect.md +28 -11
  85. package/agent-assets/docs/guides/import-knowledge-file.md +50 -40
  86. package/agent-assets/docs/guides/install-and-run.md +48 -19
  87. package/agent-assets/docs/guides/maintain-wiki-health.md +35 -10
  88. package/agent-assets/docs/guides/migrate-machines.md +74 -18
  89. package/agent-assets/docs/guides/multiple-wikis-for-multiple-domains.md +111 -60
  90. package/agent-assets/docs/guides/pause-the-agent.md +65 -24
  91. package/agent-assets/docs/guides/reinstall-cleanly.md +88 -18
  92. package/agent-assets/docs/guides/setup-wizard.md +113 -54
  93. package/agent-assets/docs/guides/switch-default-backend.md +62 -16
  94. package/agent-assets/docs/guides/use-an-existing-obsidian-vault.md +26 -10
  95. package/agent-assets/docs/reference/api.md +143 -32
  96. package/agent-assets/docs/reference/cli-commands.md +38 -17
  97. package/agent-assets/docs/reference/config.md +224 -49
  98. package/agent-assets/docs/reference/disallowed-tools.md +29 -10
  99. package/agent-assets/docs/reference/keyboard-shortcuts.md +34 -10
  100. package/agent-assets/docs/reference/knowledge-layout.md +620 -0
  101. package/agent-assets/docs/reference/process-keys.md +61 -5
  102. package/agent-assets/docs/reference/skills.md +38 -12
  103. package/agent-assets/docs/troubleshooting/auth-failed.md +48 -19
  104. package/agent-assets/docs/troubleshooting/dashboard-shows-degraded.md +90 -28
  105. package/agent-assets/docs/troubleshooting/fallback-keeps-firing.md +86 -22
  106. package/agent-assets/docs/troubleshooting/messaging-not-pairing.md +68 -24
  107. package/agent-assets/docs/troubleshooting/morning-routine-didnt-run.md +80 -20
  108. package/agent-assets/docs/troubleshooting/observation-not-detected.md +73 -21
  109. package/agent-assets/docs/troubleshooting/quota-exhausted.md +29 -5
  110. package/agent-assets/docs/troubleshooting/wiki-ingest-full-blocked.md +126 -54
  111. package/agent-assets/docs/troubleshooting/wiki-write-failed.md +29 -12
  112. package/agent-assets/optimizer-skills/drift-analysis/SKILL.md +1 -1
  113. package/agent-assets/optimizer-skills/knowledge-map/SKILL.md +1 -1
  114. package/agent-assets/optimizer-skills/skill-curation/SKILL.md +1 -1
  115. package/agent-assets/sandbox/linux/aitne-chromium.apparmor +91 -0
  116. package/agent-assets/sandbox/macos/aitne-chromium.sb +156 -0
  117. package/agent-assets/skills/agent-actions/SKILL.md +2 -2
  118. package/agent-assets/skills/agent-create/SKILL.md +149 -0
  119. package/agent-assets/skills/attach/SKILL.md +2 -2
  120. package/agent-assets/skills/browser-history/SKILL.md +198 -0
  121. package/agent-assets/skills/browser-history-respond/SKILL.md +106 -0
  122. package/agent-assets/skills/browser-task/SKILL.md +169 -0
  123. package/agent-assets/skills/context/SKILL.md +12 -12
  124. package/agent-assets/skills/context/curation.json +2 -2
  125. package/agent-assets/skills/context/references/api.md +43 -31
  126. package/agent-assets/skills/context/references/required-frontmatter.md +3 -3
  127. package/agent-assets/skills/context/references/snapshot-files.md +6 -6
  128. package/agent-assets/skills/context/seeds/file-responsibilities.seed.json +3 -3
  129. package/agent-assets/skills/docs-search/SKILL.md +4 -3
  130. package/agent-assets/skills/external-services/SKILL.delegated.claude.md +11 -21
  131. package/agent-assets/skills/external-services/SKILL.delegated.codex.md +11 -21
  132. package/agent-assets/skills/external-services/SKILL.delegated.gemini.md +11 -21
  133. package/agent-assets/skills/external-services/SKILL.md +3 -3
  134. package/agent-assets/skills/external-services/SKILL.native.claude.md +5 -5
  135. package/agent-assets/skills/external-services/SKILL.native.codex.md +7 -7
  136. package/agent-assets/skills/external-services/SKILL.native.gemini.md +4 -4
  137. package/agent-assets/skills/external-services/references/calendar-apple.md +2 -2
  138. package/agent-assets/skills/external-services/references/calendar-outlook.md +1 -1
  139. package/agent-assets/skills/external-services/references/obsidian.md +2 -2
  140. package/agent-assets/skills/gmail-lifestyle/SKILL.md +9 -82
  141. package/agent-assets/skills/mail/SKILL.delegated.claude.md +14 -5
  142. package/agent-assets/skills/mail/SKILL.delegated.codex.md +8 -4
  143. package/agent-assets/skills/mail/SKILL.delegated.gemini.md +8 -4
  144. package/agent-assets/skills/mail/references/api.md +4 -2
  145. package/agent-assets/skills/mail/references/providers.md +1 -1
  146. package/agent-assets/skills/managed-tasks/SKILL.md +9 -9
  147. package/agent-assets/skills/managed-tasks/references/errors.md +9 -6
  148. package/agent-assets/skills/managed-tasks/references/recurrence-rule.md +1 -1
  149. package/agent-assets/skills/management-policy/SKILL.md +32 -31
  150. package/agent-assets/skills/management-policy/curation.json +1 -1
  151. package/agent-assets/skills/management-policy/references/policy-workflow.md +9 -9
  152. package/agent-assets/skills/management-policy/seeds/policy-file-shape.seed.json +1 -1
  153. package/agent-assets/skills/notify/SKILL.md +4 -4
  154. package/agent-assets/skills/notify/references/priority.md +9 -4
  155. package/agent-assets/skills/notion/SKILL.delegated.claude.md +1 -1
  156. package/agent-assets/skills/notion/SKILL.delegated.codex.md +1 -1
  157. package/agent-assets/skills/notion/SKILL.delegated.gemini.md +1 -1
  158. package/agent-assets/skills/notion/SKILL.native.claude.md +10 -6
  159. package/agent-assets/skills/notion/SKILL.native.codex.md +9 -4
  160. package/agent-assets/skills/notion/SKILL.native.gemini.md +9 -4
  161. package/agent-assets/skills/observations/SKILL.md +24 -8
  162. package/agent-assets/skills/project-doc/SKILL.md +1 -1
  163. package/agent-assets/skills/project-doc/curation.json +3 -3
  164. package/agent-assets/skills/project-doc/seeds/project-shape.seed.json +7 -4
  165. package/agent-assets/skills/project-doc/seeds/slug-grammar.seed.json +3 -3
  166. package/agent-assets/skills/reading/SKILL.md +10 -0
  167. package/agent-assets/skills/reading/references/reading-taste.md +2 -2
  168. package/agent-assets/skills/roadmap/SKILL.md +5 -5
  169. package/agent-assets/skills/roadmap/curation.json +1 -1
  170. package/agent-assets/skills/roadmap/references/api.md +7 -7
  171. package/agent-assets/skills/roadmap/references/cross-check.md +15 -8
  172. package/agent-assets/skills/roadmap/references/migration.md +4 -4
  173. package/agent-assets/skills/roadmap/seeds/entry-types.seed.json +1 -1
  174. package/agent-assets/skills/schedule/SKILL.md +42 -34
  175. package/agent-assets/skills/schedule/references/batch.md +2 -2
  176. package/agent-assets/skills/schedule/references/errors.md +7 -4
  177. package/agent-assets/skills/schedule/references/model-selection.md +3 -3
  178. package/agent-assets/skills/schedule/references/recurrence-rule.md +1 -1
  179. package/agent-assets/skills/scheduled-managed-task/SKILL.md +46 -36
  180. package/agent-assets/skills/today/SKILL.md +9 -9
  181. package/agent-assets/skills/today/curation.json +3 -3
  182. package/agent-assets/skills/today/references/agent-plan-lifecycle.md +6 -5
  183. package/agent-assets/skills/today/seeds/section-shape.seed.json +1 -1
  184. package/agent-assets/skills/user-interview/SKILL.md +12 -9
  185. package/agent-assets/skills/user-interview/references/op-briefing.md +2 -2
  186. package/agent-assets/skills/user-interview/references/sweep-and-fallback.md +8 -0
  187. package/agent-assets/skills/user-profile/SKILL.md +17 -17
  188. package/agent-assets/skills/user-profile/curation.json +2 -2
  189. package/agent-assets/skills/user-profile/references/character-preferences.md +2 -2
  190. package/agent-assets/skills/user-profile/seeds/routing-table.seed.json +8 -8
  191. package/agent-assets/skills/user-profile/seeds/topic-files.seed.json +6 -6
  192. package/agent-assets/skills/wiki/wiki-compile/SKILL.md +4 -4
  193. package/agent-assets/system-prompts/routine-fetch-window.md +22 -12
  194. package/agent-assets/task-flows/_partials/calendar-acquire.google_calendar.md +4 -2
  195. package/agent-assets/task-flows/_partials/calendar-acquire.outlook_calendar.md +4 -2
  196. package/agent-assets/task-flows/_partials/capture-user-info.md +2 -2
  197. package/agent-assets/task-flows/_partials/dm-intent.long-horizon.md +1 -1
  198. package/agent-assets/task-flows/_partials/dm-intent.project.md +9 -9
  199. package/agent-assets/task-flows/_partials/mail-acquire.outlook_mail.md +3 -2
  200. package/agent-assets/task-flows/_partials/notion-acquire.notion.md +10 -5
  201. package/agent-assets/task-flows/browser_task.md +84 -0
  202. package/agent-assets/task-flows/github.assigned.md +1 -1
  203. package/agent-assets/task-flows/github.pull_request.review_requested.md +2 -2
  204. package/agent-assets/task-flows/github.workflow_run.failed.md +2 -2
  205. package/agent-assets/task-flows/knowledge.import.md +14 -14
  206. package/agent-assets/task-flows/message.received.dm.md +9 -4
  207. package/agent-assets/task-flows/message.received.dm_first.md +3 -3
  208. package/agent-assets/task-flows/routine.custom.md +3 -3
  209. package/agent-assets/task-flows/routine.evening_review.md +8 -8
  210. package/agent-assets/task-flows/routine.fetch_window.md +2 -2
  211. package/agent-assets/task-flows/routine.hourly_check.md +16 -12
  212. package/agent-assets/task-flows/routine.monthly_review.md +21 -21
  213. package/agent-assets/task-flows/routine.morning_routine_journal.md +119 -97
  214. package/agent-assets/task-flows/routine.morning_routine_today.md +43 -43
  215. package/agent-assets/task-flows/routine.research_cluster_update.md +35 -0
  216. package/agent-assets/task-flows/routine.research_dispatch.md +38 -0
  217. package/agent-assets/task-flows/routine.research_offer_dm.md +125 -0
  218. package/agent-assets/task-flows/routine.research_wiki_summary.md +53 -0
  219. package/agent-assets/task-flows/routine.roadmap_refresh.md +10 -10
  220. package/agent-assets/task-flows/routine.today_refresh.md +4 -4
  221. package/agent-assets/task-flows/routine.user_profile_sweep.md +10 -10
  222. package/agent-assets/task-flows/routine.weekly_review.md +93 -24
  223. package/agent-assets/task-flows/schedule.approaching.md +0 -1
  224. package/agent-assets/task-flows/scheduled.dm.md +5 -5
  225. package/agent-assets/task-flows/scheduled.task.md +4 -4
  226. package/agent-assets/task-flows/setup.initial.md +21 -21
  227. package/agent-assets/task-flows/setup.update.md +2 -2
  228. package/agent-assets/templates/README.md +27 -20
  229. package/agent-assets/templates/_index.md +42 -26
  230. package/agent-assets/templates/_manifest.json +34 -99
  231. package/agent-assets/templates/{user → identity}/_index.md +1 -1
  232. package/agent-assets/templates/{user → identity}/profile.md +2 -2
  233. package/agent-assets/templates/{dossiers → knowledge/dossiers}/_index.md +1 -1
  234. package/agent-assets/templates/{projects → plans/projects}/_active.base +1 -1
  235. package/agent-assets/templates/policies/_index.md +21 -0
  236. package/agent-assets/templates/{rules → policies}/journal-export.md +1 -1
  237. package/agent-assets/templates/{rules → policies}/journal-format.md +5 -5
  238. package/agent-assets/templates/{rules/policies → policies/management-captures}/_index.md +2 -2
  239. package/agent-assets/templates/{rules → policies}/management.md +3 -3
  240. package/agent-assets/templates/{rules → policies}/mcp.md +1 -1
  241. package/agent-assets/templates/{rules → policies}/redaction.md +1 -1
  242. package/agent-assets/templates/{routines → policies/routines}/_index.md +1 -1
  243. package/agent-assets/templates/{routines → policies/routines}/evening.md +2 -2
  244. package/agent-assets/templates/{routines → policies/routines}/hourly.md +1 -1
  245. package/agent-assets/templates/{routines → policies/routines}/monthly.md +2 -2
  246. package/bin/aitne.mjs +13 -4
  247. package/package.json +5 -4
  248. package/scripts/commands/doctor.mjs +14 -8
  249. package/scripts/commands/run-now.mjs +6 -21
  250. package/scripts/lib/ports.d.mts +27 -0
  251. package/scripts/lib/ports.mjs +36 -0
  252. package/scripts/lib/read-api-token.mjs +176 -0
  253. package/scripts/start.mjs +2 -1
  254. package/agent-assets/docs/features/lifestyle/travel-time.md +0 -58
  255. package/agent-assets/skills/gmail-lifestyle/references/travel-time-api.md +0 -59
  256. package/agent-assets/skills/schedule/references/recurring.md +0 -185
  257. package/agent-assets/templates/context-index.md +0 -42
  258. package/agent-assets/templates/rules/_index.md +0 -19
  259. /package/agent-assets/templates/{user → identity}/expertise.md +0 -0
  260. /package/agent-assets/templates/{user → identity}/goals.md +0 -0
  261. /package/agent-assets/templates/{user → identity}/people.md +0 -0
  262. /package/agent-assets/templates/{user → identity}/personal.md +0 -0
  263. /package/agent-assets/templates/{user → identity}/work.md +0 -0
  264. /package/agent-assets/templates/{agent/journal.md → journal/agent.md} +0 -0
  265. /package/agent-assets/templates/{dossiers → knowledge/dossiers}/evening.md +0 -0
  266. /package/agent-assets/templates/{dossiers → knowledge/dossiers}/hourly.md +0 -0
  267. /package/agent-assets/templates/{dossiers → knowledge/dossiers}/monthly.md +0 -0
  268. /package/agent-assets/templates/{dossiers → knowledge/dossiers}/morning.md +0 -0
  269. /package/agent-assets/templates/{dossiers → knowledge/dossiers}/roadmap.md +0 -0
  270. /package/agent-assets/templates/{dossiers → knowledge/dossiers}/weekly.md +0 -0
  271. /package/agent-assets/templates/{projects → plans/projects}/_index.md +0 -0
  272. /package/agent-assets/templates/{roadmap.md → plans/roadmap.md} +0 -0
  273. /package/agent-assets/templates/{routines → policies/routines}/morning.md +0 -0
  274. /package/agent-assets/templates/{routines → policies/routines}/weekly.md +0 -0
  275. /package/agent-assets/templates/{agent → state}/profile-questions.md +0 -0
  276. /package/agent-assets/templates/{today.md → state/today.md} +0 -0
@@ -15,9 +15,10 @@ summary: |
15
15
  to tune the threshold.
16
16
  section: budget-and-cost-for-wiki
17
17
  tags:
18
- - guide
18
+ - guides
19
19
  - wiki
20
20
  - cost
21
+ - approval
21
22
  status: stable
22
23
  ask_examples:
23
24
  - How much does !compile full cost?
@@ -26,68 +27,95 @@ ask_examples:
26
27
  - What does the pre-compile snapshot do?
27
28
  locale: en-US
28
29
  created: 2026-05-12
29
- updated: 2026-05-12
30
+ updated: 2026-05-28
30
31
  keywords:
31
32
  - wiki budget
32
33
  - wiki cost
33
34
  - wiki cost gate
34
35
  - wiki approval
35
36
  - compile cost
37
+ - compile full
36
38
  related:
37
39
  - features/wiki/overview
38
40
  - features/wiki/commands
41
+ - features/wiki/cost-and-approval
39
42
  - concepts/costs-and-quotas
40
43
  - troubleshooting/wiki-ingest-full-blocked
44
+ process_keys:
45
+ - wiki.compile
46
+ - wiki.ingest_url
47
+ - wiki.ask
48
+ api_endpoints:
49
+ - PATCH /api/wiki/workspaces/:workspace
50
+ - POST /api/approvals/:id/approve
51
+ - POST /api/approvals/:id/deny
41
52
  ui_anchors:
42
53
  - /settings/wiki
43
- - /approvals
54
+ - /
44
55
  ---
45
56
 
46
57
  # Wiki Budgets and Cost
47
58
 
48
59
  The wiki ships with three cost knobs you can tune in
49
- **Settings → Wiki**:
50
-
51
- 1. **Per-command model selector** for each of the three wiki
52
- processes (`wiki.ingest_url`, `wiki.compile`, `wiki.ask`).
53
- Defaults to your main backend at the medium tier; downgrade
54
- `wiki.ingest_url` to a lite tier if you ingest a lot of URLs.
60
+ **Settings → Wiki** (`/settings/wiki`):
61
+
62
+ 1. **Per-command model selector** for each wiki process. The model
63
+ picker covers the full set: `wiki.ingest_url`, `wiki.compile`,
64
+ `wiki.ask`, plus the operational triad `wiki.lint`, `wiki.trace`,
65
+ `wiki.connect`. Each defaults to your main backend at the medium
66
+ tier; downgrade `wiki.ingest_url` to a lite tier if you ingest a
67
+ lot of URLs.
55
68
  2. **Per-process budget cap** (`max_budget_usd` on each row). The
56
69
  dispatcher's per-session budget envelope is the enforcer.
57
70
  3. **Per-workspace `!compile full` approval threshold** (default
58
- $2.00). The dashboard cost estimator brackets the expected spend
59
- at 0.5× / 1× / 2× the assumed input-token count; if the
60
- pessimistic estimate breaches the threshold, the bang handler
71
+ $2.00, range $0–$100). The cost estimator brackets the expected
72
+ spend at 0.5× / 1× / 2× the estimated input-token count; if the
73
+ pessimistic (2×) estimate breaches the threshold, the bang handler
61
74
  escalates to the approval queue instead of running autonomously.
62
75
 
63
76
  ## What the Estimator Does
64
77
 
65
78
  `!compile full` is the most expensive wiki command because a full
66
79
  rebuild touches every raw note. The estimator is **pure JS** — it
67
- does not spawn an agent and computes:
80
+ does not spawn an agent (spawning one to estimate would itself burn
81
+ budget). It walks the `10_raw/` layer, approximates each file's token
82
+ count from its on-disk character count, sums the total, and brackets:
68
83
 
69
84
  ```
70
- expected_usd = raw_count × avg_input_tokens_per_raw × $0.003 / 1k tokens
85
+ expected_usd = total_estimated_input_tokens / 1000 × $0.003
71
86
  optimistic = 0.5 × expected
72
87
  pessimistic = 2.0 × expected
73
88
  ```
74
89
 
75
- Defaults: `avg_input_tokens_per_raw = 1500`, the unit cost matches
76
- Sonnet 4.6's $3 / Mtoken input price. The bracket lets you see a
77
- worst-case before approving.
90
+ Per-file token approximation is script-aware: ~4 characters per token
91
+ for Latin/prose, ~1.5 for majority-CJK files, with a 200-token floor
92
+ per file so empty or one-line stubs still account for the fixed
93
+ per-call overhead (system prompt, skills bundle, tool docs). The unit
94
+ cost (`$0.003` per 1k tokens) matches Claude Sonnet 4.6's ~$3 /
95
+ Mtoken input price. The bracket lets you see a worst case before
96
+ approving.
97
+
98
+ > The dashboard surfaces the top raw files by estimated token count,
99
+ > so you can see which sources dominate the bill before approving.
100
+ > An older flat heuristic (`raw_count × 1500 tokens`) survives as an
101
+ > opt-in fallback for deterministic banner copy, but the default is
102
+ > the per-file character scan described above.
78
103
 
79
104
  ## Where the Gate Fires
80
105
 
81
106
  - **Below threshold**: the compile runs autonomously and you get a
82
107
  completion DM with actual spend.
83
108
  - **Above threshold**: the bang handler inserts an `agent_schedule`
84
- row with `task_type='approval'` and DMs the estimate. The
85
- dashboard `/approvals` view (also reachable from Notifications)
86
- is where you click **Approve** that flips the row to
87
- `approved_task` and the scheduler picks it up.
109
+ row with `task_type='approval'`, DMs you the estimate, and pauses.
110
+ The request shows up as an **Approvals** card on the dashboard home
111
+ page (`/`); the `/settings/wiki` page also points you there.
112
+ Clicking **Approve** flips the row to `task_type='approved_task'`
113
+ and the scheduler picks it up — only then is the pre-compile git
114
+ snapshot taken (see below) and the compile session spawned.
88
115
 
89
116
  If you change your mind, hit **Deny** on the approval card — the row
90
- flips to `skipped` and no agent session is spawned.
117
+ flips to `skipped`, no git commit is made, and no agent session is
118
+ spawned.
91
119
 
92
120
  ## Git Pre-Compile Snapshot
93
121
 
@@ -106,9 +134,12 @@ deterministic so you can roll back with `git reset --hard HEAD~1` if
106
134
  the compile produces a surprise. The `--no-verify` flag is not used —
107
135
  your pre-commit hooks run as normal.
108
136
 
109
- If your vault is not a git repo, the approval-gate DM appends
110
- "no git backup taken" so you can decide whether to add one before
111
- approving.
137
+ The estimate DM tells you which snapshot path applies:
138
+ **"will commit before compile starts"** (clean repo), **"not taken
139
+ (no git repo)"**, **"disabled by setting"** (auto-commit off), or
140
+ **"not applicable"** for internal-mode workspaces — those recover via
141
+ `md_file_snapshots` instead of git. When no git backup will be taken,
142
+ you can decide whether to add one before approving.
112
143
 
113
144
  ## Tuning the Threshold
114
145
 
@@ -21,22 +21,32 @@ status: stable
21
21
  ask_examples:
22
22
  - How do I start using the wiki?
23
23
  - How do I add my first source to the wiki?
24
+ - How do I compile my ingested notes into wiki articles?
24
25
  locale: en-US
25
26
  created: 2026-05-12
26
- updated: 2026-05-12
27
+ updated: 2026-05-28
27
28
  keywords:
28
29
  - wiki
29
30
  - build wiki
30
- - !ingest
31
- - !compile
32
- - !ask
31
+ - "!ingest"
32
+ - "!compile"
33
+ - "!ask"
33
34
  - workspace
34
35
  - first day wiki
36
+ ui_anchors:
37
+ - /wiki
38
+ - /settings/wiki
39
+ process_keys:
40
+ - wiki.ingest_url
41
+ - wiki.compile
42
+ - wiki.ask
35
43
  related:
36
44
  - features/wiki/overview
37
45
  - features/wiki/commands
38
46
  - guides/use-an-existing-obsidian-vault
39
47
  - guides/budget-and-cost-for-wiki
48
+ prerequisites:
49
+ - features/messaging/pairing-and-magic-phrase
40
50
  ---
41
51
 
42
52
  # Build Your Wiki
@@ -49,7 +59,8 @@ article, and run a question against the result.
49
59
  ## Prerequisites
50
60
 
51
61
  - A paired messaging channel (Telegram, Slack, Discord, WhatsApp, or
52
- dashboard chat).
62
+ dashboard chat) — see
63
+ [Pairing and the Magic Phrase](../messaging/pairing-and-magic-phrase.md).
53
64
  - The daemon is running and the dashboard is reachable.
54
65
 
55
66
  ## Where you'll work in the dashboard
@@ -74,10 +85,12 @@ you enable a workspace, so you do not need to remember the URL.
74
85
  1. Click **My Life → Wiki** in the sidebar (`/wiki`). The page shows
75
86
  a "Wiki not enabled" card with an **Enable Wiki** button —
76
87
  clicking it jumps you to `/settings/wiki`.
77
- 2. On the settings page, click **Enable Internal Workspace**. The
78
- daemon creates `$PA_DATA_DIR/wiki/` and seeds `90_meta/taxonomy.md`
79
- plus the schema templates. (To point at an existing Obsidian
80
- vault instead, follow
88
+ 2. On the settings page, click **Enable internal wiki**. The daemon
89
+ creates the workspace under your context vault at
90
+ `knowledge/wiki/` (the daemon-owned default root) and seeds the
91
+ skeleton: `10_raw/`, `20_wiki/`, `30_outputs/`, `90_meta/` plus
92
+ `90_meta/taxonomy.md` and the schema templates. (To point at an
93
+ existing Obsidian vault instead, follow
81
94
  [Use An Existing Obsidian Vault](use-an-existing-obsidian-vault.md).)
82
95
  3. The sidebar's **My Life → Wiki** entry now lands on a workspace
83
96
  summary instead of the disabled CTA. Open it to confirm the root
@@ -6,49 +6,103 @@ id: change-which-model-handles-x
6
6
  aliases:
7
7
  - per-process tier
8
8
  - per-process model
9
+ - pin a process key
9
10
  category: guides
10
11
  summary: |
11
- Pin a specific ProcessKey to a non-default backend / tier — for
12
- example, run morning routine on Sonnet to save Opus tokens.
12
+ Pin a single ProcessKey to a non-default backend or model tier — for
13
+ example, move the evening review onto Opus (high tier) for deeper
14
+ reasoning, or run a routine on Codex while Claude stays the default.
13
15
  section: change-which-model-handles-x
14
16
  tags:
15
17
  - guide
16
18
  - backends
17
- - models
19
+ - operations
20
+ - routing
18
21
  status: stable
19
22
  ask_examples:
20
- - How do I make my morning routine use Sonnet instead of Opus?
23
+ - How do I make one routine use Opus instead of Sonnet?
24
+ - How do I pin the evening review to a different backend?
25
+ - Can I change the model for just one ProcessKey?
21
26
  locale: en-US
22
27
  created: 2026-04-25
23
- updated: 2026-04-25
28
+ updated: 2026-05-28
24
29
  keywords:
25
30
  - per-process model
26
31
  - /settings/models
27
32
  - process binding
28
33
  - tier override
29
34
  - change model
35
+ - pin process key
30
36
  related:
31
37
  - guides/switch-default-backend
32
38
  - concepts/backends-and-tiers
39
+ - concepts/process-keys
40
+ ui_anchors:
41
+ - /settings/models
42
+ - /activity
43
+ process_keys:
44
+ - routine.morning_routine
45
+ - routine.evening_review
46
+ - message.dm
47
+ - dashboard.docs_qa
48
+ - delegated_task_heavy
49
+ config_keys:
50
+ - delegatedTaskHeavyEnabled
33
51
  ---
34
52
 
35
53
  # Change Which Model Handles X
36
54
 
37
55
  ## Goal
38
56
 
39
- Override the default tier or backend on a single ProcessKey.
57
+ Override the default backend or model tier for a **single** ProcessKey
58
+ without changing the global default. Use this when one surface needs a
59
+ stronger (or cheaper) model than the seeded default — for example,
60
+ pinning the evening review to Opus (high tier), or pushing a noisy
61
+ delegated routine onto Gemini to save Claude quota.
40
62
 
41
63
  ## Steps
42
64
 
43
65
  1. Open `/settings/models`.
44
- 2. Find the ProcessKey row in the table.
45
- 3. Pick its main backend and tier explicitly.
46
- 4. Save.
66
+ 2. Find the ProcessKey row in the per-process table (e.g.
67
+ `routine.evening_review`).
68
+ 3. Set its **main backend** and **tier** explicitly. The tier maps to a
69
+ model class — `lite` → Haiku-class, `medium` → Sonnet-class,
70
+ `high` → Opus-class. Optionally set a **fallback** backend too.
71
+ 4. Save. The row is now marked operator-edited and will keep your pin
72
+ through a defaults reset (only an install-time `force` re-seed
73
+ overwrites it).
74
+
75
+ ## Concrete Example
76
+
77
+ To give the evening review deeper reasoning, set
78
+ `routine.evening_review` → main `claude`, tier `high`. The next evening
79
+ run resolves to **Opus 4.8** instead of the default Sonnet 4.6. The
80
+ execution budget for that run also scales with the tier (high tier
81
+ carries a larger turn / cost envelope than medium).
47
82
 
48
83
  ## Verification
49
84
 
50
- - The next fire of that ProcessKey shows the new model in Activity.
85
+ - The next fire of that ProcessKey shows the new backend and model in
86
+ the **Activity** event detail (after fallback resolution).
87
+
88
+ ## Caveats
89
+
90
+ - **`dashboard.docs_qa` is tier-locked to `medium`** — a high/lite pin
91
+ on that row is ignored by the router. It also inherits its backend
92
+ from `message.dm`'s pin.
93
+ - **High tier is opt-in, not auto-selected.** No install-time-seeded
94
+ surface defaults to high; the only `high`-tagged ProcessKey shipped is
95
+ `delegated_task_heavy`, gated behind the `delegatedTaskHeavyEnabled`
96
+ config flag. Any *other* ProcessKey can still be pinned to high here.
97
+ - **On Codex and Gemini there is no separately-seeded high model** —
98
+ their high tier collapses to the medium model, so pinning those
99
+ backends to high won't change the model unless you pick a specific
100
+ higher model in the row.
101
+ - To change the backend for *every* ProcessKey at once, use the global
102
+ default instead — see Related.
51
103
 
52
104
  ## Related
53
105
 
54
106
  - [Switch the Default Backend](switch-default-backend.md)
107
+ - [Backends and Tiers](../concepts/backends-and-tiers.md)
108
+ - [Process Keys](../concepts/process-keys.md)
@@ -11,8 +11,10 @@ aliases:
11
11
  - outlook setup
12
12
  category: guides
13
13
  summary: |
14
- Add a Gmail / Outlook / Yahoo / iCloud account to the mail
15
- integration. Each provider has its own credential shape.
14
+ Add a Gmail, Outlook, Yahoo, or iCloud mailbox to the mail
15
+ integration. Each provider authenticates differently: Gmail rides
16
+ the primary Google sign-in, Outlook uses OAuth, and Yahoo/iCloud
17
+ use an app password.
16
18
  section: connect-a-new-mail-account
17
19
  tags:
18
20
  - guide
@@ -22,9 +24,10 @@ status: stable
22
24
  ask_examples:
23
25
  - How do I add another Gmail account?
24
26
  - What mail providers does Aitne support?
27
+ - How do I connect an Outlook mailbox?
25
28
  locale: en-US
26
29
  created: 2026-04-25
27
- updated: 2026-04-25
30
+ updated: 2026-05-28
28
31
  keywords:
29
32
  - mail
30
33
  - imap
@@ -34,41 +37,87 @@ keywords:
34
37
  - icloud
35
38
  - mail provider
36
39
  - OAuth
40
+ - app password
37
41
  related:
38
42
  - features/integrations/mail
43
+ ui_anchors:
44
+ - /connections/mail
45
+ api_endpoints:
46
+ - /api/mail/accounts
47
+ - /api/mail/accounts/device-code
48
+ - /api/config/mail/app-password
49
+ config_keys:
50
+ - enabledMailProviders
51
+ context_files:
52
+ - state/today.md
39
53
  ---
40
54
 
41
55
  # Connect a New Mail Account
42
56
 
43
57
  ## Goal
44
58
 
45
- Wire a new mailbox into Aitne so the agent can read, label,
59
+ Wire a new mailbox into Aitne so the agent can read, label, classify,
46
60
  and search it.
47
61
 
62
+ ## Supported providers
63
+
64
+ The mail registry recognizes exactly four provider kinds — `gmail`,
65
+ `outlook`, `yahoo`, `icloud`. It deliberately stops at hosted
66
+ providers, so there is no separate "generic IMAP server" kind. Each
67
+ kind authenticates differently:
68
+
69
+ | Provider | How it connects |
70
+ |---|---|
71
+ | **Gmail** | Rides the primary Google sign-in (`/config/google-auth`). Extra Gmail accounts beyond the primary identity are not implemented yet. |
72
+ | **Outlook** | OAuth — a browser loopback flow, with a device-code fallback for headless machines. |
73
+ | **Yahoo** | App password (IMAP). |
74
+ | **iCloud** | App password (IMAP). |
75
+
48
76
  ## Prerequisites
49
77
 
50
- - The provider's OAuth or app password is available.
78
+ - For **Outlook**: the Outlook client config must already be set
79
+ (`PUT /api/config/mail/outlook/client-config`).
80
+ - For **Yahoo / iCloud**: generate a provider-specific app password
81
+ first — your regular login password will not work over IMAP.
51
82
 
52
83
  ## Steps
53
84
 
54
85
  1. Open `/connections/mail`.
55
- 2. Click "Add account".
56
- 3. Pick the provider kind. The supported set is `gmail`, `outlook`,
57
- `yahoo`, `icloud` — the registry deliberately stops at hosted
58
- providers, so a generic IMAP server is not a separate kind.
59
- 4. Step through the OAuth flow (Gmail / Outlook) or paste the
60
- provider-specific app password (Yahoo / iCloud).
61
- 5. Save. The first poll runs within a minute.
86
+ 2. Click "Add account" and pick the provider kind.
87
+ 3. Authenticate for that kind:
88
+ - **Gmail**connect the primary Google account from the setup or
89
+ connections flow (`/config/google-auth`). It then appears on the
90
+ unified mail surface automatically; you do not add it as a
91
+ separate mail account.
92
+ - **Outlook** step through the OAuth browser flow. On a headless
93
+ machine (SSH / WSL), use the device-code fallback, which prints a
94
+ code to enter at a verification URL.
95
+ - **Yahoo / iCloud** — paste the email address and the app password.
96
+ 4. Save. Registration succeeds regardless of the enabled-providers
97
+ setting (`enabledMailProviders`); the account goes live only when
98
+ you flip its **Enable** toggle on the mail card.
99
+ 5. The first poll runs within a minute of being enabled.
62
100
 
63
101
  ## Verification
64
102
 
65
- - The account row turns green on the auth-health card.
103
+ - The account row turns healthy on the auth-health card.
66
104
  - The mail count updates on `/connections/mail`.
67
105
 
68
106
  ## If It Fails
69
107
 
70
- - OAuth that does not return: confirm the redirect URL matches the
71
- daemon's API port (default 8321).
108
+ - **Outlook OAuth never returns** the loopback flow binds an
109
+ ephemeral port on `127.0.0.1`, so a fixed-port redirect mismatch is
110
+ not the cause. Confirm the browser actually opened and completed the
111
+ redirect; on a headless host switch to the device-code flow instead.
112
+ - **Outlook add returns "client config missing"** — set the Outlook
113
+ client config (`PUT /api/config/mail/outlook/client-config`) before
114
+ adding the account.
115
+ - **Yahoo / iCloud login rejected** — re-check the address and the app
116
+ password (not your normal account password); regenerate the app
117
+ password if it still fails.
118
+ - **Adding a second Gmail account fails** — only the primary Google
119
+ identity is supported today; additional Gmail accounts are not yet
120
+ implemented.
72
121
 
73
122
  ## Related
74
123
 
@@ -14,11 +14,12 @@ summary: |
14
14
  How to use `!trace <topic>` to reconstruct the evolution of an
15
15
  idea across your raw / wiki / outputs layers, and `!connect <a>
16
16
  <b>` to find bridges between two domains.
17
- section: explore-with-trace-and-connect
17
+ section: guides
18
18
  tags:
19
- - guide
19
+ - guides
20
20
  - wiki
21
21
  - exploration
22
+ - bang-commands
22
23
  status: stable
23
24
  ask_examples:
24
25
  - How do I trace an idea across the wiki?
@@ -26,19 +27,27 @@ ask_examples:
26
27
  - How do I find connections between two topics?
27
28
  - Where does the !trace output land?
28
29
  - Can I use multi-word topics with !connect?
30
+ - How do I run !trace against a non-default wiki workspace?
29
31
  locale: en-US
30
32
  created: 2026-05-12
31
- updated: 2026-05-12
33
+ updated: 2026-05-28
32
34
  keywords:
33
- - !trace
34
- - !connect
35
+ - "!trace"
36
+ - "!connect"
35
37
  - wiki exploration
36
38
  - topic history
37
39
  - topic bridges
40
+ - bridging domains
41
+ prerequisites:
42
+ - guides/build-your-wiki
38
43
  related:
39
44
  - features/wiki/overview
40
45
  - features/wiki/commands
41
46
  - guides/maintain-wiki-health
47
+ - features/messaging/bang-commands
48
+ process_keys:
49
+ - wiki.trace
50
+ - wiki.connect
42
51
  ui_anchors:
43
52
  - /wiki/timeline
44
53
  - /settings/wiki
@@ -46,10 +55,16 @@ ui_anchors:
46
55
 
47
56
  # Explore Your Wiki with `!trace` and `!connect`
48
57
 
49
- `!trace` and `!connect` are the two Phase 3 exploration commands.
50
- Both produce a one-off output document in `30_outputs/` and never
51
- touch your raw or wiki notes. Think of them as cited essays
52
- written from what your wiki actually contains.
58
+ `!trace` and `!connect` are the two wiki exploration commands. Both
59
+ produce a one-off output document in `30_outputs/` and never touch
60
+ your raw or wiki notes. Think of them as cited essays written from
61
+ what your wiki actually contains.
62
+
63
+ Both run as owner-DM bang commands. Both also accept an optional
64
+ leading `@<workspace>` token to target a non-default wiki workspace
65
+ — for example `!trace @research formal methods` or
66
+ `!connect @research category theory, distributed systems`. Omit the
67
+ token and the command runs against your default workspace.
53
68
 
54
69
  ## `!trace <topic>` — Time-Based Exploration
55
70
 
@@ -114,13 +129,15 @@ your wiki. The agent surfaces four kinds of bridges:
114
129
 
115
130
  ### Argument Forms
116
131
 
117
- `!connect` requires exactly two topics. Whitespace separates them
118
- by default; a comma lets you use multi-word topics:
132
+ `!connect` requires exactly two topics (after any optional
133
+ `@<workspace>` token). Whitespace separates them by default; a
134
+ comma lets you use multi-word topics:
119
135
 
120
136
  ```
121
137
  !connect quantum gravity
122
138
  !connect quantum computing, classical computing
123
139
  !connect category theory, distributed systems
140
+ !connect @research category theory, distributed systems
124
141
  ```
125
142
 
126
143
  The handler rejects a single topic, three-or-more topics, a