feat: Add support for builtin models in the application
- Introduced `is_builtin` property in the model configuration to identify builtin models. - Updated frontend components to display a tag for builtin models in the ModelSelector and ModelSettings. - Enhanced the ModelEditorDialog to prevent editing and deletion of builtin models. - Implemented logic in the backend to hide sensitive information for builtin models and restrict their modification. - Added informative UI elements to clarify the nature of builtin models in the settings and editor views.
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
-- 07-add-builtin-models.sql (rollback)
|
||||
-- Remove is_builtin field from models table
|
||||
|
||||
BEGIN;
|
||||
|
||||
-- Drop index
|
||||
DROP INDEX IF EXISTS idx_models_is_builtin;
|
||||
|
||||
-- Remove is_builtin column
|
||||
ALTER TABLE models
|
||||
DROP COLUMN IF EXISTS is_builtin;
|
||||
|
||||
COMMIT;
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
-- 07-add-builtin-models.sql
|
||||
-- Add is_builtin field to models table to support builtin models visible to all tenants
|
||||
|
||||
BEGIN;
|
||||
|
||||
-- Add is_builtin column to models table
|
||||
ALTER TABLE models
|
||||
ADD COLUMN IF NOT EXISTS is_builtin BOOLEAN NOT NULL DEFAULT false;
|
||||
|
||||
-- Add index for is_builtin field to improve query performance
|
||||
CREATE INDEX IF NOT EXISTS idx_models_is_builtin ON models(is_builtin);
|
||||
|
||||
COMMIT;
|
||||
|
||||
Reference in New Issue
Block a user