mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-01-24 11:16:12 +01:00
feat: add groupIcon property to modelSpecs for custom group icons
Added the ability to define icons for custom model spec groups in the UI selector. Changes: - Added property to TModelSpec type and schema in data-provider - Created GroupIcon component to render URL or built-in endpoint icons - Updated CustomGroup component to display group icons - Added documentation and examples in librechat.example.yaml Usage: The groupIcon can be: - A built-in endpoint key (e.g., "openAI", "anthropic", "groq") - A URL to a custom icon image Only the first spec in a group needs groupIcon - all specs share the same icon.
This commit is contained in:
parent
8bdc808074
commit
308347a7ad
4 changed files with 102 additions and 8 deletions
|
|
@ -339,6 +339,10 @@ endpoints:
|
|||
# - If 'group' matches an endpoint name (e.g., "openAI", "groq"), the spec appears nested under that endpoint
|
||||
# - If 'group' is a custom name (doesn't match any endpoint), it creates a separate collapsible section
|
||||
# - If 'group' is omitted, the spec appears as a standalone item at the top level
|
||||
#
|
||||
# The 'groupIcon' field sets an icon for custom groups:
|
||||
# - Only needs to be set on one spec per group (first one is used)
|
||||
# - Can be a URL or a built-in endpoint key (e.g., "openAI", "anthropic", "groq")
|
||||
# modelSpecs:
|
||||
# list:
|
||||
# # Example 1: Nested under an endpoint (grouped with openAI endpoint)
|
||||
|
|
@ -359,11 +363,12 @@ endpoints:
|
|||
# endpoint: "groq"
|
||||
# model: "llama3-70b-8192"
|
||||
#
|
||||
# # Example 3: Custom group (creates a separate collapsible section)
|
||||
# # Example 3: Custom group with icon (creates a separate collapsible section)
|
||||
# - name: "coding-assistant"
|
||||
# label: "Coding Assistant"
|
||||
# description: "Specialized for coding tasks"
|
||||
# group: "my-assistants" # Custom string - doesn't match any endpoint, so creates its own group
|
||||
# groupIcon: "https://example.com/icons/assistants.png" # Icon URL for the group
|
||||
# preset:
|
||||
# endpoint: "openAI"
|
||||
# model: "gpt-4o"
|
||||
|
|
@ -374,12 +379,22 @@ endpoints:
|
|||
# label: "Writing Assistant"
|
||||
# description: "Specialized for creative writing"
|
||||
# group: "my-assistants" # Same custom group name - both specs appear in same section
|
||||
# # No need to set groupIcon again - the first spec's icon is used
|
||||
# preset:
|
||||
# endpoint: "anthropic"
|
||||
# model: "claude-sonnet-4"
|
||||
# instructions: "You are a creative writing expert..."
|
||||
#
|
||||
# # Example 4: Standalone (no group - appears at top level)
|
||||
# # Example 4: Custom group using built-in icon key
|
||||
# - name: "fast-models"
|
||||
# label: "Fast Response Model"
|
||||
# group: "Fast Models"
|
||||
# groupIcon: "groq" # Uses the built-in Groq icon
|
||||
# preset:
|
||||
# endpoint: "groq"
|
||||
# model: "llama3-8b-8192"
|
||||
#
|
||||
# # Example 5: Standalone (no group - appears at top level)
|
||||
# - name: "general-assistant"
|
||||
# label: "General Assistant"
|
||||
# description: "General purpose assistant"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue