-
Notifications
You must be signed in to change notification settings - Fork 173
New issue
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’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't get chat playground_type to work #612
Comments
Can use this as a work-around for now: https://github.com/langchain-ai/langserve/blob/main/examples/chat_playground/server.py We'll need to investigate, but we likely doing some gymantics with input and output schema and in the process forgot to support the simplest case of just wrapping a chat model |
I'm having the same issue with the popup:
I don't quite understand what workaround was supposed to be used in the script example given. My chain is a LangGraph workflow that has a string as input and output. |
Even I am having the same issue I am trying it with a local Ollama model |
After looking at the FastAPI Swagger and playing with some Curl request, I realized what my specific issue was. The type expected for the add_routes(
app,
custom_chain.with_types(input_type=dict,output_type=str),
# custom_chain.with_types(input_type=str,output_type=str), # endpoint type change for default playground
path="/local_assistant",
playground_type="chat",
) |
I like the look of the newer chat playground_type, but I can't seem to get it work. When I try send a chat message the UI pops up the following error and the request (exported as curl below) looks malformed.
The error:
The malformed looking request:
Minimal app to reproduce the issue:
Full project for this app: langserve-test.zip
I'm using python 3.10 on macOS, latest stable release of each dependency.
The text was updated successfully, but these errors were encountered: