feat(settings): resolve namespaces per named scope

A settings namespace is now a kind; each registration is an instance
filed under the caller's nearest named scope (dsh-scope gains
createScope(..., { id }) and scopeIdOf). Instances resolve defaults →
composition base → global user section → scopes.<id>.<ns>. Global writes
fan out to every instance gated on its own resolved value; scoped writes
commit one instance. Revisions are per section so a scope nothing has
registered yet can still be written when the kind exists. describe(),
the controller verbs, and both events take an optional trailing scope.
Presets name their standing scopes preset/<id>; skill-filesystem is the
first consumer, resolving customSkillDirs per scope with live updates.
This commit is contained in:
Yichen Jiang committed 2026-09-04 03:03:43 +08:00
1 parent dc969e2ee8
commit 80ea5fcdf5
63 files changed
+1784 -435

No files matched your search

+1
View File
@@ -545,6 +545,7 @@ export const LINK_MAP: Readonly<Record<string, string>> = {
ToolRestriction: 'tools.md',
ToolSchema: 'tools.md',
SettingsNamespace: 'settings.md',
SettingsScopeId: 'settings.md',
SettingsNamespaceInput: 'settings.md',
SettingsRegisterOptions: 'settings.md',
SettingsSectionHooks: 'settings.md',