We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Langchain supports callbacks to be passed to the function invoking the LLM. Support passing these to Langchain.
This allows tools like Chainlit to display step by step outputs.
@cl.on_message async def on_message(message: cl.Message): runnable = cl.user_session.get("runnable") # type: Runnable msg = cl.Message(content="") async for chunk in runnable.astream( {"question": message.content}, config=RunnableConfig(callbacks=[cl.LangchainCallbackHandler()]), ): await msg.stream_token(chunk) await msg.send()
The text was updated successfully, but these errors were encountered:
Thank you for opening this issue, @ramnathv! We're looking into it. 馃専
If you're interested, we'd welcome your contribution on this. Feel free to ask for any guidance you need.
Happy coding! 馃殌
Sorry, something went wrong.
No branches or pull requests
馃殌 The feature
Langchain supports callbacks to be passed to the function invoking the LLM. Support passing these to Langchain.
Motivation, pitch
This allows tools like Chainlit to display step by step outputs.
The text was updated successfully, but these errors were encountered: