mirror of
https://github.com/hwchase17/langchain
synced 2024-11-06 03:20:49 +00:00
efbc03bda8
lots of kwargs! generation docs here: https://docs.nlpcloud.com/#generation This somewhat breaks the paradigm introduced in LLM base class as the stop sequence isn't a list, and should rightfully be introduced at the time of initialization of the class, along with the other kwargs that depend on its presence (e.g. remove_end_sequence, etc.) curious if you'd want to refactor LLM base class to take out stop as a specific named kwarg?
11 lines
252 B
Python
11 lines
252 B
Python
"""Test NLPCloud API wrapper."""
|
|
|
|
from langchain.llms.nlpcloud import NLPCloud
|
|
|
|
|
|
def test_nlpcloud_call() -> None:
|
|
"""Test valid call to nlpcloud."""
|
|
llm = NLPCloud(max_length=10)
|
|
output = llm("Say foo:")
|
|
assert isinstance(output, str)
|