@plurnk/plurnk-service 1.24.0 → 1.25.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 (186) hide show
  1. package/.env.defaults +17 -15
  2. package/INSTALL.md +96 -20
  3. package/README.md +2 -2
  4. package/SPEC.md +461 -169
  5. package/dist/Paths.d.ts +1 -0
  6. package/dist/Paths.d.ts.map +1 -1
  7. package/dist/Paths.js +1 -0
  8. package/dist/Paths.js.map +1 -1
  9. package/dist/build-info.json +1 -1
  10. package/dist/core/AdministrativeLoop.d.ts +1 -1
  11. package/dist/core/AdministrativeLoop.d.ts.map +1 -1
  12. package/dist/core/AdministrativeLoop.js +5 -5
  13. package/dist/core/AdministrativeLoop.js.map +1 -1
  14. package/dist/core/CapabilityResolver.js +1 -1
  15. package/dist/core/CapabilityResolver.js.map +1 -1
  16. package/dist/core/DataStatementRunner.d.ts.map +1 -1
  17. package/dist/core/DataStatementRunner.js +1 -3
  18. package/dist/core/DataStatementRunner.js.map +1 -1
  19. package/dist/core/Dispatcher.d.ts.map +1 -1
  20. package/dist/core/Dispatcher.js +28 -19
  21. package/dist/core/Dispatcher.js.map +1 -1
  22. package/dist/core/Dispatcher.sql +0 -7
  23. package/dist/core/Engine.d.ts +2 -2
  24. package/dist/core/Engine.d.ts.map +1 -1
  25. package/dist/core/ExecutorRegistry.d.ts +16 -4
  26. package/dist/core/ExecutorRegistry.d.ts.map +1 -1
  27. package/dist/core/ExecutorRegistry.js +31 -31
  28. package/dist/core/ExecutorRegistry.js.map +1 -1
  29. package/dist/core/HostPaths.d.ts +7 -1
  30. package/dist/core/HostPaths.d.ts.map +1 -1
  31. package/dist/core/HostPaths.js +25 -12
  32. package/dist/core/HostPaths.js.map +1 -1
  33. package/dist/core/LoopDriver.d.ts.map +1 -1
  34. package/dist/core/LoopDriver.js +8 -1
  35. package/dist/core/LoopDriver.js.map +1 -1
  36. package/dist/core/LoopLifecycle.d.ts +1 -1
  37. package/dist/core/LoopLifecycle.js +1 -1
  38. package/dist/core/LoopLifecycle.sql +2 -2
  39. package/dist/core/LoopPolicies.d.ts.map +1 -1
  40. package/dist/core/LoopPolicies.js +12 -7
  41. package/dist/core/LoopPolicies.js.map +1 -1
  42. package/dist/core/OperatorConfig.d.ts.map +1 -1
  43. package/dist/core/OperatorConfig.js +97 -51
  44. package/dist/core/OperatorConfig.js.map +1 -1
  45. package/dist/core/PacketBuilder.d.ts +1 -0
  46. package/dist/core/PacketBuilder.d.ts.map +1 -1
  47. package/dist/core/PacketBuilder.js +20 -24
  48. package/dist/core/PacketBuilder.js.map +1 -1
  49. package/dist/core/SchemeRegistry.d.ts.map +1 -1
  50. package/dist/core/SchemeRegistry.js +3 -2
  51. package/dist/core/SchemeRegistry.js.map +1 -1
  52. package/dist/core/TurnDispositionHandler.d.ts +1 -1
  53. package/dist/core/TurnDispositionHandler.d.ts.map +1 -1
  54. package/dist/core/TurnDispositionHandler.js +6 -15
  55. package/dist/core/TurnDispositionHandler.js.map +1 -1
  56. package/dist/core/TurnMaterialization.js +1 -1
  57. package/dist/core/TurnMaterialization.js.map +1 -1
  58. package/dist/core/TurnOps.d.ts +1 -0
  59. package/dist/core/TurnOps.d.ts.map +1 -1
  60. package/dist/core/TurnOps.js +18 -0
  61. package/dist/core/TurnOps.js.map +1 -1
  62. package/dist/core/TurnRunner.d.ts.map +1 -1
  63. package/dist/core/TurnRunner.js +7 -6
  64. package/dist/core/TurnRunner.js.map +1 -1
  65. package/dist/core/env-defaults.d.ts +12 -1
  66. package/dist/core/env-defaults.d.ts.map +1 -1
  67. package/dist/core/env-defaults.js +46 -7
  68. package/dist/core/env-defaults.js.map +1 -1
  69. package/dist/core/file-creation-policy.d.ts.map +1 -1
  70. package/dist/core/file-creation-policy.js +2 -1
  71. package/dist/core/file-creation-policy.js.map +1 -1
  72. package/dist/core/packet-wire.d.ts +1 -0
  73. package/dist/core/packet-wire.d.ts.map +1 -1
  74. package/dist/core/packet-wire.js +27 -5
  75. package/dist/core/packet-wire.js.map +1 -1
  76. package/dist/core/results.d.ts +2 -0
  77. package/dist/core/results.d.ts.map +1 -1
  78. package/dist/core/results.js +7 -0
  79. package/dist/core/results.js.map +1 -1
  80. package/dist/digest/Digest.d.ts.map +1 -1
  81. package/dist/digest/Digest.js +0 -2
  82. package/dist/digest/Digest.js.map +1 -1
  83. package/dist/digest/DigestRender.d.ts.map +1 -1
  84. package/dist/digest/DigestRender.js +15 -19
  85. package/dist/digest/DigestRender.js.map +1 -1
  86. package/dist/digest/digest-rows.d.ts +1 -1
  87. package/dist/digest/digest-rows.d.ts.map +1 -1
  88. package/dist/observe/init.d.ts +1 -0
  89. package/dist/observe/init.d.ts.map +1 -1
  90. package/dist/observe/init.js +5 -1
  91. package/dist/observe/init.js.map +1 -1
  92. package/dist/schemes/EffectPolicy.d.ts.map +1 -1
  93. package/dist/schemes/EffectPolicy.js +4 -4
  94. package/dist/schemes/EffectPolicy.js.map +1 -1
  95. package/dist/schemes/Exec.d.ts +1 -0
  96. package/dist/schemes/Exec.d.ts.map +1 -1
  97. package/dist/schemes/Exec.js +30 -14
  98. package/dist/schemes/Exec.js.map +1 -1
  99. package/dist/schemes/ExecScheduler.d.ts.map +1 -1
  100. package/dist/schemes/ExecScheduler.js +4 -3
  101. package/dist/schemes/ExecScheduler.js.map +1 -1
  102. package/dist/schemes/ExecScratch.d.ts.map +1 -1
  103. package/dist/schemes/ExecScratch.js +2 -1
  104. package/dist/schemes/ExecScratch.js.map +1 -1
  105. package/dist/schemes/File.d.ts.map +1 -1
  106. package/dist/schemes/File.js +15 -10
  107. package/dist/schemes/File.js.map +1 -1
  108. package/dist/server/AgentRoots.d.ts +6 -0
  109. package/dist/server/AgentRoots.d.ts.map +1 -0
  110. package/dist/server/AgentRoots.js +25 -0
  111. package/dist/server/AgentRoots.js.map +1 -0
  112. package/dist/server/ConfigurationDiagnostics.d.ts +12 -0
  113. package/dist/server/ConfigurationDiagnostics.d.ts.map +1 -0
  114. package/dist/server/ConfigurationDiagnostics.js +40 -0
  115. package/dist/server/ConfigurationDiagnostics.js.map +1 -0
  116. package/dist/server/Daemon.d.ts +11 -5
  117. package/dist/server/Daemon.d.ts.map +1 -1
  118. package/dist/server/Daemon.js +124 -48
  119. package/dist/server/Daemon.js.map +1 -1
  120. package/dist/server/DaemonModule.d.ts +11 -4
  121. package/dist/server/DaemonModule.d.ts.map +1 -1
  122. package/dist/server/EnvFunctionality.d.ts.map +1 -1
  123. package/dist/server/EnvFunctionality.js +5 -2
  124. package/dist/server/EnvFunctionality.js.map +1 -1
  125. package/dist/server/Functionality.d.ts +6 -0
  126. package/dist/server/Functionality.d.ts.map +1 -1
  127. package/dist/server/Functionality.js +173 -37
  128. package/dist/server/Functionality.js.map +1 -1
  129. package/dist/server/FunctionalityManager.js +6 -6
  130. package/dist/server/FunctionalityManager.js.map +1 -1
  131. package/dist/server/MembersFunctionality.d.ts.map +1 -1
  132. package/dist/server/MembersFunctionality.js +13 -41
  133. package/dist/server/MembersFunctionality.js.map +1 -1
  134. package/dist/server/PluginSources.d.ts +20 -0
  135. package/dist/server/PluginSources.d.ts.map +1 -0
  136. package/dist/server/PluginSources.js +52 -0
  137. package/dist/server/PluginSources.js.map +1 -0
  138. package/dist/server/PlurnkSkill.js +1 -1
  139. package/dist/server/PlurnkSkill.js.map +1 -1
  140. package/dist/server/Retention.d.ts.map +1 -1
  141. package/dist/server/Retention.js +11 -30
  142. package/dist/server/Retention.js.map +1 -1
  143. package/dist/server/ServiceModules.d.ts +1 -0
  144. package/dist/server/ServiceModules.d.ts.map +1 -1
  145. package/dist/server/ServiceModules.js +9 -3
  146. package/dist/server/ServiceModules.js.map +1 -1
  147. package/dist/server/SkillSource.d.ts +37 -0
  148. package/dist/server/SkillSource.d.ts.map +1 -0
  149. package/dist/server/SkillSource.js +267 -0
  150. package/dist/server/SkillSource.js.map +1 -0
  151. package/dist/server/SkillsFunctionality.d.ts +8 -27
  152. package/dist/server/SkillsFunctionality.d.ts.map +1 -1
  153. package/dist/server/SkillsFunctionality.js +218 -270
  154. package/dist/server/SkillsFunctionality.js.map +1 -1
  155. package/dist/server/WorkerModelResolver.d.ts +1 -2
  156. package/dist/server/WorkerModelResolver.d.ts.map +1 -1
  157. package/dist/server/WorkerModelResolver.js +18 -19
  158. package/dist/server/WorkerModelResolver.js.map +1 -1
  159. package/dist/server/WorkspacePlugins.d.ts +25 -0
  160. package/dist/server/WorkspacePlugins.d.ts.map +1 -0
  161. package/dist/server/WorkspacePlugins.js +43 -0
  162. package/dist/server/WorkspacePlugins.js.map +1 -0
  163. package/dist/server/dispatch-as-plurnk.d.ts.map +1 -1
  164. package/dist/server/dispatch-as-plurnk.js +2 -1
  165. package/dist/server/dispatch-as-plurnk.js.map +1 -1
  166. package/dist/server/envelope.js +1 -1
  167. package/dist/server/envelope.js.map +1 -1
  168. package/dist/server/loop-model.d.ts.map +1 -1
  169. package/dist/server/loop-model.js +1 -2
  170. package/dist/server/loop-model.js.map +1 -1
  171. package/dist/server/module-discovery.d.ts +6 -0
  172. package/dist/server/module-discovery.d.ts.map +1 -1
  173. package/dist/server/module-discovery.js +46 -24
  174. package/dist/server/module-discovery.js.map +1 -1
  175. package/dist/server/skills-problems.d.ts +8 -0
  176. package/dist/server/skills-problems.d.ts.map +1 -0
  177. package/dist/server/skills-problems.js +18 -0
  178. package/dist/server/skills-problems.js.map +1 -0
  179. package/dist/service.d.ts.map +1 -1
  180. package/dist/service.js +55 -45
  181. package/dist/service.js.map +1 -1
  182. package/docs/env.md +7 -8
  183. package/docs/members.md +4 -3
  184. package/docs/skills.md +45 -22
  185. package/package.json +37 -35
  186. package/plurnk.service +29 -0
