@aitne-sh/aitne 0.1.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 (249) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +464 -0
  3. package/agent-assets/agent-profiles/_safety.md +26 -0
  4. package/agent-assets/agent-profiles/conversational.md +33 -0
  5. package/agent-assets/agent-profiles/docs-qa.md +24 -0
  6. package/agent-assets/agent-profiles/observer.md +28 -0
  7. package/agent-assets/agent-profiles/profile-importer.md +63 -0
  8. package/agent-assets/agent-profiles/proxy.md +28 -0
  9. package/agent-assets/agent-profiles/routine.md +16 -0
  10. package/agent-assets/agent-profiles/task.md +18 -0
  11. package/agent-assets/docs/concepts/agent-day.md +88 -0
  12. package/agent-assets/docs/concepts/auth-health.md +75 -0
  13. package/agent-assets/docs/concepts/backends-and-tiers.md +126 -0
  14. package/agent-assets/docs/concepts/costs-and-quotas.md +103 -0
  15. package/agent-assets/docs/concepts/delegated-mode.md +223 -0
  16. package/agent-assets/docs/concepts/memory-model.md +118 -0
  17. package/agent-assets/docs/concepts/observations.md +80 -0
  18. package/agent-assets/docs/concepts/process-keys.md +89 -0
  19. package/agent-assets/docs/concepts/routines.md +108 -0
  20. package/agent-assets/docs/concepts/safety-and-execution.md +109 -0
  21. package/agent-assets/docs/concepts/safety-model.md +279 -0
  22. package/agent-assets/docs/concepts/skills.md +100 -0
  23. package/agent-assets/docs/features/integrations/calendar.md +92 -0
  24. package/agent-assets/docs/features/integrations/git.md +95 -0
  25. package/agent-assets/docs/features/integrations/github.md +170 -0
  26. package/agent-assets/docs/features/integrations/mail.md +106 -0
  27. package/agent-assets/docs/features/integrations/notion.md +69 -0
  28. package/agent-assets/docs/features/integrations/obsidian.md +71 -0
  29. package/agent-assets/docs/features/lifestyle/git.md +178 -0
  30. package/agent-assets/docs/features/lifestyle/reading.md +93 -0
  31. package/agent-assets/docs/features/lifestyle/receipts.md +71 -0
  32. package/agent-assets/docs/features/lifestyle/travel-bookings.md +44 -0
  33. package/agent-assets/docs/features/lifestyle/travel-time.md +52 -0
  34. package/agent-assets/docs/features/memory-files/agent-journal.md +105 -0
  35. package/agent-assets/docs/features/memory-files/projects.md +56 -0
  36. package/agent-assets/docs/features/memory-files/roadmap.md +61 -0
  37. package/agent-assets/docs/features/memory-files/schedule.md +112 -0
  38. package/agent-assets/docs/features/memory-files/today.md +73 -0
  39. package/agent-assets/docs/features/memory-files/user-profile.md +81 -0
  40. package/agent-assets/docs/features/messaging/dashboard-chat.md +93 -0
  41. package/agent-assets/docs/features/messaging/discord.md +50 -0
  42. package/agent-assets/docs/features/messaging/overview.md +111 -0
  43. package/agent-assets/docs/features/messaging/pairing-and-magic-phrase.md +69 -0
  44. package/agent-assets/docs/features/messaging/slack.md +51 -0
  45. package/agent-assets/docs/features/messaging/telegram.md +63 -0
  46. package/agent-assets/docs/features/messaging/whatsapp.md +48 -0
  47. package/agent-assets/docs/features/operations/activity-and-conversations.md +105 -0
  48. package/agent-assets/docs/features/operations/approvals.md +58 -0
  49. package/agent-assets/docs/features/operations/backend-routing.md +62 -0
  50. package/agent-assets/docs/features/operations/cost-tracking.md +59 -0
  51. package/agent-assets/docs/features/operations/notifications.md +69 -0
  52. package/agent-assets/docs/features/operations/quiet-hours.md +106 -0
  53. package/agent-assets/docs/features/operations/schedule-approaching.md +60 -0
  54. package/agent-assets/docs/features/routines/custom-routines.md +101 -0
  55. package/agent-assets/docs/features/routines/evening-review.md +81 -0
  56. package/agent-assets/docs/features/routines/hourly-check.md +85 -0
  57. package/agent-assets/docs/features/routines/monthly-review.md +65 -0
  58. package/agent-assets/docs/features/routines/morning-routine.md +123 -0
  59. package/agent-assets/docs/features/routines/weekly-review.md +70 -0
  60. package/agent-assets/docs/getting-started/01-what-is-this.md +192 -0
  61. package/agent-assets/docs/getting-started/02-first-steps.md +80 -0
  62. package/agent-assets/docs/getting-started/03-what-can-this-do.md +110 -0
  63. package/agent-assets/docs/getting-started/04-first-day.md +287 -0
  64. package/agent-assets/docs/glossary.md +116 -0
  65. package/agent-assets/docs/guides/add-a-custom-routine.md +71 -0
  66. package/agent-assets/docs/guides/backup-and-restore.md +54 -0
  67. package/agent-assets/docs/guides/change-which-model-handles-x.md +47 -0
  68. package/agent-assets/docs/guides/connect-a-new-mail-account.md +59 -0
  69. package/agent-assets/docs/guides/import-knowledge-file.md +275 -0
  70. package/agent-assets/docs/guides/install-and-run.md +72 -0
  71. package/agent-assets/docs/guides/migrate-machines.md +52 -0
  72. package/agent-assets/docs/guides/pause-the-agent.md +65 -0
  73. package/agent-assets/docs/guides/reinstall-cleanly.md +52 -0
  74. package/agent-assets/docs/guides/setup-wizard.md +107 -0
  75. package/agent-assets/docs/guides/switch-default-backend.md +60 -0
  76. package/agent-assets/docs/reference/api.md +51 -0
  77. package/agent-assets/docs/reference/cli-commands.md +121 -0
  78. package/agent-assets/docs/reference/config.md +74 -0
  79. package/agent-assets/docs/reference/disallowed-tools.md +76 -0
  80. package/agent-assets/docs/reference/keyboard-shortcuts.md +39 -0
  81. package/agent-assets/docs/reference/process-keys.md +59 -0
  82. package/agent-assets/docs/reference/skills.md +50 -0
  83. package/agent-assets/docs/troubleshooting/auth-failed.md +57 -0
  84. package/agent-assets/docs/troubleshooting/dashboard-shows-degraded.md +55 -0
  85. package/agent-assets/docs/troubleshooting/fallback-keeps-firing.md +54 -0
  86. package/agent-assets/docs/troubleshooting/messaging-not-pairing.md +53 -0
  87. package/agent-assets/docs/troubleshooting/morning-routine-didnt-run.md +75 -0
  88. package/agent-assets/docs/troubleshooting/observation-not-detected.md +57 -0
  89. package/agent-assets/docs/troubleshooting/quota-exhausted.md +57 -0
  90. package/agent-assets/optimizer-skills/drift-analysis/SKILL.md +75 -0
  91. package/agent-assets/optimizer-skills/knowledge-map/SKILL.md +71 -0
  92. package/agent-assets/optimizer-skills/skill-curation/SKILL.md +108 -0
  93. package/agent-assets/project-doc-templates/git-repo.md +21 -0
  94. package/agent-assets/project-doc-templates/project.md +38 -0
  95. package/agent-assets/skills/attach/SKILL.md +104 -0
  96. package/agent-assets/skills/context/SKILL.md +257 -0
  97. package/agent-assets/skills/context/curation.json +37 -0
  98. package/agent-assets/skills/context/seeds/file-responsibilities.seed.json +13 -0
  99. package/agent-assets/skills/context/seeds/frontmatter-requirements.seed.json +40 -0
  100. package/agent-assets/skills/docs-search/SKILL.md +176 -0
  101. package/agent-assets/skills/external-services/SKILL.delegated.claude.md +369 -0
  102. package/agent-assets/skills/external-services/SKILL.delegated.codex.md +349 -0
  103. package/agent-assets/skills/external-services/SKILL.delegated.gemini.md +347 -0
  104. package/agent-assets/skills/external-services/SKILL.md +371 -0
  105. package/agent-assets/skills/mail/SKILL.delegated.claude.md +284 -0
  106. package/agent-assets/skills/mail/SKILL.delegated.codex.md +261 -0
  107. package/agent-assets/skills/mail/SKILL.delegated.gemini.md +255 -0
  108. package/agent-assets/skills/mail/SKILL.md +313 -0
  109. package/agent-assets/skills/mail/references/errors.md +17 -0
  110. package/agent-assets/skills/mail/references/providers.md +40 -0
  111. package/agent-assets/skills/mail/references/query-grammar.md +24 -0
  112. package/agent-assets/skills/management-policy/SKILL.md +307 -0
  113. package/agent-assets/skills/management-policy/curation.json +13 -0
  114. package/agent-assets/skills/management-policy/seeds/policy-file-shape.seed.json +16 -0
  115. package/agent-assets/skills/management-task-modify/SKILL.md +202 -0
  116. package/agent-assets/skills/management-task-register/SKILL.md +330 -0
  117. package/agent-assets/skills/management-task-stop/SKILL.md +166 -0
  118. package/agent-assets/skills/notify/SKILL.md +196 -0
  119. package/agent-assets/skills/notion/SKILL.delegated.claude.md +254 -0
  120. package/agent-assets/skills/notion/SKILL.delegated.codex.md +195 -0
  121. package/agent-assets/skills/notion/SKILL.delegated.gemini.md +194 -0
  122. package/agent-assets/skills/notion/SKILL.md +86 -0
  123. package/agent-assets/skills/observations/SKILL.md +234 -0
  124. package/agent-assets/skills/observations/curation.json +13 -0
  125. package/agent-assets/skills/observations/seeds/source-namespacing.seed.json +20 -0
  126. package/agent-assets/skills/project-doc/SKILL.md +86 -0
  127. package/agent-assets/skills/project-doc/curation.json +21 -0
  128. package/agent-assets/skills/project-doc/seeds/project-shape.seed.json +25 -0
  129. package/agent-assets/skills/project-doc/seeds/slug-grammar.seed.json +20 -0
  130. package/agent-assets/skills/reading/SKILL.md +198 -0
  131. package/agent-assets/skills/reading/references/reading-taste.md +197 -0
  132. package/agent-assets/skills/receipts/SKILL.md +134 -0
  133. package/agent-assets/skills/roadmap/SKILL.md +276 -0
  134. package/agent-assets/skills/roadmap/curation.json +13 -0
  135. package/agent-assets/skills/roadmap/references/horizon-tags.md +40 -0
  136. package/agent-assets/skills/roadmap/references/preparation-timeline.md +47 -0
  137. package/agent-assets/skills/roadmap/seeds/entry-types.seed.json +16 -0
  138. package/agent-assets/skills/schedule/SKILL.md +228 -0
  139. package/agent-assets/skills/scheduled-managed-task/SKILL.md +392 -0
  140. package/agent-assets/skills/today/SKILL.md +198 -0
  141. package/agent-assets/skills/today/curation.json +21 -0
  142. package/agent-assets/skills/today/seeds/agent-notes-flavors.seed.json +17 -0
  143. package/agent-assets/skills/today/seeds/section-shape.seed.json +17 -0
  144. package/agent-assets/skills/travel/SKILL.md +132 -0
  145. package/agent-assets/skills/travel-time/SKILL.md +149 -0
  146. package/agent-assets/skills/user-interview/SKILL.md +323 -0
  147. package/agent-assets/skills/user-interview/references/sweep-and-fallback.md +94 -0
  148. package/agent-assets/skills/user-profile/SKILL.md +210 -0
  149. package/agent-assets/skills/user-profile/curation.json +29 -0
  150. package/agent-assets/skills/user-profile/seeds/learned-context-format.seed.json +14 -0
  151. package/agent-assets/skills/user-profile/seeds/routing-table.seed.json +53 -0
  152. package/agent-assets/skills/user-profile/seeds/topic-files.seed.json +27 -0
  153. package/agent-assets/task-flows/dashboard.docs_qa.md +43 -0
  154. package/agent-assets/task-flows/default.md +11 -0
  155. package/agent-assets/task-flows/git.branch.created.md +25 -0
  156. package/agent-assets/task-flows/git.lifecycle.poll.md +52 -0
  157. package/agent-assets/task-flows/git.local_ahead.stale.md +34 -0
  158. package/agent-assets/task-flows/git.merge_to_default.md +30 -0
  159. package/agent-assets/task-flows/git.project.refresh_architecture.md +100 -0
  160. package/agent-assets/task-flows/git.project.retemplate.md +73 -0
  161. package/agent-assets/task-flows/git.push.detected.md +32 -0
  162. package/agent-assets/task-flows/git.push.force_pushed.md +36 -0
  163. package/agent-assets/task-flows/git.tag.created.md +24 -0
  164. package/agent-assets/task-flows/github.assigned.md +43 -0
  165. package/agent-assets/task-flows/github.pull_request.review_requested.md +57 -0
  166. package/agent-assets/task-flows/github.security_alert.md +45 -0
  167. package/agent-assets/task-flows/github.workflow_run.failed.md +57 -0
  168. package/agent-assets/task-flows/knowledge.import.md +161 -0
  169. package/agent-assets/task-flows/message.received.dm.md +142 -0
  170. package/agent-assets/task-flows/message.received.dm_first.md +117 -0
  171. package/agent-assets/task-flows/message.received.md +14 -0
  172. package/agent-assets/task-flows/routine.custom.md +38 -0
  173. package/agent-assets/task-flows/routine.evening_review.md +323 -0
  174. package/agent-assets/task-flows/routine.hourly_check.delegated.claude.md +405 -0
  175. package/agent-assets/task-flows/routine.hourly_check.delegated.codex.md +400 -0
  176. package/agent-assets/task-flows/routine.hourly_check.delegated.gemini.md +404 -0
  177. package/agent-assets/task-flows/routine.hourly_check.md +184 -0
  178. package/agent-assets/task-flows/routine.hourly_check.triage.md +93 -0
  179. package/agent-assets/task-flows/routine.monthly_review.md +250 -0
  180. package/agent-assets/task-flows/routine.morning_routine.md +300 -0
  181. package/agent-assets/task-flows/routine.morning_routine_initial.md +184 -0
  182. package/agent-assets/task-flows/routine.roadmap_refresh.md +275 -0
  183. package/agent-assets/task-flows/routine.today_refresh.md +172 -0
  184. package/agent-assets/task-flows/routine.user_profile_sweep.md +242 -0
  185. package/agent-assets/task-flows/routine.weekly_review.md +247 -0
  186. package/agent-assets/task-flows/schedule.approaching.md +124 -0
  187. package/agent-assets/task-flows/scheduled.dm.md +391 -0
  188. package/agent-assets/task-flows/scheduled.task.md +141 -0
  189. package/agent-assets/task-flows/setup.initial.md +277 -0
  190. package/agent-assets/task-flows/setup.update.md +53 -0
  191. package/agent-assets/templates/README.md +85 -0
  192. package/agent-assets/templates/_index.md +39 -0
  193. package/agent-assets/templates/_manifest.json +103 -0
  194. package/agent-assets/templates/agent/journal.md +10 -0
  195. package/agent-assets/templates/agent/profile-questions.md +74 -0
  196. package/agent-assets/templates/context-index.md +42 -0
  197. package/agent-assets/templates/dossiers/_index.md +22 -0
  198. package/agent-assets/templates/dossiers/evening.md +23 -0
  199. package/agent-assets/templates/dossiers/hourly.md +23 -0
  200. package/agent-assets/templates/dossiers/monthly.md +23 -0
  201. package/agent-assets/templates/dossiers/morning.md +23 -0
  202. package/agent-assets/templates/dossiers/roadmap.md +23 -0
  203. package/agent-assets/templates/dossiers/weekly.md +23 -0
  204. package/agent-assets/templates/projects/_active.base +14 -0
  205. package/agent-assets/templates/projects/_index.md +29 -0
  206. package/agent-assets/templates/roadmap.md +15 -0
  207. package/agent-assets/templates/routines/_index.md +20 -0
  208. package/agent-assets/templates/routines/evening.md +22 -0
  209. package/agent-assets/templates/routines/hourly.md +30 -0
  210. package/agent-assets/templates/routines/monthly.md +25 -0
  211. package/agent-assets/templates/routines/morning.md +26 -0
  212. package/agent-assets/templates/routines/weekly.md +23 -0
  213. package/agent-assets/templates/rules/_index.md +19 -0
  214. package/agent-assets/templates/rules/journal-export.md +41 -0
  215. package/agent-assets/templates/rules/journal-format.md +61 -0
  216. package/agent-assets/templates/rules/management.md +48 -0
  217. package/agent-assets/templates/rules/mcp.md +40 -0
  218. package/agent-assets/templates/rules/policies/_index.md +22 -0
  219. package/agent-assets/templates/rules/redaction.md +30 -0
  220. package/agent-assets/templates/today.md +13 -0
  221. package/agent-assets/templates/user/_index.md +16 -0
  222. package/agent-assets/templates/user/expertise.md +7 -0
  223. package/agent-assets/templates/user/goals.md +7 -0
  224. package/agent-assets/templates/user/people.md +7 -0
  225. package/agent-assets/templates/user/personal.md +7 -0
  226. package/agent-assets/templates/user/profile.md +28 -0
  227. package/agent-assets/templates/user/work.md +7 -0
  228. package/bin/aitne.mjs +1096 -0
  229. package/package.json +78 -0
  230. package/personal-agent.mjs +39 -0
  231. package/scripts/browser.mjs +99 -0
  232. package/scripts/check-redaction-coverage.mjs +109 -0
  233. package/scripts/commands/audit.mjs +309 -0
  234. package/scripts/commands/doctor.mjs +437 -0
  235. package/scripts/commands/open.mjs +40 -0
  236. package/scripts/commands/setup.mjs +21 -0
  237. package/scripts/commands/uninstall.mjs +114 -0
  238. package/scripts/commands/update.mjs +96 -0
  239. package/scripts/commands/version.mjs +62 -0
  240. package/scripts/commands.md +0 -0
  241. package/scripts/lib/sqlite-loader.mjs +49 -0
  242. package/scripts/message-discipline-digest.mjs +535 -0
  243. package/scripts/poc/google-connector-inheritance/REPORT.md +197 -0
  244. package/scripts/poc/google-connector-inheritance/claude-sdk-probe.mjs +79 -0
  245. package/scripts/remint-roadmap-ids.mjs +257 -0
  246. package/scripts/rm-paths.mjs +22 -0
  247. package/scripts/run-node.mjs +223 -0
  248. package/scripts/smoke-obsidian-api.mjs +166 -0
  249. package/scripts/start.mjs +160 -0
