nemo_automodel.components.models.clm.prompting
nemo_automodel.components.models.clm.prompting
CLM prompt layout: how a SystemOne record becomes state texts and candidate texts.
This mirrors clm.schema from the contrastive-lm package (Apache-2.0) exactly, because the released CLM heads
were trained on this layout: the state head sees context + question, the action head sees each option’s own text.
Module Contents
Functions
Data
API
(option ids in CLM order, candidate text per option) for one question.
{question_id: (state_text, option_ids, candidate_texts)} for every question of a record.
Context first, question last: the layout CLM’s state head was trained on.
Load the tokenizer with the publisher’s CLM serving input contract.
Parameters:
Tokenizer repository ID or local directory.
Tokenizer revision recorded in the frozen-feature cache identity.
Returns: PreTrainedTokenizerBase
Tokenizer using right padding and left truncation, retaining the final
Render a JSON value as prose: objects become key: value lines, arrays become - item lines.