Custom Model Configurations
Custom Model Configurations
Control Your AI Generation Parameters
Data Designer allows you to customize the AI models used for text generation through custom model configurations. This feature gives you precise control over model selection and generation parameters, enabling you to fine-tune the behavior of your AI-generated data.
Model Suites Overview
Data Designer offers different model suites with pre-configured model aliases:
Apache-2.0 Suite
Llama-3.x Suite
Basic Usage
To use custom model configurations, first define your model configs and then pass them when initializing your Data Designer instance:
Using Default Model Aliases
You can also use the pre-configured model aliases from your chosen model suite:
Model Configuration Components
ModelConfig Class
The ModelConfig
class takes the following parameters:
alias
: A unique identifier you'll use to reference this model configurationmodel_name
: The fully qualified model name (depends on your Gretel deployment)generation_parameters
: Controls how the model generates text
Generation Parameters
The GenerationParameters
class supports various parameters:
temperature
: Controls randomness in the outputHigher values (0.7-1.0) produce more creative, diverse outputs
Lower values (0.0-0.3) produce more deterministic, focused outputs
Fixed value:
temperature=0.75
Variable range:
temperature={"type": "uniform", "params": {"low": 0.50, "high": 0.90"}}
top_p
: Controls the diversity of word selectionAdditional parameters may be available depending on the model
Using Variable Parameters
You can define parameters with dynamic ranges for increased variety in your generated data:
This configuration will use a different temperature value for each record, sampled from a uniform distribution between 0.5 and 0.9.
Best Practices
Purpose-specific models: Create different model configurations for different types of content (factual vs. creative)
Parameter tuning: Start with default parameters and adjust based on your specific needs
Consistent naming: Use descriptive aliases that indicate the model's purpose
Testing: Preview your results with different configurations before large-scale generation
Reproducibility: Use fixed parameters when consistency is important
Variety: Use variable parameters when diversity is desired
License compliance: Choose model suites according to your organization's licensing requirements
Choosing Between Model Suites
Apache-2.0 suite: Provides specialized models for different tasks (text, code, judging)
Llama-3.x suite: Uses Meta's Llama 3.1 model via Amazon Bedrock for all tasks
When selecting a model suite, consider your specific needs:
Apache-2.0 suite offers task-specific models
Llama-3.x suite provides consistent behavior across tasks
Licensing requirements may dictate which suite you can use
Last updated
Was this helpful?