mirror of
https://github.com/hwchase17/langchain.git
synced 2025-07-18 10:43:36 +00:00
docs: Update concepts.mdx (#26496)
- Fix comments in Python - Fix repeated sentences
This commit is contained in:
parent
9f5960a0aa
commit
bd42344b0a
@ -595,10 +595,10 @@ tool_call = ai_msg.tool_calls[0]
|
|||||||
# -> ToolCall(args={...}, id=..., ...)
|
# -> ToolCall(args={...}, id=..., ...)
|
||||||
tool_message = tool.invoke(tool_call)
|
tool_message = tool.invoke(tool_call)
|
||||||
# -> ToolMessage(
|
# -> ToolMessage(
|
||||||
content="tool result foobar...",
|
# content="tool result foobar...",
|
||||||
tool_call_id=...,
|
# tool_call_id=...,
|
||||||
name="tool_name"
|
# name="tool_name"
|
||||||
)
|
# )
|
||||||
```
|
```
|
||||||
|
|
||||||
If you are invoking the tool this way and want to include an [artifact](/docs/concepts/#toolmessage) for the ToolMessage, you will need to have the tool return two things.
|
If you are invoking the tool this way and want to include an [artifact](/docs/concepts/#toolmessage) for the ToolMessage, you will need to have the tool return two things.
|
||||||
@ -717,8 +717,6 @@ During run-time LangChain configures an appropriate callback manager (e.g., [Cal
|
|||||||
|
|
||||||
The `callbacks` property is available on most objects throughout the API (Models, Tools, Agents, etc.) in two different places:
|
The `callbacks` property is available on most objects throughout the API (Models, Tools, Agents, etc.) in two different places:
|
||||||
|
|
||||||
The callbacks are available on most objects throughout the API (Models, Tools, Agents, etc.) in two different places:
|
|
||||||
|
|
||||||
- **Request time callbacks**: Passed at the time of the request in addition to the input data.
|
- **Request time callbacks**: Passed at the time of the request in addition to the input data.
|
||||||
Available on all standard `Runnable` objects. These callbacks are INHERITED by all children
|
Available on all standard `Runnable` objects. These callbacks are INHERITED by all children
|
||||||
of the object they are defined on. For example, `chain.invoke({"number": 25}, {"callbacks": [handler]})`.
|
of the object they are defined on. For example, `chain.invoke({"number": 25}, {"callbacks": [handler]})`.
|
||||||
|
Loading…
Reference in New Issue
Block a user