@@ -0,0 +1,62 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/operations/backend-routing
4
+ title: Backend Routing
5
+ id: backend-routing
6
+ aliases:
7
+ - router
8
+ - main fallback
9
+ - failover
10
+ category: features
11
+ summary: |
12
+ BackendRouter resolves each ProcessKey to a (main, fallback) backend
13
+ pair and a tier. On BackendQuotaError or BackendDecisiveFailure, the
14
+ main backend's session fails over to the fallback's.
15
+ section: operations
16
+ tags:
17
+ - core
18
+ - operations
19
+ - backends
20
+ status: stable
21
+ ask_examples:
22
+ - What happens when my Claude quota is exhausted?
23
+ - Why did my routine run on Codex when I picked Claude?
24
+ - How do fallbacks work?
25
+ locale: en-US
26
+ created: 2026-04-25
27
+ updated: 2026-04-25
28
+ related:
29
+ - concepts/backends-and-tiers
30
+ - features/operations/cost-tracking
31
+ ---
32
+
33
+ # Backend Routing
34
+
35
+ ## In One Sentence
36
+
37
+ Each ProcessKey resolves to a `(main, fallback)` pair and a tier; on
38
+ quota or decisive failure, the dispatcher transitions to the fallback
39
+ mid-run.
40
+
41
+ ## What It Does
42
+
43
+ - Reads the `process_backend_config` table to find the binding.
44
+ - Falls back to the default tier map when no override exists.
45
+ - Re-materializes the session workdir for the fallback backend's
46
+ instruction file and skill set.
47
+
48
+ ## Where in the Dashboard
49
+
50
+ - **Settings → Models** is the unified surface for picking main and
51
+ fallback per ProcessKey.
52
+ - **Activity** rows show which backend actually served each turn after
53
+ fallback resolution.
54
+
55
+ ## When Something Goes Wrong
56
+
57
+ - A `fallback-failed` notification: both backends rejected the run.
58
+ Most often a credentials issue on both sides.
59
+
60
+ ## Related
61
+
62
+ - [Backends and Tiers](../../concepts/backends-and-tiers.md)
@@ -0,0 +1,59 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/operations/cost-tracking
4
+ title: Cost Tracking
5
+ id: cost-tracking
6
+ aliases:
7
+ - analytics
8
+ - cost rollup
9
+ category: features
10
+ summary: |
11
+ The Analytics page rolls cost up by ProcessKey, by backend, and by
12
+ agent day. The sidebar footer shows the running daily total.
13
+ section: operations
14
+ tags:
15
+ - core
16
+ - cost
17
+ - operations
18
+ status: stable
19
+ ask_examples:
20
+ - How much did the agent cost me today?
21
+ - Which routines are the most expensive?
22
+ - How do I cap autonomous spending?
23
+ locale: en-US
24
+ created: 2026-04-25
25
+ updated: 2026-04-25
26
+ related:
27
+ - concepts/costs-and-quotas
28
+ config_keys:
29
+ - autonomousDailyCostCapUsd
30
+ ---
31
+
32
+ # Cost Tracking
33
+
34
+ ## In One Sentence
35
+
36
+ A rolling rollup of token-cost per session, indexed by ProcessKey,
37
+ backend, and agent day.
38
+
39
+ ## What It Does
40
+
41
+ - Records per-execute cost into `agent_actions`.
42
+ - Aggregates into the Analytics page's charts.
43
+ - Surfaces the running daily total in the sidebar footer.
44
+
45
+ ## Where in the Dashboard
46
+
47
+ - **Analytics** is the rollup.
48
+ - **Settings → Models → Cost Guardrails** holds
49
+ `autonomousDailyCostCapUsd`.
50
+
51
+ ## When Something Goes Wrong
52
+
53
+ - A cost number that looks wrong: cross-check against the backend's
54
+ own dashboard. Aitne's count is its best estimate from
55
+ per-call token math.
56
+
57
+ ## Related
58
+
59
+ - [Costs and Quotas](../../concepts/costs-and-quotas.md)
@@ -0,0 +1,69 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/operations/notifications
4
+ title: Notifications
5
+ id: notifications
6
+ aliases:
7
+ - notify
8
+ - notification
9
+ - alerts
10
+ category: features
11
+ summary: |
12
+ Notifications are the agent's outbound DMs to the operator. They
13
+ fire from routines, observations, and approvals. Quiet hours and
14
+ rate limits gate the flow.
15
+ section: operations
16
+ tags:
17
+ - core
18
+ - notifications
19
+ - operations
20
+ status: stable
21
+ ask_examples:
22
+ - When does the agent send me a notification?
23
+ - How do I limit how often it notifies me?
24
+ locale: en-US
25
+ created: 2026-04-25
26
+ updated: 2026-04-25
27
+ related:
28
+ - features/operations/quiet-hours
29
+ - features/operations/approvals
30
+ - features/messaging/overview
31
+ config_keys:
32
+ - maxNotificationsPerHour
33
+ - maxNotificationsPerDay
34
+ - batchIntervalMinutes
35
+ - primaryPlatform
36
+ ---
37
+
38
+ # Notifications
39
+
40
+ ## In One Sentence
41
+
42
+ Outbound DMs the agent sends through the paired messaging app, gated
43
+ by quiet hours and rate limits.
44
+
45
+ ## What It Does
46
+
47
+ - Routines and observations enqueue notifications.
48
+ - Quiet hours hold notifications until the window ends.
49
+ - Per-hour and per-day rate limits cap the volume.
50
+ - Batching folds multiple small alerts into a single message.
51
+
52
+ ## Configuration
53
+
54
+ | Setting | Default |
55
+ |---|---|
56
+ | `maxNotificationsPerHour` | 3 |
57
+ | `maxNotificationsPerDay` | 12 |
58
+ | `batchIntervalMinutes` | 15 |
59
+ | `primaryPlatform` | first paired |
60
+
61
+ ## When Something Goes Wrong
62
+
63
+ - A notification you expected: check the rate-limit counters and the
64
+ quiet-hours window.
65
+
66
+ ## Related
67
+
68
+ - [Quiet Hours](quiet-hours.md)
69
+ - [Approvals](approvals.md)
@@ -0,0 +1,106 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/operations/quiet-hours
4
+ title: Quiet Hours
5
+ id: quiet-hours
6
+ aliases:
7
+ - do not disturb
8
+ - dnd
9
+ - notifications off
10
+ - silent hours
11
+ category: features
12
+ summary: |
13
+ A nightly silent window during which the agent suppresses
14
+ notifications. Routines still run, but their output queues until
15
+ morning instead of waking you.
16
+ section: operations
17
+ tags:
18
+ - operations
19
+ - notifications
20
+ - core
21
+ status: stable
22
+ ask_examples:
23
+ - How do I stop notifications at night?
24
+ - When does the agent go silent?
25
+ - Will routines still run during quiet hours?
26
+ locale: en-US
27
+ created: 2026-04-25
28
+ updated: 2026-04-25
29
+ keywords:
30
+ - quiet hours
31
+ - dnd
32
+ - quietHoursStart
33
+ - quietHoursEnd
34
+ related:
35
+ - features/operations/notifications
36
+ - features/operations/approvals
37
+ - concepts/agent-day
38
+ ui_anchors:
39
+ - /settings/schedule
40
+ config_keys:
41
+ - quietHoursStart
42
+ - quietHoursEnd
43
+ ---
44
+
45
+ # Quiet Hours
46
+
47
+ ## In One Sentence
48
+
49
+ Set a nightly window (default 22:00 → 08:00) during which the agent
50
+ batches notifications instead of pushing them to the messaging app
51
+ in real time.
52
+
53
+ ## What It Does
54
+
55
+ During quiet hours:
56
+
57
+ - **Notifications** are queued, not sent. They flush at the end of the
58
+ window or get folded into the morning routine's "good morning" message.
59
+ - **Routines** keep running. The morning routine fires at
60
+ `dayBoundaryHour` (the same time the agent-day rolls over) — even
61
+ if that falls inside quiet hours, the routine runs and its output
62
+ is batched until the window ends.
63
+ - **Reactive DMs** still respond. Quiet hours only suppress
64
+ *agent-initiated* messages.
65
+
66
+ ## When It Runs / How It Is Triggered
67
+
68
+ Continuously. Every notification dispatcher checks `quietHoursStart`
69
+ and `quietHoursEnd` against the current local time before sending.
70
+ The window is allowed to wrap midnight (22:00 → 08:00 is the default
71
+ shape).
72
+
73
+ ## What It Outputs
74
+
75
+ - An empty notification queue during the window.
76
+ - A consolidated "while you were away" summary at flush time when
77
+ many notifications batched up.
78
+
79
+ ## Where in the Dashboard
80
+
81
+ - **Settings → Schedule** holds `quietHoursStart` and `quietHoursEnd`.
82
+ The form refuses windows that overlap the active hours.
83
+
84
+ ## Configuration
85
+
86
+ | Setting | Default | Notes |
87
+ |---|---|---|
88
+ | `quietHoursStart` | `"22:00"` | `HH:MM` local time string. |
89
+ | `quietHoursEnd` | `"08:00"` | `HH:MM` local time string. |
90
+ | `batchIntervalMinutes` | `15` | How often the batched flush runs once awake. |
91
+
92
+ ## When Something Goes Wrong
93
+
94
+ - An **important** notification that you expected to wake you
95
+ during quiet hours: Aitne does not have a notify-anyway
96
+ override yet (Approvals are the only thing that bypass quiet hours).
97
+ If you need real-time night alerts for, say, a critical mail label,
98
+ the workaround is to disable quiet hours.
99
+ - A notification that fired *after* the window ended but feels stale:
100
+ check `batchIntervalMinutes` — if you set it long, the flush can
101
+ lag the window end by several minutes.
102
+
103
+ ## Related
104
+
105
+ - [Notifications](notifications.md) — the broader notification model.
106
+ - [Approvals](approvals.md) — the only tier that bypasses quiet hours.
@@ -0,0 +1,60 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/operations/schedule-approaching
4
+ title: Schedule Approaching
5
+ id: schedule-approaching
6
+ aliases:
7
+ - schedule reminders
8
+ - approaching event
9
+ category: features
10
+ summary: |
11
+ Lightweight pre-event nudges fire when a calendar event is close
12
+ enough to remind the operator about. The lead time is configurable.
13
+ section: operations
14
+ tags:
15
+ - operations
16
+ - calendar
17
+ - notifications
18
+ status: stable
19
+ ask_examples:
20
+ - How does the agent remind me about meetings?
21
+ - Can I change the lead time?
22
+ locale: en-US
23
+ created: 2026-04-25
24
+ updated: 2026-04-25
25
+ related:
26
+ - features/integrations/calendar
27
+ - features/operations/notifications
28
+ ---
29
+
30
+ # Schedule Approaching
31
+
32
+ ## In One Sentence
33
+
34
+ Pre-event reminders fire on a configurable lead time before each
35
+ calendar event.
36
+
37
+ ## What It Does
38
+
39
+ - Watches the calendar event queue.
40
+ - Fires a notification N minutes before each event.
41
+ - Optionally includes the travel-time estimate when the event has
42
+ a location and the travel-time skill is enabled.
43
+
44
+ ## When It Runs / How It Is Triggered
45
+
46
+ The scheduler keeps a sorted view of upcoming events; a tick at the
47
+ event's lead-time mark fires the notification.
48
+
49
+ ## Where in the Dashboard
50
+
51
+ - **Settings → Schedule** holds the lead-time options.
52
+
53
+ ## When Something Goes Wrong
54
+
55
+ - A reminder you expected: confirm the calendar integration is
56
+ reading the right calendar (some operators have multiple).
57
+
58
+ ## Related
59
+
60
+ - [Calendar](../integrations/calendar.md)
@@ -0,0 +1,101 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/routines/custom-routines
4
+ title: Custom Routines
5
+ id: custom-routines
6
+ aliases:
7
+ - custom routine
8
+ - cron routine
9
+ - user routine
10
+ category: features
11
+ summary: |
12
+ Beyond the built-in morning / evening / weekly / monthly / hourly
13
+ routines, the operator can define custom routines that fire on any
14
+ cron schedule.
15
+ section: routines
16
+ tags:
17
+ - routine
18
+ - autonomous
19
+ - advanced
20
+ status: stable
21
+ ask_examples:
22
+ - How do I add a custom routine?
23
+ - What can a custom routine do?
24
+ - Can I disable a custom routine?
25
+ locale: en-US
26
+ created: 2026-04-25
27
+ updated: 2026-04-25
28
+ related:
29
+ - guides/add-a-custom-routine
30
+ - concepts/routines
31
+ process_keys:
32
+ - routine.custom.<slug>
33
+ ---
34
+
35
+ # Custom Routines
36
+
37
+ ## In One Sentence
38
+
39
+ Operator-defined routines fire at any cron schedule, run under the
40
+ backend the operator picks (light / heavy tier), and are bounded by
41
+ the same safety layers as the built-ins.
42
+
43
+ ## What It Does
44
+
45
+ - Runs a vault-file-defined check list at a cron schedule.
46
+ - Resolves the backend at fire time from the chosen tier (no concrete
47
+ model picker — tier resolution mirrors the built-in routines).
48
+ - Logs its run to Activity exactly like a built-in routine.
49
+
50
+ ## When It Runs / How It Is Triggered
51
+
52
+ The cron expression in the routine's vault file
53
+ `routines/custom/<slug>.md`. The custom-routine scheduler watches the
54
+ file and re-reads the frontmatter on every change.
55
+
56
+ ## What It Outputs
57
+
58
+ - Whatever the check list produces — a context-file write, a
59
+ notification, a no-op.
60
+
61
+ ## Where in the Dashboard
62
+
63
+ - **Settings → Routines** is the operator surface for adding,
64
+ editing, and disabling. (The `/connections/routines` URL is a
65
+ back-compat alias that redirects here.)
66
+
67
+ ## Configuration
68
+
69
+ Each custom routine is a Markdown file under
70
+ `~/.personal-agent/context/routines/custom/<slug>.md` whose
71
+ frontmatter carries:
72
+
73
+ | Field | Type | Notes |
74
+ |---|---|---|
75
+ | `type` | `rule` | Always `rule` for custom routines. |
76
+ | `slug` | string | Kebab-case; matches the file stem and the ProcessKey suffix. |
77
+ | `cron` | string | Standard 5-field cron expression (e.g. `0 11 * * 2`). |
78
+ | `process_key` | `routine.custom.<slug>` | Must match the slug. |
79
+ | `enabled` | boolean | Disable without deleting by setting `false`. |
80
+ | `backend_tier` | `light` \| `heavy` | Drives BackendRouter tier resolution. |
81
+ | `max_budget_usd` | number | Per-execute USD cap (e.g. `0.05`). |
82
+
83
+ The body holds the `## Checks` section the agent runs through on each
84
+ fire. Hand-editing the file is fully supported — the watcher picks up
85
+ changes without a daemon restart.
86
+
87
+ > **Distinct from `recurring_schedules`.** The `recurring_schedules`
88
+ > table powers DM-style scheduled tasks (`agent.task` /
89
+ > `agent.dm_task`) — e.g. "remind me at 9am every weekday". Those
90
+ > use a structured `RecurrenceRule` (frequency + time + dayOf*) and
91
+ > are managed via `POST /api/recurring-schedules`. They are not the
92
+ > same surface as `routine.custom.<slug>`.
93
+
94
+ ## When Something Goes Wrong
95
+
96
+ - A cron expression that resolves to "never": the routine appears in
97
+ the list but never fires. The dashboard shows next-fire as N/A.
98
+
99
+ ## Related
100
+
101
+ - [Add a Custom Routine](../../guides/add-a-custom-routine.md)
@@ -0,0 +1,81 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/routines/evening-review
4
+ title: Evening Review
5
+ id: evening-review
6
+ aliases:
7
+ - evening routine
8
+ - end of day
9
+ - retro
10
+ category: features
11
+ summary: |
12
+ The evening review fires once per day at 18:00 local time. It writes
13
+ the day's retrospective into the agent journal and rolls up unfinished
14
+ items for tomorrow's plan.
15
+ section: routines
16
+ tags:
17
+ - routine
18
+ - autonomous
19
+ - daily
20
+ - light-tier
21
+ status: stable
22
+ ask_examples:
23
+ - When does the evening review run?
24
+ - What does the evening review write?
25
+ - How do I disable it?
26
+ locale: en-US
27
+ created: 2026-04-25
28
+ updated: 2026-04-25
29
+ keywords:
30
+ - evening review
31
+ - retro
32
+ - end of day
33
+ related:
34
+ - concepts/routines
35
+ - features/memory-files/agent-journal
36
+ - features/routines/morning-routine
37
+ process_keys:
38
+ - routine.evening_review
39
+ ---
40
+
41
+ # Evening Review
42
+
43
+ ## In One Sentence
44
+
45
+ A light-tier routine that fires daily at 18:00 local time and writes
46
+ the day's retro into the journal.
47
+
48
+ ## What It Does
49
+
50
+ - Reads the day's `today.md`, the journal entries, the activity feed.
51
+ - Writes a short retrospective into `agent/journal.md`.
52
+ - Surfaces uncompleted carry-over items the morning routine should
53
+ re-pick-up tomorrow.
54
+
55
+ ## When It Runs / How It Is Triggered
56
+
57
+ Every day at **18:00 local time**, exactly once. The cron expression
58
+ is fixed in `packages/daemon/src/core/scheduler.ts` and is not
59
+ operator-configurable.
60
+
61
+ ## What It Outputs
62
+
63
+ - An `agent/journal.md` entry.
64
+ - A "today wraps up here" notification (subject to quiet hours).
65
+
66
+ ## Where in the Dashboard
67
+
68
+ - **Connections → Journal** shows the appended entry.
69
+
70
+ ## Configuration
71
+
72
+ This routine has no operator-tunable knobs. The fire time and tier
73
+ are fixed in code.
74
+
75
+ ## When Something Goes Wrong
76
+
77
+ - A journal that **stops growing**: see [Auth Failed](../../troubleshooting/auth-failed.md) — the routine may be hitting a quota wall.
78
+
79
+ ## Related
80
+
81
+ - [agent/journal.md](../memory-files/agent-journal.md)
@@ -0,0 +1,85 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/routines/hourly-check
4
+ title: Hourly Check
5
+ id: hourly-check
6
+ aliases:
7
+ - hourly
8
+ - observation consumer
9
+ category: features
10
+ summary: |
11
+ A light-tier routine that fires every hour during active hours and
12
+ consumes accumulated observations from the polling integrations.
13
+ section: routines
14
+ tags:
15
+ - routine
16
+ - autonomous
17
+ - light-tier
18
+ status: stable
19
+ ask_examples:
20
+ - What does the hourly check do?
21
+ - When does it run?
22
+ - How do I tune the threshold?
23
+ locale: en-US
24
+ created: 2026-04-25
25
+ updated: 2026-04-25
26
+ keywords:
27
+ - hourly
28
+ - observations
29
+ - polling
30
+ related:
31
+ - concepts/observations
32
+ - concepts/routines
33
+ process_keys:
34
+ - routine.hourly_check
35
+ config_keys:
36
+ - hourlyCheckEnabled
37
+ - hourlyCheckIntervalMinutes
38
+ - hourlyCheckActiveStartHour
39
+ - hourlyCheckActiveEndHour
40
+ - hourlyCheckMinObservations
41
+ ---
42
+
43
+ # Hourly Check
44
+
45
+ ## In One Sentence
46
+
47
+ A light-tier routine that empties the observations queue and decides
48
+ whether the accumulated changes warrant a notification.
49
+
50
+ ## What It Does
51
+
52
+ - Reads pending `observations` rows.
53
+ - Decides whether the pattern adds up to something worth surfacing.
54
+ - Either appends to `today.md` or sends a notification (or both).
55
+
56
+ ## When It Runs / How It Is Triggered
57
+
58
+ Every `hourlyCheckIntervalMinutes` (default 60), inside the active
59
+ window (`hourlyCheckActiveStartHour` to `hourlyCheckActiveEndHour`).
60
+ Skips when the morning routine is in progress; an atomic flag
61
+ prevents two hourly checks from running at once.
62
+
63
+ ## What It Outputs
64
+
65
+ - Updates to `today.md`.
66
+ - Notifications when warranted.
67
+
68
+ ## Configuration
69
+
70
+ | Setting | Default |
71
+ |---|---|
72
+ | `hourlyCheckEnabled` | true |
73
+ | `hourlyCheckIntervalMinutes` | 60 |
74
+ | `hourlyCheckActiveStartHour` | 4 |
75
+ | `hourlyCheckActiveEndHour` | 24 (end-exclusive, ≡ midnight) |
76
+ | `hourlyCheckMinObservations` | 1 |
77
+
78
+ ## When Something Goes Wrong
79
+
80
+ - Skipped hourly checks below the min-observations threshold are
81
+ expected. The daemon log shows the skip reason.
82
+
83
+ ## Related
84
+
85
+ - [Observations](../../concepts/observations.md)
@@ -0,0 +1,65 @@
1
+ ---
2
+ schema_version: 1
3
+ slug: features/routines/monthly-review
4
+ title: Monthly Review
5
+ id: monthly-review
6
+ aliases:
7
+ - monthly retro
8
+ category: features
9
+ summary: |
10
+ Once a month, the agent rolls up the four weekly retros into a
11
+ single monthly synthesis under monthly/<YYYY-MM>.md.
12
+ section: routines
13
+ tags:
14
+ - routine
15
+ - autonomous
16
+ - light-tier
17
+ status: stable
18
+ ask_examples:
19
+ - When does the monthly review fire?
20
+ - Where do monthly retros live?
21
+ locale: en-US
22
+ created: 2026-04-25
23
+ updated: 2026-04-25
24
+ related:
25
+ - features/routines/weekly-review
26
+ process_keys:
27
+ - routine.monthly_review
28
+ ---
29
+
30
+ # Monthly Review
31
+
32
+ ## In One Sentence
33
+
34
+ Light-tier monthly retro that synthesizes the four weekly reviews into
35
+ a single monthly file.
36
+
37
+ ## What It Does
38
+
39
+ - Reads the past month of weekly retros.
40
+ - Surfaces threads, recurring patterns, and unfinished pushes.
41
+ - Writes the synthesis into `monthly/<YYYY-MM>.md`.
42
+
43
+ ## When It Runs / How It Is Triggered
44
+
45
+ The **last day of the calendar month at 18:00 local time**. The schedule
46
+ is fixed in `packages/daemon/src/core/scheduler.ts` and is not
47
+ operator-configurable.
48
+
49
+ ## What It Outputs
50
+
51
+ - A single `monthly/<YYYY-MM>.md` file.
52
+
53
+ ## Configuration
54
+
55
+ This routine has no operator-tunable knobs. The fire time, day-of-month,
56
+ and tier are fixed in code.
57
+
58
+ ## When Something Goes Wrong
59
+
60
+ - A late-month install will skip the first month's retro because
61
+ there are not four weekly retros to synthesize yet.
62
+
63
+ ## Related
64
+
65
+ - [Weekly Review](weekly-review.md)