mirror of
https://github.com/googleapis/genai-toolbox.git
synced 2026-01-09 15:38:08 -05:00
doc(langchain-sdk): Update LangChain SDK example to use Gemini Pro model for better tool selection. (#196)
This commit is contained in:
@@ -90,7 +90,7 @@ toolkit.
|
||||
```py
|
||||
from langchain_google_vertexai import ChatVertexAI
|
||||
|
||||
model = ChatVertexAI(model="gemini-1.5-flash-001")
|
||||
model = ChatVertexAI(model="gemini-1.5-pro-002")
|
||||
|
||||
# Initialize agent with tools
|
||||
agent = model.bind_tools(tools)
|
||||
@@ -123,7 +123,7 @@ def call_model(state: MessagesState):
|
||||
# We return a list, because this will get added to the existing list
|
||||
return {"messages": [response]}
|
||||
|
||||
model = ChatVertexAI(model="gemini-1.5-flash-001")
|
||||
model = ChatVertexAI(model="gemini-1.5-pro-002")
|
||||
builder = StateGraph(MessagesState)
|
||||
tool_node = ToolNode(tools)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user