feat(models): add max concurrency setting for background tasks
Introduce a new `max_concurrency` parameter to the model configuration, allowing control over the maximum number of concurrent background tasks (ingestion/enrichment) per model. This feature is applicable to chat, embedding, and VLM models, with a value of 0 or undefined falling back to the global default. Update UI components and localization files to support this new setting, ensuring a seamless user experience.
This commit is contained in:
@@ -47,6 +47,7 @@ type ModelParametersDTO struct {
|
||||
ExtraConfig map[string]string `json:"extra_config,omitempty"`
|
||||
CustomHeaders map[string]string `json:"custom_headers,omitempty"`
|
||||
SupportsVision bool `json:"supports_vision"`
|
||||
MaxConcurrency int `json:"max_concurrency,omitempty"`
|
||||
AppID string `json:"app_id,omitempty"`
|
||||
}
|
||||
|
||||
@@ -67,6 +68,7 @@ func NewModelResponse(ctx context.Context, m *types.Model) *ModelResponse {
|
||||
ExtraConfig: m.Parameters.ExtraConfig,
|
||||
CustomHeaders: m.Parameters.CustomHeaders,
|
||||
SupportsVision: m.Parameters.SupportsVision,
|
||||
MaxConcurrency: m.Parameters.MaxConcurrency,
|
||||
AppID: m.Parameters.AppID,
|
||||
}
|
||||
if !CanViewIntegrationSecrets(ctx) {
|
||||
|
||||
Reference in New Issue
Block a user