Add Langchain Agent wrapper with OpenAI Function / Self-ask agent support (#82)

* update Param() type hint in MVP

* update default embedding endpoint

* update Langchain agent wrapper

* update langchain agent
This commit is contained in:
Tuan Anh Nguyen Dang (Tadashi_Cin)
2023-11-20 16:26:08 +07:00
committed by GitHub
parent 0a3fc4b228
commit 8bb7ad91e0
9 changed files with 137 additions and 35 deletions

View File

@@ -1,12 +1,12 @@
from .base import AgentOutput
from ...base import Document
def get_plugin_response_content(output) -> str:
"""
Wrapper for AgentOutput content return
"""
if isinstance(output, AgentOutput):
return output.output
if isinstance(output, Document):
return output.text
else:
return str(output)