Skip to content

Self-improving AI Employees for everyone

feat(allowlist): auto-hide skill folders tied to disabled features (Wave 34.1)

trohitga18e33aa5ac7
diff --git a/client/src/components/parameterPanel/MasterSkillEditor.tsx b/client/src/components/parameterPanel/MasterSkillEditor.tsx
index 58073ae3..ba6a5597 100644
--- a/client/src/components/parameterPanel/MasterSkillEditor.tsx
+++ b/client/src/components/parameterPanel/MasterSkillEditor.tsx
@@ -50,6 +50,7 @@ import { useWebSocket } from '../../contexts/WebSocketContext';
import { NodeIcon } from '../../assets/icons';
import { cn } from '@/lib/utils';
import { useFolderSkills } from '../../hooks/useFolderSkills';
+import { useNodeAllowlist } from '../../hooks/useNodeAllowlist';
// Skill configuration stored in node parameters
// Key is skillName (folder name like 'whatsapp-skill')
@@ -151,7 +152,18 @@ const MasterSkillEditor: React.FC<MasterSkillEditorProps> = ({
},
staleTime: Infinity,
});
- const availableFolders = foldersQuery.data ?? [];
+
+ // Filter out skill folders disabled via the allowlist
+ // (server/config/node_allowlist.json -> disabled_skill_folders).
+ // Same mode-independent enforcement as the credential-category and
+ // node-group blocklists. Use to auto-hide skill folders tied to a
+ // disabled feature (e.g. `android_agent` when android nodes +
+ // credentials are blocked).
+ const { isSkillFolderDisabled } = useNodeAllowlist();
+ const availableFolders = useMemo(
+ () => (foldersQuery.data ?? []).filter((f) => !isSkillFolderDisabled(f.name)),
+ [foldersQuery.data, isSkillFolderDisabled],
+ );
const foldersLoaded = !foldersQuery.isLoading;
const folderSkillsQuery = useFolderSkills(skillFolder);
diff --git a/client/src/hooks/useNodeAllowlist.ts b/client/src/hooks/useNodeAllowlist.ts
index 00422a4e..a8090b1a 100644
--- a/client/src/hooks/useNodeAllowlist.ts
+++ b/client/src/hooks/useNodeAllowlist.ts
@@ -17,6 +17,10 @@ interface NodeAllowlistResponse {
* e.g. 'android' / 'ai' / 'social'). Empty array on older
* deployments. */
disabled_credential_categories: string[];
+ /** Mode-independent blocklist for the Master Skill folder
+ * dropdown — every entry hides the matching subfolder under
+ * server/skills/. Empty array on older deployments. */
+ disabled_skill_folders: string[];
}
/**
@@ -63,6 +67,7 @@ export const useNodeAllowlist = () => {
disabled_groups: response?.disabled_groups ?? [],
disabled_nodes: response?.disabled_nodes ?? [],
disabled_credential_categories: response?.disabled_credential_categories ?? [],
+ disabled_skill_folders: response?.disabled_skill_folders ?? [],
});
})
.catch((error) => {
@@ -73,6 +78,7 @@ export const useNodeAllowlist = () => {
disabled_groups: [],
disabled_nodes: [],
disabled_credential_categories: [],
+ disabled_skill_folders: [],
});
});
}, [isConnected, sendRequest]);
@@ -128,5 +134,23 @@ export const useNodeAllowlist = () => {
[config]
);
- return { isVisible, isBlocked, isAllowed, isCredentialCategoryDisabled };
+ /** True if the skill folder is in the absolute blocklist — use to
+ * filter the Master Skill folder dropdown (e.g. hide
+ * 'android_agent' when the android feature is disabled). False
+ * while loading so the dropdown doesn't pre-hide. */
+ const isSkillFolderDisabled = useCallback(
+ (folderName: string): boolean => {
+ if (!config) return false;
+ return config.disabled_skill_folders.includes(folderName);
+ },
+ [config]
+ );
+
+ return {
+ isVisible,
+ isBlocked,
+ isAllowed,
+ isCredentialCategoryDisabled,
+ isSkillFolderDisabled,
+ };
};
diff --git a/server/config/node_allowlist.json b/server/config/node_allowlist.json
index e7b67ebd..3d071885 100644
--- a/server/config/node_allowlist.json
+++ b/server/config/node_allowlist.json
@@ -37,5 +37,8 @@
"disabled_credential_categories": [
"android",
"email"
+ ],
+ "disabled_skill_folders": [
+ "android_agent"
]
}
diff --git a/server/services/node_allowlist.py b/server/services/node_allowlist.py
index 743cea41..faf4b31b 100644
--- a/server/services/node_allowlist.py
+++ b/server/services/node_allowlist.py
@@ -55,6 +55,16 @@ class NodeAllowlistService:
semantically — the same conceptual entity (android
feature surface) but the credential catalogue uses its
own category taxonomy independent of node groups.
+ disabled_skill_folders: list[str]
+ Absolute blocklist for the Master Skill folder
+ dropdown — every entry hides the matching subfolder
+ under server/skills/. Use when disabling a feature
+ that also ships its own skill folder (e.g.
+ 'android_agent' so users can't see the 12 android-
+ tied skills when android nodes are disabled).
+ Email has no dedicated skill folder (email-tied skills
+ live under productivity_agent mixed with Google
+ Workspace) so no email entry is needed.
"""
defaults = {
"show_all": True,
@@ -62,6 +72,7 @@ class NodeAllowlistService:
"disabled_groups": [],
"disabled_nodes": [],
"disabled_credential_categories": [],
+ "disabled_skill_folders": [],
}
if not self._config_path.exists():
@@ -88,6 +99,7 @@ class NodeAllowlistService:
disabled_groups = _str_list("disabled_groups")
disabled_nodes = _str_list("disabled_nodes")
disabled_credential_categories = _str_list("disabled_credential_categories")
+ disabled_skill_folders = _str_list("disabled_skill_folders")
show_all = len(enabled_nodes) == 0
@@ -97,6 +109,7 @@ class NodeAllowlistService:
"disabled_groups": disabled_groups,
"disabled_nodes": disabled_nodes,
"disabled_credential_categories": disabled_credential_categories,
+ "disabled_skill_folders": disabled_skill_folders,
}