langchain/docs/modules/prompts/output_parsers
mwinterde 9c0cb90997
Resolve error in StructuredOutputParser docs (#5240)
# Resolve error in StructuredOutputParser docs

Documentation for `StructuredOutputParser` currently not reproducible,
that is, `output_parser.parse(output)` raises an error because the LLM
returns a response with an invalid format

```python
_input = prompt.format_prompt(question="what's the capital of france")
output = model(_input.to_string())

output

# ?
#
# ```json
# {
# 	"answer": "Paris",
# 	"source": "https://www.worldatlas.com/articles/what-is-the-capital-of-france.html"
# }
# ```
```

Was fixed by adding a question mark to the prompt
2023-05-25 07:47:25 -07:00
..
examples Resolve error in StructuredOutputParser docs (#5240) 2023-05-25 07:47:25 -07:00
getting_started.ipynb Fix docs for parse_with_prompt (#2986) 2023-04-16 12:57:04 -07:00
how_to_guides.rst big docs refactor (#1978) 2023-03-26 19:49:46 -07:00