LibreChat/librechat.example.subfolder.yaml
constanttime 4fe600990c feat: Add subfolder support for model specs (#9165)
- Add optional `folder` field to TModelSpec type and schema
- Create ModelSpecFolder component for hierarchical display
- Implement expand/collapse functionality for folders
- Update search results to show folder context
- Sort folders alphabetically and specs by order/label
- Maintain backward compatibility (specs without folders appear at root)

This enhancement allows organizing model specs into categories/folders
for better organization and improved user experience when dealing with
many model configurations.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-24 23:37:53 +05:30

149 lines
No EOL
4.4 KiB
YAML

# Example configuration demonstrating model spec subfolder/category support
# This shows how to organize model specs into folders for better organization
version: 1.1.7
modelSpecs:
enforce: false
prioritize: true
list:
# OpenAI Models Category
- name: "gpt4_turbo"
label: "GPT-4 Turbo"
folder: "OpenAI Models" # This spec will appear under "OpenAI Models" folder
preset:
endpoint: "openAI"
model: "gpt-4-turbo-preview"
temperature: 0.7
description: "Latest GPT-4 Turbo model with enhanced capabilities"
iconURL: "openAI"
order: 1
- name: "gpt4_vision"
label: "GPT-4 Vision"
folder: "OpenAI Models" # Same folder as above
preset:
endpoint: "openAI"
model: "gpt-4-vision-preview"
temperature: 0.7
description: "GPT-4 with vision capabilities"
iconURL: "openAI"
order: 2
- name: "gpt35_turbo"
label: "GPT-3.5 Turbo"
folder: "OpenAI Models"
preset:
endpoint: "openAI"
model: "gpt-3.5-turbo"
temperature: 0.7
description: "Fast and efficient model for most tasks"
iconURL: "openAI"
order: 3
# Anthropic Models Category
- name: "claude3_opus"
label: "Claude 3 Opus"
folder: "Anthropic Models" # Different folder
preset:
endpoint: "anthropic"
model: "claude-3-opus-20240229"
temperature: 0.7
description: "Most capable Claude model"
iconURL: "anthropic"
order: 1
- name: "claude3_sonnet"
label: "Claude 3 Sonnet"
folder: "Anthropic Models"
preset:
endpoint: "anthropic"
model: "claude-3-sonnet-20240229"
temperature: 0.7
description: "Balanced performance and cost"
iconURL: "anthropic"
order: 2
- name: "claude3_haiku"
label: "Claude 3 Haiku"
folder: "Anthropic Models"
preset:
endpoint: "anthropic"
model: "claude-3-haiku-20240307"
temperature: 0.7
description: "Fast and affordable"
iconURL: "anthropic"
order: 3
# Specialized Models Category
- name: "code_assistant"
label: "Code Assistant"
folder: "Specialized Models"
preset:
endpoint: "openAI"
model: "gpt-4-turbo-preview"
temperature: 0.2
systemMessage: "You are an expert programmer. Provide clear, well-commented code solutions."
description: "Optimized for coding tasks"
iconURL: "openAI"
- name: "creative_writer"
label: "Creative Writer"
folder: "Specialized Models"
preset:
endpoint: "anthropic"
model: "claude-3-opus-20240229"
temperature: 0.9
systemMessage: "You are a creative writer. Generate engaging and imaginative content."
description: "For creative writing tasks"
iconURL: "anthropic"
- name: "research_analyst"
label: "Research Analyst"
folder: "Specialized Models"
preset:
endpoint: "openAI"
model: "gpt-4-turbo-preview"
temperature: 0.3
systemMessage: "You are a research analyst. Provide thorough, fact-based analysis."
description: "For research and analysis"
iconURL: "openAI"
# Models without folders (appear at root level)
- name: "quick_chat"
label: "Quick Chat"
preset:
endpoint: "openAI"
model: "gpt-3.5-turbo"
temperature: 0.7
description: "Fast general-purpose chat"
iconURL: "openAI"
default: true # This is the default model
- name: "advanced_reasoning"
label: "Advanced Reasoning"
preset:
endpoint: "anthropic"
model: "claude-3-opus-20240229"
temperature: 0.5
description: "For complex reasoning tasks"
iconURL: "anthropic"
# Interface configuration
interface:
endpointsMenu: false # Hide endpoints menu when using model specs
modelSelect: false # Hide traditional model selector
parameters: false # Hide parameter controls (using presets)
presets: false # Hide preset selector (using model specs)
# Endpoints configuration (required for the model specs to work)
endpoints:
openAI:
apiKey: "${OPENAI_API_KEY}"
models:
default: ["gpt-3.5-turbo", "gpt-4-turbo-preview", "gpt-4-vision-preview"]
anthropic:
apiKey: "${ANTHROPIC_API_KEY}"
models:
default: ["claude-3-opus-20240229", "claude-3-sonnet-20240229", "claude-3-haiku-20240307"]