diff --git a/src/locales/en/main.json b/src/locales/en/main.json index 6e2504388..07e37f7da 100644 --- a/src/locales/en/main.json +++ b/src/locales/en/main.json @@ -577,6 +577,7 @@ "Area Composition": "Area Composition", "3D": "3D", "Audio": "Audio", + "LLMs": "LLMs", "Image API": "Image API", "Video API": "Video API", "LLM API": "LLM API", diff --git a/src/stores/workflowTemplatesStore.ts b/src/stores/workflowTemplatesStore.ts index 059354979..2fdca0a31 100644 --- a/src/stores/workflowTemplatesStore.ts +++ b/src/stores/workflowTemplatesStore.ts @@ -303,6 +303,11 @@ export const useWorkflowTemplatesStore = defineStore( (t) => t.categoryType === 'audio' && !t.isAPI ) + case 'generation-llm': + return enhancedTemplates.value.filter( + (t) => t.tags?.includes('LLM') || t.tags?.includes('Chat') + ) + case 'api-nodes': return enhancedTemplates.value.filter((t) => t.isAPI) @@ -354,6 +359,9 @@ export const useWorkflowTemplatesStore = defineStore( const audioCounts = enhancedTemplates.value.filter( (t) => t.categoryType === 'audio' && !t.isAPI ).length + const llmCounts = enhancedTemplates.value.filter( + (t) => t.tags?.includes('LLM') || t.tags?.includes('Chat') + ).length const threeDCounts = enhancedTemplates.value.filter( (t) => t.categoryType === '3d' && !t.isAPI ).length @@ -404,7 +412,8 @@ export const useWorkflowTemplatesStore = defineStore( imageCounts > 0 || videoCounts > 0 || threeDCounts > 0 || - audioCounts > 0 + audioCounts > 0 || + llmCounts > 0 ) { const generationTypeItems: NavItemData[] = [] @@ -440,6 +449,14 @@ export const useWorkflowTemplatesStore = defineStore( }) } + if (llmCounts > 0) { + generationTypeItems.push({ + id: 'generation-llm', + label: st('templateWorkflows.category.LLMs', 'LLMs'), + icon: getCategoryIcon('generation-llm') + }) + } + items.push({ title: st( 'templateWorkflows.category.GenerationType', diff --git a/src/utils/categoryIcons.ts b/src/utils/categoryIcons.ts index 6d81a403b..223381bca 100644 --- a/src/utils/categoryIcons.ts +++ b/src/utils/categoryIcons.ts @@ -16,6 +16,7 @@ export const getCategoryIcon = (categoryId: string): string => { '3d': 'box', 'generation-audio': 'volume-2', audio: 'volume-2', + 'generation-llm': 'message-square-text', // API and models 'api-nodes': 'hand-coins', @@ -24,6 +25,7 @@ export const getCategoryIcon = (categoryId: string): string => { // LLMs and AI llm: 'message-square-text', llms: 'message-square-text', + 'llm-api': 'message-square-text', // Performance and hardware 'small-models': 'zap',