CBExploreADFPredict
Python template · sinapsis_vowpal_wabbit.templates.cb_explore_adf_predict
Overview
Template to perform action predictions using the Vowpal Wabbit CB_Explore_ADF approach.
Attributes: actions (list[str]): List of available action identifiers or labels that the model can predict or explore. model_path (str): File system path to the trained Vowpal Wabbit model that will be used for making predictions. inference_only (bool): Flag to determine the operation mode. When True, the model operates in inference-only mode without updates or learning. Defaults to True. threshold (float): Minimum confidence or score threshold for predictions. Predictions below this threshold may be filtered or handled differently. Defaults to 0. top_k (int): Number of top-ranked predictions or actions to return or consider in the output. Defaults to 3.
Capabilities
Capabilities: not setInstallation
Install the published package using pip or uv.
pip install sinapsis-vowpal-wabbit==1.0.0uv pip install sinapsis-vowpal-wabbit==1.0.0uv add sinapsis-vowpal-wabbit==1.0.0Configuration
Effective fields from the inspector schema, including nested Pydantic model fields.
Number of top-ranked predictions or actions to return or consider in the output. Defaults to 3.
Optional
Default: 3
List of available action identifiers or labels that the model can predict or explore.
Required
Default: null
Optional
Default: null
Minimum confidence or score threshold for predictions. Predictions below this threshold may be filtered or handled differently. Defaults to 0.
Optional
Default: 0
File system path to the trained Vowpal Wabbit model that will be used for making predictions.
Required
Default: null
Optional
Default: ["i","me","my","myself","we","our","ours","ourselves","you","you're","your","yours","yourself","yourselves","he","him","his","himself","she","her","hers","herself","it","its","itself","they","them","their","theirs","themselves","what","which","who","whom","this","that","these","those","am","is","are","was","were","be","been","being","have","has","had","having","do","does","did","doing","a","an","the","and","but","if","or","because","as","until","while","of","at","by","for","with","about","against","between","into","through","during","before","after","above","below","to","from","up","down","in","out","on","off","over","under","again","further","then","once","here","there","when","where","why","how"]
Optional
Default: null
Flag to determine the operation mode. When True, the model operates in inference-only mode without updates or learning. Defaults to True.
Optional
Default: true
Flag indicating whether to remove stop words from text. Defaults to False.
Optional
Default: false
Optional
Default: "[^a-z0-9\\s]"
Workspace parameters specific to the CB explore-adf algorithm. Defaults to an empty CBExploreADFWorkspaceParams instance if not provided or if an empty dict is passed.
Optional
Default: null
Optional
Default: 0
Optional
Default: 0
Whether to suppress output. Defaults to False. Raises: ValueError: If exploration_value is inconsistent with exploration_method: - If method is "first" or "bag" but value is not an integer - If method is "epsilon" but… Read full field description
Whether to suppress output. Defaults to False. Raises: ValueError: If exploration_value is inconsistent with exploration_method: - If method is "first" or "bag" but value is not an integer - If method is "epsilon" but value is not a float or outside [0.0, 1.0] Properties: vw_exploration_string: Generates the corresponding Vowpal Wabbit command line arguments for the configured exploration method and value.
Optional
Default: false
Whether to use adaptive exploration. Defaults to True.
Optional
Default: true
Optional
Default: 2
Whether to use normalized weights. Defaults to True.
Optional
Default: true
Optional
Default: 24
Optional
Default: null
Optional
Default: []
The value parameter for the chosen exploration method. - For "first" and "bag": Must be an integer (e.g., number of actions to explore) - For "epsilon": Must be a float between 0.0 and 1.0 (exploration probability) - For "softmax": Must be a float (lambda/temperature parameter) Defaults to 0.2.
Optional
Default: 0.2
Optional
Default: []
The exploration strategy to use. Options are: - "first": Explores the first action - "epsilon": Epsilon-greedy exploration - "bag": Bagging/bootstrap exploration - "softmax": Softmax exploration with temperature parameter Defaults to "epsilon".
Optional
Default: "epsilon"
Optional
Default: []
Flag indicating whether to remove special characters from text. Defaults to True.
Optional
Default: true
Configuration example
Generated from documented defaults. Replace any placeholders and complete required nested settings before running.
templates:
- template_name: "CBExploreADFPredict"
class_name: "CBExploreADFPredict"
attributes:
top_k: 3
actions: "<required>"
threshold: 0
model_path: "<required>"
stop_words: {}
random_seed: null
inference_only: true
remove_stop_words: false
clean_text_pattern: "[^a-z0-9\\s]"
vw_workspace_params:
l1: 0
l2: 0
quiet: false
adaptive: true
ngram_size: 2
normalized: true
bit_precision: 24
learning_rate: null
ngram_namespaces: []
exploration_value: 0.2
cubic_interactions: []
exploration_method: "epsilon"
quadratic_interactions: []
remove_special_characters: true
Inheritance
sinapsis_vowpal_wabbit.templates.cb_explore_adf_base.CBExploreADFBaseEnvironment variables
Environment definitions belong to their canonical Python modules.
No directly related environment variables listed.