package/.env.defaults CHANGED
@@ -1,9 +1,9 @@
1
1
  # @plurnk/plurnk-service — daemon configuration.
2
2
  # Active declarations are defaults; commented declarations are optional examples.
3
- # Put overrides in the shell, ./.env, or $XDG_CONFIG_HOME/plurnk/.env.
3
+ # Put overrides in the shell or $XDG_CONFIG_HOME/plurnk/.env; a working directory's .env is not read.
4
4
  # Full installed reference: plurnk-service config defaults
5
5
  # Precedence (highest first): CLI flags > shell > --env-file* > --config >
6
- # ./.env > user .env > package defaults. Later explicit env files win.
6
+ # user .env > package defaults. Later explicit env files win.
7
7
  # Service flags mirror these names: PLURNK_SERVICE_MAX_TURNS → --service-max-turns.
8
8
 
9
9
  # --- Storage ---
@@ -51,11 +51,12 @@ PLURNK_SERVICE_UNATTENDED_PROPOSALS=reject
51
51
  PLURNK_SERVICE_FILE_CREATE_SCOPE=root
52
52
  # Model-added membership: none | root | namespace. Workspaces may narrow it.
53
53
  PLURNK_SERVICE_MEMBERS_MODEL_SCOPE=namespace
54
- # Operator members definitions enabled by default, JSON array of aliases; [] = none.
55
- PLURNK_MEMBERS_ENABLED=[]
56
- # A definition is PLURNK_MEMBERS_<alias>=<glob>; a leading ! excludes.
54
+ # Enable declared membership rules by default; per-alias _ENABLED overrides this.
55
+ PLURNK_MEMBERS_ENABLED=1
56
+ # Lowercase aliases use _ for -. A leading ! in the glob excludes.
57
57
  # PLURNK_MEMBERS_docs=docs/**
