add links

This commit is contained in:
Eugene Yurtsev
2024-05-23 15:16:40 -04:00
parent aa3d7edf44
commit 5be142381d
2 changed files with 7 additions and 6 deletions

View File

@@ -559,10 +559,9 @@ callbacks to any child objects.
Any `RunnableLambda`, a `RunnableGenerator`, or `Tool` that invokes other runnables
and is running async in python<=3.10, will have to propagate callbacks to child
objects manually. This is because LangChain cannot automatically propagate
callbacks to child objects in this case.
This is a common reason why you may fail to see events being emitted from custom
runnables or tools.
callbacks to child objects in this case. If you see that callbacks
are not being triggered in your child objects, you may need to [manually
propagate runnable config to child runnables](/docs/how_to/runnables_propagate_config/).
:::
## Techniques

View File

@@ -12,6 +12,7 @@
"\n",
"- [Callbacks](/docs/concepts/#callbacks)\n",
"- [Custom callback handlers](/docs/how_to/custom_callbacks)\n",
"- [Custom callback handlers](/docs/how_to/propagate_runnable_config)\n",
":::\n",
"\n",
"If you are planning to use the async APIs, it is recommended to use and extend [`AsyncCallbackHandler`](https://api.python.langchain.com/en/latest/callbacks/langchain_core.callbacks.base.AsyncCallbackHandler.html) to avoid blocking the event.\n",
@@ -23,8 +24,9 @@
"\n",
":::{.callout-danger}\n",
"\n",
"If you're on `python<=3.10`, you need to remember to propagate `config` or `callbacks` when invoking other `runnable` from within a `RunnableLambda`, `RunnableGenerator` or `@tool`. If you do not do this,\n",
"the callbacks will not be propagated to the child runnables being invoked.\n",
"If you're on `python<=3.10`, you need to remember to propagate `config` or `callbacks` when invoking other `runnable` from within a `RunnableLambda`, `RunnableGenerator` or `@tool`. \n",
"\n",
"See this the guide on [how to propagate runnable config to child components](/docs/how_to/propagate_runnable_config) for more information.\n",
":::"
]
},