feat: add SkillAutocomplete component and integrate skill selection in ChatInput

This commit is contained in:
Bohdan Triapitsyn
2026-01-08 19:58:31 +02:00
parent b9ed2217a6
commit a2f2d91a22
5 changed files with 251 additions and 12 deletions
+9 -1
View File
@@ -62,6 +62,7 @@ export interface DiscoveredSkill {
path: string;
scope: SkillScope;
source: SkillSource;
description?: string;
}
export interface SkillConfig {
@@ -154,7 +155,14 @@ export const useSkillsStore = create<SkillsStore>()(
}
const data = await response.json();
const skills = (data.skills || []) as DiscoveredSkill[];
const rawSkills = data.skills || [];
const skills = rawSkills.map((s: any) => ({
name: s.name,
path: s.path,
scope: s.scope,
source: s.source,
description: s.sources?.md?.description || '',
})) as DiscoveredSkill[];
set({ skills, isLoading: false });
return true;