initial commit: slides + practica_resueltos + README
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
---
|
||||
layout: default
|
||||
---
|
||||
|
||||
# Qdrant - Crear e insertar
|
||||
|
||||
```typescript
|
||||
import { QdrantVectorStore } from "@langchain/qdrant";
|
||||
import { OpenAIEmbeddings } from "@langchain/openai";
|
||||
|
||||
const vectorStore = await QdrantVectorStore.fromTexts(
|
||||
[
|
||||
"LangChain es un framework para aplicaciones con LLMs",
|
||||
"Los embeddings capturan el significado del texto",
|
||||
"RAG combina búsqueda con generación de texto",
|
||||
],
|
||||
[{ source: "doc1" }, { source: "doc2" }, { source: "doc3" }],
|
||||
new OpenAIEmbeddings(),
|
||||
{
|
||||
url: "http://localhost:6333",
|
||||
collectionName: "langchain_docs",
|
||||
}
|
||||
);
|
||||
|
||||
console.log("Documentos indexados correctamente");
|
||||
```
|
||||
Reference in New Issue
Block a user