Comprehensive guide to managing model configuration settings in the View platform.
Overview
Model Configurations manage AI model settings and parameters within the View platform. They provide centralized configuration for AI model behavior, including embeddings generation, text completion, context management, and performance tuning, enabling precise control over AI model operations and optimization.
Model Configurations are managed via the View server API and provide comprehensive settings for model parameters, including context size, temperature, token limits, streaming capabilities, and additional metadata for optimal AI model performance and behavior.
Model Configuration Object Structure
Model Configuration objects contain comprehensive settings for AI model behavior. Here's the complete structure:
{
"GUID": "00000000-0000-0000-0000-000000000000",
"TenantGUID": "00000000-0000-0000-0000-000000000000",
"ModelName": "all-minilm",
"Embeddings": true,
"Completions": false,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.2,
"TopP": 1,
"TopK": 40,
"FrequencyPenalty": 0,
"PresencePenalty": 0,
"EnableStreaming": true,
"TimeoutMs": 30000,
"AdditionalData": "Description for all-minilm",
"Active": true,
"CreatedUtc": "2025-10-08T19:39:59.160283Z"
}
Field Descriptions
- GUID (GUID): Globally unique identifier for the model configuration object
- TenantGUID (GUID): Globally unique identifier for the tenant
- ModelName (string): Name of the AI model this configuration applies to
- Embeddings (boolean): Whether this model supports embeddings generation
- Completions (boolean): Whether this model supports text completion
- ContextSize (integer): Maximum context window size in tokens
- MaxOutputTokens (integer): Maximum number of tokens to generate in completions
- Temperature (decimal): Sampling temperature for text generation (0.0 to 2.0)
- TopP (decimal): Nucleus sampling parameter (0.0 to 1.0)
- TopK (integer): Top-k sampling parameter for token selection
- FrequencyPenalty (decimal): Frequency penalty for reducing repetition (-2.0 to 2.0)
- PresencePenalty (decimal): Presence penalty for encouraging diversity (-2.0 to 2.0)
- EnableStreaming (boolean): Whether to enable streaming responses
- TimeoutMs (integer): Request timeout in milliseconds
- AdditionalData (string): Additional metadata or description for the configuration
- Active (boolean): Whether the configuration is currently active and available
- CreatedUtc (datetime): Timestamp when the configuration was created
Enumerate Model Configurations
Retrieves all model configurations for a tenant using GET /v2.0/tenants/[tenant-guid]/modelconfigs
. Returns a JSON array containing all model configuration settings.
Request Parameters
No additional parameters required beyond authentication.
Response
Returns an array of all model configurations for the tenant, or a 404 Not Found error if no configurations exist.
curl --location 'http://localhost:8000/v2.0/tenants/00000000-0000-0000-0000-000000000000/modelconfigs/' \
--header 'Authorization: ••••••'
import { ViewSdk } from "view-sdk";
const api = new ViewSdk(
"[endpoint-url]", //endpoint
"[tenant-guid]", //tenant Id
"[access-key]" //access key
);
const enumerateModelConfigs = async () => {
try {
const response = await api.ModelConfig.enumerate();
console.log(response, 'Model configs fetched successfully');
} catch (err) {
console.log('Error fetching Model configs:', err);
}
};
enumerateModelConfigurations();
import view_sdk
from view_sdk import configuration
from view_sdk.sdk_configuration import Service
sdk = view_sdk.configure(
access_key="default",
base_url="endpoint-url",
tenant_guid="tenant-guid",
service_ports={Service.DEFAULT: 8000},
)
def enumerateModelConfigurations():
"""Enumerate all model configurations."""
model_configs = configuration.ModelConfiguration.enumerate()
print("Enumerated ModelConfigurations:")
print(model_configs)
enumerateModelConfigurations()
Response
Returns an array of all model configurations:
{
"Success": true,
"Timestamp": {
"Start": "2025-10-09T09:33:51.807075Z",
"TotalMs": 5.73,
"Messages": {}
},
"MaxResults": 1000,
"Skip": 0,
"IterationsRequired": 1,
"EndOfResults": true,
"TotalRecords": 2,
"RecordsRemaining": 0,
"Objects": [
{
"GUID": "00000000-0000-0000-0000-000000000001",
"TenantGUID": "00000000-0000-0000-0000-000000000000",
"ModelName": "qwen2.5:3b",
"Embeddings": false,
"Completions": true,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.2,
"TopP": 1,
"TopK": 40,
"FrequencyPenalty": 0,
"PresencePenalty": 0,
"EnableStreaming": true,
"TimeoutMs": 30000,
"AdditionalData": "Description for qwen2.5:3b",
"Active": true,
"CreatedUtc": "2025-10-08T19:39:59.160283Z"
},
{
"GUID": "00000000-0000-0000-0000-000000000000",
"TenantGUID": "00000000-0000-0000-0000-000000000000",
"ModelName": "all-minilm",
"Embeddings": true,
"Completions": false,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.2,
"TopP": 1,
"TopK": 40,
"FrequencyPenalty": 0,
"PresencePenalty": 0,
"EnableStreaming": true,
"TimeoutMs": 30000,
"AdditionalData": "Description for all-minilm",
"Active": true,
"CreatedUtc": "2025-10-08T19:39:59.160283Z"
}
]
}
Read All Model Configurations
Retrieves all model configurations for a tenant using GET /v1.0/tenants/[tenant-guid]/modelconfigs
. Returns a JSON array containing all model configuration settings with complete details.
curl --location 'http://localhost8000/v1.0/tenants/00000000-0000-0000-0000-000000000000/modelconfigs/' \
--header 'Authorization: ••••••'
import { ViewSdk } from "view-sdk";
const api = new ViewSdk(
"[endpoint-url]", //endpoint
"[tenant-guid]", //tenant Id
"[access-key]" //access key
);
const readAllModelConfigs = async () => {
try {
const response = await api.ModelConfig.readAll();
console.log(response, 'All model configs fetched successfully');
} catch (err) {
console.log('Error fetching All model configs:', err);
}
};
readAllModelConfigs();
import view_sdk
from view_sdk import configuration
from view_sdk.sdk_configuration import Service
sdk = view_sdk.configure(
access_key="default",
base_url="endpoint-url",
tenant_guid="tenant-guid",
service_ports={Service.DEFAULT: 8000},
)
def retrieveAllModelConfigurations():
"""Retrieve all model configurations."""
model_configs = configuration.ModelConfiguration.retrieve_all()
print("All ModelConfigurations:")
print(model_configs)
retrieveAllModelConfigurations()
Response
Returns an array of all model configurations with complete details:
[
{
"GUID": "00000000-0000-0000-0000-000000000000",
"TenantGUID": "00000000-0000-0000-0000-000000000000",
"ModelName": "all-minilm",
"Embeddings": true,
"Completions": false,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.2,
"TopP": 1,
"TopK": 40,
"FrequencyPenalty": 0,
"PresencePenalty": 0,
"EnableStreaming": true,
"TimeoutMs": 30000,
"AdditionalData": "Description for all-minilm",
"Active": true,
"CreatedUtc": "2025-10-08T19:39:59.160283Z"
},
{
"GUID": "11111111-1111-1111-1111-111111111111",
"TenantGUID": "00000000-0000-0000-0000-000000000000",
"ModelName": "gpt-4",
"Embeddings": false,
"Completions": true,
"ContextSize": 8192,
"MaxOutputTokens": 4096,
"Temperature": 0.7,
"TopP": 0.9,
"TopK": 50,
"FrequencyPenalty": 0.1,
"PresencePenalty": 0.1,
"EnableStreaming": true,
"TimeoutMs": 60000,
"AdditionalData": "GPT-4 model configuration",
"Active": true,
"CreatedUtc": "2025-10-08T20:15:30.123456Z"
}
]
Read Model Configuration
Retrieves a specific model configuration by GUID using GET /v1.0/tenants/[tenant-guid]/modelconfigs/[modelconfig-guid]
. Returns the complete configuration settings with all details.
Request Parameters
- modelconfig-guid (string, Path, Required): GUID of the model configuration to retrieve
Response
Returns the model configuration object with all settings details if found, or a 404 Not Found error if the configuration doesn't exist.
Note: The HEAD
method can be used as an alternative to simply check the existence of the object. HEAD requests return either a 200 OK if the object exists, or a 404 Not Found if not. No response body is returned with a HEAD request.
curl --location 'http://localhost:8000/v1.0/tenants/00000000-0000-0000-0000-000000000000/modelconfigs/00000000-0000-0000-0000-000000000000' \
--header 'Authorization: ••••••'
import { ViewSdk } from "view-sdk";
const api = new ViewSdk(
"[endpoint-url]", //endpoint
"[tenant-guid]", //tenant Id
"[access-key]" //access key
);
const readModelConfig = async () => {
try {
const response = await api.ModelConfig.read('00000000-0000-0000-0000-000000000000');
console.log(response, 'Model config fetched successfully');
} catch (err) {
console.log('Error fetching Model config:', err);
}
};
readModelConfig();
import view_sdk
from view_sdk import configuration
from view_sdk.sdk_configuration import Service
sdk = view_sdk.configure(
access_key="default",
base_url="endpoint-url",
tenant_guid="tenant-guid",
service_ports={Service.DEFAULT: 8000},
)
def readModelConfiguration():
"""Retrieve a specific model configuration by GUID."""
model_config = configuration.ModelConfiguration.retrieve(
"modelconfig-guid"
)
print("Retrieved ModelConfiguration:")
print(model_config)
readModelConfiguration()
Response
Returns the complete model configuration with settings details:
{
"GUID": "00000000-0000-0000-0000-000000000000",
"TenantGUID": "00000000-0000-0000-0000-000000000000",
"ModelName": "all-minilm",
"Embeddings": true,
"Completions": false,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.2,
"TopP": 1,
"TopK": 40,
"FrequencyPenalty": 0,
"PresencePenalty": 0,
"EnableStreaming": true,
"TimeoutMs": 30000,
"AdditionalData": "Description for all-minilm",
"Active": true,
"CreatedUtc": "2025-10-08T19:39:59.160283Z"
}
Create Model Configuration
Creates a new model configuration using PUT /v1.0/tenants/[tenant-guid]/modelconfigs
. Creates a new configuration with the specified parameters.
Request Parameters
- ModelName (string, Required): Name of the AI model
- Embeddings (boolean, Required): Whether this model supports embeddings generation
- Completions (boolean, Required): Whether this model supports text completion
- ContextSize (integer, Optional): Maximum context window size in tokens (default: 4096)
- MaxOutputTokens (integer, Optional): Maximum number of tokens to generate (default: 2048)
- Temperature (decimal, Optional): Sampling temperature (default: 0.7)
- TopP (decimal, Optional): Nucleus sampling parameter (default: 1.0)
- TopK (integer, Optional): Top-k sampling parameter (default: 40)
- FrequencyPenalty (decimal, Optional): Frequency penalty (default: 0)
- PresencePenalty (decimal, Optional): Presence penalty (default: 0)
- EnableStreaming (boolean, Optional): Whether to enable streaming (default: true)
- TimeoutMs (integer, Optional): Request timeout in milliseconds (default: 30000)
- AdditionalData (string, Optional): Additional metadata or description
- Active (boolean, Optional): Whether the configuration is active (default: true)
Request Body
{
"ModelName": "owner/modelname",
"Embeddings": false,
"Completions": true,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.2,
"TopP": 1.0,
"TopK": 40,
"FrequencyPenalty": 0.0,
"PresencePenalty": 0.0,
"EnableStreaming": true,
"TimeoutMs": 30000,
"AdditionalData": "My open text field",
"Active": true
}
Response
Returns the created model configuration object with all settings details, or a 400 Bad Request error if the request is invalid.
curl --location --request PUT 'http://view.homedns.org:8000/v1.0/tenants/00000000-0000-0000-0000-000000000000/modelconfigs/00000000-0000-0000-0000-000000000000' \
--header 'content-type: application/json' \
--header 'Authorization: ••••••' \
--data '{
"ModelName": "owner/modelname",
"Embeddings": false,
"Completions": true,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.2,
"TopP": 1.0,
"TopK": 40,
"FrequencyPenalty": 0.0,
"PresencePenalty": 0.0,
"EnableStreaming": true,
"TimeoutMs": 30000,
"AdditionalData": "My open text field",
"Active": true
}'
import { ViewSdk } from "view-sdk";
const api = new ViewSdk(
"[endpoint-url]", //endpoint
"[tenant-guid]", //tenant Id
"[access-key]" //access key
);
const createModelConfig = async () => {
try {
const response = await api.ModelConfig.create({
ModelName: 'all-minilm',
Embeddings: true,
Completions: false,
ContextSize: 4096,
MaxOutputTokens: 2048,
Temperature: 0.2,
TopP: 1,
TopK: 40,
FrequencyPenalty: 0,
PresencePenalty: 0,
EnableStreaming: true,
TimeoutMs: 30000,
AdditionalData: 'Description for all-minilm',
Active: true,
});
console.log(response, 'Model config created successfully');
} catch (err) {
console.log('Error creating Model config:', err);
}
};
createModelConfig();
import view_sdk
from view_sdk import configuration
from view_sdk.sdk_configuration import Service
sdk = view_sdk.configure(
access_key="default",
base_url="endpoint-url",
tenant_guid="tenant-guid",
service_ports={Service.DEFAULT: 8000},
)
def createModelConfiguration():
"""Create a new model configuration."""
model_config = configuration.ModelConfiguration.create(
ModelName="llama2:7b",
Embeddings=True,
Completions=True,
ContextSize=4096,
MaxOutputTokens=2048,
Temperature=0.7,
TopP=0.9,
TopK=40,
FrequencyPenalty=0.0,
PresencePenalty=0.0,
EnableStreaming=True,
TimeoutMs=30000,
AdditionalData="Demo model configuration for testing",
Active=True
)
print("Created ModelConfiguration:")
print(model_config)
return model_config
createModelConfiguration()
Response
Returns the created model configuration with complete settings:
{
"GUID": "22222222-2222-2222-2222-222222222222",
"TenantGUID": "00000000-0000-0000-0000-000000000000",
"ModelName": "llama-2-7b",
"Embeddings": false,
"Completions": true,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.8,
"TopP": 0.9,
"TopK": 50,
"FrequencyPenalty": 0.1,
"PresencePenalty": 0.1,
"EnableStreaming": true,
"TimeoutMs": 45000,
"AdditionalData": "Llama 2 7B model configuration",
"Active": true,
"CreatedUtc": "2025-10-08T21:30:45.789012Z"
}
Update Model Configuration
Updates an existing model configuration using PUT /v1.0/tenants/[tenant-guid]/modelconfigs/[modelconfig-guid]
. Modifies the configuration settings with the provided parameters.
Request Parameters
- modelconfig-guid (string, Path, Required): GUID of the model configuration to update
Request Body
{
"ModelName": "llama-2-7b-updated",
"Embeddings": false,
"Completions": true,
"ContextSize": 8192,
"MaxOutputTokens": 4096,
"Temperature": 0.9,
"TopP": 0.95,
"TopK": 60,
"FrequencyPenalty": 0.2,
"PresencePenalty": 0.2,
"EnableStreaming": true,
"TimeoutMs": 60000,
"AdditionalData": "Updated Llama 2 7B model configuration",
"Active": true
}
Response
Returns the updated model configuration object with all settings details, or a 404 Not Found error if the configuration doesn't exist.
curl --location --request PUT 'http://localhost:8000/v1.0/tenants/00000000-0000-0000-0000-000000000000/modelconfigs/00000000-0000-0000-0000-000000000000' \
--header 'content-type: application/json' \
--header 'Authorization: ••••••' \
--data '{
"ModelName": "owner/modelname",
"Embeddings": false,
"Completions": true,
"ContextSize": 4096,
"MaxOutputTokens": 2048,
"Temperature": 0.2,
"TopP": 1.0,
"TopK": 40,
"FrequencyPenalty": 0.0,
"PresencePenalty": 0.0,
"EnableStreaming": true,
"TimeoutMs": 30000,
"AdditionalData": "My open text field",
"Active": true
}'
import { ViewSdk } from "view-sdk";
const api = new ViewSdk(
"[endpoint-url]", //endpoint
"[tenant-guid]", //tenant Id
"[access-key]" //access key
);
const updateModelConfig = async () => {
try {
const response = await api.ModelConfig.update({
GUID: 'b6fcf520-b712-4e61-b2c4-6cebbafd39f6',
TenantGUID: '00000000-0000-0000-0000-000000000000',
ModelName: 'all-minilm [UPDATED]',
Embeddings: true,
Completions: false,
ContextSize: 4096,
MaxOutputTokens: 2048,
Temperature: 0.2,
TopP: 1,
TopK: 40,
FrequencyPenalty: 0,
PresencePenalty: 0,
EnableStreaming: true,
TimeoutMs: 30000,
AdditionalData: 'Updated description for all-minilm',
Active: true,
CreatedUtc: '2025-10-08T19:39:59.160283Z',
});
console.log(response, 'Model config updated successfully');
} catch (err) {
console.log('Error updating Model config:', err);
}
};
updateModelConfig();
import view_sdk
from view_sdk import configuration
from view_sdk.sdk_configuration import Service
sdk = view_sdk.configure(
access_key="default",
base_url="endpoint-url",
tenant_guid="tenant-guid",
service_ports={Service.DEFAULT: 8000},
)
def updateModelConfiguration():
"""Update an existing model configuration."""
model_config = configuration.ModelConfiguration.update(
"modelconfig-guid",
ModelName="llama2:13b",
Temperature=0.8,
MaxOutputTokens=4096,
AdditionalData="Updated model configuration for testing"
)
print("Updated ModelConfiguration:")
print(model_config)
updateModelConfiguration()
Response
Returns the updated model configuration with complete settings:
{
"GUID": "00000000-0000-0000-0000-000000000000",
"TenantGUID": "00000000-0000-0000-0000-000000000000",
"ModelName": "llama-2-7b-updated",
"Embeddings": false,
"Completions": true,
"ContextSize": 8192,
"MaxOutputTokens": 4096,
"Temperature": 0.9,
"TopP": 0.95,
"TopK": 60,
"FrequencyPenalty": 0.2,
"PresencePenalty": 0.2,
"EnableStreaming": true,
"TimeoutMs": 60000,
"AdditionalData": "Updated Llama 2 7B model configuration",
"Active": true,
"CreatedUtc": "2025-10-08T19:39:59.160283Z"
}
Check Model Configuration Existence
Checks whether a model configuration exists using HEAD /v1.0/tenants/[tenant-guid]/modelconfigs/[modelconfig-guid]
. Returns only HTTP status codes without response body for efficient existence verification.
Request Parameters
- modelconfig-guid (string, Path, Required): GUID of the model configuration to check
Response
- 200 OK: Model configuration exists
- 404 Not Found: Model configuration does not exist
- No response body: Only HTTP status code is returned
Note: HEAD requests do not return a response body, only the HTTP status code indicating whether the model configuration exists.
curl --location --head 'http://localhost:8000/v1.0/tenants/00000000-0000-0000-0000-000000000000/modelconfigs/00000000-0000-0000-0000-000000000000' \
--header 'Authorization: ••••••'
import { ViewSdk } from "view-sdk";
const api = new ViewSdk(
"[endpoint-url]", //endpoint
"[tenant-guid]", //tenant Id
"[access-key]" //access key
);
const modelConfigExists = async () => {
try {
const response = await api.ModelConfig.exists('00000000-0000-0000-0000-000000000000');
console.log(response, 'Model config exists');
} catch (err) {
console.log('Error checking Model config:', err);
}
};
modelConfigExists();
import view_sdk
from view_sdk import configuration
from view_sdk.sdk_configuration import Service
sdk = view_sdk.configure(
access_key="default",
base_url="endpoint-url",
tenant_guid="tenant-guid",
service_ports={Service.DEFAULT: 8000},
)
def existsModelConfiguration():
"""Check if a model configuration exists."""
exists = configuration.ModelConfiguration.exists(
"modelconfi-guid"
)
print("ModelConfiguration exists:")
print(exists)
existsModelConfiguration()
Response
- 200 No Content: Model configuration exists
- 404 Not Found: Model configuration does not exist
- No response body: Only HTTP status code is returned
Note: HEAD requests do not return a response body, only the HTTP status code indicating whether the model configuration exists.
Delete Model Configuration
Deletes a model configuration by GUID using DELETE /v1.0/tenants/[tenant-guid]/modelconfigs/[modelconfig-guid]
. Removes the configuration settings from the system.
Request Parameters
- modelconfig-guid (string, Path, Required): GUID of the model configuration to delete
Response
- 200 OK: Model configuration deleted successfully
- 404 Not Found: Model configuration does not exist
Note: Deleting a model configuration removes it from the system permanently. This action cannot be undone.
curl --location --request DELETE 'http://localhost:8000/v1.0/tenants/00000000-0000-0000-0000-000000000000/modelconfigs/00000000-0000-0000-0000-000000000000' \
--header 'Authorization: ••••••'
import { ViewSdk } from "view-sdk";
const api = new ViewSdk(
"[endpoint-url]", //endpoint
"[tenant-guid]", //tenant Id
"[access-key]" //access key
);
const deleteModelConfig = async () => {
try {
const response = await api.ModelConfig.delete('b6fcf520-b712-4e61-b2c4-6cebbafd39f6');
console.log(response, 'Model config deleted successfully');
} catch (err) {
console.log('Error deleting Model config:', err);
}
};
deleteModelConfiguration();
import view_sdk
from view_sdk import configuration
from view_sdk.sdk_configuration import Service
sdk = view_sdk.configure(
access_key="default",
base_url="endpoint-url",
tenant_guid="tenant-guid",
service_ports={Service.DEFAULT: 8000},
)
def deleteModelConfiguration():
"""Delete a model configuration."""
result = configuration.ModelConfiguration.delete(
"modelconfig-guid"
)
print("Deleted ModelConfiguration:")
print(result)
deleteModelConfiguration()
Response
Returns 204 No Content on successful deletion. No response body is returned.
Best Practices
When managing model configurations in the View platform, consider the following recommendations for optimal AI model performance, parameter tuning, and system maintenance:
- Parameter Tuning: Experiment with temperature, top-p, and penalty settings to optimize model output quality for your specific use case
- Context Management: Set appropriate context sizes based on your model's capabilities and memory constraints
- Token Limits: Configure max output tokens based on expected response lengths and model capabilities
- Streaming Configuration: Enable streaming for real-time applications and disable for batch processing
- Timeout Settings: Set appropriate timeouts based on model complexity and expected processing times
- Active Status: Monitor and manage active status to control which configurations are available for use
- Performance Testing: Regularly test different parameter combinations to find optimal settings for your workloads
- Documentation: Use AdditionalData field to document configuration purposes and use cases
Next Steps
After successfully managing model configurations, you can:
- AI Model Optimization: Use configured parameters to optimize AI model performance for specific tasks and use cases
- Parameter Experimentation: Test different parameter combinations to find optimal settings for your applications
- Performance Monitoring: Track configuration performance and adjust parameters based on usage patterns
- Model Selection: Use configurations to select appropriate models for different tasks (embeddings vs completions)
- Platform Integration: Integrate model configurations with other View platform services for comprehensive AI capabilities