The agent engineering platform.
Python agentsaiai-agentsanthropicchatgptdeepagentsenterpriseframeworkgeminigenerative-ailangchainlanggraphllmmultiagentopen-sourceopenaipydanticpythonragtypescript
core: Assign missing message ids in BaseChatModel (#19863)
Nuno Campos2ae6dcdf0117
diff --git a/libs/core/langchain_core/language_models/chat_models.py b/libs/core/langchain_core/language_models/chat_models.pyindex 235b5d4b7b..daf6aeb3a7 100644--- a/libs/core/langchain_core/language_models/chat_models.py+++ b/libs/core/langchain_core/language_models/chat_models.py@@ -224,6 +224,8 @@ class BaseChatModel(BaseLanguageModel[BaseMessage], ABC):run_manager.on_llm_new_token(cast(str, chunk.message.content), chunk=chunk)+ if chunk.message.id is None:+ chunk.message.id = f"run-{run_manager.run_id}"chunk.message.response_metadata = _gen_info_and_msg_metadata(chunk)yield chunk.messageif generation is None:@@ -294,6 +296,8 @@ class BaseChatModel(BaseLanguageModel[BaseMessage], ABC):await run_manager.on_llm_new_token(cast(str, chunk.message.content), chunk=chunk)+ if chunk.message.id is None:+ chunk.message.id = f"run-{run_manager.run_id}"chunk.message.response_metadata = _gen_info_and_msg_metadata(chunk)yield chunk.messageif generation is None:@@ -607,6 +611,8 @@ class BaseChatModel(BaseLanguageModel[BaseMessage], ABC):chunks: List[ChatGenerationChunk] = []for chunk in self._stream(messages, stop=stop, **kwargs):if run_manager:+ if chunk.message.id is None:+ chunk.message.id = f"run-{run_manager.run_id}"run_manager.on_llm_new_token(cast(str, chunk.message.content), chunk=chunk)@@ -622,7 +628,9 @@ class BaseChatModel(BaseLanguageModel[BaseMessage], ABC):result = self._generate(messages, stop=stop, **kwargs)# Add response metadata to each generation- for generation in result.generations:+ for idx, generation in enumerate(result.generations):+ if run_manager and generation.message.id is None:+ generation.message.id = f"run-{run_manager.run_id}-{idx}"generation.message.response_metadata = _gen_info_and_msg_metadata(generation)@@ -684,6 +692,8 @@ class BaseChatModel(BaseLanguageModel[BaseMessage], ABC):chunks: List[ChatGenerationChunk] = []async for chunk in self._astream(messages, stop=stop, **kwargs):if run_manager:+ if chunk.message.id is None:+ chunk.message.id = f"run-{run_manager.run_id}"await run_manager.on_llm_new_token(cast(str, chunk.message.content), chunk=chunk)@@ -699,7 +709,9 @@ class BaseChatModel(BaseLanguageModel[BaseMessage], ABC):result = await self._agenerate(messages, stop=stop, **kwargs)# Add response metadata to each generation- for generation in result.generations:+ for idx, generation in enumerate(result.generations):+ if run_manager and generation.message.id is None:+ generation.message.id = f"run-{run_manager.run_id}-{idx}"generation.message.response_metadata = _gen_info_and_msg_metadata(generation)diff --git a/libs/core/langchain_core/language_models/fake_chat_models.py b/libs/core/langchain_core/language_models/fake_chat_models.pyindex 8324787c50..8285d79674 100644--- a/libs/core/langchain_core/language_models/fake_chat_models.py+++ b/libs/core/langchain_core/language_models/fake_chat_models.py@@ -223,7 +223,9 @@ class GenericFakeChatModel(BaseChatModel):content_chunks = cast(List[str], re.split(r"(\s)", content))for token in content_chunks:- chunk = ChatGenerationChunk(message=AIMessageChunk(content=token))+ chunk = ChatGenerationChunk(+ message=AIMessageChunk(content=token, id=message.id)+ )if run_manager:run_manager.on_llm_new_token(token, chunk=chunk)yield chunk@@ -240,6 +242,7 @@ class GenericFakeChatModel(BaseChatModel):for fvalue_chunk in fvalue_chunks:chunk = ChatGenerationChunk(message=AIMessageChunk(+ id=message.id,content="",additional_kwargs={"function_call": {fkey: fvalue_chunk}@@ -255,6 +258,7 @@ class GenericFakeChatModel(BaseChatModel):else:chunk = ChatGenerationChunk(message=AIMessageChunk(+ id=message.id,content="",additional_kwargs={"function_call": {fkey: fvalue}},)@@ -268,7 +272,7 @@ class GenericFakeChatModel(BaseChatModel):else:chunk = ChatGenerationChunk(message=AIMessageChunk(- content="", additional_kwargs={key: value}+ id=message.id, content="", additional_kwargs={key: value}))if run_manager:diff --git a/libs/core/langchain_core/load/mapping.py b/libs/core/langchain_core/load/mapping.pyindex 10a3a6413c..5ac56503ea 100644--- a/libs/core/langchain_core/load/mapping.py+++ b/libs/core/langchain_core/load/mapping.py@@ -971,4 +971,10 @@ _JS_SERIALIZABLE_MAPPING: Dict[Tuple[str, ...], Tuple[str, ...]] = {"tool","ToolMessageChunk",),+ ("langchain_core", "prompts", "image", "ImagePromptTemplate"): (+ "langchain_core",+ "prompts",+ "image",+ "ImagePromptTemplate",+ ),}diff --git a/libs/core/langchain_core/messages/ai.py b/libs/core/langchain_core/messages/ai.pyindex 3db9858834..22740326e8 100644--- a/libs/core/langchain_core/messages/ai.py+++ b/libs/core/langchain_core/messages/ai.py@@ -56,6 +56,7 @@ class AIMessageChunk(AIMessage, BaseMessageChunk):response_metadata=merge_dicts(self.response_metadata, other.response_metadata),+ id=self.id,)return super().__add__(other)diff --git a/libs/core/langchain_core/messages/base.py b/libs/core/langchain_core/messages/base.pyindex 26d9558e36..60c5722003 100644--- a/libs/core/langchain_core/messages/base.py+++ b/libs/core/langchain_core/messages/base.py@@ -34,6 +34,8 @@ class BaseMessage(Serializable):name: Optional[str] = Noneid: Optional[str] = None+ """An optional unique identifier for the message. This should ideally be+ provided by the provider/model which created the message."""class Config:extra = Extra.allowdiff --git a/libs/core/langchain_core/messages/chat.py b/libs/core/langchain_core/messages/chat.pyindex fad0d265ea..f8a9add85e 100644--- a/libs/core/langchain_core/messages/chat.py+++ b/libs/core/langchain_core/messages/chat.py@@ -54,6 +54,7 @@ class ChatMessageChunk(ChatMessage, BaseMessageChunk):response_metadata=merge_dicts(self.response_metadata, other.response_metadata),+ id=self.id,)elif isinstance(other, BaseMessageChunk):return self.__class__(@@ -65,6 +66,7 @@ class ChatMessageChunk(ChatMessage, BaseMessageChunk):response_metadata=merge_dicts(self.response_metadata, other.response_metadata),+ id=self.id,)else:return super().__add__(other)diff --git a/libs/core/langchain_core/messages/function.py b/libs/core/langchain_core/messages/function.pyindex a98242756a..c28f42b939 100644--- a/libs/core/langchain_core/messages/function.py+++ b/libs/core/langchain_core/messages/function.py@@ -54,6 +54,7 @@ class FunctionMessageChunk(FunctionMessage, BaseMessageChunk):response_metadata=merge_dicts(self.response_metadata, other.response_metadata),+ id=self.id,)return super().__add__(other)diff --git a/libs/core/langchain_core/messages/tool.py b/libs/core/langchain_core/messages/tool.pyindex 9891cab771..d91bc196bc 100644--- a/libs/core/langchain_core/messages/tool.py+++ b/libs/core/langchain_core/messages/tool.py@@ -54,6 +54,7 @@ class ToolMessageChunk(ToolMessage, BaseMessageChunk):response_metadata=merge_dicts(self.response_metadata, other.response_metadata),+ id=self.id,)return super().__add__(other)diff --git a/libs/core/langchain_core/runnables/graph.py b/libs/core/langchain_core/runnables/graph.pyindex 5c7a8e9985..84ae717d03 100644--- a/libs/core/langchain_core/runnables/graph.py+++ b/libs/core/langchain_core/runnables/graph.py@@ -116,7 +116,9 @@ def node_data_str(node: Node) -> str:return data if not data.startswith("Runnable") else data[8:]-def node_data_json(node: Node) -> Dict[str, Union[str, Dict[str, Any]]]:+def node_data_json(+ node: Node, *, with_schemas: bool = False+) -> Dict[str, Union[str, Dict[str, Any]]]:from langchain_core.load.serializable import to_json_not_implementedfrom langchain_core.runnables.base import Runnable, RunnableSerializable@@ -137,10 +139,17 @@ def node_data_json(node: Node) -> Dict[str, Union[str, Dict[str, Any]]]:},}elif inspect.isclass(node.data) and issubclass(node.data, BaseModel):- return {- "type": "schema",- "data": node.data.schema(),- }+ return (+ {+ "type": "schema",+ "data": node.data.schema(),+ }+ if with_schemas+ else {+ "type": "schema",+ "data": node_data_str(node),+ }+ )else:return {"type": "unknown",@@ -156,7 +165,7 @@ class Graph:edges: List[Edge] = field(default_factory=list)branches: Optional[Dict[str, List[Branch]]] = field(default_factory=dict)- def to_json(self) -> Dict[str, List[Dict[str, Any]]]:+ def to_json(self, *, with_schemas: bool = False) -> Dict[str, List[Dict[str, Any]]]:"""Convert the graph to a JSON-serializable format."""stable_node_ids = {node.id: i if is_uuid(node.id) else node.id@@ -165,7 +174,10 @@ class Graph:return {"nodes": [- {"id": stable_node_ids[node.id], **node_data_json(node)}+ {+ "id": stable_node_ids[node.id],+ **node_data_json(node, with_schemas=with_schemas),+ }for node in self.nodes.values()],"edges": [diff --git a/libs/core/tests/unit_tests/fake/test_fake_chat_model.py b/libs/core/tests/unit_tests/fake/test_fake_chat_model.pyindex d2faf94b22..8e3da6ea1f 100644--- a/libs/core/tests/unit_tests/fake/test_fake_chat_model.py+++ b/libs/core/tests/unit_tests/fake/test_fake_chat_model.py@@ -8,6 +8,7 @@ from langchain_core.language_models import GenericFakeChatModel, ParrotFakeChatMfrom langchain_core.messages import AIMessage, AIMessageChunk, BaseMessagefrom langchain_core.messages.human import HumanMessagefrom langchain_core.outputs import ChatGenerationChunk, GenerationChunk+from tests.unit_tests.stubs import AnyStrdef test_generic_fake_chat_model_invoke() -> None:@@ -15,11 +16,11 @@ def test_generic_fake_chat_model_invoke() -> None:infinite_cycle = cycle([AIMessage(content="hello"), AIMessage(content="goodbye")])model = GenericFakeChatModel(messages=infinite_cycle)response = model.invoke("meow")- assert response == AIMessage(content="hello")+ assert response == AIMessage(content="hello", id=AnyStr())response = model.invoke("kitty")- assert response == AIMessage(content="goodbye")+ assert response == AIMessage(content="goodbye", id=AnyStr())response = model.invoke("meow")- assert response == AIMessage(content="hello")+ assert response == AIMessage(content="hello", id=AnyStr())async def test_generic_fake_chat_model_ainvoke() -> None:@@ -27,11 +28,11 @@ async def test_generic_fake_chat_model_ainvoke() -> None:infinite_cycle = cycle([AIMessage(content="hello"), AIMessage(content="goodbye")])model = GenericFakeChatModel(messages=infinite_cycle)response = await model.ainvoke("meow")- assert response == AIMessage(content="hello")+ assert response == AIMessage(content="hello", id=AnyStr())response = await model.ainvoke("kitty")- assert response == AIMessage(content="goodbye")+ assert response == AIMessage(content="goodbye", id=AnyStr())response = await model.ainvoke("meow")- assert response == AIMessage(content="hello")+ assert response == AIMessage(content="hello", id=AnyStr())async def test_generic_fake_chat_model_stream() -> None:@@ -44,17 +45,19 @@ async def test_generic_fake_chat_model_stream() -> None:model = GenericFakeChatModel(messages=infinite_cycle)chunks = [chunk async for chunk in model.astream("meow")]assert chunks == [- AIMessageChunk(content="hello"),- AIMessageChunk(content=" "),- AIMessageChunk(content="goodbye"),+ AIMessageChunk(content="hello", id=AnyStr()),+ AIMessageChunk(content=" ", id=AnyStr()),+ AIMessageChunk(content="goodbye", id=AnyStr()),]+ assert len({chunk.id for chunk in chunks}) == 1chunks = [chunk for chunk in model.stream("meow")]assert chunks == [- AIMessageChunk(content="hello"),- AIMessageChunk(content=" "),- AIMessageChunk(content="goodbye"),+ AIMessageChunk(content="hello", id=AnyStr()),+ AIMessageChunk(content=" ", id=AnyStr()),+ AIMessageChunk(content="goodbye", id=AnyStr()),]+ assert len({chunk.id for chunk in chunks}) == 1# Test streaming of additional kwargs.# Relying on insertion order of the additional kwargs dict@@ -62,9 +65,10 @@ async def test_generic_fake_chat_model_stream() -> None:model = GenericFakeChatModel(messages=cycle([message]))chunks = [chunk async for chunk in model.astream("meow")]assert chunks == [- AIMessageChunk(content="", additional_kwargs={"foo": 42}),- AIMessageChunk(content="", additional_kwargs={"bar": 24}),+ AIMessageChunk(content="", additional_kwargs={"foo": 42}, id=AnyStr()),+ AIMessageChunk(content="", additional_kwargs={"bar": 24}, id=AnyStr()),]+ assert len({chunk.id for chunk in chunks}) == 1message = AIMessage(content="",@@ -81,24 +85,31 @@ async def test_generic_fake_chat_model_stream() -> None:assert chunks == [AIMessageChunk(- content="", additional_kwargs={"function_call": {"name": "move_file"}}+ content="",+ additional_kwargs={"function_call": {"name": "move_file"}},+ id=AnyStr(),),AIMessageChunk(content="",additional_kwargs={- "function_call": {"arguments": '{\n "source_path": "foo"'}+ "function_call": {"arguments": '{\n "source_path": "foo"'},},+ id=AnyStr(),),AIMessageChunk(- content="", additional_kwargs={"function_call": {"arguments": ","}}+ content="",+ additional_kwargs={"function_call": {"arguments": ","}},+ id=AnyStr(),),AIMessageChunk(content="",additional_kwargs={- "function_call": {"arguments": '\n "destination_path": "bar"\n}'}+ "function_call": {"arguments": '\n "destination_path": "bar"\n}'},},+ id=AnyStr(),),]+ assert len({chunk.id for chunk in chunks}) == 1accumulate_chunks = Nonefor chunk in chunks:@@ -116,6 +127,7 @@ async def test_generic_fake_chat_model_stream() -> None:'destination_path": "bar"\n}',}},+ id=chunks[0].id,)@@ -128,10 +140,11 @@ async def test_generic_fake_chat_model_astream_log() -> None:]final = log_patches[-1]assert final.state["streamed_output"] == [- AIMessageChunk(content="hello"),- AIMessageChunk(content=" "),- AIMessageChunk(content="goodbye"),+ AIMessageChunk(content="hello", id=AnyStr()),+ AIMessageChunk(content=" ", id=AnyStr()),+ AIMessageChunk(content="goodbye", id=AnyStr()),]+ assert len({chunk.id for chunk in final.state["streamed_output"]}) == 1async def test_callback_handlers() -> None:@@ -178,16 +191,19 @@ async def test_callback_handlers() -> None:# New modelresults = list(model.stream("meow", {"callbacks": [MyCustomAsyncHandler(tokens)]}))assert results == [- AIMessageChunk(content="hello"),- AIMessageChunk(content=" "),- AIMessageChunk(content="goodbye"),+ AIMessageChunk(content="hello", id=AnyStr()),+ AIMessageChunk(content=" ", id=AnyStr()),+ AIMessageChunk(content="goodbye", id=AnyStr()),]assert tokens == ["hello", " ", "goodbye"]+ assert len({chunk.id for chunk in results}) == 1def test_chat_model_inputs() -> None:fake = ParrotFakeChatModel()- assert fake.invoke("hello") == HumanMessage(content="hello")- assert fake.invoke([("ai", "blah")]) == AIMessage(content="blah")- assert fake.invoke([AIMessage(content="blah")]) == AIMessage(content="blah")+ assert fake.invoke("hello") == HumanMessage(content="hello", id=AnyStr())+ assert fake.invoke([("ai", "blah")]) == AIMessage(content="blah", id=AnyStr())+ assert fake.invoke([AIMessage(content="blah")]) == AIMessage(+ content="blah", id=AnyStr()+ )diff --git a/libs/core/tests/unit_tests/language_models/chat_models/test_base.py b/libs/core/tests/unit_tests/language_models/chat_models/test_base.pyindex 2eb87e0f12..f65646f445 100644--- a/libs/core/tests/unit_tests/language_models/chat_models/test_base.py+++ b/libs/core/tests/unit_tests/language_models/chat_models/test_base.py@@ -21,6 +21,7 @@ from tests.unit_tests.fake.callbacks import (FakeAsyncCallbackHandler,FakeCallbackHandler,)+from tests.unit_tests.stubs import AnyStr@pytest.fixture@@ -140,10 +141,10 @@ async def test_astream_fallback_to_ainvoke() -> None:model = ModelWithGenerate()chunks = [chunk for chunk in model.stream("anything")]- assert chunks == [AIMessage(content="hello")]+ assert chunks == [AIMessage(content="hello", id=AnyStr())]chunks = [chunk async for chunk in model.astream("anything")]- assert chunks == [AIMessage(content="hello")]+ assert chunks == [AIMessage(content="hello", id=AnyStr())]async def test_astream_implementation_fallback_to_stream() -> None:@@ -178,15 +179,17 @@ async def test_astream_implementation_fallback_to_stream() -> None:model = ModelWithSyncStream()chunks = [chunk for chunk in model.stream("anything")]assert chunks == [- AIMessageChunk(content="a"),- AIMessageChunk(content="b"),+ AIMessageChunk(content="a", id=AnyStr()),+ AIMessageChunk(content="b", id=AnyStr()),]+ assert len({chunk.id for chunk in chunks}) == 1assert type(model)._astream == BaseChatModel._astreamastream_chunks = [chunk async for chunk in model.astream("anything")]assert astream_chunks == [- AIMessageChunk(content="a"),- AIMessageChunk(content="b"),+ AIMessageChunk(content="a", id=AnyStr()),+ AIMessageChunk(content="b", id=AnyStr()),]+ assert len({chunk.id for chunk in astream_chunks}) == 1async def test_astream_implementation_uses_astream() -> None:@@ -221,6 +224,7 @@ async def test_astream_implementation_uses_astream() -> None:model = ModelWithAsyncStream()chunks = [chunk async for chunk in model.astream("anything")]assert chunks == [- AIMessageChunk(content="a"),- AIMessageChunk(content="b"),+ AIMessageChunk(content="a", id=AnyStr()),+ AIMessageChunk(content="b", id=AnyStr()),]+ assert len({chunk.id for chunk in chunks}) == 1diff --git a/libs/core/tests/unit_tests/runnables/__snapshots__/test_fallbacks.ambr b/libs/core/tests/unit_tests/runnables/__snapshots__/test_fallbacks.ambrindex 3df05b800a..b802468d17 100644--- a/libs/core/tests/unit_tests/runnables/__snapshots__/test_fallbacks.ambr+++ b/libs/core/tests/unit_tests/runnables/__snapshots__/test_fallbacks.ambr@@ -41,24 +41,12 @@{"id": 0,"type": "schema",- "data": {- "title": "RunnableParallel<buz>Input",- "type": "object",- "properties": {}- }+ "data": "Parallel<buz>Input"},{"id": 1,"type": "schema",- "data": {- "title": "RunnableParallel<buz>Output",- "type": "object",- "properties": {- "buz": {- "title": "Buz"- }- }- }+ "data": "Parallel<buz>Output"},{"id": 2,@@ -130,16 +118,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "buz": {- "title": "Buz",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -157,436 +136,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -618,464 +168,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListLLMInput"},{"id": 1,@@ -1093,10 +186,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -1119,16 +209,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "buz": {- "title": "Buz",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -1159,10 +240,7 @@{"id": 3,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -1215,16 +293,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "buz": {- "title": "Buz",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -1242,436 +311,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -1703,464 +343,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListLLMInput"},{"id": 1,@@ -2178,10 +361,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -2204,16 +384,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "buz": {- "title": "Buz",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -2244,10 +415,7 @@{"id": 3,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -2286,16 +454,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "buz": {- "title": "Buz",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -2313,10 +472,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -2339,11 +495,7 @@{"id": 0,"type": "schema",- "data": {- "title": "RunnableParallel<buz>Input",- "type": "object",- "properties": {}- }+ "data": "Parallel<buz>Input"},{"id": 1,@@ -2374,10 +526,7 @@{"id": 3,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -2441,9 +590,7 @@{"id": 0,"type": "schema",- "data": {- "title": "RunnablePassthroughInput"- }+ "data": "PassthroughInput"},{"id": 1,@@ -2461,9 +608,7 @@{"id": 2,"type": "schema",- "data": {- "title": "RunnablePassthroughOutput"- }+ "data": "PassthroughOutput"}],"edges": [@@ -2486,24 +631,12 @@{"id": 0,"type": "schema",- "data": {- "title": "RunnableParallel<text>Input",- "type": "object",- "properties": {}- }+ "data": "Parallel<text>Input"},{"id": 1,"type": "schema",- "data": {- "title": "RunnableParallel<text>Output",- "type": "object",- "properties": {- "text": {- "title": "Text"- }- }- }+ "data": "Parallel<text>Output"},{"id": 2,@@ -2585,10 +718,7 @@{"id": 0,"type": "schema",- "data": {- "title": "_raise_error_input",- "type": "object"- }+ "data": "_raise_error_input"},{"id": 1,@@ -2606,10 +736,7 @@{"id": 2,"type": "schema",- "data": {- "title": "_raise_error_output",- "type": "string"- }+ "data": "_raise_error_output"}],"edges": [@@ -2632,11 +759,7 @@{"id": 0,"type": "schema",- "data": {- "title": "RunnableParallel<text>Input",- "type": "object",- "properties": {}- }+ "data": "Parallel<text>Input"},{"id": 1,@@ -2667,10 +790,7 @@{"id": 3,"type": "schema",- "data": {- "title": "_raise_error_output",- "type": "string"- }+ "data": "_raise_error_output"}],"edges": [@@ -2719,464 +839,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListLLMInput"},{"id": 1,@@ -3194,10 +857,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -3229,464 +889,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListLLMInput"},{"id": 1,@@ -3704,10 +907,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -3742,474 +942,17 @@{"id": 0,"type": "schema",+ "data": "FakeListLLMInput"+ },+ {+ "id": 1,+ "type": "runnable","data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "schema",- "runnable",- "RunnableWithFallbacks"+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableWithFallbacks"],"name": "RunnableWithFallbacks"}@@ -4217,10 +960,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -4265,464 +1005,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListLLMInput"},{"id": 1,@@ -4740,10 +1023,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -4775,464 +1055,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListLLMInput"},{"id": 1,@@ -5250,10 +1073,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -5284,464 +1104,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListLLMInput"},{"id": 1,@@ -5759,10 +1122,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [@@ -5797,464 +1157,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListLLMInput"},{"id": 1,@@ -6272,10 +1175,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListLLMOutput"}],"edges": [diff --git a/libs/core/tests/unit_tests/runnables/__snapshots__/test_runnable.ambr b/libs/core/tests/unit_tests/runnables/__snapshots__/test_runnable.ambrindex b49af50a3e..120e57319f 100644--- a/libs/core/tests/unit_tests/runnables/__snapshots__/test_runnable.ambr+++ b/libs/core/tests/unit_tests/runnables/__snapshots__/test_runnable.ambr@@ -53,11 +53,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }+ "data": "PromptInput"},{"id": 1,@@ -75,436 +71,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -554,16 +121,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -581,436 +139,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -1038,16 +167,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -1065,436 +185,107 @@{"id": 2,"type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [+ {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "repr": "FakeListChatModel(responses=['foo, bar'])",+ "name": "FakeListChatModel",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListChatModelInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListChatModelOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ ],+ "last": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "kwargs": {},+ "name": "CommaSeparatedListOutputParser",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserInput"+ },+ {+ "id": 1,+ "type": "runnable","data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }+ "name": "CommaSeparatedListOutputParser"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput"}],"edges": [@@ -1509,481 +300,313 @@]}},+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "name": "CommaSeparatedListOutputParser"+ }+ },+ {+ "id": 4,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ },+ {+ "source": 3,+ "target": 4+ },+ {+ "source": 2,+ "target": 3+ }+ ]+ }+ }+ '''+# ---+# name: test_combining_sequences.1+ '''+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(lambda x: {'question': x[0] + x[1]})"+ },"middle": [{"lc": 1,- "type": "not_implemented",+ "type": "constructor","id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"],- "repr": "FakeListChatModel(responses=['foo, bar'])",- "name": "FakeListChatModel",- "graph": {- "nodes": [+ "kwargs": {+ "messages": [{- "id": 0,- "type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [],+ "template": "You are a nicer assistant.",+ "template_format": "f-string",+ "partial_variables": {}},- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "name": {- "title": "Name",- "type": "string"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},- "id": {- "title": "Id",- "type": "string"+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "id": {- "title": "Id",- "type": "string"+ {+ "source": 1,+ "target": 2}- },- "required": [- "content",- "name"]+ }+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}},- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "id": {- "title": "Id",- "type": "string"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"+ {+ "source": 1,+ "target": 2}- },- "required": [- "messages"]}}}+ }+ ],+ "input_variables": [+ "question"+ ]+ },+ "name": "ChatPromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "repr": "FakeListChatModel(responses=['baz, qux'])",+ "name": "FakeListChatModel",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListChatModelInput"},{"id": 1,@@ -2001,382 +624,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }+ "data": "FakeListChatModelOutput"}],"edges": [@@ -2408,385 +656,7 @@{"id": 0,"type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }+ "data": "CommaSeparatedListOutputParserInput"},{"id": 1,@@ -2804,13 +674,7 @@{"id": 2,"type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }+ "data": "CommaSeparatedListOutputParserOutput"}],"edges": [@@ -2833,19 +697,23 @@{"id": 0,"type": "schema",+ "data": "LambdaInput"+ },+ {+ "id": 1,+ "type": "runnable","data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"}},{- "id": 1,+ "id": 2,"type": "runnable","data": {"id": [@@ -2858,7 +726,7 @@}},{- "id": 2,+ "id": 3,"type": "runnable","data": {"id": [@@ -2871,7 +739,7 @@}},{- "id": 3,+ "id": 4,"type": "runnable","data": {"id": [@@ -2884,15 +752,9 @@}},{- "id": 4,+ "id": 5,"type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }+ "data": "CommaSeparatedListOutputParserOutput"}],"edges": [@@ -2904,20 +766,24 @@"source": 1,"target": 2},- {- "source": 3,- "target": 4- },{"source": 2,"target": 3+ },+ {+ "source": 4,+ "target": 5+ },+ {+ "source": 3,+ "target": 4}]}}'''# ----# name: test_combining_sequences.1+# name: test_combining_sequences.2'''{"lc": 1,@@ -2931,569 +797,346 @@"kwargs": {"first": {"lc": 1,- "type": "not_implemented",+ "type": "constructor","id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"],- "repr": "RunnableLambda(lambda x: {'question': x[0] + x[1]})"- },- "middle": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [],- "template": "You are a nicer assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "kwargs": {+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [],+ "template": "You are a nice assistant.",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"}- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"}- ]- }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]}}- },- {- "lc": 1,- "type": "constructor",+ }+ }+ ],+ "input_variables": [+ "question"+ ]+ },+ "name": "ChatPromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {"id": ["langchain","prompts","chat",- "HumanMessagePromptTemplate"+ "ChatPromptTemplate"],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "template": "{question}",- "template_format": "f-string",- "partial_variables": {}- },+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [+ {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "repr": "FakeListChatModel(responses=['foo, bar'])",+ "name": "FakeListChatModel",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListChatModelInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListChatModelOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "kwargs": {},+ "name": "CommaSeparatedListOutputParser",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "name": "CommaSeparatedListOutputParser"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(lambda x: {'question': x[0] + x[1]})"+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "kwargs": {+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [],+ "template": "You are a nicer assistant.",+ "template_format": "f-string",+ "partial_variables": {}+ },"name": "PromptTemplate","graph": {"nodes": [{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -3511,436 +1154,75 @@{"id": 2,"type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable","data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }+ "name": "PromptTemplate"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}],"edges": [@@ -3968,16 +1250,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -3995,436 +1268,7 @@{"id": 2,"type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "ChatPromptTemplateOutput"}],"edges": [@@ -4455,464 +1299,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListChatModelInput"},{"id": 1,@@ -4930,382 +1317,7 @@{"id": 2,"type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }+ "data": "FakeListChatModelOutput"}],"edges": [@@ -5337,385 +1349,7 @@{"id": 0,"type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }+ "data": "CommaSeparatedListOutputParserInput"},{"id": 1,@@ -5733,13 +1367,7 @@{"id": 2,"type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }+ "data": "CommaSeparatedListOutputParserOutput"}],"edges": [@@ -5762,12 +1390,49 @@{"id": 0,"type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable","data": {- "title": "RunnableLambdaInput"+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"}},{- "id": 1,+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "name": "CommaSeparatedListOutputParser"+ }+ },+ {+ "id": 4,"type": "runnable","data": {"id": [@@ -5780,7 +1445,7 @@}},{- "id": 2,+ "id": 5,"type": "runnable","data": {"id": [@@ -5793,7 +1458,7 @@}},{- "id": 3,+ "id": 6,"type": "runnable","data": {"id": [@@ -5806,7 +1471,7 @@}},{- "id": 4,+ "id": 7,"type": "runnable","data": {"id": [@@ -5819,15 +1484,9 @@}},{- "id": 5,+ "id": 8,"type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }+ "data": "CommaSeparatedListOutputParserOutput"}],"edges": [@@ -5843,20 +1502,37 @@"source": 2,"target": 3},+ {+ "source": 3,+ "target": 4+ },{"source": 4,"target": 5},{- "source": 3,- "target": 4+ "source": 5,+ "target": 6+ },+ {+ "source": 7,+ "target": 8+ },+ {+ "source": 6,+ "target": 7}]}}'''# ----# name: test_combining_sequences.2+# name: test_combining_sequences.3+ list([+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo, bar'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'repr': "RunnableLambda(lambda x: {'question': x[0] + x[1]})"}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nicer assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['baz, qux'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'runnable', 'data': {'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'name': 'RunnableLambda'}}, {'id': 5, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 6, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 7, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 8, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 2, 'target': 3}, {'source': 3, 'target': 4}, {'source': 4, 'target': 5}, {'source': 5, 'target': 6}, {'source': 7, 'target': 8}, {'source': 6, 'target': 7}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ['baz', 'qux']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo, bar'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo, bar'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo, bar', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'foo, bar'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': AIMessage(content='foo, bar', id='')}, outputs={'output': ['foo', 'bar']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003'), Run(id=UUID('00000000-0000-4000-8000-000000000004'), name='RunnableLambda', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'repr': "RunnableLambda(lambda x: {'question': x[0] + x[1]})"}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': ['foo', 'bar']}, outputs={'question': 'foobar'}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:4'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000004'), Run(id=UUID('00000000-0000-4000-8000-000000000005'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nicer assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'foobar'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nicer assistant.'), HumanMessage(content='foobar')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:5'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000005'), Run(id=UUID('00000000-0000-4000-8000-000000000006'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['baz, qux'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['baz, qux'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nicer assistant.\nHuman: foobar']}, outputs={'generations': [[{'text': 'baz, qux', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'baz, qux'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:6'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000006'), Run(id=UUID('00000000-0000-4000-8000-000000000007'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': AIMessage(content='baz, qux', id='')}, outputs={'output': ['baz', 'qux']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:7'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000007')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ ])+# ---+# name: test_each'''{"lc": 1,@@ -5910,11 +1586,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }+ "data": "PromptInput"},{"id": 1,@@ -5932,436 +1604,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -6411,16 +1654,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -6438,436 +1672,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -6895,16 +1700,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -6922,436 +1718,7 @@{"id": 2,"type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "ChatPromptTemplateOutput"}],"edges": [@@ -7373,474 +1740,17 @@"id": ["langchain_core","language_models",- "fake_chat_models",- "FakeListChatModel"+ "fake",+ "FakeStreamingListLLM"],- "repr": "FakeListChatModel(responses=['foo, bar'])",- "name": "FakeListChatModel",+ "repr": "FakeStreamingListLLM(responses=['first item, second item, third item'])",+ "name": "FakeStreamingListLLM","graph": {"nodes": [{"id": 0,"type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeStreamingListLLMInput"},{"id": 1,@@ -7849,391 +1759,16 @@"id": ["langchain_core","language_models",- "fake_chat_models",- "FakeListChatModel"+ "fake",+ "FakeStreamingListLLM"],- "name": "FakeListChatModel"+ "name": "FakeStreamingListLLM"}},{"id": 2,"type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }+ "data": "FakeStreamingListLLMOutput"}],"edges": [@@ -8252,421 +1787,39 @@"lc": 1,"type": "constructor","id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"+ "tests",+ "unit_tests",+ "runnables",+ "test_runnable",+ "FakeSplitIntoListParser"],"kwargs": {},- "name": "CommaSeparatedListOutputParser",+ "name": "FakeSplitIntoListParser","graph": {"nodes": [{"id": 0,"type": "schema",+ "data": "FakeSplitIntoListParserInput"+ },+ {+ "id": 1,+ "type": "runnable","data": {- "title": "CommaSeparatedListOutputParserInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }+ "id": [+ "tests",+ "unit_tests",+ "runnables",+ "test_runnable",+ "FakeSplitIntoListParser"],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "name": "CommaSeparatedListOutputParser"+ "name": "FakeSplitIntoListParser"}},{"id": 2,"type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }+ "data": "FakeSplitIntoListParserOutput"}],"edges": [@@ -8680,2830 +1833,372 @@}]}- },- {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(lambda x: {'question': x[0] + x[1]})"- },- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",+ }+ ],+ "last": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableEach"+ ],+ "kwargs": {+ "bound": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeStreamingListLLM"+ ],+ "repr": "FakeStreamingListLLM(responses=['this', 'is', 'a', 'test'])",+ "name": "FakeStreamingListLLM",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeStreamingListLLMInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {"id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"+ "langchain_core",+ "language_models",+ "fake",+ "FakeStreamingListLLM"],- "kwargs": {- "input_variables": [],- "template": "You are a nicer assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }+ "name": "FakeStreamingListLLM"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeStreamingListLLMOutput"}- },- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ },+ "name": "RunnableEach<FakeStreamingListLLM>",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeStreamingListLLMInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeStreamingListLLM"+ ],+ "name": "FakeStreamingListLLM"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeStreamingListLLMOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeStreamingListLLM"+ ],+ "name": "FakeStreamingListLLM"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "tests",+ "unit_tests",+ "runnables",+ "test_runnable",+ "FakeSplitIntoListParser"+ ],+ "name": "FakeSplitIntoListParser"+ }+ },+ {+ "id": 4,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeStreamingListLLM"+ ],+ "name": "FakeStreamingListLLM"+ }+ },+ {+ "id": 5,+ "type": "schema",+ "data": "FakeStreamingListLLMOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ },+ {+ "source": 2,+ "target": 3+ },+ {+ "source": 4,+ "target": 5+ },+ {+ "source": 3,+ "target": 4+ }+ ]+ }+ }+ '''+# ---+# name: test_higher_order_lambda_runnable+ '''+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableParallel"+ ],+ "kwargs": {+ "steps": {+ "key": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(lambda x: x['key'])"+ },+ "input": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableParallel"+ ],+ "kwargs": {+ "steps": {+ "question": {"lc": 1,- "type": "constructor",+ "type": "not_implemented","id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"],- "kwargs": {- "input_variables": [- "question"+ "repr": "RunnableLambda(lambda x: x['question'])"+ }+ }+ },+ "name": "RunnableParallel<question>",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "Parallel<question>Input"+ },+ {+ "id": 1,+ "type": "schema",+ "data": "Parallel<question>Output"+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"],- "template": "{question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "input_variables": [- "question"- ]- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"+ "name": "RunnableLambda"}}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }+ ],+ "edges": [+ {+ "source": 0,+ "target": 2+ },+ {+ "source": 2,+ "target": 1}- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2+ ]}- ]+ }}},- {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"+ "name": "RunnableParallel<key,input>",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "Parallel<key,input>Input"+ },+ {+ "id": 1,+ "type": "schema",+ "data": "Parallel<key,input>Output"+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ }],- "repr": "FakeListChatModel(responses=['baz, qux'])",- "name": "FakeListChatModel",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }+ "edges": [+ {+ "source": 0,+ "target": 2+ },+ {+ "source": 2,+ "target": 1+ },+ {+ "source": 0,+ "target": 3+ },+ {+ "source": 3,+ "target": 1+ }+ ]}- ],+ },+ "middle": [],"last": {"lc": 1,- "type": "constructor",+ "type": "not_implemented","id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"],- "kwargs": {},- "name": "CommaSeparatedListOutputParser",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "name": "CommaSeparatedListOutputParser"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }+ "repr": "RunnableLambda(router)"},"name": null},@@ -11513,29 +2208,12 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "Parallel<key,input>Input"},{"id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }+ "type": "schema",+ "data": "Parallel<key,input>Output"},{"id": 2,@@ -11543,29 +2221,16 @@"data": {"id": ["langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"+ "runnables",+ "base",+ "RunnableLambda"],- "name": "FakeListChatModel"+ "name": "RunnableLambda"}},{"id": 3,"type": "runnable",- "data": {- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "name": "CommaSeparatedListOutputParser"- }- },- {- "id": 4,- "type": "runnable","data": {"id": ["langchain_core",@@ -11576,8 +2241,18 @@"name": "RunnableLambda"}},+ {+ "id": 4,+ "type": "schema",+ "data": "router_input"+ },{"id": 5,+ "type": "schema",+ "data": "router_output"+ },+ {+ "id": 6,"type": "runnable","data": {"id": [@@ -11590,87 +2265,102 @@}},{- "id": 6,+ "id": 7,"type": "runnable","data": {"id": ["langchain_core","language_models",- "fake_chat_models",- "FakeListChatModel"+ "fake",+ "FakeListLLM"],- "name": "FakeListChatModel"+ "name": "FakeListLLM"}},{- "id": 7,+ "id": 8,"type": "runnable","data": {"id": ["langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"+ "prompts",+ "chat",+ "ChatPromptTemplate"],- "name": "CommaSeparatedListOutputParser"+ "name": "ChatPromptTemplate"}},{- "id": 8,- "type": "schema",+ "id": 9,+ "type": "runnable","data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"}}],"edges": [{"source": 0,- "target": 1- },- {- "source": 1,"target": 2},{"source": 2,+ "target": 1+ },+ {+ "source": 0,"target": 3},{"source": 3,- "target": 4+ "target": 1},{- "source": 4,- "target": 5+ "source": 6,+ "target": 7},{- "source": 5,+ "source": 4,"target": 6},{"source": 7,- "target": 8+ "target": 5},{- "source": 6,- "target": 7+ "source": 8,+ "target": 9+ },+ {+ "source": 4,+ "target": 8+ },+ {+ "source": 9,+ "target": 5+ },+ {+ "source": 1,+ "target": 4}]}}'''# ----# name: test_combining_sequences.3- list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo, bar'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'repr': "RunnableLambda(lambda x: {'question': x[0] + x[1]})"}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nicer assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['baz, qux'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'runnable', 'data': {'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'name': 'RunnableLambda'}}, {'id': 5, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 6, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 7, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 8, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 2, 'target': 3}, {'source': 3, 'target': 4}, {'source': 4, 'target': 5}, {'source': 5, 'target': 6}, {'source': 7, 'target': 8}, {'source': 6, 'target': 7}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ['baz', 'qux']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo, bar'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo, bar'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo, bar', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'foo, bar'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': AIMessage(content='foo, bar')}, outputs={'output': ['foo', 'bar']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003'), Run(id=UUID('00000000-0000-4000-8000-000000000004'), name='RunnableLambda', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'repr': "RunnableLambda(lambda x: {'question': x[0] + x[1]})"}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': ['foo', 'bar']}, outputs={'question': 'foobar'}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:4'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000004'), Run(id=UUID('00000000-0000-4000-8000-000000000005'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nicer assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'foobar'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nicer assistant.'), HumanMessage(content='foobar')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:5'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000005'), Run(id=UUID('00000000-0000-4000-8000-000000000006'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['baz, qux'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['baz, qux'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nicer assistant.\nHuman: foobar']}, outputs={'generations': [[{'text': 'baz, qux', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'baz, qux'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:6'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000006'), Run(id=UUID('00000000-0000-4000-8000-000000000007'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': AIMessage(content='baz, qux')}, outputs={'output': ['baz', 'qux']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:7'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000007')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),- ])+# name: test_prompt_with_chat_model+ '''+ ChatPromptTemplate(input_variables=['question'], messages=[SystemMessagePromptTemplate(prompt=PromptTemplate(input_variables=[], template='You are a nice assistant.')), HumanMessagePromptTemplate(prompt=PromptTemplate(input_variables=['question'], template='{question}'))])+ | FakeListChatModel(responses=['foo'])+ '''# ----# name: test_each+# name: test_prompt_with_chat_model.1'''{"lc": 1,@@ -11724,11 +2414,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }+ "data": "PromptInput"},{"id": 1,@@ -11746,436 +2432,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -12225,16 +2482,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -12252,436 +2500,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -12709,16 +2528,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -12736,436 +2546,57 @@{"id": 2,"type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [],+ "last": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "repr": "FakeListChatModel(responses=['foo'])",+ "name": "FakeListChatModel",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListChatModelInput"+ },+ {+ "id": 1,+ "type": "runnable","data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }+ "name": "FakeListChatModel"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListChatModelOutput"}],"edges": [@@ -13180,481 +2611,290 @@]}},- "middle": [+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [{- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake",- "FakeStreamingListLLM"- ],- "repr": "FakeStreamingListLLM(responses=['first item, second item, third item'])",- "name": "FakeStreamingListLLM",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeStreamingListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }+ },+ {+ "id": 3,+ "type": "schema",+ "data": "FakeListChatModelOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 2,+ "target": 3+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ '''+# ---+# name: test_prompt_with_chat_model.2+ list([+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 3, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': AIMessage(content='foo', id='')}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'foo'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ ])+# ---+# name: test_prompt_with_chat_model_and_parser+ '''+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "kwargs": {+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }+ "kwargs": {+ "input_variables": [],+ "template": "You are a nice assistant.",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"+ "name": "PromptTemplate"}},- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"+ "name": "PromptTemplate"}},- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "required": [- "messages"- ]- }+ {+ "source": 1,+ "target": 2+ }+ ]}}+ }+ }+ ],+ "input_variables": [+ "question"+ ]+ },+ "name": "ChatPromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [+ {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "repr": "FakeListChatModel(responses=['foo, bar'])",+ "name": "FakeListChatModel",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListChatModelInput"},{"id": 1,@@ -13663,19 +2903,16 @@"id": ["langchain_core","language_models",- "fake",- "FakeStreamingListLLM"+ "fake_chat_models",+ "FakeListChatModel"],- "name": "FakeStreamingListLLM"+ "name": "FakeListChatModel"}},{"id": 2,"type": "schema",- "data": {- "title": "FakeStreamingListLLMOutput",- "type": "string"- }+ "data": "FakeListChatModelOutput"}],"edges": [@@ -13689,1428 +2926,365 @@}]}- },- {- "lc": 1,- "type": "constructor",- "id": [- "tests",- "unit_tests",- "runnables",- "test_runnable",- "FakeSplitIntoListParser"+ }+ ],+ "last": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "kwargs": {},+ "name": "CommaSeparatedListOutputParser",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "name": "CommaSeparatedListOutputParser"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput"+ }],- "kwargs": {},- "name": "FakeSplitIntoListParser",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeSplitIntoListParserInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "tests",- "unit_tests",- "runnables",- "test_runnable",- "FakeSplitIntoListParser"- ],- "name": "FakeSplitIntoListParser"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeSplitIntoListParserOutput",- "type": "array",- "items": {- "type": "string"- }- }- }+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "name": "CommaSeparatedListOutputParser"}+ },+ {+ "id": 4,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput"}],- "last": {+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ },+ {+ "source": 3,+ "target": 4+ },+ {+ "source": 2,+ "target": 3+ }+ ]+ }+ }+ '''+# ---+# name: test_prompt_with_chat_model_and_parser.1+ list([+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo, bar'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ['foo', 'bar']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo, bar'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo, bar'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo, bar', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'foo, bar'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': AIMessage(content='foo, bar', id='')}, outputs={'output': ['foo', 'bar']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ ])+# ---+# name: test_prompt_with_chat_model_async+ '''+ ChatPromptTemplate(input_variables=['question'], messages=[SystemMessagePromptTemplate(prompt=PromptTemplate(input_variables=[], template='You are a nice assistant.')), HumanMessagePromptTemplate(prompt=PromptTemplate(input_variables=['question'], template='{question}'))])+ | FakeListChatModel(responses=['foo'])+ '''+# ---+# name: test_prompt_with_chat_model_async.1+ '''+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {"lc": 1,"type": "constructor","id": ["langchain",- "schema",- "runnable",- "RunnableEach"+ "prompts",+ "chat",+ "ChatPromptTemplate"],"kwargs": {- "bound": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake",- "FakeStreamingListLLM"- ],- "repr": "FakeStreamingListLLM(responses=['this', 'is', 'a', 'test'])",- "name": "FakeStreamingListLLM",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeStreamingListLLMInput",- "anyOf": [+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [],+ "template": "You are a nice assistant.",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [{- "type": "string"+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},{- "$ref": "#/definitions/StringPromptValue"+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},{- "$ref": "#/definitions/ChatPromptValueConcrete"+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},{- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }+ "source": 1,+ "target": 2}+ ]+ }+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeStreamingListLLM"],- "name": "FakeStreamingListLLM"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeStreamingListLLMOutput",- "type": "string"+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]}}- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]+ }}- }+ ],+ "input_variables": [+ "question"+ ]},- "name": "RunnableEach<FakeStreamingListLLM>",+ "name": "ChatPromptTemplate","graph": {"nodes": [{"id": 0,"type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable","data": {- "title": "FakeStreamingListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }+ "name": "ChatPromptTemplate"}},+ {+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [],+ "last": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "repr": "FakeListChatModel(responses=['foo'])",+ "name": "FakeListChatModel",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListChatModelInput"+ },{"id": 1,"type": "runnable",@@ -15118,19 +3292,16 @@"id": ["langchain_core","language_models",- "fake",- "FakeStreamingListLLM"+ "fake_chat_models",+ "FakeListChatModel"],- "name": "FakeStreamingListLLM"+ "name": "FakeListChatModel"}},{"id": 2,"type": "schema",- "data": {- "title": "FakeStreamingListLLMOutput",- "type": "string"- }+ "data": "FakeListChatModelOutput"}],"edges": [@@ -15153,16 +3324,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -15184,46 +3346,16 @@"id": ["langchain_core","language_models",- "fake",- "FakeStreamingListLLM"+ "fake_chat_models",+ "FakeListChatModel"],- "name": "FakeStreamingListLLM"+ "name": "FakeListChatModel"}},{"id": 3,- "type": "runnable",- "data": {- "id": [- "tests",- "unit_tests",- "runnables",- "test_runnable",- "FakeSplitIntoListParser"- ],- "name": "FakeSplitIntoListParser"- }- },- {- "id": 4,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeStreamingListLLM"- ],- "name": "FakeStreamingListLLM"- }- },- {- "id": 5,"type": "schema",- "data": {- "title": "FakeStreamingListLLMOutput",- "type": "string"- }+ "data": "FakeListChatModelOutput"}],"edges": [@@ -15231,28 +3363,25 @@"source": 0,"target": 1},- {- "source": 1,- "target": 2- },{"source": 2,"target": 3},{- "source": 4,- "target": 5- },- {- "source": 3,- "target": 4+ "source": 1,+ "target": 2}]}}'''# ----# name: test_higher_order_lambda_runnable+# name: test_prompt_with_chat_model_async.2+ list([+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 3, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': AIMessage(content='foo', id='')}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListChatModelInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListChatModelOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'foo'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ ])+# ---+# name: test_prompt_with_llm'''{"lc": 1,@@ -15269,183 +3398,186 @@"type": "constructor","id": ["langchain",- "schema",- "runnable",- "RunnableParallel"+ "prompts",+ "chat",+ "ChatPromptTemplate"],"kwargs": {- "steps": {- "key": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(lambda x: x['key'])"- },- "input": {+ "messages": [+ {"lc": 1,"type": "constructor","id": ["langchain",- "schema",- "runnable",- "RunnableParallel"+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"],"kwargs": {- "steps": {- "question": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(lambda x: x['question'])"- }- }- },- "name": "RunnableParallel<question>",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnableParallel<question>Input",- "type": "object",- "properties": {- "question": {- "title": "Question"- }- }- }+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [],+ "template": "You are a nice assistant.",+ "template_format": "f-string",+ "partial_variables": {}},- {- "id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<question>Output",- "type": "object",- "properties": {- "question": {- "title": "Question"+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]}- ],- "edges": [- {- "source": 0,- "target": 2+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}},- {- "source": 2,- "target": 1+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]}- ]+ }}}- }+ ],+ "input_variables": [+ "question"+ ]},- "name": "RunnableParallel<key,input>",+ "name": "ChatPromptTemplate","graph": {"nodes": [{"id": 0,"type": "schema",- "data": {- "title": "RunnableParallel<key,input>Input",- "type": "object",- "properties": {- "key": {- "title": "Key"- },- "question": {- "title": "Question"- }- }- }+ "data": "PromptInput"},{"id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<key,input>Output",- "type": "object",- "properties": {- "key": {- "title": "Key"- },- "input": {- "title": "Input",- "type": "object"- }- }- }- },- {- "id": 2,"type": "runnable","data": {"id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"],- "name": "RunnableLambda"+ "name": "ChatPromptTemplate"}},{- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"}],"edges": [{"source": 0,- "target": 2- },- {- "source": 2,"target": 1},{- "source": 0,- "target": 3- },- {- "source": 3,- "target": 1+ "source": 1,+ "target": 2}]}@@ -15456,11 +3588,49 @@"type": "not_implemented","id": ["langchain_core",- "runnables",- "base",- "RunnableLambda"+ "language_models",+ "fake",+ "FakeListLLM"],- "repr": "RunnableLambda(router)"+ "repr": "FakeListLLM(responses=['foo', 'bar'])",+ "name": "FakeListLLM",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListLLMInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListLLMOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }},"name": null},@@ -15470,80 +3640,11 @@{"id": 0,"type": "schema",- "data": {- "title": "RunnableParallel<key,input>Input",- "type": "object",- "properties": {- "key": {- "title": "Key"- },- "question": {- "title": "Question"- }- }- }+ "data": "PromptInput"},{"id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<key,input>Output",- "type": "object",- "properties": {- "key": {- "title": "Key"- },- "input": {- "title": "Input",- "type": "object"- }- }- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 4,- "type": "schema",- "data": {- "title": "router_input",- "type": "object"- }- },- {- "id": 5,- "type": "schema",- "data": {- "title": "router_output"- }- },- {- "id": 6,- "type": "runnable",+ "type": "runnable","data": {"id": ["langchain",@@ -15555,7 +3656,7 @@}},{- "id": 7,+ "id": 2,"type": "runnable","data": {"id": [@@ -15568,89 +3669,41 @@}},{- "id": 8,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 9,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }+ "id": 3,+ "type": "schema",+ "data": "FakeListLLMOutput"}],"edges": [{"source": 0,- "target": 2- },- {- "source": 2,"target": 1},{- "source": 0,+ "source": 2,"target": 3},- {- "source": 3,- "target": 1- },- {- "source": 6,- "target": 7- },- {- "source": 4,- "target": 6- },- {- "source": 7,- "target": 5- },- {- "source": 8,- "target": 9- },- {- "source": 4,- "target": 8- },- {- "source": 9,- "target": 5- },{"source": 1,- "target": 4+ "target": 2}]}}'''# ----# name: test_prompt_with_chat_model- '''- ChatPromptTemplate(input_variables=['question'], messages=[SystemMessagePromptTemplate(prompt=PromptTemplate(input_variables=[], template='You are a nice assistant.')), HumanMessagePromptTemplate(prompt=PromptTemplate(input_variables=['question'], template='{question}'))])- | FakeListChatModel(responses=['foo'])- '''+# name: test_prompt_with_llm.1+ list([+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'])", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 3, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': 'foo'}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo', 'bar'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'])", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ ])# ----# name: test_prompt_with_chat_model.1+# name: test_prompt_with_llm.2+ list([+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'], i=1)", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 3, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': 'bar'}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo', 'bar'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 2}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'], i=1)", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'bar', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'], i=1)", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 3, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your favorite color?'}, outputs={'output': 'foo'}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000004'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your favorite color?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your favorite color?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000003'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000003'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000003.20230101T000000000000Z00000000-0000-4000-8000-000000000004'), Run(id=UUID('00000000-0000-4000-8000-000000000005'), name='FakeListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo', 'bar'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 2}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'], i=1)", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your favorite color?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000003'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000003'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000003.20230101T000000000000Z00000000-0000-4000-8000-000000000005')], trace_id=UUID('00000000-0000-4000-8000-000000000003'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000003'),+ ])+# ---+# name: test_prompt_with_llm_and_async_lambda'''{"lc": 1,@@ -15704,11 +3757,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }+ "data": "PromptInput"},{"id": 1,@@ -15726,436 +3775,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -16205,16 +3825,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -16232,436 +3843,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -16689,16 +3871,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -16716,436 +3889,7 @@{"id": 2,"type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "ChatPromptTemplateOutput"}],"edges": [@@ -17160,876 +3904,339 @@]}},- "middle": [],+ "middle": [+ {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "repr": "FakeListLLM(responses=['foo', 'bar'])",+ "name": "FakeListLLM",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListLLMInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListLLMOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ ],"last": {"lc": 1,"type": "not_implemented","id": ["langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"+ "runnables",+ "base",+ "RunnableLambda"],- "repr": "FakeListChatModel(responses=['foo'])",- "name": "FakeListChatModel",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]+ "repr": "RunnableLambda(afunc=passthrough)"+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "passthrough"+ }+ },+ {+ "id": 4,+ "type": "schema",+ "data": "passthrough_output"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ },+ {+ "source": 3,+ "target": 4+ },+ {+ "source": 2,+ "target": 3+ }+ ]+ }+ }+ '''+# ---+# name: test_prompt_with_llm_and_async_lambda.1+ list([+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'])", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'repr': 'RunnableLambda(afunc=passthrough)'}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'name': 'passthrough'}}, {'id': 4, 'type': 'schema', 'data': 'passthrough_output'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': 'foo'}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo', 'bar'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'])", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='passthrough', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'repr': 'RunnableLambda(afunc=passthrough)'}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': 'foo'}, outputs={'output': 'foo'}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ ])+# ---+# name: test_prompt_with_llm_parser+ '''+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "kwargs": {+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [],+ "template": "You are a nice assistant.",+ "template_format": "f-string",+ "partial_variables": {}},- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "id": {- "title": "Id",- "type": "string"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"+ {+ "source": 1,+ "target": 2}- },- "required": [- "messages"]}}}},{- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}},- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "name": {- "title": "Name",- "type": "string"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},- "id": {- "title": "Id",- "type": "string"+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"+ {+ "source": 1,+ "target": 2}- },- "required": [- "content",- "tool_call_id"]}}}}],+ "input_variables": [+ "question"+ ]+ },+ "name": "ChatPromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],"edges": [{"source": 0,@@ -18042,31 +4249,122 @@]}},- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [+ "middle": [{- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeStreamingListLLM"+ ],+ "repr": "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'])",+ "name": "FakeStreamingListLLM",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeStreamingListLLMInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeStreamingListLLM"+ ],+ "name": "FakeStreamingListLLM"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeStreamingListLLMOutput"}- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ ],+ "last": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "kwargs": {},+ "name": "CommaSeparatedListOutputParser",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "name": "CommaSeparatedListOutputParser"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain","prompts","chat","ChatPromptTemplate"@@ -18081,391 +4379,29 @@"id": ["langchain_core","language_models",- "fake_chat_models",- "FakeListChatModel"+ "fake",+ "FakeStreamingListLLM"],- "name": "FakeListChatModel"+ "name": "FakeStreamingListLLM"}},{"id": 3,- "type": "schema",+ "type": "runnable","data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }+ "name": "CommaSeparatedListOutputParser"}+ },+ {+ "id": 4,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput"}],"edges": [@@ -18473,25 +4409,35 @@"source": 0,"target": 1},- {- "source": 2,- "target": 3- },{"source": 1,"target": 2+ },+ {+ "source": 3,+ "target": 4+ },+ {+ "source": 2,+ "target": 3}]}}'''# ----# name: test_prompt_with_chat_model.2+# name: test_prompt_with_llm_parser.1list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 3, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': AIMessage(content='foo')}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'foo'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'])", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeStreamingListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeStreamingListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ['bear', 'dog', 'cat']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeStreamingListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['bear, dog, cat', 'tomato, lettuce, onion'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'])", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeStreamingListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeStreamingListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'bear, dog, cat', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': 'bear, dog, cat'}, outputs={'output': ['bear', 'dog', 'cat']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),])# ----# name: test_prompt_with_chat_model_and_parser+# name: test_prompt_with_llm_parser.2+ list([+ Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'], i=1)", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeStreamingListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeStreamingListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ['tomato', 'lettuce', 'onion']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeStreamingListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['bear, dog, cat', 'tomato, lettuce, onion'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 2}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'], i=1)", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeStreamingListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeStreamingListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'tomato, lettuce, onion', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': 'tomato, lettuce, onion'}, outputs={'output': ['tomato', 'lettuce', 'onion']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),+ Run(id=UUID('00000000-0000-4000-8000-000000000004'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'], i=1)", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeStreamingListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeStreamingListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your favorite color?'}, outputs={'output': ['bear', 'dog', 'cat']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000005'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'PromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'PromptInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': 'ChatPromptTemplateOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your favorite color?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your favorite color?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000004'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000004'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000004.20230101T000000000000Z00000000-0000-4000-8000-000000000005'), Run(id=UUID('00000000-0000-4000-8000-000000000006'), name='FakeStreamingListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['bear, dog, cat', 'tomato, lettuce, onion'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 2}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'], i=1)", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'FakeStreamingListLLMInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': 'FakeStreamingListLLMOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your favorite color?']}, outputs={'generations': [[{'text': 'bear, dog, cat', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000004'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000004'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000004.20230101T000000000000Z00000000-0000-4000-8000-000000000006'), Run(id=UUID('00000000-0000-4000-8000-000000000007'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserInput'}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': 'CommaSeparatedListOutputParserOutput'}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': 'bear, dog, cat'}, outputs={'output': ['bear', 'dog', 'cat']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000004'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000004'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000004.20230101T000000000000Z00000000-0000-4000-8000-000000000007')], trace_id=UUID('00000000-0000-4000-8000-000000000004'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000004'),+ ])+# ---+# name: test_router_runnable'''{"lc": 1,@@ -18508,48 +4454,262 @@"type": "constructor","id": ["langchain",- "prompts",- "chat",- "ChatPromptTemplate"+ "schema",+ "runnable",+ "RunnableParallel"],"kwargs": {- "messages": [- {+ "steps": {+ "key": {"lc": 1,- "type": "constructor",+ "type": "not_implemented","id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(...)"+ },+ "input": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableParallel"+ ],"kwargs": {- "prompt": {+ "steps": {+ "question": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(...)"+ }+ }+ },+ "name": "RunnableParallel<question>",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "Parallel<question>Input"+ },+ {+ "id": 1,+ "type": "schema",+ "data": "Parallel<question>Output"+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 2+ },+ {+ "source": 2,+ "target": 1+ }+ ]+ }+ }+ }+ },+ "name": "RunnableParallel<key,input>",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "Parallel<key,input>Input"+ },+ {+ "id": 1,+ "type": "schema",+ "data": "Parallel<key,input>Output"+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 2+ },+ {+ "source": 2,+ "target": 1+ },+ {+ "source": 0,+ "target": 3+ },+ {+ "source": 3,+ "target": 1+ }+ ]+ }+ },+ "middle": [],+ "last": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RouterRunnable"+ ],+ "kwargs": {+ "runnables": {+ "math": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {"lc": 1,"type": "constructor","id": ["langchain","prompts",- "prompt",- "PromptTemplate"+ "chat",+ "ChatPromptTemplate"],"kwargs": {- "input_variables": [],- "template": "You are a nice assistant.",- "template_format": "f-string",+ "input_variables": [+ "question"+ ],+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "You are a math genius. Answer the question: {question}",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ }+ }+ ],"partial_variables": {}},- "name": "PromptTemplate",+ "name": "ChatPromptTemplate","graph": {"nodes": [{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }+ "data": "PromptInput"},{"id": 1,@@ -18558,445 +4718,66 @@"id": ["langchain","prompts",- "prompt",- "PromptTemplate"+ "chat",+ "ChatPromptTemplate"],- "name": "PromptTemplate"+ "name": "ChatPromptTemplate"}},{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [],+ "last": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "repr": "FakeListLLM(responses=['4'])",+ "name": "FakeListLLM",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListLLMInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListLLMOutput"}],"edges": [@@ -19010,52 +4791,167 @@}]}- }+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"+ }+ },+ {+ "id": 3,+ "type": "schema",+ "data": "FakeListLLMOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 2,+ "target": 3+ },+ {+ "source": 1,+ "target": 2+ }+ ]}},- {+ "english": {"lc": 1,"type": "constructor","id": ["langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"+ "schema",+ "runnable",+ "RunnableSequence"],"kwargs": {- "prompt": {+ "first": {"lc": 1,"type": "constructor","id": ["langchain","prompts",- "prompt",- "PromptTemplate"+ "chat",+ "ChatPromptTemplate"],"kwargs": {"input_variables": ["question"],- "template": "{question}",- "template_format": "f-string",+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "You are an english major. Answer the question: {question}",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ }+ }+ }+ ],"partial_variables": {}},- "name": "PromptTemplate",+ "name": "ChatPromptTemplate","graph": {"nodes": [{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -19064,445 +4960,66 @@"id": ["langchain","prompts",- "prompt",- "PromptTemplate"+ "chat",+ "ChatPromptTemplate"],- "name": "PromptTemplate"+ "name": "ChatPromptTemplate"}},{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [],+ "last": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "repr": "FakeListLLM(responses=['2'])",+ "name": "FakeListLLM",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListLLMInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListLLMOutput"}],"edges": [@@ -19516,30 +5033,74 @@}]}- }+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"+ }+ },+ {+ "id": 3,+ "type": "schema",+ "data": "FakeListLLMOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 2,+ "target": 3+ },+ {+ "source": 1,+ "target": 2+ }+ ]}}- ],- "input_variables": [- "question"- ]+ }},- "name": "ChatPromptTemplate",+ "name": "RouterRunnable","graph": {"nodes": [{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "RouterRunnableInput"},{"id": 1,@@ -19547,446 +5108,17 @@"data": {"id": ["langchain",- "prompts",- "chat",- "ChatPromptTemplate"+ "schema",+ "runnable",+ "RouterRunnable"],- "name": "ChatPromptTemplate"+ "name": "RouterRunnable"}},{"id": 2,"type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "RouterRunnableOutput"}],"edges": [@@ -20001,1353 +5133,20 @@]}},- "middle": [- {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "repr": "FakeListChatModel(responses=['foo, bar'])",- "name": "FakeListChatModel",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- ],- "last": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "kwargs": {},- "name": "CommaSeparatedListOutputParser",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "name": "CommaSeparatedListOutputParser"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "Parallel<key,input>Input"},{"id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }+ "type": "schema",+ "data": "Parallel<key,input>Output"},{"id": 2,@@ -21355,11 +5154,11 @@"data": {"id": ["langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"+ "runnables",+ "base",+ "RunnableLambda"],- "name": "FakeListChatModel"+ "name": "RunnableLambda"}},{@@ -21367,21411 +5166,3108 @@"type": "runnable","data": {"id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"],- "name": "CommaSeparatedListOutputParser"+ "name": "RunnableLambda"}},{"id": 4,- "type": "schema",+ "type": "runnable","data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RouterRunnable"+ ],+ "name": "RouterRunnable"}+ },+ {+ "id": 5,+ "type": "schema",+ "data": "RouterRunnableOutput"}],"edges": [{"source": 0,+ "target": 2+ },+ {+ "source": 2,"target": 1},{- "source": 1,- "target": 2+ "source": 0,+ "target": 3},{"source": 3,- "target": 4+ "target": 1},{- "source": 2,- "target": 3+ "source": 4,+ "target": 5+ },+ {+ "source": 1,+ "target": 4}]}}'''# ----# name: test_prompt_with_chat_model_and_parser.1- list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo, bar'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ['foo', 'bar']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo, bar'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo, bar'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo, bar', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'foo, bar'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': AIMessage(content='foo, bar')}, outputs={'output': ['foo', 'bar']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),- ])-# ----# name: test_prompt_with_chat_model_async- '''- ChatPromptTemplate(input_variables=['question'], messages=[SystemMessagePromptTemplate(prompt=PromptTemplate(input_variables=[], template='You are a nice assistant.')), HumanMessagePromptTemplate(prompt=PromptTemplate(input_variables=['question'], template='{question}'))])- | FakeListChatModel(responses=['foo'])- '''-# ----# name: test_prompt_with_chat_model_async.1- '''- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [],- "template": "You are a nice assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- },- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "template": "{question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "input_variables": [- "question"- ]- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "middle": [],- "last": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "repr": "FakeListChatModel(responses=['foo'])",- "name": "FakeListChatModel",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 3,- "type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 2,- "target": 3- },- {- "source": 1,- "target": 2- }- ]- }- }- '''-# ----# name: test_prompt_with_chat_model_async.2- list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 3, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': AIMessage(content='foo')}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListChatModel', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo'], '_type': 'fake-list-chat-model', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'repr': "FakeListChatModel(responses=['foo'])", 'name': 'FakeListChatModel', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListChatModelInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake_chat_models', 'FakeListChatModel'], 'name': 'FakeListChatModel'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListChatModelOutput', 'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'ChatGeneration', 'message': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'AIMessage'], 'kwargs': {'content': 'foo'}}}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),- ])-# ----# name: test_prompt_with_llm- '''- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [],- "template": "You are a nice assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- },- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "template": "{question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "input_variables": [- "question"- ]- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "middle": [],- "last": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "repr": "FakeListLLM(responses=['foo', 'bar'])",- "name": "FakeListLLM",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }- },- {- "id": 3,- "type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 2,- "target": 3- },- {- "source": 1,- "target": 2- }- ]- }- }- '''-# ----# name: test_prompt_with_llm.1- list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'])", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 3, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': 'foo'}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo', 'bar'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'])", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),- ])-# ----# name: test_prompt_with_llm.2- list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'], i=1)", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 3, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': 'bar'}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo', 'bar'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 2}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'], i=1)", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'bar', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),- Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'], i=1)", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 3, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 2, 'target': 3}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your favorite color?'}, outputs={'output': 'foo'}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000004'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your favorite color?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your favorite color?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000003'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000003'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000003.20230101T000000000000Z00000000-0000-4000-8000-000000000004'), Run(id=UUID('00000000-0000-4000-8000-000000000005'), name='FakeListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo', 'bar'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 2}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'], i=1)", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your favorite color?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000003'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000003'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000003.20230101T000000000000Z00000000-0000-4000-8000-000000000005')], trace_id=UUID('00000000-0000-4000-8000-000000000003'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000003'),- ])-# ----# name: test_prompt_with_llm_and_async_lambda- '''- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [],- "template": "You are a nice assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- },- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "template": "{question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "input_variables": [- "question"- ]- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "middle": [- {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "repr": "FakeListLLM(responses=['foo', 'bar'])",- "name": "FakeListLLM",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- ],- "last": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(afunc=passthrough)"- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }- },- {- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "passthrough"- }- },- {- "id": 4,- "type": "schema",- "data": {- "title": "passthrough_output"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- },- {- "source": 3,- "target": 4- },- {- "source": 2,- "target": 3- }- ]- }- }- '''-# ----# name: test_prompt_with_llm_and_async_lambda.1- list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'])", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'repr': 'RunnableLambda(afunc=passthrough)'}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'name': 'passthrough'}}, {'id': 4, 'type': 'schema', 'data': {'title': 'passthrough_output'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': 'foo'}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['foo', 'bar'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'repr': "FakeListLLM(responses=['foo', 'bar'])", 'name': 'FakeListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeListLLM'], 'name': 'FakeListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'foo', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='passthrough', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'runnables', 'base', 'RunnableLambda'], 'repr': 'RunnableLambda(afunc=passthrough)'}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': 'foo'}, outputs={'output': 'foo'}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),- ])-# ----# name: test_prompt_with_llm_parser- '''- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [],- "template": "You are a nice assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- },- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "template": "{question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "input_variables": [- "question"- ]- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "middle": [- {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake",- "FakeStreamingListLLM"- ],- "repr": "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'])",- "name": "FakeStreamingListLLM",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeStreamingListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeStreamingListLLM"- ],- "name": "FakeStreamingListLLM"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeStreamingListLLMOutput",- "type": "string"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- ],- "last": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "kwargs": {},- "name": "CommaSeparatedListOutputParser",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "name": "CommaSeparatedListOutputParser"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeStreamingListLLM"- ],- "name": "FakeStreamingListLLM"- }- },- {- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "name": "CommaSeparatedListOutputParser"- }- },- {- "id": 4,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- },- {- "source": 3,- "target": 4- },- {- "source": 2,- "target": 3- }- ]- }- }- '''-# ----# name: test_prompt_with_llm_parser.1- list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'])", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ['bear', 'dog', 'cat']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeStreamingListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['bear, dog, cat', 'tomato, lettuce, onion'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 1}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'])", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'bear, dog, cat', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': 'bear, dog, cat'}, outputs={'output': ['bear', 'dog', 'cat']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),- ])-# ----# name: test_prompt_with_llm_parser.2- list([- Run(id=UUID('00000000-0000-4000-8000-000000000000'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'], i=1)", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ['tomato', 'lettuce', 'onion']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000001'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your name?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your name?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000001'), Run(id=UUID('00000000-0000-4000-8000-000000000002'), name='FakeStreamingListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['bear, dog, cat', 'tomato, lettuce, onion'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 2}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'], i=1)", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your name?']}, outputs={'generations': [[{'text': 'tomato, lettuce, onion', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000002'), Run(id=UUID('00000000-0000-4000-8000-000000000003'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': 'tomato, lettuce, onion'}, outputs={'output': ['tomato', 'lettuce', 'onion']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000000'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000.20230101T000000000000Z00000000-0000-4000-8000-000000000003')], trace_id=UUID('00000000-0000-4000-8000-000000000000'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000000'),- Run(id=UUID('00000000-0000-4000-8000-000000000004'), name='RunnableSequence', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='chain', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'runnable', 'RunnableSequence'], 'kwargs': {'first': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'middle': [{'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'], i=1)", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}], 'last': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, 'name': None}, 'name': 'RunnableSequence', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 3, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 4, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}, {'source': 3, 'target': 4}, {'source': 2, 'target': 3}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your favorite color?'}, outputs={'output': ['bear', 'dog', 'cat']}, reference_example_id=None, parent_run_id=None, tags=[], execution_order=None, child_execution_order=None, child_runs=[Run(id=UUID('00000000-0000-4000-8000-000000000005'), name='ChatPromptTemplate', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='prompt', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'kwargs': {'messages': [{'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'SystemMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': [], 'template': 'You are a nice assistant.', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}, {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'chat', 'HumanMessagePromptTemplate'], 'kwargs': {'prompt': {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'kwargs': {'input_variables': ['question'], 'template': '{question}', 'template_format': 'f-string', 'partial_variables': {}}, 'name': 'PromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'prompt', 'PromptTemplate'], 'name': 'PromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'PromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}}}], 'input_variables': ['question']}, 'name': 'ChatPromptTemplate', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'PromptInput', 'type': 'object', 'properties': {'question': {'title': 'Question', 'type': 'string'}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'prompts', 'chat', 'ChatPromptTemplate'], 'name': 'ChatPromptTemplate'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'ChatPromptTemplateOutput', 'anyOf': [{'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'question': 'What is your favorite color?'}, outputs={'output': ChatPromptValue(messages=[SystemMessage(content='You are a nice assistant.'), HumanMessage(content='What is your favorite color?')])}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000004'), tags=['seq:step:1'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000004'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000004.20230101T000000000000Z00000000-0000-4000-8000-000000000005'), Run(id=UUID('00000000-0000-4000-8000-000000000006'), name='FakeStreamingListLLM', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='llm', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={'invocation_params': {'responses': ['bear, dog, cat', 'tomato, lettuce, onion'], '_type': 'fake-list', 'stop': None}, 'options': {'stop': None}, 'batch_size': 2}, error=None, serialized={'lc': 1, 'type': 'not_implemented', 'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'repr': "FakeStreamingListLLM(responses=['bear, dog, cat', 'tomato, lettuce, onion'], i=1)", 'name': 'FakeStreamingListLLM', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/StringPromptValue'}, {'$ref': '#/definitions/ChatPromptValueConcrete'}, {'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}], 'definitions': {'StringPromptValue': {'title': 'StringPromptValue', 'description': 'String prompt value.', 'type': 'object', 'properties': {'text': {'title': 'Text', 'type': 'string'}, 'type': {'title': 'Type', 'default': 'StringPromptValue', 'enum': ['StringPromptValue'], 'type': 'string'}}, 'required': ['text']}, 'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}, 'ChatPromptValueConcrete': {'title': 'ChatPromptValueConcrete', 'description': 'Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.', 'type': 'object', 'properties': {'messages': {'title': 'Messages', 'type': 'array', 'items': {'anyOf': [{'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}]}}, 'type': {'title': 'Type', 'default': 'ChatPromptValueConcrete', 'enum': ['ChatPromptValueConcrete'], 'type': 'string'}}, 'required': ['messages']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain_core', 'language_models', 'fake', 'FakeStreamingListLLM'], 'name': 'FakeStreamingListLLM'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'FakeStreamingListLLMOutput', 'type': 'string'}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'prompts': ['System: You are a nice assistant.\nHuman: What is your favorite color?']}, outputs={'generations': [[{'text': 'bear, dog, cat', 'generation_info': None, 'type': 'Generation'}]], 'llm_output': None, 'run': None}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000004'), tags=['seq:step:2'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000004'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000004.20230101T000000000000Z00000000-0000-4000-8000-000000000006'), Run(id=UUID('00000000-0000-4000-8000-000000000007'), name='CommaSeparatedListOutputParser', start_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), run_type='parser', end_time=FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc), extra={}, error=None, serialized={'lc': 1, 'type': 'constructor', 'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'kwargs': {}, 'name': 'CommaSeparatedListOutputParser', 'graph': {'nodes': [{'id': 0, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserInput', 'anyOf': [{'type': 'string'}, {'$ref': '#/definitions/AIMessage'}, {'$ref': '#/definitions/HumanMessage'}, {'$ref': '#/definitions/ChatMessage'}, {'$ref': '#/definitions/SystemMessage'}, {'$ref': '#/definitions/FunctionMessage'}, {'$ref': '#/definitions/ToolMessage'}], 'definitions': {'AIMessage': {'title': 'AIMessage', 'description': 'Message from an AI.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'ai', 'enum': ['ai'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'HumanMessage': {'title': 'HumanMessage', 'description': 'Message from a human.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'human', 'enum': ['human'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'example': {'title': 'Example', 'default': False, 'type': 'boolean'}}, 'required': ['content']}, 'ChatMessage': {'title': 'ChatMessage', 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'chat', 'enum': ['chat'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'role': {'title': 'Role', 'type': 'string'}}, 'required': ['content', 'role']}, 'SystemMessage': {'title': 'SystemMessage', 'description': 'Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'system', 'enum': ['system'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content']}, 'FunctionMessage': {'title': 'FunctionMessage', 'description': 'Message for passing the result of executing a function back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'function', 'enum': ['function'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}}, 'required': ['content', 'name']}, 'ToolMessage': {'title': 'ToolMessage', 'description': 'Message for passing the result of executing a tool back to a model.', 'type': 'object', 'properties': {'content': {'title': 'Content', 'anyOf': [{'type': 'string'}, {'type': 'array', 'items': {'anyOf': [{'type': 'string'}, {'type': 'object'}]}}]}, 'additional_kwargs': {'title': 'Additional Kwargs', 'type': 'object'}, 'response_metadata': {'title': 'Response Metadata', 'type': 'object'}, 'type': {'title': 'Type', 'default': 'tool', 'enum': ['tool'], 'type': 'string'}, 'name': {'title': 'Name', 'type': 'string'}, 'id': {'title': 'Id', 'type': 'string'}, 'tool_call_id': {'title': 'Tool Call Id', 'type': 'string'}}, 'required': ['content', 'tool_call_id']}}}}, {'id': 1, 'type': 'runnable', 'data': {'id': ['langchain', 'output_parsers', 'list', 'CommaSeparatedListOutputParser'], 'name': 'CommaSeparatedListOutputParser'}}, {'id': 2, 'type': 'schema', 'data': {'title': 'CommaSeparatedListOutputParserOutput', 'type': 'array', 'items': {'type': 'string'}}}], 'edges': [{'source': 0, 'target': 1}, {'source': 1, 'target': 2}]}}, events=[{'name': 'start', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}, {'name': 'end', 'time': FakeDatetime(2023, 1, 1, 0, 0, tzinfo=datetime.timezone.utc)}], inputs={'input': 'bear, dog, cat'}, outputs={'output': ['bear', 'dog', 'cat']}, reference_example_id=None, parent_run_id=UUID('00000000-0000-4000-8000-000000000004'), tags=['seq:step:3'], execution_order=None, child_execution_order=None, child_runs=[], trace_id=UUID('00000000-0000-4000-8000-000000000004'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000004.20230101T000000000000Z00000000-0000-4000-8000-000000000007')], trace_id=UUID('00000000-0000-4000-8000-000000000004'), dotted_order='20230101T000000000000Z00000000-0000-4000-8000-000000000004'),- ])-# ----# name: test_router_runnable- '''- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableParallel"- ],- "kwargs": {- "steps": {- "key": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(...)"- },- "input": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableParallel"- ],- "kwargs": {- "steps": {- "question": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(...)"- }- }- },- "name": "RunnableParallel<question>",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnableParallel<question>Input",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<question>Output",- "type": "object",- "properties": {- "question": {- "title": "Question"- }- }- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- }- ],- "edges": [- {- "source": 0,- "target": 2- },- {- "source": 2,- "target": 1- }- ]- }- }- }- },- "name": "RunnableParallel<key,input>",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnableParallel<key,input>Input",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<key,input>Output",- "type": "object",- "properties": {- "key": {- "title": "Key"- },- "input": {- "title": "Input",- "type": "object"- }- }- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- }- ],- "edges": [- {- "source": 0,- "target": 2- },- {- "source": 2,- "target": 1- },- {- "source": 0,- "target": 3- },- {- "source": 3,- "target": 1- }- ]- }- },- "middle": [],- "last": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RouterRunnable"- ],- "kwargs": {- "runnables": {- "math": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "template": "You are a math genius. Answer the question: {question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "partial_variables": {}- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "middle": [],- "last": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "repr": "FakeListLLM(responses=['4'])",- "name": "FakeListLLM",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }- },- {- "id": 3,- "type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 2,- "target": 3- },- {- "source": 1,- "target": 2- }- ]- }- },- "english": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "template": "You are an english major. Answer the question: {question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "partial_variables": {}- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "middle": [],- "last": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "repr": "FakeListLLM(responses=['2'])",- "name": "FakeListLLM",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }- },- {- "id": 3,- "type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 2,- "target": 3- },- {- "source": 1,- "target": 2- }- ]- }- }- }- },- "name": "RouterRunnable",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RouterRunnableInput",- "$ref": "#/definitions/RouterInput",- "definitions": {- "RouterInput": {- "title": "RouterInput",- "type": "object",- "properties": {- "key": {- "title": "Key",- "type": "string"- },- "input": {- "title": "Input"- }- },- "required": [- "key",- "input"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "schema",- "runnable",- "RouterRunnable"- ],- "name": "RouterRunnable"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "RouterRunnableOutput"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnableParallel<key,input>Input",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<key,input>Output",- "type": "object",- "properties": {- "key": {- "title": "Key"- },- "input": {- "title": "Input",- "type": "object"- }- }- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 4,- "type": "runnable",- "data": {- "id": [- "langchain",- "schema",- "runnable",- "RouterRunnable"- ],- "name": "RouterRunnable"- }- },- {- "id": 5,- "type": "schema",- "data": {- "title": "RouterRunnableOutput"- }- }- ],- "edges": [- {- "source": 0,- "target": 2- },- {- "source": 2,- "target": 1- },- {- "source": 0,- "target": 3- },- {- "source": 3,- "target": 1- },- {- "source": 4,- "target": 5- },- {- "source": 1,- "target": 4- }- ]- }- }- '''-# ----# name: test_schemas- dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- '$ref': '#/definitions/StringPromptValue',- }),- dict({- '$ref': '#/definitions/ChatPromptValueConcrete',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'definitions': dict({- 'AIMessage': dict({- 'description': 'Message from an AI.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'ai',- 'enum': list([- 'ai',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'AIMessage',- 'type': 'object',- }),- 'ChatMessage': dict({- 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'role': dict({- 'title': 'Role',- 'type': 'string',- }),- 'type': dict({- 'default': 'chat',- 'enum': list([- 'chat',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'role',- ]),- 'title': 'ChatMessage',- 'type': 'object',- }),- 'ChatPromptValueConcrete': dict({- 'description': '''- Chat prompt value which explicitly lists out the message types it accepts.- For use in external schemas.- ''',- 'properties': dict({- 'messages': dict({- 'items': dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- }),- 'title': 'Messages',- 'type': 'array',- }),- 'type': dict({- 'default': 'ChatPromptValueConcrete',- 'enum': list([- 'ChatPromptValueConcrete',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'messages',- ]),- 'title': 'ChatPromptValueConcrete',- 'type': 'object',- }),- 'FunctionMessage': dict({- 'description': 'Message for passing the result of executing a function back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'function',- 'enum': list([- 'function',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'name',- ]),- 'title': 'FunctionMessage',- 'type': 'object',- }),- 'HumanMessage': dict({- 'description': 'Message from a human.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'human',- 'enum': list([- 'human',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'HumanMessage',- 'type': 'object',- }),- 'StringPromptValue': dict({- 'description': 'String prompt value.',- 'properties': dict({- 'text': dict({- 'title': 'Text',- 'type': 'string',- }),- 'type': dict({- 'default': 'StringPromptValue',- 'enum': list([- 'StringPromptValue',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'text',- ]),- 'title': 'StringPromptValue',- 'type': 'object',- }),- 'SystemMessage': dict({- 'description': '''- Message for priming AI behavior, usually passed in as the first of a sequence- of input messages.- ''',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'system',- 'enum': list([- 'system',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'SystemMessage',- 'type': 'object',- }),- 'ToolMessage': dict({- 'description': 'Message for passing the result of executing a tool back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'tool_call_id': dict({- 'title': 'Tool Call Id',- 'type': 'string',- }),- 'type': dict({- 'default': 'tool',- 'enum': list([- 'tool',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'tool_call_id',- ]),- 'title': 'ToolMessage',- 'type': 'object',- }),- }),- 'title': 'FakeListLLMInput',- })-# ----# name: test_schemas.1- dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- '$ref': '#/definitions/StringPromptValue',- }),- dict({- '$ref': '#/definitions/ChatPromptValueConcrete',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'definitions': dict({- 'AIMessage': dict({- 'description': 'Message from an AI.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'ai',- 'enum': list([- 'ai',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'AIMessage',- 'type': 'object',- }),- 'ChatMessage': dict({- 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'role': dict({- 'title': 'Role',- 'type': 'string',- }),- 'type': dict({- 'default': 'chat',- 'enum': list([- 'chat',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'role',- ]),- 'title': 'ChatMessage',- 'type': 'object',- }),- 'ChatPromptValueConcrete': dict({- 'description': '''- Chat prompt value which explicitly lists out the message types it accepts.- For use in external schemas.- ''',- 'properties': dict({- 'messages': dict({- 'items': dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- }),- 'title': 'Messages',- 'type': 'array',- }),- 'type': dict({- 'default': 'ChatPromptValueConcrete',- 'enum': list([- 'ChatPromptValueConcrete',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'messages',- ]),- 'title': 'ChatPromptValueConcrete',- 'type': 'object',- }),- 'FunctionMessage': dict({- 'description': 'Message for passing the result of executing a function back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'function',- 'enum': list([- 'function',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'name',- ]),- 'title': 'FunctionMessage',- 'type': 'object',- }),- 'HumanMessage': dict({- 'description': 'Message from a human.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'human',- 'enum': list([- 'human',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'HumanMessage',- 'type': 'object',- }),- 'StringPromptValue': dict({- 'description': 'String prompt value.',- 'properties': dict({- 'text': dict({- 'title': 'Text',- 'type': 'string',- }),- 'type': dict({- 'default': 'StringPromptValue',- 'enum': list([- 'StringPromptValue',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'text',- ]),- 'title': 'StringPromptValue',- 'type': 'object',- }),- 'SystemMessage': dict({- 'description': '''- Message for priming AI behavior, usually passed in as the first of a sequence- of input messages.- ''',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'system',- 'enum': list([- 'system',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'SystemMessage',- 'type': 'object',- }),- 'ToolMessage': dict({- 'description': 'Message for passing the result of executing a tool back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'tool_call_id': dict({- 'title': 'Tool Call Id',- 'type': 'string',- }),- 'type': dict({- 'default': 'tool',- 'enum': list([- 'tool',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'tool_call_id',- ]),- 'title': 'ToolMessage',- 'type': 'object',- }),- }),- 'title': 'FakeListChatModelInput',- })-# ----# name: test_schemas.2- dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- 'definitions': dict({- 'AIMessage': dict({- 'description': 'Message from an AI.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'ai',- 'enum': list([- 'ai',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'AIMessage',- 'type': 'object',- }),- 'ChatMessage': dict({- 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'role': dict({- 'title': 'Role',- 'type': 'string',- }),- 'type': dict({- 'default': 'chat',- 'enum': list([- 'chat',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'role',- ]),- 'title': 'ChatMessage',- 'type': 'object',- }),- 'FunctionMessage': dict({- 'description': 'Message for passing the result of executing a function back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'function',- 'enum': list([- 'function',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'name',- ]),- 'title': 'FunctionMessage',- 'type': 'object',- }),- 'HumanMessage': dict({- 'description': 'Message from a human.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'human',- 'enum': list([- 'human',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'HumanMessage',- 'type': 'object',- }),- 'SystemMessage': dict({- 'description': '''- Message for priming AI behavior, usually passed in as the first of a sequence- of input messages.- ''',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'system',- 'enum': list([- 'system',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'SystemMessage',- 'type': 'object',- }),- 'ToolMessage': dict({- 'description': 'Message for passing the result of executing a tool back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'tool_call_id': dict({- 'title': 'Tool Call Id',- 'type': 'string',- }),- 'type': dict({- 'default': 'tool',- 'enum': list([- 'tool',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'tool_call_id',- ]),- 'title': 'ToolMessage',- 'type': 'object',- }),- }),- 'title': 'FakeListChatModelOutput',- })-# ----# name: test_schemas.3- dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/StringPromptValue',- }),- dict({- '$ref': '#/definitions/ChatPromptValueConcrete',- }),- ]),- 'definitions': dict({- 'AIMessage': dict({- 'description': 'Message from an AI.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'ai',- 'enum': list([- 'ai',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'AIMessage',- 'type': 'object',- }),- 'ChatMessage': dict({- 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'role': dict({- 'title': 'Role',- 'type': 'string',- }),- 'type': dict({- 'default': 'chat',- 'enum': list([- 'chat',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'role',- ]),- 'title': 'ChatMessage',- 'type': 'object',- }),- 'ChatPromptValueConcrete': dict({- 'description': '''- Chat prompt value which explicitly lists out the message types it accepts.- For use in external schemas.- ''',- 'properties': dict({- 'messages': dict({- 'items': dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- }),- 'title': 'Messages',- 'type': 'array',- }),- 'type': dict({- 'default': 'ChatPromptValueConcrete',- 'enum': list([- 'ChatPromptValueConcrete',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'messages',- ]),- 'title': 'ChatPromptValueConcrete',- 'type': 'object',- }),- 'FunctionMessage': dict({- 'description': 'Message for passing the result of executing a function back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'function',- 'enum': list([- 'function',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'name',- ]),- 'title': 'FunctionMessage',- 'type': 'object',- }),- 'HumanMessage': dict({- 'description': 'Message from a human.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'human',- 'enum': list([- 'human',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'HumanMessage',- 'type': 'object',- }),- 'StringPromptValue': dict({- 'description': 'String prompt value.',- 'properties': dict({- 'text': dict({- 'title': 'Text',- 'type': 'string',- }),- 'type': dict({- 'default': 'StringPromptValue',- 'enum': list([- 'StringPromptValue',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'text',- ]),- 'title': 'StringPromptValue',- 'type': 'object',- }),- 'SystemMessage': dict({- 'description': '''- Message for priming AI behavior, usually passed in as the first of a sequence- of input messages.- ''',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'system',- 'enum': list([- 'system',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'SystemMessage',- 'type': 'object',- }),- 'ToolMessage': dict({- 'description': 'Message for passing the result of executing a tool back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'tool_call_id': dict({- 'title': 'Tool Call Id',- 'type': 'string',- }),- 'type': dict({- 'default': 'tool',- 'enum': list([- 'tool',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'tool_call_id',- ]),- 'title': 'ToolMessage',- 'type': 'object',- }),- }),- 'title': 'ChatPromptTemplateOutput',- })-# ----# name: test_schemas.4- dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/StringPromptValue',- }),- dict({- '$ref': '#/definitions/ChatPromptValueConcrete',- }),- ]),- 'definitions': dict({- 'AIMessage': dict({- 'description': 'Message from an AI.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'ai',- 'enum': list([- 'ai',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'AIMessage',- 'type': 'object',- }),- 'ChatMessage': dict({- 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'role': dict({- 'title': 'Role',- 'type': 'string',- }),- 'type': dict({- 'default': 'chat',- 'enum': list([- 'chat',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'role',- ]),- 'title': 'ChatMessage',- 'type': 'object',- }),- 'ChatPromptValueConcrete': dict({- 'description': '''- Chat prompt value which explicitly lists out the message types it accepts.- For use in external schemas.- ''',- 'properties': dict({- 'messages': dict({- 'items': dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- }),- 'title': 'Messages',- 'type': 'array',- }),- 'type': dict({- 'default': 'ChatPromptValueConcrete',- 'enum': list([- 'ChatPromptValueConcrete',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'messages',- ]),- 'title': 'ChatPromptValueConcrete',- 'type': 'object',- }),- 'FunctionMessage': dict({- 'description': 'Message for passing the result of executing a function back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'function',- 'enum': list([- 'function',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'name',- ]),- 'title': 'FunctionMessage',- 'type': 'object',- }),- 'HumanMessage': dict({- 'description': 'Message from a human.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'human',- 'enum': list([- 'human',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'HumanMessage',- 'type': 'object',- }),- 'StringPromptValue': dict({- 'description': 'String prompt value.',- 'properties': dict({- 'text': dict({- 'title': 'Text',- 'type': 'string',- }),- 'type': dict({- 'default': 'StringPromptValue',- 'enum': list([- 'StringPromptValue',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'text',- ]),- 'title': 'StringPromptValue',- 'type': 'object',- }),- 'SystemMessage': dict({- 'description': '''- Message for priming AI behavior, usually passed in as the first of a sequence- of input messages.- ''',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'system',- 'enum': list([- 'system',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'SystemMessage',- 'type': 'object',- }),- 'ToolMessage': dict({- 'description': 'Message for passing the result of executing a tool back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'tool_call_id': dict({- 'title': 'Tool Call Id',- 'type': 'string',- }),- 'type': dict({- 'default': 'tool',- 'enum': list([- 'tool',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'tool_call_id',- ]),- 'title': 'ToolMessage',- 'type': 'object',- }),- }),- 'title': 'PromptTemplateOutput',- })-# ----# name: test_schemas.5- dict({- 'definitions': dict({- 'AIMessage': dict({- 'description': 'Message from an AI.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'ai',- 'enum': list([- 'ai',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'AIMessage',- 'type': 'object',- }),- 'ChatMessage': dict({- 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'role': dict({- 'title': 'Role',- 'type': 'string',- }),- 'type': dict({- 'default': 'chat',- 'enum': list([- 'chat',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'role',- ]),- 'title': 'ChatMessage',- 'type': 'object',- }),- 'ChatPromptValueConcrete': dict({- 'description': '''- Chat prompt value which explicitly lists out the message types it accepts.- For use in external schemas.- ''',- 'properties': dict({- 'messages': dict({- 'items': dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- }),- 'title': 'Messages',- 'type': 'array',- }),- 'type': dict({- 'default': 'ChatPromptValueConcrete',- 'enum': list([- 'ChatPromptValueConcrete',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'messages',- ]),- 'title': 'ChatPromptValueConcrete',- 'type': 'object',- }),- 'FunctionMessage': dict({- 'description': 'Message for passing the result of executing a function back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'function',- 'enum': list([- 'function',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'name',- ]),- 'title': 'FunctionMessage',- 'type': 'object',- }),- 'HumanMessage': dict({- 'description': 'Message from a human.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'human',- 'enum': list([- 'human',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'HumanMessage',- 'type': 'object',- }),- 'PromptTemplateOutput': dict({- 'anyOf': list([- dict({- '$ref': '#/definitions/StringPromptValue',- }),- dict({- '$ref': '#/definitions/ChatPromptValueConcrete',- }),- ]),- 'title': 'PromptTemplateOutput',- }),- 'StringPromptValue': dict({- 'description': 'String prompt value.',- 'properties': dict({- 'text': dict({- 'title': 'Text',- 'type': 'string',- }),- 'type': dict({- 'default': 'StringPromptValue',- 'enum': list([- 'StringPromptValue',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'text',- ]),- 'title': 'StringPromptValue',- 'type': 'object',- }),- 'SystemMessage': dict({- 'description': '''- Message for priming AI behavior, usually passed in as the first of a sequence- of input messages.- ''',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'system',- 'enum': list([- 'system',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'SystemMessage',- 'type': 'object',- }),- 'ToolMessage': dict({- 'description': 'Message for passing the result of executing a tool back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'tool_call_id': dict({- 'title': 'Tool Call Id',- 'type': 'string',- }),- 'type': dict({- 'default': 'tool',- 'enum': list([- 'tool',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'tool_call_id',- ]),- 'title': 'ToolMessage',- 'type': 'object',- }),- }),- 'items': dict({- '$ref': '#/definitions/PromptTemplateOutput',- }),- 'title': 'RunnableEach<PromptTemplate>Output',- 'type': 'array',- })-# ----# name: test_schemas.6- dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- '$ref': '#/definitions/AIMessage',- }),- dict({- '$ref': '#/definitions/HumanMessage',- }),- dict({- '$ref': '#/definitions/ChatMessage',- }),- dict({- '$ref': '#/definitions/SystemMessage',- }),- dict({- '$ref': '#/definitions/FunctionMessage',- }),- dict({- '$ref': '#/definitions/ToolMessage',- }),- ]),- 'definitions': dict({- 'AIMessage': dict({- 'description': 'Message from an AI.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'ai',- 'enum': list([- 'ai',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'AIMessage',- 'type': 'object',- }),- 'ChatMessage': dict({- 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'role': dict({- 'title': 'Role',- 'type': 'string',- }),- 'type': dict({- 'default': 'chat',- 'enum': list([- 'chat',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'role',- ]),- 'title': 'ChatMessage',- 'type': 'object',- }),- 'FunctionMessage': dict({- 'description': 'Message for passing the result of executing a function back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'function',- 'enum': list([- 'function',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'name',- ]),- 'title': 'FunctionMessage',- 'type': 'object',- }),- 'HumanMessage': dict({- 'description': 'Message from a human.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'example': dict({- 'default': False,- 'title': 'Example',- 'type': 'boolean',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'human',- 'enum': list([- 'human',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'HumanMessage',- 'type': 'object',- }),- 'SystemMessage': dict({- 'description': '''- Message for priming AI behavior, usually passed in as the first of a sequence- of input messages.- ''',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'type': dict({- 'default': 'system',- 'enum': list([- 'system',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- ]),- 'title': 'SystemMessage',- 'type': 'object',- }),- 'ToolMessage': dict({- 'description': 'Message for passing the result of executing a tool back to a model.',- 'properties': dict({- 'additional_kwargs': dict({- 'title': 'Additional Kwargs',- 'type': 'object',- }),- 'content': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'items': dict({- 'anyOf': list([- dict({- 'type': 'string',- }),- dict({- 'type': 'object',- }),- ]),- }),- 'type': 'array',- }),- ]),- 'title': 'Content',- }),- 'id': dict({- 'title': 'Id',- 'type': 'string',- }),- 'name': dict({- 'title': 'Name',- 'type': 'string',- }),- 'response_metadata': dict({- 'title': 'Response Metadata',- 'type': 'object',- }),- 'tool_call_id': dict({- 'title': 'Tool Call Id',- 'type': 'string',- }),- 'type': dict({- 'default': 'tool',- 'enum': list([- 'tool',- ]),- 'title': 'Type',- 'type': 'string',- }),- }),- 'required': list([- 'content',- 'tool_call_id',- ]),- 'title': 'ToolMessage',- 'type': 'object',- }),- }),- 'title': 'CommaSeparatedListOutputParserInput',- })-# ----# name: test_seq_dict_prompt_llm- '''- {- question: RunnablePassthrough()- | RunnableLambda(...),- documents: RunnableLambda(...)- | FakeRetriever(),- just_to_test_lambda: RunnableLambda(...)- }- | ChatPromptTemplate(input_variables=['documents', 'question'], messages=[SystemMessagePromptTemplate(prompt=PromptTemplate(input_variables=[], template='You are a nice assistant.')), HumanMessagePromptTemplate(prompt=PromptTemplate(input_variables=['documents', 'question'], template='Context:\n{documents}\n\nQuestion:\n{question}'))])- | FakeListChatModel(responses=['foo, bar'])- | CommaSeparatedListOutputParser()- '''-# ----# name: test_seq_dict_prompt_llm.1- '''- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableParallel"- ],- "kwargs": {- "steps": {- "question": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnablePassthrough"- ],- "kwargs": {- "func": null,- "afunc": null,- "input_type": null- },- "name": "RunnablePassthrough",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnablePassthroughInput"- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "schema",- "runnable",- "RunnablePassthrough"- ],- "name": "RunnablePassthrough"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "RunnablePassthroughOutput"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "middle": [],- "last": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(...)"- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnablePassthroughInput"- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "schema",- "runnable",- "RunnablePassthrough"- ],- "name": "RunnablePassthrough"- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 3,- "type": "schema",- "data": {- "title": "RunnableLambdaOutput"- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 2,- "target": 3- },- {- "source": 1,- "target": 2- }- ]- }- },- "documents": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(...)"- },- "middle": [],- "last": {- "lc": 1,- "type": "not_implemented",- "id": [- "tests",- "unit_tests",- "runnables",- "test_runnable",- "FakeRetriever"- ],- "repr": "FakeRetriever()",- "name": "FakeRetriever",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeRetrieverInput",- "type": "string"- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "tests",- "unit_tests",- "runnables",- "test_runnable",- "FakeRetriever"- ],- "name": "FakeRetriever"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeRetrieverOutput",- "type": "array",- "items": {- "$ref": "#/definitions/Document"- },- "definitions": {- "Document": {- "title": "Document",- "description": "Class for storing a piece of text and associated metadata.",- "type": "object",- "properties": {- "page_content": {- "title": "Page Content",- "type": "string"- },- "metadata": {- "title": "Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "Document",- "enum": [- "Document"- ],- "type": "string"- }- },- "required": [- "page_content"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnableLambdaInput"- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "tests",- "unit_tests",- "runnables",- "test_runnable",- "FakeRetriever"- ],- "name": "FakeRetriever"- }- },- {- "id": 3,- "type": "schema",- "data": {- "title": "FakeRetrieverOutput",- "type": "array",- "items": {- "$ref": "#/definitions/Document"- },- "definitions": {- "Document": {- "title": "Document",- "description": "Class for storing a piece of text and associated metadata.",- "type": "object",- "properties": {- "page_content": {- "title": "Page Content",- "type": "string"- },- "metadata": {- "title": "Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "Document",- "enum": [- "Document"- ],- "type": "string"- }- },- "required": [- "page_content"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 2,- "target": 3- },- {- "source": 1,- "target": 2- }- ]- }- },- "just_to_test_lambda": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(...)"- }- }- },- "name": "RunnableParallel<question,documents,just_to_test_lambda>",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnableParallel<question,documents,just_to_test_lambda>Input",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<question,documents,just_to_test_lambda>Output",- "type": "object",- "properties": {- "question": {- "title": "Question"- },- "documents": {- "title": "Documents",- "type": "array",- "items": {- "$ref": "#/definitions/Document"- }- },- "just_to_test_lambda": {- "title": "Just To Test Lambda"- }- },- "definitions": {- "Document": {- "title": "Document",- "description": "Class for storing a piece of text and associated metadata.",- "type": "object",- "properties": {- "page_content": {- "title": "Page Content",- "type": "string"- },- "metadata": {- "title": "Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "Document",- "enum": [- "Document"- ],- "type": "string"- }- },- "required": [- "page_content"- ]- }- }- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain",- "schema",- "runnable",- "RunnablePassthrough"- ],- "name": "RunnablePassthrough"- }- },- {- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 4,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 5,- "type": "runnable",- "data": {- "id": [- "tests",- "unit_tests",- "runnables",- "test_runnable",- "FakeRetriever"- ],- "name": "FakeRetriever"- }- },- {- "id": 6,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- }- ],- "edges": [- {- "source": 2,- "target": 3- },- {- "source": 0,- "target": 2- },- {- "source": 3,- "target": 1- },- {- "source": 4,- "target": 5- },- {- "source": 0,- "target": 4- },- {- "source": 5,- "target": 1- },- {- "source": 0,- "target": 6- },- {- "source": 6,- "target": 1- }- ]- }- },- "middle": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [],- "template": "You are a nice assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- },- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "documents",- "question"- ],- "template": "Context:\n{documents}\n\nQuestion:\n{question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "documents": {- "title": "Documents",- "type": "string"- },- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "input_variables": [- "documents",- "question"- ]- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "documents": {- "title": "Documents",- "type": "string"- },- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "repr": "FakeListChatModel(responses=['foo, bar'])",- "name": "FakeListChatModel",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- ],- "last": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "kwargs": {},- "name": "CommaSeparatedListOutputParser",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "name": "CommaSeparatedListOutputParser"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "name": null- },- "name": "RunnableSequence",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnableParallel<question,documents,just_to_test_lambda>Input",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<question,documents,just_to_test_lambda>Output",- "type": "object",- "properties": {- "question": {- "title": "Question"- },- "documents": {- "title": "Documents",- "type": "array",- "items": {- "$ref": "#/definitions/Document"- }- },- "just_to_test_lambda": {- "title": "Just To Test Lambda"- }- },- "definitions": {- "Document": {- "title": "Document",- "description": "Class for storing a piece of text and associated metadata.",- "type": "object",- "properties": {- "page_content": {- "title": "Page Content",- "type": "string"- },- "metadata": {- "title": "Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "Document",- "enum": [- "Document"- ],- "type": "string"- }- },- "required": [- "page_content"- ]- }- }- }- },- {- "id": 2,- "type": "runnable",- "data": {- "id": [- "langchain",- "schema",- "runnable",- "RunnablePassthrough"- ],- "name": "RunnablePassthrough"- }- },- {- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 4,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 5,- "type": "runnable",- "data": {- "id": [- "tests",- "unit_tests",- "runnables",- "test_runnable",- "FakeRetriever"- ],- "name": "FakeRetriever"- }- },- {- "id": 6,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "name": "RunnableLambda"- }- },- {- "id": 7,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 8,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 9,- "type": "runnable",- "data": {- "id": [- "langchain",- "output_parsers",- "list",- "CommaSeparatedListOutputParser"- ],- "name": "CommaSeparatedListOutputParser"- }- },- {- "id": 10,- "type": "schema",- "data": {- "title": "CommaSeparatedListOutputParserOutput",- "type": "array",- "items": {- "type": "string"- }- }- }- ],- "edges": [- {- "source": 2,- "target": 3- },- {- "source": 0,- "target": 2- },- {- "source": 3,- "target": 1- },- {- "source": 4,- "target": 5- },- {- "source": 0,- "target": 4- },- {- "source": 5,- "target": 1- },- {- "source": 0,- "target": 6- },- {- "source": 6,- "target": 1- },- {- "source": 1,- "target": 7- },- {- "source": 7,- "target": 8- },- {- "source": 9,- "target": 10- },- {- "source": 8,- "target": 9- }- ]- }- }- '''-# ----# name: test_seq_prompt_dict- '''- ChatPromptTemplate(input_variables=['question'], messages=[SystemMessagePromptTemplate(prompt=PromptTemplate(input_variables=[], template='You are a nice assistant.')), HumanMessagePromptTemplate(prompt=PromptTemplate(input_variables=['question'], template='{question}'))])- | RunnableLambda(...)- | {- chat: FakeListChatModel(responses=["i'm a chatbot"]),- llm: FakeListLLM(responses=["i'm a textbot"])- }- '''-# ----# name: test_seq_prompt_dict.1- '''- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [],- "template": "You are a nice assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- },- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "HumanMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [- "question"- ],- "template": "{question}",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "input_variables": [- "question"- ]- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- },- "middle": [- {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(...)"- }- ],- "last": {+# name: test_schemas+ dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ '$ref': '#/definitions/StringPromptValue',+ }),+ dict({+ '$ref': '#/definitions/ChatPromptValueConcrete',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'definitions': dict({+ 'AIMessage': dict({+ 'description': 'Message from an AI.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'ai',+ 'enum': list([+ 'ai',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'AIMessage',+ 'type': 'object',+ }),+ 'ChatMessage': dict({+ 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'role': dict({+ 'title': 'Role',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'chat',+ 'enum': list([+ 'chat',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'role',+ ]),+ 'title': 'ChatMessage',+ 'type': 'object',+ }),+ 'ChatPromptValueConcrete': dict({+ 'description': '''+ Chat prompt value which explicitly lists out the message types it accepts.+ For use in external schemas.+ ''',+ 'properties': dict({+ 'messages': dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ }),+ 'title': 'Messages',+ 'type': 'array',+ }),+ 'type': dict({+ 'default': 'ChatPromptValueConcrete',+ 'enum': list([+ 'ChatPromptValueConcrete',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'messages',+ ]),+ 'title': 'ChatPromptValueConcrete',+ 'type': 'object',+ }),+ 'FunctionMessage': dict({+ 'description': 'Message for passing the result of executing a function back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'function',+ 'enum': list([+ 'function',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'name',+ ]),+ 'title': 'FunctionMessage',+ 'type': 'object',+ }),+ 'HumanMessage': dict({+ 'description': 'Message from a human.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'human',+ 'enum': list([+ 'human',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'HumanMessage',+ 'type': 'object',+ }),+ 'StringPromptValue': dict({+ 'description': 'String prompt value.',+ 'properties': dict({+ 'text': dict({+ 'title': 'Text',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'StringPromptValue',+ 'enum': list([+ 'StringPromptValue',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'text',+ ]),+ 'title': 'StringPromptValue',+ 'type': 'object',+ }),+ 'SystemMessage': dict({+ 'description': '''+ Message for priming AI behavior, usually passed in as the first of a sequence+ of input messages.+ ''',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'system',+ 'enum': list([+ 'system',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'SystemMessage',+ 'type': 'object',+ }),+ 'ToolMessage': dict({+ 'description': 'Message for passing the result of executing a tool back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'tool_call_id': dict({+ 'title': 'Tool Call Id',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'tool',+ 'enum': list([+ 'tool',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'tool_call_id',+ ]),+ 'title': 'ToolMessage',+ 'type': 'object',+ }),+ }),+ 'title': 'FakeListLLMInput',+ })+# ---+# name: test_schemas.1+ dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ '$ref': '#/definitions/StringPromptValue',+ }),+ dict({+ '$ref': '#/definitions/ChatPromptValueConcrete',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'definitions': dict({+ 'AIMessage': dict({+ 'description': 'Message from an AI.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'ai',+ 'enum': list([+ 'ai',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'AIMessage',+ 'type': 'object',+ }),+ 'ChatMessage': dict({+ 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'role': dict({+ 'title': 'Role',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'chat',+ 'enum': list([+ 'chat',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'role',+ ]),+ 'title': 'ChatMessage',+ 'type': 'object',+ }),+ 'ChatPromptValueConcrete': dict({+ 'description': '''+ Chat prompt value which explicitly lists out the message types it accepts.+ For use in external schemas.+ ''',+ 'properties': dict({+ 'messages': dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ }),+ 'title': 'Messages',+ 'type': 'array',+ }),+ 'type': dict({+ 'default': 'ChatPromptValueConcrete',+ 'enum': list([+ 'ChatPromptValueConcrete',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'messages',+ ]),+ 'title': 'ChatPromptValueConcrete',+ 'type': 'object',+ }),+ 'FunctionMessage': dict({+ 'description': 'Message for passing the result of executing a function back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'function',+ 'enum': list([+ 'function',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'name',+ ]),+ 'title': 'FunctionMessage',+ 'type': 'object',+ }),+ 'HumanMessage': dict({+ 'description': 'Message from a human.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'human',+ 'enum': list([+ 'human',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'HumanMessage',+ 'type': 'object',+ }),+ 'StringPromptValue': dict({+ 'description': 'String prompt value.',+ 'properties': dict({+ 'text': dict({+ 'title': 'Text',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'StringPromptValue',+ 'enum': list([+ 'StringPromptValue',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'text',+ ]),+ 'title': 'StringPromptValue',+ 'type': 'object',+ }),+ 'SystemMessage': dict({+ 'description': '''+ Message for priming AI behavior, usually passed in as the first of a sequence+ of input messages.+ ''',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'system',+ 'enum': list([+ 'system',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'SystemMessage',+ 'type': 'object',+ }),+ 'ToolMessage': dict({+ 'description': 'Message for passing the result of executing a tool back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'tool_call_id': dict({+ 'title': 'Tool Call Id',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'tool',+ 'enum': list([+ 'tool',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'tool_call_id',+ ]),+ 'title': 'ToolMessage',+ 'type': 'object',+ }),+ }),+ 'title': 'FakeListChatModelInput',+ })+# ---+# name: test_schemas.2+ dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ 'definitions': dict({+ 'AIMessage': dict({+ 'description': 'Message from an AI.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'ai',+ 'enum': list([+ 'ai',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'AIMessage',+ 'type': 'object',+ }),+ 'ChatMessage': dict({+ 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'role': dict({+ 'title': 'Role',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'chat',+ 'enum': list([+ 'chat',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'role',+ ]),+ 'title': 'ChatMessage',+ 'type': 'object',+ }),+ 'FunctionMessage': dict({+ 'description': 'Message for passing the result of executing a function back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'function',+ 'enum': list([+ 'function',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'name',+ ]),+ 'title': 'FunctionMessage',+ 'type': 'object',+ }),+ 'HumanMessage': dict({+ 'description': 'Message from a human.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'human',+ 'enum': list([+ 'human',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'HumanMessage',+ 'type': 'object',+ }),+ 'SystemMessage': dict({+ 'description': '''+ Message for priming AI behavior, usually passed in as the first of a sequence+ of input messages.+ ''',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'system',+ 'enum': list([+ 'system',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'SystemMessage',+ 'type': 'object',+ }),+ 'ToolMessage': dict({+ 'description': 'Message for passing the result of executing a tool back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'tool_call_id': dict({+ 'title': 'Tool Call Id',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'tool',+ 'enum': list([+ 'tool',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'tool_call_id',+ ]),+ 'title': 'ToolMessage',+ 'type': 'object',+ }),+ }),+ 'title': 'FakeListChatModelOutput',+ })+# ---+# name: test_schemas.3+ dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/StringPromptValue',+ }),+ dict({+ '$ref': '#/definitions/ChatPromptValueConcrete',+ }),+ ]),+ 'definitions': dict({+ 'AIMessage': dict({+ 'description': 'Message from an AI.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'ai',+ 'enum': list([+ 'ai',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'AIMessage',+ 'type': 'object',+ }),+ 'ChatMessage': dict({+ 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'role': dict({+ 'title': 'Role',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'chat',+ 'enum': list([+ 'chat',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'role',+ ]),+ 'title': 'ChatMessage',+ 'type': 'object',+ }),+ 'ChatPromptValueConcrete': dict({+ 'description': '''+ Chat prompt value which explicitly lists out the message types it accepts.+ For use in external schemas.+ ''',+ 'properties': dict({+ 'messages': dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ }),+ 'title': 'Messages',+ 'type': 'array',+ }),+ 'type': dict({+ 'default': 'ChatPromptValueConcrete',+ 'enum': list([+ 'ChatPromptValueConcrete',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'messages',+ ]),+ 'title': 'ChatPromptValueConcrete',+ 'type': 'object',+ }),+ 'FunctionMessage': dict({+ 'description': 'Message for passing the result of executing a function back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'function',+ 'enum': list([+ 'function',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'name',+ ]),+ 'title': 'FunctionMessage',+ 'type': 'object',+ }),+ 'HumanMessage': dict({+ 'description': 'Message from a human.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'human',+ 'enum': list([+ 'human',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'HumanMessage',+ 'type': 'object',+ }),+ 'StringPromptValue': dict({+ 'description': 'String prompt value.',+ 'properties': dict({+ 'text': dict({+ 'title': 'Text',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'StringPromptValue',+ 'enum': list([+ 'StringPromptValue',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'text',+ ]),+ 'title': 'StringPromptValue',+ 'type': 'object',+ }),+ 'SystemMessage': dict({+ 'description': '''+ Message for priming AI behavior, usually passed in as the first of a sequence+ of input messages.+ ''',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'system',+ 'enum': list([+ 'system',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'SystemMessage',+ 'type': 'object',+ }),+ 'ToolMessage': dict({+ 'description': 'Message for passing the result of executing a tool back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'tool_call_id': dict({+ 'title': 'Tool Call Id',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'tool',+ 'enum': list([+ 'tool',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'tool_call_id',+ ]),+ 'title': 'ToolMessage',+ 'type': 'object',+ }),+ }),+ 'title': 'ChatPromptTemplateOutput',+ })+# ---+# name: test_schemas.4+ dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/StringPromptValue',+ }),+ dict({+ '$ref': '#/definitions/ChatPromptValueConcrete',+ }),+ ]),+ 'definitions': dict({+ 'AIMessage': dict({+ 'description': 'Message from an AI.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'ai',+ 'enum': list([+ 'ai',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'AIMessage',+ 'type': 'object',+ }),+ 'ChatMessage': dict({+ 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'role': dict({+ 'title': 'Role',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'chat',+ 'enum': list([+ 'chat',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'role',+ ]),+ 'title': 'ChatMessage',+ 'type': 'object',+ }),+ 'ChatPromptValueConcrete': dict({+ 'description': '''+ Chat prompt value which explicitly lists out the message types it accepts.+ For use in external schemas.+ ''',+ 'properties': dict({+ 'messages': dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ }),+ 'title': 'Messages',+ 'type': 'array',+ }),+ 'type': dict({+ 'default': 'ChatPromptValueConcrete',+ 'enum': list([+ 'ChatPromptValueConcrete',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'messages',+ ]),+ 'title': 'ChatPromptValueConcrete',+ 'type': 'object',+ }),+ 'FunctionMessage': dict({+ 'description': 'Message for passing the result of executing a function back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'function',+ 'enum': list([+ 'function',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'name',+ ]),+ 'title': 'FunctionMessage',+ 'type': 'object',+ }),+ 'HumanMessage': dict({+ 'description': 'Message from a human.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'human',+ 'enum': list([+ 'human',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'HumanMessage',+ 'type': 'object',+ }),+ 'StringPromptValue': dict({+ 'description': 'String prompt value.',+ 'properties': dict({+ 'text': dict({+ 'title': 'Text',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'StringPromptValue',+ 'enum': list([+ 'StringPromptValue',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'text',+ ]),+ 'title': 'StringPromptValue',+ 'type': 'object',+ }),+ 'SystemMessage': dict({+ 'description': '''+ Message for priming AI behavior, usually passed in as the first of a sequence+ of input messages.+ ''',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'system',+ 'enum': list([+ 'system',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'SystemMessage',+ 'type': 'object',+ }),+ 'ToolMessage': dict({+ 'description': 'Message for passing the result of executing a tool back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'tool_call_id': dict({+ 'title': 'Tool Call Id',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'tool',+ 'enum': list([+ 'tool',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'tool_call_id',+ ]),+ 'title': 'ToolMessage',+ 'type': 'object',+ }),+ }),+ 'title': 'PromptTemplateOutput',+ })+# ---+# name: test_schemas.5+ dict({+ 'definitions': dict({+ 'AIMessage': dict({+ 'description': 'Message from an AI.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'ai',+ 'enum': list([+ 'ai',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'AIMessage',+ 'type': 'object',+ }),+ 'ChatMessage': dict({+ 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'role': dict({+ 'title': 'Role',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'chat',+ 'enum': list([+ 'chat',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'role',+ ]),+ 'title': 'ChatMessage',+ 'type': 'object',+ }),+ 'ChatPromptValueConcrete': dict({+ 'description': '''+ Chat prompt value which explicitly lists out the message types it accepts.+ For use in external schemas.+ ''',+ 'properties': dict({+ 'messages': dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ }),+ 'title': 'Messages',+ 'type': 'array',+ }),+ 'type': dict({+ 'default': 'ChatPromptValueConcrete',+ 'enum': list([+ 'ChatPromptValueConcrete',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'messages',+ ]),+ 'title': 'ChatPromptValueConcrete',+ 'type': 'object',+ }),+ 'FunctionMessage': dict({+ 'description': 'Message for passing the result of executing a function back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'function',+ 'enum': list([+ 'function',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'name',+ ]),+ 'title': 'FunctionMessage',+ 'type': 'object',+ }),+ 'HumanMessage': dict({+ 'description': 'Message from a human.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'human',+ 'enum': list([+ 'human',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'HumanMessage',+ 'type': 'object',+ }),+ 'PromptTemplateOutput': dict({+ 'anyOf': list([+ dict({+ '$ref': '#/definitions/StringPromptValue',+ }),+ dict({+ '$ref': '#/definitions/ChatPromptValueConcrete',+ }),+ ]),+ 'title': 'PromptTemplateOutput',+ }),+ 'StringPromptValue': dict({+ 'description': 'String prompt value.',+ 'properties': dict({+ 'text': dict({+ 'title': 'Text',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'StringPromptValue',+ 'enum': list([+ 'StringPromptValue',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'text',+ ]),+ 'title': 'StringPromptValue',+ 'type': 'object',+ }),+ 'SystemMessage': dict({+ 'description': '''+ Message for priming AI behavior, usually passed in as the first of a sequence+ of input messages.+ ''',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'system',+ 'enum': list([+ 'system',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'SystemMessage',+ 'type': 'object',+ }),+ 'ToolMessage': dict({+ 'description': 'Message for passing the result of executing a tool back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'tool_call_id': dict({+ 'title': 'Tool Call Id',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'tool',+ 'enum': list([+ 'tool',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'tool_call_id',+ ]),+ 'title': 'ToolMessage',+ 'type': 'object',+ }),+ }),+ 'items': dict({+ '$ref': '#/definitions/PromptTemplateOutput',+ }),+ 'title': 'RunnableEach<PromptTemplate>Output',+ 'type': 'array',+ })+# ---+# name: test_schemas.6+ dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ '$ref': '#/definitions/AIMessage',+ }),+ dict({+ '$ref': '#/definitions/HumanMessage',+ }),+ dict({+ '$ref': '#/definitions/ChatMessage',+ }),+ dict({+ '$ref': '#/definitions/SystemMessage',+ }),+ dict({+ '$ref': '#/definitions/FunctionMessage',+ }),+ dict({+ '$ref': '#/definitions/ToolMessage',+ }),+ ]),+ 'definitions': dict({+ 'AIMessage': dict({+ 'description': 'Message from an AI.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'ai',+ 'enum': list([+ 'ai',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'AIMessage',+ 'type': 'object',+ }),+ 'ChatMessage': dict({+ 'description': 'Message that can be assigned an arbitrary speaker (i.e. role).',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'role': dict({+ 'title': 'Role',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'chat',+ 'enum': list([+ 'chat',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'role',+ ]),+ 'title': 'ChatMessage',+ 'type': 'object',+ }),+ 'FunctionMessage': dict({+ 'description': 'Message for passing the result of executing a function back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'function',+ 'enum': list([+ 'function',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'name',+ ]),+ 'title': 'FunctionMessage',+ 'type': 'object',+ }),+ 'HumanMessage': dict({+ 'description': 'Message from a human.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'example': dict({+ 'default': False,+ 'title': 'Example',+ 'type': 'boolean',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'human',+ 'enum': list([+ 'human',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'HumanMessage',+ 'type': 'object',+ }),+ 'SystemMessage': dict({+ 'description': '''+ Message for priming AI behavior, usually passed in as the first of a sequence+ of input messages.+ ''',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'type': dict({+ 'default': 'system',+ 'enum': list([+ 'system',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ ]),+ 'title': 'SystemMessage',+ 'type': 'object',+ }),+ 'ToolMessage': dict({+ 'description': 'Message for passing the result of executing a tool back to a model.',+ 'properties': dict({+ 'additional_kwargs': dict({+ 'title': 'Additional Kwargs',+ 'type': 'object',+ }),+ 'content': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'items': dict({+ 'anyOf': list([+ dict({+ 'type': 'string',+ }),+ dict({+ 'type': 'object',+ }),+ ]),+ }),+ 'type': 'array',+ }),+ ]),+ 'title': 'Content',+ }),+ 'id': dict({+ 'title': 'Id',+ 'type': 'string',+ }),+ 'name': dict({+ 'title': 'Name',+ 'type': 'string',+ }),+ 'response_metadata': dict({+ 'title': 'Response Metadata',+ 'type': 'object',+ }),+ 'tool_call_id': dict({+ 'title': 'Tool Call Id',+ 'type': 'string',+ }),+ 'type': dict({+ 'default': 'tool',+ 'enum': list([+ 'tool',+ ]),+ 'title': 'Type',+ 'type': 'string',+ }),+ }),+ 'required': list([+ 'content',+ 'tool_call_id',+ ]),+ 'title': 'ToolMessage',+ 'type': 'object',+ }),+ }),+ 'title': 'CommaSeparatedListOutputParserInput',+ })+# ---+# name: test_seq_dict_prompt_llm+ '''+ {+ question: RunnablePassthrough()+ | RunnableLambda(...),+ documents: RunnableLambda(...)+ | FakeRetriever(),+ just_to_test_lambda: RunnableLambda(...)+ }+ | ChatPromptTemplate(input_variables=['documents', 'question'], messages=[SystemMessagePromptTemplate(prompt=PromptTemplate(input_variables=[], template='You are a nice assistant.')), HumanMessagePromptTemplate(prompt=PromptTemplate(input_variables=['documents', 'question'], template='Context:\n{documents}\n\nQuestion:\n{question}'))])+ | FakeListChatModel(responses=['foo, bar'])+ | CommaSeparatedListOutputParser()+ '''+# ---+# name: test_seq_dict_prompt_llm.1+ '''+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {"lc": 1,"type": "constructor","id": [@@ -42782,873 +8278,253 @@],"kwargs": {"steps": {- "chat": {+ "question": {"lc": 1,- "type": "not_implemented",+ "type": "constructor","id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "repr": "FakeListChatModel(responses=[\"i'm a chatbot\"])",- "name": "FakeListChatModel",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnablePassthrough"+ ],+ "kwargs": {+ "func": null,+ "afunc": null,+ "input_type": null+ },+ "name": "RunnablePassthrough",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PassthroughInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnablePassthrough"+ ],+ "name": "RunnablePassthrough"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PassthroughOutput"}- }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [],+ "last": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(...)"+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PassthroughInput"},{"id": 1,"type": "runnable","data": {"id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"+ "langchain",+ "schema",+ "runnable",+ "RunnablePassthrough"],- "name": "FakeListChatModel"+ "name": "RunnablePassthrough"}},{"id": 2,- "type": "schema",+ "type": "runnable","data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]+ "name": "RunnableLambda"+ }+ },+ {+ "id": 3,+ "type": "schema",+ "data": "LambdaOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 2,+ "target": 3+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "documents": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(...)"+ },+ "middle": [],+ "last": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "tests",+ "unit_tests",+ "runnables",+ "test_runnable",+ "FakeRetriever"+ ],+ "repr": "FakeRetriever()",+ "name": "FakeRetriever",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeRetrieverInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "tests",+ "unit_tests",+ "runnables",+ "test_runnable",+ "FakeRetriever"+ ],+ "name": "FakeRetriever"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeRetrieverOutput"}+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "LambdaInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "tests",+ "unit_tests",+ "runnables",+ "test_runnable",+ "FakeRetriever"+ ],+ "name": "FakeRetriever"}+ },+ {+ "id": 3,+ "type": "schema",+ "data": "FakeRetrieverOutput"}],"edges": [@@ -43656,6 +8532,10 @@"source": 0,"target": 1},+ {+ "source": 2,+ "target": 3+ },{"source": 1,"target": 2@@ -43663,962 +8543,422 @@]}},- "llm": {+ "just_to_test_lambda": {"lc": 1,"type": "not_implemented","id": ["langchain_core",- "language_models",- "fake",- "FakeListLLM"+ "runnables",+ "base",+ "RunnableLambda"],- "repr": "FakeListLLM(responses=[\"i'm a textbot\"])",- "name": "FakeListLLM",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [+ "repr": "RunnableLambda(...)"+ }+ }+ },+ "name": "RunnableParallel<question,documents,just_to_test_lambda>",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "Parallel<question,documents,just_to_test_lambda>Input"+ },+ {+ "id": 1,+ "type": "schema",+ "data": "Parallel<question,documents,just_to_test_lambda>Output"+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnablePassthrough"+ ],+ "name": "RunnablePassthrough"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 4,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 5,+ "type": "runnable",+ "data": {+ "id": [+ "tests",+ "unit_tests",+ "runnables",+ "test_runnable",+ "FakeRetriever"+ ],+ "name": "FakeRetriever"+ }+ },+ {+ "id": 6,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ }+ ],+ "edges": [+ {+ "source": 2,+ "target": 3+ },+ {+ "source": 0,+ "target": 2+ },+ {+ "source": 3,+ "target": 1+ },+ {+ "source": 4,+ "target": 5+ },+ {+ "source": 0,+ "target": 4+ },+ {+ "source": 5,+ "target": 1+ },+ {+ "source": 0,+ "target": 6+ },+ {+ "source": 6,+ "target": 1+ }+ ]+ }+ },+ "middle": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "kwargs": {+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [],+ "template": "You are a nice assistant.",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },{- "type": "string"+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},{- "$ref": "#/definitions/StringPromptValue"- },+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"+ }+ ],+ "edges": [{- "$ref": "#/definitions/ChatPromptValueConcrete"+ "source": 0,+ "target": 1},{- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }+ "source": 1,+ "target": 2}+ ]+ }+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "documents",+ "question"],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]+ "template": "Context:\n{documents}\n\nQuestion:\n{question}",+ "template_format": "f-string",+ "partial_variables": {}+ },+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"],- "name": "FakeListLLM"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]}}- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]+ }+ }+ ],+ "input_variables": [+ "documents",+ "question"+ ]+ },+ "name": "ChatPromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "repr": "FakeListChatModel(responses=['foo, bar'])",+ "name": "FakeListChatModel",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListChatModelInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListChatModelOutput"}- }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]}- },- "name": "RunnableParallel<chat,llm>",+ }+ ],+ "last": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "kwargs": {},+ "name": "CommaSeparatedListOutputParser","graph": {"nodes": [{"id": 0,"type": "schema",- "data": {- "title": "RunnableParallel<chat,llm>Input",- "type": "object",- "properties": {}- }+ "data": "CommaSeparatedListOutputParserInput"},{"id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<chat,llm>Output",- "type": "object",- "properties": {- "chat": {- "title": "Chat",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- },- "llm": {- "title": "Llm",- "type": "string"- }- },- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }- },- {- "id": 2,"type": "runnable","data": {"id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"],- "name": "FakeListChatModel"+ "name": "CommaSeparatedListOutputParser"}},{- "id": 3,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "name": "FakeListLLM"- }+ "id": 2,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput"}],"edges": [{"source": 0,- "target": 2- },- {- "source": 2,"target": 1},{- "source": 0,- "target": 3- },- {- "source": 3,- "target": 1+ "source": 1,+ "target": 2}]}@@ -44629,21 +8969,83 @@"graph": {"nodes": [{- "id": 0,- "type": "schema",+ "id": 0,+ "type": "schema",+ "data": "Parallel<question,documents,just_to_test_lambda>Input"+ },+ {+ "id": 1,+ "type": "schema",+ "data": "Parallel<question,documents,just_to_test_lambda>Output"+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnablePassthrough"+ ],+ "name": "RunnablePassthrough"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 4,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 5,+ "type": "runnable","data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }+ "id": [+ "tests",+ "unit_tests",+ "runnables",+ "test_runnable",+ "FakeRetriever"+ ],+ "name": "FakeRetriever"}},{- "id": 1,+ "id": 6,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 7,"type": "runnable","data": {"id": [@@ -44656,417 +9058,532 @@}},{- "id": 2,+ "id": 8,"type": "runnable","data": {"id": ["langchain_core",- "runnables",- "base",- "RunnableLambda"+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"],- "name": "RunnableLambda"+ "name": "FakeListChatModel"}},{- "id": 3,- "type": "schema",+ "id": 9,+ "type": "runnable","data": {- "title": "RunnableParallel<chat,llm>Input",- "type": "object",- "properties": {}+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser"+ ],+ "name": "CommaSeparatedListOutputParser"}},{- "id": 4,+ "id": 10,"type": "schema",- "data": {- "title": "RunnableParallel<chat,llm>Output",- "type": "object",- "properties": {- "chat": {- "title": "Chat",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- },- "llm": {- "title": "Llm",- "type": "string"- }- },- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"+ "data": "CommaSeparatedListOutputParserOutput"+ }+ ],+ "edges": [+ {+ "source": 2,+ "target": 3+ },+ {+ "source": 0,+ "target": 2+ },+ {+ "source": 3,+ "target": 1+ },+ {+ "source": 4,+ "target": 5+ },+ {+ "source": 0,+ "target": 4+ },+ {+ "source": 5,+ "target": 1+ },+ {+ "source": 0,+ "target": 6+ },+ {+ "source": 6,+ "target": 1+ },+ {+ "source": 1,+ "target": 7+ },+ {+ "source": 7,+ "target": 8+ },+ {+ "source": 9,+ "target": 10+ },+ {+ "source": 8,+ "target": 9+ }+ ]+ }+ }+ '''+# ---+# name: test_seq_prompt_dict+ '''+ ChatPromptTemplate(input_variables=['question'], messages=[SystemMessagePromptTemplate(prompt=PromptTemplate(input_variables=[], template='You are a nice assistant.')), HumanMessagePromptTemplate(prompt=PromptTemplate(input_variables=['question'], template='{question}'))])+ | RunnableLambda(...)+ | {+ chat: FakeListChatModel(responses=["i'm a chatbot"]),+ llm: FakeListLLM(responses=["i'm a textbot"])+ }+ '''+# ---+# name: test_seq_prompt_dict.1+ '''+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "kwargs": {+ "messages": [+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "SystemMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [],+ "template": "You are a nice assistant.",+ "template_format": "f-string",+ "partial_variables": {}},- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [+ "name": "PromptTemplate",+ "graph": {+ "nodes": [{- "type": "string"+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},{- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"}- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"},{- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [+ ],+ "edges": [{- "type": "string"+ "source": 0,+ "target": 1},{- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }+ "source": 1,+ "target": 2}]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"+ }+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}},- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [+ "name": "PromptTemplate",+ "graph": {+ "nodes": [{- "type": "string"+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},{- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [+ "edges": [{- "type": "string"+ "source": 0,+ "target": 1},{- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }+ "source": 1,+ "target": 2}]+ }+ }+ }+ }+ ],+ "input_variables": [+ "question"+ ]+ },+ "name": "ChatPromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1+ },+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "middle": [+ {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(...)"+ }+ ],+ "last": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableParallel"+ ],+ "kwargs": {+ "steps": {+ "chat": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "repr": "FakeListChatModel(responses=[\"i'm a chatbot\"])",+ "name": "FakeListChatModel",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListChatModelInput"},- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }},- "response_metadata": {- "title": "Response Metadata",- "type": "object"+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListChatModelOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"+ {+ "source": 1,+ "target": 2+ }+ ]+ }+ },+ "llm": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "repr": "FakeListLLM(responses=[\"i'm a textbot\"])",+ "name": "FakeListLLM",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListLLMInput"},- "name": {- "title": "Name",- "type": "string"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"+ }},- "id": {- "title": "Id",- "type": "string"+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListLLMOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"+ {+ "source": 1,+ "target": 2}- },- "required": [- "content",- "tool_call_id"]}}}},+ "name": "RunnableParallel<chat,llm>",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "Parallel<chat,llm>Input"+ },+ {+ "id": 1,+ "type": "schema",+ "data": "Parallel<chat,llm>Output"+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake_chat_models",+ "FakeListChatModel"+ ],+ "name": "FakeListChatModel"+ }+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"+ }+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 2+ },+ {+ "source": 2,+ "target": 1+ },+ {+ "source": 0,+ "target": 3+ },+ {+ "source": 3,+ "target": 1+ }+ ]+ }+ },+ "name": null+ },+ "name": "RunnableSequence",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "name": "RunnableLambda"+ }+ },+ {+ "id": 3,+ "type": "schema",+ "data": "Parallel<chat,llm>Input"+ },+ {+ "id": 4,+ "type": "schema",+ "data": "Parallel<chat,llm>Output"+ },{"id": 5,"type": "runnable",@@ -45114,542 +9631,43 @@{"source": 3,"target": 6- },- {- "source": 6,- "target": 4- },- {- "source": 2,- "target": 3- }- ]- }- }- '''-# ----# name: test_seq_prompt_map- '''- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "schema",- "runnable",- "RunnableSequence"- ],- "kwargs": {- "first": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "kwargs": {- "messages": [- {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "chat",- "SystemMessagePromptTemplate"- ],- "kwargs": {- "prompt": {- "lc": 1,- "type": "constructor",- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "kwargs": {- "input_variables": [],- "template": "You are a nice assistant.",- "template_format": "f-string",- "partial_variables": {}- },- "name": "PromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "prompt",- "PromptTemplate"- ],- "name": "PromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- },+ },+ {+ "source": 6,+ "target": 4+ },+ {+ "source": 2,+ "target": 3+ }+ ]+ }+ }+ '''+# ---+# name: test_seq_prompt_map+ '''+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "schema",+ "runnable",+ "RunnableSequence"+ ],+ "kwargs": {+ "first": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "kwargs": {+ "messages": [{"lc": 1,"type": "constructor",@@ -45657,7 +9675,7 @@"langchain","prompts","chat",- "HumanMessagePromptTemplate"+ "SystemMessagePromptTemplate"],"kwargs": {"prompt": {@@ -45670,10 +9688,8 @@"PromptTemplate"],"kwargs": {- "input_variables": [- "question"- ],- "template": "{question}",+ "input_variables": [],+ "template": "You are a nice assistant.","template_format": "f-string","partial_variables": {}},@@ -45683,16 +9699,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -45710,922 +9717,123 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [{- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2- }- ]- }- }- }- }- ],- "input_variables": [- "question"- ]- },- "name": "ChatPromptTemplate",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain",- "prompts",- "chat",- "ChatPromptTemplate"- ],- "name": "ChatPromptTemplate"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"+ "source": 0,+ "target": 1},- "id": {- "title": "Id",- "type": "string"+ {+ "source": 1,+ "target": 2}- },- "required": [- "content",- "name"]+ }+ }+ }+ },+ {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "chat",+ "HumanMessagePromptTemplate"+ ],+ "kwargs": {+ "prompt": {+ "lc": 1,+ "type": "constructor",+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "kwargs": {+ "input_variables": [+ "question"+ ],+ "template": "{question}",+ "template_format": "f-string",+ "partial_variables": {}},- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"+ "name": "PromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"},- "id": {- "title": "Id",- "type": "string"+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "prompt",+ "PromptTemplate"+ ],+ "name": "PromptTemplate"+ }},- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"+ {+ "id": 2,+ "type": "schema",+ "data": "PromptTemplateOutput"}- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"+ {+ "source": 1,+ "target": 2}- },- "required": [- "messages"]}}}}],+ "input_variables": [+ "question"+ ]+ },+ "name": "ChatPromptTemplate",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput"+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "prompts",+ "chat",+ "ChatPromptTemplate"+ ],+ "name": "ChatPromptTemplate"+ }+ },+ {+ "id": 2,+ "type": "schema",+ "data": "ChatPromptTemplateOutput"+ }+ ],"edges": [{"source": 0,@@ -46688,464 +9896,7 @@{"id": 0,"type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListChatModelInput"},{"id": 1,@@ -47156,389 +9907,14 @@"language_models","fake_chat_models","FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }+ ],+ "name": "FakeListChatModel"}+ },+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListChatModelOutput"}],"edges": [@@ -47548,1366 +9924,28 @@},{"source": 1,- "target": 2- }- ]- }- },- "kwargs": {- "stop": [- "Thought:"- ]- },- "config": {},- "config_factories": [],- "custom_input_type": null,- "custom_output_type": null- },- "name": "FakeListChatModel",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "FakeListChatModelInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }- },- {- "id": 1,- "type": "runnable",- "data": {- "id": [- "langchain_core",- "language_models",- "fake_chat_models",- "FakeListChatModel"- ],- "name": "FakeListChatModel"- }- },- {- "id": 2,- "type": "schema",- "data": {- "title": "FakeListChatModelOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }+ "target": 2}- }- }- ],- "edges": [- {- "source": 0,- "target": 1- },- {- "source": 1,- "target": 2+ ]}- ]- }- },- "llm": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "language_models",- "fake",- "FakeListLLM"- ],- "repr": "FakeListLLM(responses=[\"i'm a textbot\"])",- "name": "FakeListLLM",+ },+ "kwargs": {+ "stop": [+ "Thought:"+ ]+ },+ "config": {},+ "config_factories": [],+ "custom_input_type": null,+ "custom_output_type": null+ },+ "name": "FakeListChatModel","graph": {"nodes": [{"id": 0,"type": "schema",- "data": {- "title": "FakeListLLMInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "FakeListChatModelInput"},{"id": 1,@@ -48916,19 +9954,16 @@"id": ["langchain_core","language_models",- "fake",- "FakeListLLM"+ "fake_chat_models",+ "FakeListChatModel"],- "name": "FakeListLLM"+ "name": "FakeListChatModel"}},{"id": 2,"type": "schema",- "data": {- "title": "FakeListLLMOutput",- "type": "string"- }+ "data": "FakeListChatModelOutput"}],"edges": [@@ -48940,427 +9975,84 @@"source": 1,"target": 2}- ]- }- },- "passthrough": {- "lc": 1,- "type": "not_implemented",- "id": [- "langchain_core",- "runnables",- "base",- "RunnableLambda"- ],- "repr": "RunnableLambda(...)"- }- }- },- "name": "RunnableParallel<chat,llm,passthrough>",- "graph": {- "nodes": [- {- "id": 0,- "type": "schema",- "data": {- "title": "RunnableParallel<chat,llm,passthrough>Input",- "type": "object",- "properties": {}- }- },- {- "id": 1,- "type": "schema",- "data": {- "title": "RunnableParallel<chat,llm,passthrough>Output",- "type": "object",- "properties": {- "chat": {- "title": "Chat",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- },- "llm": {- "title": "Llm",- "type": "string"- },- "passthrough": {- "title": "Passthrough"- }- },- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]+ ]+ }+ },+ "llm": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "repr": "FakeListLLM(responses=[\"i'm a textbot\"])",+ "name": "FakeListLLM",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "FakeListLLMInput"},- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "language_models",+ "fake",+ "FakeListLLM"+ ],+ "name": "FakeListLLM"+ }},- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]+ {+ "id": 2,+ "type": "schema",+ "data": "FakeListLLMOutput"+ }+ ],+ "edges": [+ {+ "source": 0,+ "target": 1},- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]+ {+ "source": 1,+ "target": 2}- }+ ]}},+ "passthrough": {+ "lc": 1,+ "type": "not_implemented",+ "id": [+ "langchain_core",+ "runnables",+ "base",+ "RunnableLambda"+ ],+ "repr": "RunnableLambda(...)"+ }+ }+ },+ "name": "RunnableParallel<chat,llm,passthrough>",+ "graph": {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "Parallel<chat,llm,passthrough>Input"+ },+ {+ "id": 1,+ "type": "schema",+ "data": "Parallel<chat,llm,passthrough>Output"+ },{"id": 2,"type": "runnable",@@ -49437,16 +10129,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "question": {- "title": "Question",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -49477,404 +10160,12 @@{"id": 3,"type": "schema",- "data": {- "title": "RunnableParallel<chat,llm,passthrough>Input",- "type": "object",- "properties": {}- }+ "data": "Parallel<chat,llm,passthrough>Input"},{"id": 4,"type": "schema",- "data": {- "title": "RunnableParallel<chat,llm,passthrough>Output",- "type": "object",- "properties": {- "chat": {- "title": "Chat",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- },- "llm": {- "title": "Llm",- "type": "string"- },- "passthrough": {- "title": "Passthrough"- }- },- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }+ "data": "Parallel<chat,llm,passthrough>Output"},{"id": 5,diff --git a/libs/core/tests/unit_tests/runnables/test_graph.py b/libs/core/tests/unit_tests/runnables/test_graph.pyindex 3bee036acc..f4a6a5ee2a 100644--- a/libs/core/tests/unit_tests/runnables/test_graph.py+++ b/libs/core/tests/unit_tests/runnables/test_graph.py@@ -33,6 +33,55 @@ def test_graph_sequence(snapshot: SnapshotAssertion) -> None:sequence = prompt | fake_llm | list_parsergraph = sequence.get_graph()assert graph.to_json() == {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput",+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": ["langchain", "prompts", "prompt", "PromptTemplate"],+ "name": "PromptTemplate",+ },+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": ["langchain_core", "language_models", "fake", "FakeListLLM"],+ "name": "FakeListLLM",+ },+ },+ {+ "id": 3,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser",+ ],+ "name": "CommaSeparatedListOutputParser",+ },+ },+ {+ "id": 4,+ "type": "schema",+ "data": "CommaSeparatedListOutputParserOutput",+ },+ ],+ "edges": [+ {"source": 0, "target": 1},+ {"source": 1, "target": 2},+ {"source": 3, "target": 4},+ {"source": 2, "target": 3},+ ],+ }+ assert graph.to_json(with_schemas=True) == {"nodes": [{"id": 0,@@ -76,9 +125,9 @@ def test_graph_sequence(snapshot: SnapshotAssertion) -> None:"id": 4,"type": "schema","data": {+ "items": {"type": "string"},"title": "CommaSeparatedListOutputParserOutput","type": "array",- "items": {"type": "string"},},},],@@ -115,7 +164,7 @@ def test_graph_sequence_map(snapshot: SnapshotAssertion) -> None:})graph = sequence.get_graph()- assert graph.to_json() == {+ assert graph.to_json(with_schemas=True) == {"nodes": [{"id": 0,@@ -484,5 +533,97 @@ def test_graph_sequence_map(snapshot: SnapshotAssertion) -> None:{"source": 2, "target": 3},],}+ assert graph.to_json() == {+ "nodes": [+ {+ "id": 0,+ "type": "schema",+ "data": "PromptInput",+ },+ {+ "id": 1,+ "type": "runnable",+ "data": {+ "id": ["langchain", "prompts", "prompt", "PromptTemplate"],+ "name": "PromptTemplate",+ },+ },+ {+ "id": 2,+ "type": "runnable",+ "data": {+ "id": ["langchain_core", "language_models", "fake", "FakeListLLM"],+ "name": "FakeListLLM",+ },+ },+ {+ "id": 3,+ "type": "schema",+ "data": "Parallel<as_list,as_str>Input",+ },+ {+ "id": 4,+ "type": "schema",+ "data": "Parallel<as_list,as_str>Output",+ },+ {+ "id": 5,+ "type": "runnable",+ "data": {+ "id": [+ "langchain",+ "output_parsers",+ "list",+ "CommaSeparatedListOutputParser",+ ],+ "name": "CommaSeparatedListOutputParser",+ },+ },+ {+ "id": 6,+ "type": "schema",+ "data": "conditional_str_parser_input",+ },+ {+ "id": 7,+ "type": "schema",+ "data": "conditional_str_parser_output",+ },+ {+ "id": 8,+ "type": "runnable",+ "data": {+ "id": ["langchain", "schema", "output_parser", "StrOutputParser"],+ "name": "StrOutputParser",+ },+ },+ {+ "id": 9,+ "type": "runnable",+ "data": {+ "id": [+ "langchain_core",+ "output_parsers",+ "xml",+ "XMLOutputParser",+ ],+ "name": "XMLOutputParser",+ },+ },+ ],+ "edges": [+ {"source": 0, "target": 1},+ {"source": 1, "target": 2},+ {"source": 3, "target": 5},+ {"source": 5, "target": 4},+ {"source": 6, "target": 8},+ {"source": 8, "target": 7},+ {"source": 6, "target": 9},+ {"source": 9, "target": 7},+ {"source": 3, "target": 6},+ {"source": 7, "target": 4},+ {"source": 2, "target": 3},+ ],+ }assert graph.draw_ascii() == snapshot(name="ascii")assert graph.draw_mermaid() == snapshot(name="mermaid")diff --git a/libs/core/tests/unit_tests/runnables/test_runnable.py b/libs/core/tests/unit_tests/runnables/test_runnable.pyindex 80b5dfa054..3a860642c3 100644--- a/libs/core/tests/unit_tests/runnables/test_runnable.py+++ b/libs/core/tests/unit_tests/runnables/test_runnable.py@@ -41,6 +41,7 @@ from langchain_core.messages import (HumanMessage,SystemMessage,)+from langchain_core.messages.base import BaseMessagefrom langchain_core.output_parsers import (BaseOutputParser,CommaSeparatedListOutputParser,@@ -86,6 +87,7 @@ from langchain_core.tracers import (RunLogPatch,)from langchain_core.tracers.context import collect_runs+from tests.unit_tests.stubs import AnyStrclass FakeTracer(BaseTracer):@@ -106,6 +108,12 @@ class FakeTracer(BaseTracer):self.uuids_map[uuid] = next(self.uuids_generator)return self.uuids_map[uuid]+ def _replace_message_id(self, maybe_message: Any) -> Any:+ if isinstance(maybe_message, BaseMessage):+ maybe_message.id = AnyStr()++ return maybe_message+def _copy_run(self, run: Run) -> Run:if run.dotted_order:levels = run.dotted_order.split(".")@@ -129,6 +137,16 @@ class FakeTracer(BaseTracer):"child_execution_order": None,"trace_id": self._replace_uuid(run.trace_id) if run.trace_id else None,"dotted_order": new_dotted_order,+ "inputs": {+ k: self._replace_message_id(v) for k, v in run.inputs.items()+ }+ if isinstance(run.inputs, dict)+ else run.inputs,+ "outputs": {+ k: self._replace_message_id(v) for k, v in run.outputs.items()+ }+ if isinstance(run.outputs, dict)+ else run.outputs,})@@ -1922,7 +1940,7 @@ def test_prompt_with_chat_model(tracer = FakeTracer()assert chain.invoke({"question": "What is your name?"}, dict(callbacks=[tracer])- ) == AIMessage(content="foo")+ ) == AIMessage(content="foo", id=AnyStr())assert prompt_spy.call_args.args[1] == {"question": "What is your name?"}assert chat_spy.call_args.args[1] == ChatPromptValue(messages=[@@ -1947,8 +1965,8 @@ def test_prompt_with_chat_model(],dict(callbacks=[tracer]),) == [- AIMessage(content="foo"),- AIMessage(content="foo"),+ AIMessage(content="foo", id=AnyStr()),+ AIMessage(content="foo", id=AnyStr()),]assert prompt_spy.call_args.args[1] == [{"question": "What is your name?"},@@ -1988,9 +2006,9 @@ def test_prompt_with_chat_model(assert [*chain.stream({"question": "What is your name?"}, dict(callbacks=[tracer]))] == [- AIMessageChunk(content="f"),- AIMessageChunk(content="o"),- AIMessageChunk(content="o"),+ AIMessageChunk(content="f", id=AnyStr()),+ AIMessageChunk(content="o", id=AnyStr()),+ AIMessageChunk(content="o", id=AnyStr()),]assert prompt_spy.call_args.args[1] == {"question": "What is your name?"}assert chat_spy.call_args.args[1] == ChatPromptValue(@@ -2026,7 +2044,7 @@ async def test_prompt_with_chat_model_async(tracer = FakeTracer()assert await chain.ainvoke({"question": "What is your name?"}, dict(callbacks=[tracer])- ) == AIMessage(content="foo")+ ) == AIMessage(content="foo", id=AnyStr())assert prompt_spy.call_args.args[1] == {"question": "What is your name?"}assert chat_spy.call_args.args[1] == ChatPromptValue(messages=[@@ -2051,8 +2069,8 @@ async def test_prompt_with_chat_model_async(],dict(callbacks=[tracer]),) == [- AIMessage(content="foo"),- AIMessage(content="foo"),+ AIMessage(content="foo", id=AnyStr()),+ AIMessage(content="foo", id=AnyStr()),]assert prompt_spy.call_args.args[1] == [{"question": "What is your name?"},@@ -2095,9 +2113,9 @@ async def test_prompt_with_chat_model_async({"question": "What is your name?"}, dict(callbacks=[tracer]))] == [- AIMessageChunk(content="f"),- AIMessageChunk(content="o"),- AIMessageChunk(content="o"),+ AIMessageChunk(content="f", id=AnyStr()),+ AIMessageChunk(content="o", id=AnyStr()),+ AIMessageChunk(content="o", id=AnyStr()),]assert prompt_spy.call_args.args[1] == {"question": "What is your name?"}assert chat_spy.call_args.args[1] == ChatPromptValue(@@ -2762,7 +2780,7 @@ def test_prompt_with_chat_model_and_parser(HumanMessage(content="What is your name?"),])- assert parser_spy.call_args.args[1] == AIMessage(content="foo, bar")+ assert parser_spy.call_args.args[1] == AIMessage(content="foo, bar", id=AnyStr())assert tracer.runs == snapshot@@ -2895,7 +2913,7 @@ What is your name?"""),])- assert parser_spy.call_args.args[1] == AIMessage(content="foo, bar")+ assert parser_spy.call_args.args[1] == AIMessage(content="foo, bar", id=AnyStr())assert len([r for r in tracer.runs if r.parent_run_id is None]) == 1parent_run = next(r for r in tracer.runs if r.parent_run_id is None)assert len(parent_run.child_runs) == 4@@ -2941,7 +2959,7 @@ def test_seq_prompt_dict(mocker: MockerFixture, snapshot: SnapshotAssertion) ->assert chain.invoke({"question": "What is your name?"}, dict(callbacks=[tracer])) == {- "chat": AIMessage(content="i'm a chatbot"),+ "chat": AIMessage(content="i'm a chatbot", id=AnyStr()),"llm": "i'm a textbot",}assert prompt_spy.call_args.args[1] == {"question": "What is your name?"}@@ -3151,7 +3169,7 @@ def test_seq_prompt_map(mocker: MockerFixture, snapshot: SnapshotAssertion) -> Nassert chain.invoke({"question": "What is your name?"}, dict(callbacks=[tracer])) == {- "chat": AIMessage(content="i'm a chatbot"),+ "chat": AIMessage(content="i'm a chatbot", id=AnyStr()),"llm": "i'm a textbot","passthrough": ChatPromptValue(messages=[@@ -3360,12 +3378,13 @@ async def test_map_astream() -> None:assert streamed_chunks[0] in [{"passthrough": prompt.invoke({"question": "What is your name?"})},{"llm": "i"},- {"chat": AIMessageChunk(content="i")},+ {"chat": AIMessageChunk(content="i", id=AnyStr())},]assert len(streamed_chunks) == len(chat_res) + len(llm_res) + 1assert all(len(c.keys()) == 1 for c in streamed_chunks)assert final_value is not Noneassert final_value.get("chat").content == "i'm a chatbot"+ final_value["chat"].id = AnyStr()assert final_value.get("llm") == "i'm a textbot"assert final_value.get("passthrough") == prompt.invoke({"question": "What is your name?"}diff --git a/libs/core/tests/unit_tests/runnables/test_runnable_events.py b/libs/core/tests/unit_tests/runnables/test_runnable_events.pyindex bc5d6102ec..8d81f6c347 100644--- a/libs/core/tests/unit_tests/runnables/test_runnable_events.py+++ b/libs/core/tests/unit_tests/runnables/test_runnable_events.py@@ -29,6 +29,7 @@ from langchain_core.runnables import (from langchain_core.runnables.history import RunnableWithMessageHistoryfrom langchain_core.runnables.schema import StreamEventfrom langchain_core.tools import tool+from tests.unit_tests.stubs import AnyStrdef _with_nulled_run_id(events: Sequence[StreamEvent]) -> List[StreamEvent]:@@ -340,7 +341,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content="hello")},+ "data": {"chunk": AIMessageChunk(content="hello", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -348,7 +349,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content=" ")},+ "data": {"chunk": AIMessageChunk(content=" ", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -356,7 +357,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content="world!")},+ "data": {"chunk": AIMessageChunk(content="world!", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -364,7 +365,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"output": AIMessageChunk(content="hello world!")},+ "data": {"output": AIMessageChunk(content="hello world!", id=AnyStr())},"event": "on_chat_model_end","metadata": {"a": "b"},"name": "my_model",@@ -399,7 +400,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content="hello")},+ "data": {"chunk": AIMessageChunk(content="hello", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -407,7 +408,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content=" ")},+ "data": {"chunk": AIMessageChunk(content=" ", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -415,7 +416,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content="world!")},+ "data": {"chunk": AIMessageChunk(content="world!", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -430,7 +431,9 @@ async def test_astream_events_from_model() -> None:[{"generation_info": None,- "message": AIMessage(content="hello world!"),+ "message": AIMessage(+ content="hello world!", id=AnyStr()+ ),"text": "hello world!","type": "ChatGeneration",}@@ -447,7 +450,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessage(content="hello world!")},+ "data": {"chunk": AIMessage(content="hello world!", id=AnyStr())},"event": "on_chain_stream","metadata": {},"name": "i_dont_stream",@@ -455,7 +458,7 @@ async def test_astream_events_from_model() -> None:"tags": [],},{- "data": {"output": AIMessage(content="hello world!")},+ "data": {"output": AIMessage(content="hello world!", id=AnyStr())},"event": "on_chain_end","metadata": {},"name": "i_dont_stream",@@ -490,7 +493,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content="hello")},+ "data": {"chunk": AIMessageChunk(content="hello", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -498,7 +501,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content=" ")},+ "data": {"chunk": AIMessageChunk(content=" ", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -506,7 +509,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessageChunk(content="world!")},+ "data": {"chunk": AIMessageChunk(content="world!", id=AnyStr())},"event": "on_chat_model_stream","metadata": {"a": "b"},"name": "my_model",@@ -521,7 +524,9 @@ async def test_astream_events_from_model() -> None:[{"generation_info": None,- "message": AIMessage(content="hello world!"),+ "message": AIMessage(+ content="hello world!", id=AnyStr()+ ),"text": "hello world!","type": "ChatGeneration",}@@ -538,7 +543,7 @@ async def test_astream_events_from_model() -> None:"tags": ["my_model"],},{- "data": {"chunk": AIMessage(content="hello world!")},+ "data": {"chunk": AIMessage(content="hello world!", id=AnyStr())},"event": "on_chain_stream","metadata": {},"name": "ai_dont_stream",@@ -546,7 +551,7 @@ async def test_astream_events_from_model() -> None:"tags": [],},{- "data": {"output": AIMessage(content="hello world!")},+ "data": {"output": AIMessage(content="hello world!", id=AnyStr())},"event": "on_chain_end","metadata": {},"name": "ai_dont_stream",@@ -563,7 +568,10 @@ async def test_event_stream_with_simple_chain() -> None:).with_config({"run_name": "my_template", "tags": ["my_template"]})infinite_cycle = cycle(- [AIMessage(content="hello world!"), AIMessage(content="goodbye world!")]+ [+ AIMessage(content="hello world!", id="ai1"),+ AIMessage(content="goodbye world!", id="ai2"),+ ])# When streaming GenericFakeChatModel breaks AIMessage into chunks based on spacesmodel = (@@ -640,7 +648,7 @@ async def test_event_stream_with_simple_chain() -> None:"tags": ["my_chain", "my_model", "seq:step:2"],},{- "data": {"chunk": AIMessageChunk(content="hello")},+ "data": {"chunk": AIMessageChunk(content="hello", id="ai1")},"event": "on_chat_model_stream","metadata": {"a": "b", "foo": "bar"},"name": "my_model",@@ -648,7 +656,7 @@ async def test_event_stream_with_simple_chain() -> None:"tags": ["my_chain", "my_model", "seq:step:2"],},{- "data": {"chunk": AIMessageChunk(content="hello")},+ "data": {"chunk": AIMessageChunk(content="hello", id="ai1")},"event": "on_chain_stream","metadata": {"foo": "bar"},"name": "my_chain",@@ -656,7 +664,7 @@ async def test_event_stream_with_simple_chain() -> None:"tags": ["my_chain"],},{- "data": {"chunk": AIMessageChunk(content=" ")},+ "data": {"chunk": AIMessageChunk(content=" ", id="ai1")},"event": "on_chat_model_stream","metadata": {"a": "b", "foo": "bar"},"name": "my_model",@@ -664,7 +672,7 @@ async def test_event_stream_with_simple_chain() -> None:"tags": ["my_chain", "my_model", "seq:step:2"],},{- "data": {"chunk": AIMessageChunk(content=" ")},+ "data": {"chunk": AIMessageChunk(content=" ", id="ai1")},"event": "on_chain_stream","metadata": {"foo": "bar"},"name": "my_chain",@@ -672,7 +680,7 @@ async def test_event_stream_with_simple_chain() -> None:"tags": ["my_chain"],},{- "data": {"chunk": AIMessageChunk(content="world!")},+ "data": {"chunk": AIMessageChunk(content="world!", id="ai1")},"event": "on_chat_model_stream","metadata": {"a": "b", "foo": "bar"},"name": "my_model",@@ -680,7 +688,7 @@ async def test_event_stream_with_simple_chain() -> None:"tags": ["my_chain", "my_model", "seq:step:2"],},{- "data": {"chunk": AIMessageChunk(content="world!")},+ "data": {"chunk": AIMessageChunk(content="world!", id="ai1")},"event": "on_chain_stream","metadata": {"foo": "bar"},"name": "my_chain",@@ -702,7 +710,9 @@ async def test_event_stream_with_simple_chain() -> None:[{"generation_info": None,- "message": AIMessageChunk(content="hello world!"),+ "message": AIMessageChunk(+ content="hello world!", id="ai1"+ ),"text": "hello world!","type": "ChatGenerationChunk",}@@ -719,7 +729,7 @@ async def test_event_stream_with_simple_chain() -> None:"tags": ["my_chain", "my_model", "seq:step:2"],},{- "data": {"output": AIMessageChunk(content="hello world!")},+ "data": {"output": AIMessageChunk(content="hello world!", id="ai1")},"event": "on_chain_end","metadata": {"foo": "bar"},"name": "my_chain",@@ -1332,8 +1342,8 @@ async def test_runnable_each() -> None:async def test_events_astream_config() -> None:"""Test that astream events support accepting config"""- infinite_cycle = cycle([AIMessage(content="hello world!")])- good_world_on_repeat = cycle([AIMessage(content="Goodbye world")])+ infinite_cycle = cycle([AIMessage(content="hello world!", id="ai1")])+ good_world_on_repeat = cycle([AIMessage(content="Goodbye world", id="ai2")])model = GenericFakeChatModel(messages=infinite_cycle).configurable_fields(messages=ConfigurableField(id="messages",@@ -1343,7 +1353,7 @@ async def test_events_astream_config() -> None:)model_02 = model.with_config({"configurable": {"messages": good_world_on_repeat}})- assert model_02.invoke("hello") == AIMessage(content="Goodbye world")+ assert model_02.invoke("hello") == AIMessage(content="Goodbye world", id="ai2")events = await _collect_events(model_02.astream_events("hello", version="v1"))assert events == [@@ -1356,7 +1366,7 @@ async def test_events_astream_config() -> None:"tags": [],},{- "data": {"chunk": AIMessageChunk(content="Goodbye")},+ "data": {"chunk": AIMessageChunk(content="Goodbye", id="ai2")},"event": "on_chat_model_stream","metadata": {},"name": "RunnableConfigurableFields",@@ -1364,7 +1374,7 @@ async def test_events_astream_config() -> None:"tags": [],},{- "data": {"chunk": AIMessageChunk(content=" ")},+ "data": {"chunk": AIMessageChunk(content=" ", id="ai2")},"event": "on_chat_model_stream","metadata": {},"name": "RunnableConfigurableFields",@@ -1372,7 +1382,7 @@ async def test_events_astream_config() -> None:"tags": [],},{- "data": {"chunk": AIMessageChunk(content="world")},+ "data": {"chunk": AIMessageChunk(content="world", id="ai2")},"event": "on_chat_model_stream","metadata": {},"name": "RunnableConfigurableFields",@@ -1380,7 +1390,7 @@ async def test_events_astream_config() -> None:"tags": [],},{- "data": {"output": AIMessageChunk(content="Goodbye world")},+ "data": {"output": AIMessageChunk(content="Goodbye world", id="ai2")},"event": "on_chat_model_end","metadata": {},"name": "RunnableConfigurableFields",@@ -1418,7 +1428,9 @@ async def test_runnable_with_message_history() -> None:store[session_id] = []return InMemoryHistory(messages=store[session_id])- infinite_cycle = cycle([AIMessage(content="hello"), AIMessage(content="world")])+ infinite_cycle = cycle(+ [AIMessage(content="hello", id="ai3"), AIMessage(content="world", id="ai4")]+ )prompt = ChatPromptTemplate.from_messages([@@ -1441,7 +1453,10 @@ async def test_runnable_with_message_history() -> None:).ainvoke({"question": "hello"})assert store == {- "session-123": [HumanMessage(content="hello"), AIMessage(content="hello")]+ "session-123": [+ HumanMessage(content="hello"),+ AIMessage(content="hello", id="ai3"),+ ]}with_message_history.with_config(@@ -1450,8 +1465,8 @@ async def test_runnable_with_message_history() -> None:assert store == {"session-123": [HumanMessage(content="hello"),- AIMessage(content="hello"),+ AIMessage(content="hello", id="ai3"),HumanMessage(content="meow"),- AIMessage(content="world"),+ AIMessage(content="world", id="ai4"),]}diff --git a/libs/core/tests/unit_tests/stubs.py b/libs/core/tests/unit_tests/stubs.pynew file mode 100644index 0000000000..38e84a3a7a--- /dev/null+++ b/libs/core/tests/unit_tests/stubs.py@@ -0,0 +1,6 @@+from typing import Any+++class AnyStr(str):+ def __eq__(self, other: Any) -> bool:+ return isinstance(other, str)diff --git a/libs/core/tests/unit_tests/test_messages.py b/libs/core/tests/unit_tests/test_messages.pyindex 7cd7c9a913..aeb480e206 100644--- a/libs/core/tests/unit_tests/test_messages.py+++ b/libs/core/tests/unit_tests/test_messages.py@@ -23,15 +23,16 @@ from langchain_core.messages import (def test_message_chunks() -> None:- assert AIMessageChunk(content="I am") + AIMessageChunk(+ assert AIMessageChunk(content="I am", id="ai3") + AIMessageChunk(content=" indeed.") == AIMessageChunk(- content="I am indeed."+ content="I am indeed.", id="ai3"), "MessageChunk + MessageChunk should be a MessageChunk"assert (- AIMessageChunk(content="I am") + HumanMessageChunk(content=" indeed.")- == AIMessageChunk(content="I am indeed.")+ AIMessageChunk(content="I am", id="ai2")+ + HumanMessageChunk(content=" indeed.", id="human1")+ == AIMessageChunk(content="I am indeed.", id="ai2")), "MessageChunk + MessageChunk should be a MessageChunk of same class as the left side" # noqa: E501assert (@@ -69,10 +70,10 @@ def test_message_chunks() -> None:def test_chat_message_chunks() -> None:- assert ChatMessageChunk(role="User", content="I am") + ChatMessageChunk(+ assert ChatMessageChunk(role="User", content="I am", id="ai4") + ChatMessageChunk(role="User", content=" indeed.") == ChatMessageChunk(- role="User", content="I am indeed."+ id="ai4", role="User", content="I am indeed."), "ChatMessageChunk + ChatMessageChunk should be a ChatMessageChunk"with pytest.raises(ValueError):@@ -94,10 +95,10 @@ def test_chat_message_chunks() -> None:def test_function_message_chunks() -> None:- assert FunctionMessageChunk(name="hello", content="I am") + FunctionMessageChunk(- name="hello", content=" indeed."- ) == FunctionMessageChunk(- name="hello", content="I am indeed."+ assert FunctionMessageChunk(+ name="hello", content="I am", id="ai5"+ ) + FunctionMessageChunk(name="hello", content=" indeed.") == FunctionMessageChunk(+ id="ai5", name="hello", content="I am indeed."), "FunctionMessageChunk + FunctionMessageChunk should be a FunctionMessageChunk"with pytest.raises(ValueError):diff --git a/libs/langchain/Makefile b/libs/langchain/Makefileindex cff2f34854..119e15422f 100644--- a/libs/langchain/Makefile+++ b/libs/langchain/Makefile@@ -25,7 +25,7 @@ extended_tests:poetry run pytest --disable-socket --allow-unix-socket --only-extended tests/unit_teststest_watch:- poetry run ptw --snapshot-update --now . -- -x --disable-socket --allow-unix-socket tests/unit_tests+ poetry run ptw --snapshot-update --now . -- -x --disable-socket --allow-unix-socket --disable-warnings tests/unit_teststest_watch_extended:poetry run ptw --snapshot-update --now . -- -x --disable-socket --allow-unix-socket --only-extended tests/unit_testsdiff --git a/libs/langchain/tests/unit_tests/agents/test_agent.py b/libs/langchain/tests/unit_tests/agents/test_agent.pyindex 5ce9def909..9dc3198d0b 100644--- a/libs/langchain/tests/unit_tests/agents/test_agent.py+++ b/libs/langchain/tests/unit_tests/agents/test_agent.py@@ -35,6 +35,7 @@ from langchain.prompts import ChatPromptTemplatefrom langchain.tools import toolfrom tests.unit_tests.callbacks.fake_callback_handler import FakeCallbackHandlerfrom tests.unit_tests.llms.fake_chat_model import GenericFakeChatModel+from tests.unit_tests.stubs import AnyStrclass FakeListLLM(LLM):@@ -839,6 +840,7 @@ async def test_openai_agent_with_streaming() -> None:log="\nInvoking: `find_pet` with `{'pet': 'cat'}`\n\n\n",message_log=[AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"function_call": {@@ -852,6 +854,7 @@ async def test_openai_agent_with_streaming() -> None:],"messages": [AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"function_call": {@@ -874,6 +877,7 @@ async def test_openai_agent_with_streaming() -> None:log="\nInvoking: `find_pet` with `{'pet': 'cat'}`\n\n\n",message_log=[AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"function_call": {@@ -1014,6 +1018,7 @@ async def test_openai_agent_tools_agent() -> None:log="\nInvoking: `find_pet` with `{'pet': 'cat'}`\n\n\n",message_log=[AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"tool_calls": [@@ -1040,6 +1045,7 @@ async def test_openai_agent_tools_agent() -> None:],"messages": [AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"tool_calls": [@@ -1067,6 +1073,7 @@ async def test_openai_agent_tools_agent() -> None:log="\nInvoking: `check_time` with `{}`\n\n\n",message_log=[AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"tool_calls": [@@ -1093,6 +1100,7 @@ async def test_openai_agent_tools_agent() -> None:],"messages": [AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"tool_calls": [@@ -1124,6 +1132,7 @@ async def test_openai_agent_tools_agent() -> None:log="\nInvoking: `find_pet` with `{'pet': 'cat'}`\n\n\n",message_log=[AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"tool_calls": [@@ -1166,6 +1175,7 @@ async def test_openai_agent_tools_agent() -> None:log="\nInvoking: `check_time` with `{}`\n\n\n",message_log=[AIMessageChunk(+ id=AnyStr(),content="",additional_kwargs={"tool_calls": [diff --git a/libs/langchain/tests/unit_tests/llms/fake_chat_model.py b/libs/langchain/tests/unit_tests/llms/fake_chat_model.pyindex ffc80bf683..fe0d1c9c61 100644--- a/libs/langchain/tests/unit_tests/llms/fake_chat_model.py+++ b/libs/langchain/tests/unit_tests/llms/fake_chat_model.py@@ -119,7 +119,9 @@ class GenericFakeChatModel(BaseChatModel):content_chunks = cast(List[str], re.split(r"(\s)", content))for token in content_chunks:- chunk = ChatGenerationChunk(message=AIMessageChunk(content=token))+ chunk = ChatGenerationChunk(+ message=AIMessageChunk(id=message.id, content=token)+ )if run_manager:run_manager.on_llm_new_token(token, chunk=chunk)yield chunk@@ -136,6 +138,7 @@ class GenericFakeChatModel(BaseChatModel):for fvalue_chunk in fvalue_chunks:chunk = ChatGenerationChunk(message=AIMessageChunk(+ id=message.id,content="",additional_kwargs={"function_call": {fkey: fvalue_chunk}@@ -151,6 +154,7 @@ class GenericFakeChatModel(BaseChatModel):else:chunk = ChatGenerationChunk(message=AIMessageChunk(+ id=message.id,content="",additional_kwargs={"function_call": {fkey: fvalue}},)@@ -164,7 +168,7 @@ class GenericFakeChatModel(BaseChatModel):else:chunk = ChatGenerationChunk(message=AIMessageChunk(- content="", additional_kwargs={key: value}+ id=message.id, content="", additional_kwargs={key: value}))if run_manager:diff --git a/libs/langchain/tests/unit_tests/llms/test_fake_chat_model.py b/libs/langchain/tests/unit_tests/llms/test_fake_chat_model.pyindex db658736e8..7a0362740c 100644--- a/libs/langchain/tests/unit_tests/llms/test_fake_chat_model.py+++ b/libs/langchain/tests/unit_tests/llms/test_fake_chat_model.py@@ -8,6 +8,7 @@ from langchain_core.outputs import ChatGenerationChunk, GenerationChunkfrom langchain.callbacks.base import AsyncCallbackHandlerfrom tests.unit_tests.llms.fake_chat_model import GenericFakeChatModel+from tests.unit_tests.stubs import AnyStrdef test_generic_fake_chat_model_invoke() -> None:@@ -15,11 +16,11 @@ def test_generic_fake_chat_model_invoke() -> None:infinite_cycle = cycle([AIMessage(content="hello"), AIMessage(content="goodbye")])model = GenericFakeChatModel(messages=infinite_cycle)response = model.invoke("meow")- assert response == AIMessage(content="hello")+ assert response == AIMessage(content="hello", id=AnyStr())response = model.invoke("kitty")- assert response == AIMessage(content="goodbye")+ assert response == AIMessage(content="goodbye", id=AnyStr())response = model.invoke("meow")- assert response == AIMessage(content="hello")+ assert response == AIMessage(content="hello", id=AnyStr())async def test_generic_fake_chat_model_ainvoke() -> None:@@ -27,11 +28,11 @@ async def test_generic_fake_chat_model_ainvoke() -> None:infinite_cycle = cycle([AIMessage(content="hello"), AIMessage(content="goodbye")])model = GenericFakeChatModel(messages=infinite_cycle)response = await model.ainvoke("meow")- assert response == AIMessage(content="hello")+ assert response == AIMessage(content="hello", id=AnyStr())response = await model.ainvoke("kitty")- assert response == AIMessage(content="goodbye")+ assert response == AIMessage(content="goodbye", id=AnyStr())response = await model.ainvoke("meow")- assert response == AIMessage(content="hello")+ assert response == AIMessage(content="hello", id=AnyStr())async def test_generic_fake_chat_model_stream() -> None:@@ -44,16 +45,16 @@ async def test_generic_fake_chat_model_stream() -> None:model = GenericFakeChatModel(messages=infinite_cycle)chunks = [chunk async for chunk in model.astream("meow")]assert chunks == [- AIMessageChunk(content="hello"),- AIMessageChunk(content=" "),- AIMessageChunk(content="goodbye"),+ AIMessageChunk(content="hello", id=AnyStr()),+ AIMessageChunk(content=" ", id=AnyStr()),+ AIMessageChunk(content="goodbye", id=AnyStr()),]chunks = [chunk for chunk in model.stream("meow")]assert chunks == [- AIMessageChunk(content="hello"),- AIMessageChunk(content=" "),- AIMessageChunk(content="goodbye"),+ AIMessageChunk(content="hello", id=AnyStr()),+ AIMessageChunk(content=" ", id=AnyStr()),+ AIMessageChunk(content="goodbye", id=AnyStr()),]# Test streaming of additional kwargs.@@ -62,11 +63,12 @@ async def test_generic_fake_chat_model_stream() -> None:model = GenericFakeChatModel(messages=cycle([message]))chunks = [chunk async for chunk in model.astream("meow")]assert chunks == [- AIMessageChunk(content="", additional_kwargs={"foo": 42}),- AIMessageChunk(content="", additional_kwargs={"bar": 24}),+ AIMessageChunk(content="", additional_kwargs={"foo": 42}, id=AnyStr()),+ AIMessageChunk(content="", additional_kwargs={"bar": 24}, id=AnyStr()),]message = AIMessage(+ id="a1",content="",additional_kwargs={"function_call": {@@ -81,18 +83,22 @@ async def test_generic_fake_chat_model_stream() -> None:assert chunks == [AIMessageChunk(- content="", additional_kwargs={"function_call": {"name": "move_file"}}+ content="",+ additional_kwargs={"function_call": {"name": "move_file"}},+ id="a1",),AIMessageChunk(+ id="a1",content="",additional_kwargs={"function_call": {"arguments": '{\n "source_path": "foo"'}},),AIMessageChunk(- content="", additional_kwargs={"function_call": {"arguments": ","}}+ id="a1", content="", additional_kwargs={"function_call": {"arguments": ","}}),AIMessageChunk(+ id="a1",content="",additional_kwargs={"function_call": {"arguments": '\n "destination_path": "bar"\n}'}@@ -108,6 +114,7 @@ async def test_generic_fake_chat_model_stream() -> None:accumulate_chunks += chunkassert accumulate_chunks == AIMessageChunk(+ id="a1",content="",additional_kwargs={"function_call": {@@ -128,9 +135,9 @@ async def test_generic_fake_chat_model_astream_log() -> None:]final = log_patches[-1]assert final.state["streamed_output"] == [- AIMessageChunk(content="hello"),- AIMessageChunk(content=" "),- AIMessageChunk(content="goodbye"),+ AIMessageChunk(content="hello", id=AnyStr()),+ AIMessageChunk(content=" ", id=AnyStr()),+ AIMessageChunk(content="goodbye", id=AnyStr()),]@@ -178,8 +185,8 @@ async def test_callback_handlers() -> None:# New modelresults = list(model.stream("meow", {"callbacks": [MyCustomAsyncHandler(tokens)]}))assert results == [- AIMessageChunk(content="hello"),- AIMessageChunk(content=" "),- AIMessageChunk(content="goodbye"),+ AIMessageChunk(content="hello", id=AnyStr()),+ AIMessageChunk(content=" ", id=AnyStr()),+ AIMessageChunk(content="goodbye", id=AnyStr()),]assert tokens == ["hello", " ", "goodbye"]diff --git a/libs/langchain/tests/unit_tests/load/__snapshots__/test_dump.ambr b/libs/langchain/tests/unit_tests/load/__snapshots__/test_dump.ambrindex 11d73a7c63..e6d27fada5 100644--- a/libs/langchain/tests/unit_tests/load/__snapshots__/test_dump.ambr+++ b/libs/langchain/tests/unit_tests/load/__snapshots__/test_dump.ambr@@ -97,464 +97,7 @@{"id": 0,"type": "schema",- "data": {- "title": "OpenAIInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "OpenAIInput"},{"id": 1,@@ -572,10 +115,7 @@{"id": 2,"type": "schema",- "data": {- "title": "OpenAIOutput",- "type": "string"- }+ "data": "OpenAIOutput"}],"edges": [@@ -613,16 +153,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "name": {- "title": "Name",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -640,436 +171,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -1091,15 +193,7 @@{"id": 0,"type": "schema",- "data": {- "title": "ChainInput",- "type": "object",- "properties": {- "name": {- "title": "Name"- }- }- }+ "data": "ChainInput"},{"id": 1,@@ -1117,15 +211,7 @@{"id": 2,"type": "schema",- "data": {- "title": "ChainOutput",- "type": "object",- "properties": {- "text": {- "title": "Text"- }- }- }+ "data": "ChainOutput"}],"edges": [@@ -1180,464 +266,7 @@{"id": 0,"type": "schema",- "data": {- "title": "ChatOpenAIInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "ChatOpenAIInput"},{"id": 1,@@ -1655,382 +284,7 @@{"id": 2,"type": "schema",- "data": {- "title": "ChatOpenAIOutput",- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ],- "definitions": {- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- }- }- }+ "data": "ChatOpenAIOutput"}],"edges": [@@ -2092,16 +346,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "name": {- "title": "Name",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -2119,436 +364,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -2574,16 +390,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "name": {- "title": "Name",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -2601,436 +408,7 @@{"id": 2,"type": "schema",- "data": {- "title": "ChatPromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "ChatPromptTemplateOutput"}],"edges": [@@ -3051,16 +429,8 @@"nodes": [{"id": 0,- "type": "schema",- "data": {- "title": "ChainInput",- "type": "object",- "properties": {- "name": {- "title": "Name"- }- }- }+ "type": "schema",+ "data": "ChainInput"},{"id": 1,@@ -3078,15 +448,7 @@{"id": 2,"type": "schema",- "data": {- "title": "ChainOutput",- "type": "object",- "properties": {- "text": {- "title": "Text"- }- }- }+ "data": "ChainOutput"}],"edges": [@@ -3141,464 +503,7 @@{"id": 0,"type": "schema",- "data": {- "title": "OpenAIInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "OpenAIInput"},{"id": 1,@@ -3616,10 +521,7 @@{"id": 2,"type": "schema",- "data": {- "title": "OpenAIOutput",- "type": "string"- }+ "data": "OpenAIOutput"}],"edges": [@@ -3657,16 +559,7 @@{"id": 0,"type": "schema",- "data": {- "title": "PromptInput",- "type": "object",- "properties": {- "name": {- "title": "Name",- "type": "string"- }- }- }+ "data": "PromptInput"},{"id": 1,@@ -3684,436 +577,7 @@{"id": 2,"type": "schema",- "data": {- "title": "PromptTemplateOutput",- "anyOf": [- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "PromptTemplateOutput"}],"edges": [@@ -4135,15 +599,7 @@{"id": 0,"type": "schema",- "data": {- "title": "ChainInput",- "type": "object",- "properties": {- "name": {- "title": "Name"- }- }- }+ "data": "ChainInput"},{"id": 1,@@ -4161,15 +617,7 @@{"id": 2,"type": "schema",- "data": {- "title": "ChainOutput",- "type": "object",- "properties": {- "text": {- "title": "Text"- }- }- }+ "data": "ChainOutput"}],"edges": [@@ -4214,464 +662,7 @@{"id": 0,"type": "schema",- "data": {- "title": "OpenAIInput",- "anyOf": [- {- "type": "string"- },- {- "$ref": "#/definitions/StringPromptValue"- },- {- "$ref": "#/definitions/ChatPromptValueConcrete"- },- {- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- }- ],- "definitions": {- "StringPromptValue": {- "title": "StringPromptValue",- "description": "String prompt value.",- "type": "object",- "properties": {- "text": {- "title": "Text",- "type": "string"- },- "type": {- "title": "Type",- "default": "StringPromptValue",- "enum": [- "StringPromptValue"- ],- "type": "string"- }- },- "required": [- "text"- ]- },- "AIMessage": {- "title": "AIMessage",- "description": "Message from an AI.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "ai",- "enum": [- "ai"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "HumanMessage": {- "title": "HumanMessage",- "description": "Message from a human.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "human",- "enum": [- "human"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "example": {- "title": "Example",- "default": false,- "type": "boolean"- }- },- "required": [- "content"- ]- },- "ChatMessage": {- "title": "ChatMessage",- "description": "Message that can be assigned an arbitrary speaker (i.e. role).",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "chat",- "enum": [- "chat"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "role": {- "title": "Role",- "type": "string"- }- },- "required": [- "content",- "role"- ]- },- "SystemMessage": {- "title": "SystemMessage",- "description": "Message for priming AI behavior, usually passed in as the first of a sequence\nof input messages.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "system",- "enum": [- "system"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content"- ]- },- "FunctionMessage": {- "title": "FunctionMessage",- "description": "Message for passing the result of executing a function back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "function",- "enum": [- "function"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- }- },- "required": [- "content",- "name"- ]- },- "ToolMessage": {- "title": "ToolMessage",- "description": "Message for passing the result of executing a tool back to a model.",- "type": "object",- "properties": {- "content": {- "title": "Content",- "anyOf": [- {- "type": "string"- },- {- "type": "array",- "items": {- "anyOf": [- {- "type": "string"- },- {- "type": "object"- }- ]- }- }- ]- },- "additional_kwargs": {- "title": "Additional Kwargs",- "type": "object"- },- "response_metadata": {- "title": "Response Metadata",- "type": "object"- },- "type": {- "title": "Type",- "default": "tool",- "enum": [- "tool"- ],- "type": "string"- },- "name": {- "title": "Name",- "type": "string"- },- "id": {- "title": "Id",- "type": "string"- },- "tool_call_id": {- "title": "Tool Call Id",- "type": "string"- }- },- "required": [- "content",- "tool_call_id"- ]- },- "ChatPromptValueConcrete": {- "title": "ChatPromptValueConcrete",- "description": "Chat prompt value which explicitly lists out the message types it accepts.\nFor use in external schemas.",- "type": "object",- "properties": {- "messages": {- "title": "Messages",- "type": "array",- "items": {- "anyOf": [- {- "$ref": "#/definitions/AIMessage"- },- {- "$ref": "#/definitions/HumanMessage"- },- {- "$ref": "#/definitions/ChatMessage"- },- {- "$ref": "#/definitions/SystemMessage"- },- {- "$ref": "#/definitions/FunctionMessage"- },- {- "$ref": "#/definitions/ToolMessage"- }- ]- }- },- "type": {- "title": "Type",- "default": "ChatPromptValueConcrete",- "enum": [- "ChatPromptValueConcrete"- ],- "type": "string"- }- },- "required": [- "messages"- ]- }- }- }+ "data": "OpenAIInput"},{"id": 1,@@ -4689,10 +680,7 @@{"id": 2,"type": "schema",- "data": {- "title": "OpenAIOutput",- "type": "string"- }+ "data": "OpenAIOutput"}],"edges": [diff --git a/libs/langchain/tests/unit_tests/stubs.py b/libs/langchain/tests/unit_tests/stubs.pynew file mode 100644index 0000000000..38e84a3a7a--- /dev/null+++ b/libs/langchain/tests/unit_tests/stubs.py@@ -0,0 +1,6 @@+from typing import Any+++class AnyStr(str):+ def __eq__(self, other: Any) -> bool:+ return isinstance(other, str)