Prettier formatting
This commit is contained in:
parent
d01e8def07
commit
7b68e28f05
2 changed files with 6 additions and 7 deletions
|
|
@ -68,7 +68,7 @@ class MCPClient {
|
|||
});
|
||||
console.log(
|
||||
"Connected to server with tools:",
|
||||
this.tools.map(({ name }) => name)
|
||||
this.tools.map(({ name }) => name),
|
||||
);
|
||||
} catch (e) {
|
||||
console.log("Failed to connect to MCP server: ", e);
|
||||
|
|
@ -90,7 +90,6 @@ class MCPClient {
|
|||
},
|
||||
];
|
||||
|
||||
|
||||
// Initial Claude API call
|
||||
const response = await this.anthropic.messages.create({
|
||||
model: "claude-3-5-sonnet-20241022",
|
||||
|
|
@ -117,7 +116,7 @@ class MCPClient {
|
|||
});
|
||||
toolResults.push(result);
|
||||
finalText.push(
|
||||
`[Calling tool ${toolName} with args ${JSON.stringify(toolArgs)}]`
|
||||
`[Calling tool ${toolName} with args ${JSON.stringify(toolArgs)}]`,
|
||||
);
|
||||
|
||||
// Continue conversation with tool results
|
||||
|
|
@ -134,7 +133,7 @@ class MCPClient {
|
|||
});
|
||||
|
||||
finalText.push(
|
||||
response.content[0].type === "text" ? response.content[0].text : ""
|
||||
response.content[0].type === "text" ? response.content[0].text : "",
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue