πŸ“„ SimpleΒΆ

templates.language_identification.simple

InputOutputTemplate(
    instruction="You are given a text. In what language is this text written?",
    input_format="Text: {text}",
    output_format="{label}",
    target_prefix="The text is in ",
    postprocessors=[
        "processors.take_first_word",
    ],
)
[source]

Explanation about InputOutputTemplateΒΆ

Generate field β€˜source’ from fields designated as input, and fields β€˜target’ and β€˜references’ from fields designated as output, of the processed instance.

Args specify the formatting strings with which to glue together the input and reference fields of the processed instance into one string (β€˜source’ and β€˜target’), and into a list of strings (β€˜references’).

References: processors.take_first_word

Read more about catalog usage here.