get_template_variables#
- langchain_core.prompts.string.get_template_variables(template: str, template_format: str) List[str] [source]#
Get the variables from the template.
- Parameters:
template (str) β The template string.
template_format (str) β The template format. Should be one of βf-stringβ or βjinja2β.
- Returns:
The variables from the template.
- Raises:
ValueError β If the template format is not supported.
- Return type:
List[str]