Skip to content
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

Better input/output visibility in Langchain callback #7478

Merged
merged 5 commits into from
Oct 5, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,9 @@ def on_tool_start(
label=self._labeler.get_tool_label(self._last_tool, is_complete=False),
state="running",
)
if len(input_str) > MAX_TOOL_INPUT_STR_LENGTH:
# output is printed later in on_tool_end
self._container.markdown(f"**Input:**\n\n{input_str}\n\n**Output:**")
vdonato marked this conversation as resolved.
Show resolved Hide resolved

def on_tool_end(
self,
Expand Down