Add replicate take 2 (#2077)

This PR adds a replicate integration to langchain. 

It's an updated version of
https://github.com/hwchase17/langchain/pull/1993, but with updates to
match latest replicate-python code.
https://github.com/replicate/replicate-python.

---------

Co-authored-by: Harrison Chase <hw.chase.17@gmail.com>
Co-authored-by: Zeke Sikelianos <zeke@sikelianos.com>
This commit is contained in:
Charlie Holtz
2023-03-28 11:56:57 -07:00
committed by GitHub
parent a9e1043673
commit f16c1fb6df
5 changed files with 520 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
"""Test Replicate API wrapper."""
from langchain.llms.replicate import Replicate
def test_replicate_call() -> None:
"""Test valid call to Replicate."""
llm = Replicate()
output = llm("Say foo:")
assert isinstance(output, str)