Step 2: Remove MODEL_CONFIG and update get_model_config() to use IntegrationSettings only

- Remove MODEL_CONFIG dict with hardcoded defaults
- Update get_model_config() to require account parameter
- Remove default_config fallback
- Remove unused helper functions (get_model, get_max_tokens, get_temperature)
- Fix generate_images.py to pass account to get_model_config()
- Raise ValueError with clear messages when IntegrationSettings not configured
This commit is contained in:
IGNY8 VPS (Salman)
2025-11-16 09:17:17 +00:00
parent 60ffc12e8c
commit 6044fab57d
2 changed files with 73 additions and 96 deletions

View File

@@ -122,8 +122,10 @@ class GenerateImagesFunction(BaseAIFunction):
}
)
# Get model config
model_config = get_model_config('extract_image_prompts')
# Get model config (requires account)
if not account_obj:
raise ValueError("Account is required for model configuration")
model_config = get_model_config('extract_image_prompts', account=account_obj)
# Call AI to extract prompts using centralized request handler
result = ai_core.run_ai_request(