mirror of
https://github.com/hwchase17/langchain.git
synced 2025-06-24 15:43:54 +00:00
pipe default key (#11788)
This commit is contained in:
parent
6e78dacd78
commit
f3ad22e64a
@ -992,6 +992,7 @@ class RunnableSerializable(Serializable, Runnable[Input, Output]):
|
||||
def configurable_alternatives(
|
||||
self,
|
||||
which: ConfigurableField,
|
||||
default_key: str = "default",
|
||||
**kwargs: Runnable[Input, Output],
|
||||
) -> RunnableSerializable[Input, Output]:
|
||||
from langchain.schema.runnable.configurable import (
|
||||
@ -999,7 +1000,7 @@ class RunnableSerializable(Serializable, Runnable[Input, Output]):
|
||||
)
|
||||
|
||||
return RunnableConfigurableAlternatives(
|
||||
which=which, default=self, alternatives=kwargs
|
||||
which=which, default=self, alternatives=kwargs, default_key=default_key
|
||||
)
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user