initial commit: slides + practica_resueltos + README

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-29 11:50:55 +02:00
commit 0aff31e2d3
203 changed files with 23207 additions and 0 deletions
+30
View File
@@ -0,0 +1,30 @@
---
layout: default
---
# Integración MCP (Model Context Protocol)
<v-clicks>
### MCP en LangChain.js
Protocolo abierto que estandariza cómo las aplicaciones proporcionan tools y contexto a LLMs.
```typescript
import { ChatOpenAI, tools } from "@langchain/openai";
const model = new ChatOpenAI({ model: "gpt-4.1" });
const response = await model.invoke("Roll 2d4+1", {
tools: [
tools.mcp({
serverLabel: "dmcp",
serverDescription: "A D&D MCP server for dice rolling",
serverUrl: "https://dmcp-server.deno.dev/sse",
requireApproval: "never",
}),
],
});
```
</v-clicks>