58
58
  # PLURNK_MEMBERS_no_locks=!**/*.lock
59
+ # PLURNK_MEMBERS_docs_ENABLED=0
59
60
  # Matched paths a members definition lists as its sample; the rest are counted.
60
61
  PLURNK_SERVICE_MEMBERS_SAMPLE=20
61
62
  # Git membership, status, and branch integration: 1 = permitted; 0 = denied service-wide.
@@ -193,16 +194,17 @@ PLURNK_SERVICE_FILES_ITEMS=-1
193
194
  # Scheme names omitted from discoverable references, comma-separated; empty = none.
194
195
  # Executable docs instead follow tool enablement. Plugin trust lives in plurnk-meta's defaults.
195
196
  PLURNK_SERVICE_DOCS_EXCLUDE="plurnk,file,exec"
196
- # Agent Skills installer command, used by the service beneath skills add/remove/discover.
197
- PLURNK_SERVICE_SKILLS_CLI="npx --yes skills"
198
- # Skills search registry (GET /api/search?q=...); empty = registry search disabled.
199
- PLURNK_SERVICE_SKILLS_REGISTRY_URL=https://skills.sh
200
- # Results one registry search asks for.
201
- PLURNK_SERVICE_SKILLS_REGISTRY_LIMIT=20
202
- # Deadline for one registry search, positive ms.
203
- PLURNK_SERVICE_SKILLS_REGISTRY_TIMEOUT_MS=30000
204
- # Deadline for one skills CLI run, positive ms.
205
- PLURNK_SERVICE_SKILLS_CLI_TIMEOUT_MS=120000
197
+ # Skills, plugin and standalone MCP configuration roots, comma-separated, nearest first: project
198
+ # (the workspace project's .agents), plurnk ($XDG_CONFIG_HOME/plurnk), global (~/.agents).
199
+ PLURNK_SERVICE_ROOTS=project,plurnk,global
200
+ # Agent Skills: whole source definitions override discovered skills by their exact standard name.
201
+ # `_` in a key represents `-`; Unicode names work in .env or via `env 'KEY=value' command`.
202
+ # PLURNK_SKILLS_code_review={"name":"code-review","source":"/srv/skills/code-review"}
203
+ # Declared and discovered skills default enabled; per-name controls override this default.
204
+ PLURNK_SKILLS_ENABLED=1
205
+ # PLURNK_SKILLS_code_review_ENABLED=0
206
+ # Deadline for one skills source fetch (git ls-remote, git clone, tar, unzip), positive ms.
207
+ PLURNK_SERVICE_SKILLS_FETCH_TIMEOUT_MS=120000
206
208
  # Extra Markdown after language teaching, reread each turn; unreadable explicit paths fail.
