Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/oss/javascript/migrate/langchain-v1.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ await agent.invoke({

### Pre-model hook

Pre-model hooks are now implemented as middleware with the `beforeModel` method. This pattern is more extensible-- you can define multiple middlewares to run before the model is called and reuse them across agents.
Pre-model hooks are now implemented as middleware with the `beforeModel` method. This pattern is more extensible--you can define multiple middlewares to run before the model is called and reuse them across agents.

Common use cases include:
- Summarizing conversation history
Expand Down
8 changes: 4 additions & 4 deletions src/oss/python/migrate/langchain-v1.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The `langchain` package namespace has been significantly reduced in v1 to focus
|-------------------------|------------------------------------------------|-----------------------------------|
| @[`langchain.agents`] | @[`create_agent`], @[`AgentState`] | Core agent creation functionality |
| @[`langchain.messages`] | Message types, @[content blocks][ContentBlock], @[`trim_messages`] | Re-exported from `langchain-core` |
| @[`langchain.tools`] | @[`tool`], @[`BaseTool`], injection helpers | Re-exported from `langchain-core` |
| @[`langchain.tools`] | @[`@tool`], @[`BaseTool`], injection helpers | Re-exported from `langchain-core` |
| @[`langchain.chat_models`] | @[`init_chat_model`], @[`BaseChatModel`] | Unified model initialization |
| @[`langchain.embeddings`] | @[`init_embeddings`], @[`Embeddings`] | Embedding models |

Expand Down Expand Up @@ -235,7 +235,7 @@ agent.invoke(
### Pre-model hook

Pre-model hooks are now implemented as middleware with the `before_model` method.
This new pattern is more extensible-- you can define multiple middlewares to run before the model is called,
This new pattern is more extensible--you can define multiple middlewares to run before the model is called,
reusing common patterns across different agents.

Common use cases include:
Expand Down Expand Up @@ -279,7 +279,7 @@ agent = create_react_agent(
### Post-model hook

Post-model hooks are now implemented as middleware with the `after_model` method.
This new pattern is more extensible-- you can define multiple middlewares to run after the model is called,
This new pattern is more extensible--you can define multiple middlewares to run after the model is called,
reusing common patterns across different agents.

Common use cases include:
Expand Down Expand Up @@ -788,7 +788,7 @@ The `langchain` package namespace has been significantly reduced in v1 to focus
|-------------------------|------------------------------------------------|-----------------------------------|
| @[`langchain.agents`] | @[`create_agent`], @[`AgentState`] | Core agent creation functionality |
| @[`langchain.messages`] | Message types, @[content blocks][ContentBlock], @[`trim_messages`] | Re-exported from `langchain-core` |
| @[`langchain.tools`] | @[`tool`], @[`BaseTool`], injection helpers | Re-exported from `langchain-core` |
| @[`langchain.tools`] | @[`@tool`], @[`BaseTool`], injection helpers | Re-exported from `langchain-core` |
| @[`langchain.chat_models`] | @[`init_chat_model`], @[`BaseChatModel`] | Unified model initialization |
| @[`langchain.embeddings`] | @[`init_embeddings`], @[`Embeddings`] | Embedding models |

Expand Down