tmc / langchaingo

LangChain for Go, the easiest way to write LLM-based programs in Go
https://tmc.github.io/langchaingo/
MIT License
5k stars 643 forks source link

outputparser: improve DefinedOutputParser #980

Closed amitaifrey closed 2 months ago

amitaifrey commented 3 months ago

The DefinedOutputParser prompted the LLM with a Typescript schema, but expected a json in response: https://github.com/tmc/langchaingo/blob/1975058648b5914fdd9dc53434c5b59f219e2b5c/outputparser/defined.go\#L65-69 Now it also requests a json.

PR Checklist