1 Star 0 Fork 0

Survivor_zzc / langchaingo

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
output_parsers.go 543 Bytes
一键复制 编辑 原始数据 按行查看 历史
Survivor_zzc 提交于 2023-10-24 15:15 . mark
package schema
// OutputParser is an interface for parsing the output of an LLM call.
type OutputParser[T any] interface {
// Parse parses the output of an LLM call.
Parse(text string) (T, error)
// ParseWithPrompt parses the output of an LLM call with the prompt used.
ParseWithPrompt(text string, prompt PromptValue) (T, error)
// GetFormatInstructions returns a string describing the format of the output.
GetFormatInstructions() string
// Type returns the string type key uniquely identifying this class of parser
Type() string
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/zzcadmin/langchaingo.git
git@gitee.com:zzcadmin/langchaingo.git
zzcadmin
langchaingo
langchaingo
v0.4.7

搜索帮助

344bd9b3 5694891 D2dac590 5694891