207
209
  # PLURNK_SERVICE_PACKET_INJECT="~/injection.md"
208
210
  # Policy Markdown: unset = $XDG_CONFIG_HOME/plurnk/AGENTS.md; empty = off; otherwise that path.
package/INSTALL.md CHANGED
@@ -15,21 +15,33 @@ plurnk-service start
15
15
  ```
16
16
 
17
17
  First start seeds the user's configuration once. No model ships active;
18
- [choose a model route](https://github.com/plurnk/plurnk-service/blob/main/plurnk-providers/README.md#configure-a-model) before starting a model loop. The version-1 database
19
- baseline is disposable during development.
18
+ [choose a model route](https://github.com/plurnk/plurnk-service/blob/main/plurnk-providers/README.md#configure-a-model) before starting a model loop.
19
+
20
+ For an explicitly shared Linux daemon, the npm package includes an example
21
+ [systemd user unit](./plurnk.service). Its comments cover manual installation,
22
+ executable paths, environment, and logs. Installing the package never installs
23
+ or enables the unit.
20
24
 
21
25
  | Resource | Default location |
22
26
  | --- | --- |
23
27
  | User configuration | `$XDG_CONFIG_HOME/plurnk/.env` (`~/.config/plurnk/.env`) |
24
28
  | Operating policy | `$XDG_CONFIG_HOME/plurnk/AGENTS.md` |
25
29
  | Database | `$XDG_DATA_HOME/plurnk/plurnk.db` (`~/.local/share/plurnk/plurnk.db`) |
26
- | Project configuration | `.env` in the service's working directory |
27
30
  | Project / global Agent Skills | `.agents/skills/` / `~/.agents/skills/` |
31
+ | Plurnk-only Agent Skills | `$XDG_CONFIG_HOME/plurnk/skills/` |
32
+ | Project / global MCP servers | `.agents/mcp.json` / `~/.agents/mcp.json` |
33
+ | Plurnk-only MCP servers | `$XDG_CONFIG_HOME/plurnk/mcp.json` |
28
34
 
29
35
  Use `plurnk-service config` for paths and precedence, `config edit` to edit the
30
36
  user file, and `config check` to validate it. An old `~/.plurnk` is not read
31
37
  implicitly; `plurnk-service paths migrate` relocates it with the daemon stopped.
32
38
 
39
+ Invalid optional configuration stays visible without removing the repair environment.
40
+ `config check` is strict; ordinary startup keeps unrelated capabilities and client
41
+ inspection available. Model providers are constructed and verified on selection or
42
+ first use, not on startup. An invalid default never selects a different model:
43
+ choose a valid model in the client or correct the daemon's configuration.
44
+
33
45
  ## Precedence
34
46
 
35
47
  Highest priority first ({§operator-config-precedence}):
@@ -40,10 +52,12 @@ Highest priority first ({§operator-config-precedence}):
40
52
  | Initial shell environment | Preserved over files. |
41
53
  | `--env-file` / `--env-file-if-exists` | Repeatable; later files win. The optional form skips absent files. |
42
54
  | `--config=<path>` | One explicit service configuration file. |
43
- | `./.env` | Service working-directory configuration. |
44
55
  | `$XDG_CONFIG_HOME/plurnk/.env` | User configuration. |
45
56
  | Installed packages' `.env.defaults` | Set-if-unset floor; duplicate key ownership fails boot. |
46
57
 
58
+ A working directory's `.env` belongs to that directory's application and is never read. A project's
59
+ variables reach its commands through the workspace environment (`/env import .env`).
60
+
47
61
  For a service-owned variable, strip `PLURNK_`, lowercase, and replace `_` with
48
62
  `-` to obtain its CLI flag: `PLURNK_SERVICE_MAX_TURNS` → `--service-max-turns`.
49
63
  Plugin settings remain environment/configuration values; they do not extend the
@@ -56,7 +70,8 @@ the owning declaration specifies its meaning.
56
70
  | --- | --- |
57
71
  | Startup defaults or installed plugin configuration | The daemon's environment cascade. A remote client's shell does not change it. |
58
72
  | Model, reasoning, child model | Worker selections persist. Set them through client controls; changing a startup default does not retarget an existing Worker. |
59
- | MCPs, skills, agents | Workspace Functionality: list, discover, add, enable, disable, remove. Workers share the workspace's current selection. |
73
+ | MCPs, skills, outbound agents, schedules, membership | Workspace Functionality: list, discover, add, enable, disable, remove. Workers share the workspace's current selection. |
74
+ | Command environment | `env` manages worker overrides or workspace defaults. It does not reconfigure the daemon; running processes keep their launch environment. |
60
75
  | External capabilities | Service policy is a ceiling; workspace policy can narrow it for every worker. Hiding a doc does not grant or revoke authority. |
61
76
  | Proposal review / YOLO | Decides who accepts or rejects an admitted operation. Automatic acceptance never overrides capability or resource permissions. |
62
77
  | File creation and membership | Separate policies. Creating an out-of-root file, admitting a new file, and editing an existing member are distinct decisions. |
@@ -77,18 +92,79 @@ a model cannot widen their ceiling by changing its policy prose.
77
92
 
78
93
  ## Skills
79
94
 
80
- Project names shadow global names, which shadow service-provided skills.
81
- Plurnk's own skill uses the same discovery, READ, and workspace enablement as
82
- installed skills. It is not copied into a universal root.
83
-
84
- Clients use `workspace.skills.{list,discover,add,enable,disable,remove}`; models use
85
- the generated `skills` executor. `discover` returns candidates without
86
- installation. `add` installs through the standard skills CLI into the chosen
87
- project or global scope; `remove` uninstalls a workspace-origin installation.
88
- Service-provided entries can be disabled, not uninstalled through that action.
89
- An external installer changes the available catalog at the next turn.
90
-
91
- Project installation is local to that project. Global installation intentionally
92
- shares the skill with other compatible agents using `~/.agents/skills/`.
93
- Supporting files stay in their original tree, including script siblings.
94
- READ is not execution; running a script follows ordinary proposal policy.
95
+ Project names shadow Plurnk-only names, then user-global names, then
96
+ service-provided skills. Agent Plugin skills join the same scope after standalone
97
+ skills; npm bundles follow user-global roots. These are read-only configuration inputs;
98
+ external edits appear at the next turn. Plurnk's own skill uses the same READ,
99
+ discovery, and workspace enablement as other skills.
100
+
101
+ `skills (add)` binds a source to this workspace, never installs into those roots.
102
+ Local folders and `SKILL.md` files stay live references, with supporting files in
103
+ place. Git/archive sources become workspace-owned copies retained across enable
104
+ and restart until the source definition changes. `remove` forgets the workspace
105
+ binding without deleting its source. READ is not execution; running a skill's
106
+ script follows ordinary proposal policy. The [skills reference](worker:///_plurnk/plurnk/skills.md)
107
+ covers discovery, source forms, and Git refs.
108
+
109
+ ## Resource definitions
110
+
111
+ Supported standard sources, environment declarations, and live workspace changes
112
+ feed the same family. Whole definitions replace lower definitions; omitted fields
113
+ never inherit. Workspace overrides win over environment declarations, which win
114
+ over discovered sources. Independent behavior controls cascade separately.
115
+
116
+ ```dotenv
117
+ PLURNK_MCP_docs={"name":"docs","type":"streamable-http","url":"https://docs.example/mcp"}
118
+ PLURNK_MCP_ENABLED=1
119
+ PLURNK_MCP_docs_ENABLED=0
120
+ ```
121
+
122
+ MCP, skills, outbound A2A, schedule, and members use this same naming pattern;
123
+ their `.env.defaults` entries describe each family's definition and controls.
124
+ Aliases use lowercase names, with `_` encoding `-`; skills retain their standard
125
+ Unicode and digit-leading names. An empty definition is invalid, not a disable
126
+ instruction. A control may precede the resource it will govern.
127
+
128
+ | Action | Effect |
129
+ | --- | --- |
130
+ | Declare in configuration | Supply an inherited definition, enabled by default unless a control disables it. No workspace writes. |
131
+ | `list` | Inspect the effective definition, ownership (`origin`), winning configuration input (`provenance`), enabledness, and runtime readiness without starting it. |
132
+ | `discover` | Return inert candidates; nothing is added or enabled. |
133
+ | `add` | Persist a workspace override and prepare it through the ordinary authorization policy. |
134
+ | `disable` / `enable` | Change availability without forgetting the definition or updating fetched skill copies. |
135
+ | `remove` | Forget the local override and restore the inherited definition and enabledness. Use `disable` to suppress an inherited entry. |
136
+
137
+ Use the environment cascade for daemon/CI defaults and the subsystem actions for
138
+ live workspace changes. A declared or enabled resource never bypasses capability
139
+ or proposal policy. Unavailable resources retain their exact Problem in `list`.
140
+ Configuration provenance names the definition's environment key, discovered
141
+ `SKILL.md` path, or MCP JSON file and JSON Pointer, not a dotenv file or shadowed history. Local overrides are
142
+ workspace-owned; removing one exposes its current inherited source again.
143
+
144
+ ## Native extensions
145
+
146
+ Standard [Agent Plugins](https://agent-plugins.org/specification) keep their portable
147
+ skills and MCP servers and may add one native capability under `extensions.ai.plurnk`.
148
+ That declaration uses the family's existing loader and lifetime. For daemon lifecycle
149
+ hooks, declare a module:
150
+
151
+ ```json
152
+ {
153
+ "$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json",
154
+ "name": "example-plugin",
155
+ "extensions": { "ai.plurnk": { "kind": "module", "module": "ai.plurnk/plugin.js" } }
156
+ }
157
+ ```
158
+
159
+ Daemon modules load at startup from installed npm packages and selected user roots:
160
+ `$XDG_CONFIG_HOME/plurnk/plugins/` before `~/.agents/plugins/`, then npm. The manifest name
161
+ identifies a plugin across those sources. Project plugins never load native code into the daemon.
162
+ `PLURNK_SERVICE_ROOTS` selects the directory roots; `PLURNK_PLUGINS_TRUSTED_ONLY` governs native
163
+ imports, using the npm package name when present or the plugin name otherwise.
164
+ Other native families (executors, schemes, providers, mimetypes and HTTP materializers)
165
+ require npm installation and retain their own loading behavior.
166
+
167
+ The module exports a lifecycle object or a no-argument factory. `setup` registers capabilities;
168
+ `stop` drains producers; `close` releases registrations and observers. See {§module-lifecycle}.
169
+ Native files and the optional configuration panel live under `ai.plurnk/`; its `.env.defaults`
170
+ joins the ordinary floor. npm owns dependencies and delivery, not a second native declaration.
package/README.md CHANGED
@@ -53,8 +53,8 @@ configuration guide.** A legacy mixed `~/.plurnk` is moved only by the explicit
53
53
  The 1.x package retains its frozen root library barrel for SemVer compatibility;
54
54
  it is not the client boundary and gains no new APIs. Programmatic forensic use
55
55
  imports `@plurnk/plurnk-service/digest`.
56
- The digest replaces its selected output directory; keep that directory separate
57
- from its input database. Overlapping input/output paths are refused.
56
+ The digest requires a new or empty output directory, separate from its input
57
+ database. Existing output and overlapping input/output paths are refused.
58
58
 
59
59
  ## Contract & siblings
60
60