Open TanGentleman opened 1 month ago
Here's the source code for the JsonOutputParser: https://api.python.langchain.com/en/latest/_modules/langchain_core/output_parsers/json.html#JsonOutputParser.parse
Seems like when I approach this, I'm going to want to keep the LangGraph philosophy and manage state very deliberately. Here's the starting point, and though I've dabbled a bit within notebooks, I want to follow the most current practices, since they've changed:
This whole thing may be better suited to a chain! I'll have to think about composing it in different ways a bit down the line. For now, I'm comfortable with this architecture, but I think I'll eventually be able to compose everything into a type-conforming ChainClass with a dict of inputs as single parameter.
Either way, I want to play around with constructing a Pydantic Schema, passing it to the JsonOutputParser, and having that work its magic during the flashcard generation. This plays beautifully with the new architecture I have for the control flow for the new flashrag UX, stay tuned!