enforce_stop_tokens#

langchain_cohere.llms.enforce_stop_tokens(text: str, stop: List[str]) str[source]#

Cut off the text as soon as any stop words occur.

Parameters:
  • text (str)

  • stop (List[str])

Return type:

str