What Changed
Mistral launched new embedding models optimized for retrieval tasks (RAG), with specific improvements for non-English languages, including Spanish and Portuguese.
This is relevant because most search and RAG systems in production still suffer significant degradation when working with Spanish content.
Why It Matters
Embeddings are the foundation of any RAG system.
If the model doesn’t correctly represent the meaning of text in Spanish:
- search results worsen
- noise increases
- relevance decreases
With better embeddings, you don’t need to change your architecture, but you can dramatically improve your results.
How to Test Them in Practice
1. Install Dependencies
npm install @mistralai/mistralai
2. Generate Embeddings
import { Mistral } from '@mistralai/mistralai'
const client = new Mistral({ apiKey: process.env.MISTRAL_API_KEY })
const response = await client.embeddings.create({
model: "mistral-embed",
input: "How to implement authentication in a REST API"
})
console.log(response.data[0].embedding)
3. Store Them in Your Vector DB
You can use:
- PostgreSQL + pgvector
- Pinecone
- Weaviate
- Redis
Example with pgvector:
INSERT INTO documents (content, embedding)
VALUES ('How to implement authentication in a REST API', '[...]');
Practical Case: Spanish Search
Without optimized embeddings, a query like:
“secure login in API”
might not retrieve relevant documents if they’re written as:
“authentication in REST services”
With better embeddings, semantic similarity improves and the system understands that both concepts are related.
Real-World Use Cases
1. Customer Support
- Knowledge base search
- Spanish FAQs
2. Internal Documentation
- Technical wikis
- Process manuals
3. SaaS Products
- In-app search
- Internal assistants
Advantages
- Better retrieval in Spanish and Portuguese
- Less need for fine-tuning
- Direct integration with existing pipelines
Limitations
- Data cleaning is still necessary
- API dependency
- Costs if scaled
When to Use This
It makes sense if:
- your product is in Spanish
- you’re building RAG
- you have relevance issues
It’s not necessary if:
- you only work in English
- you don’t use semantic search
Conclusion
Most teams don’t have an architecture problem in their RAG systems.
They have an embeddings problem.
And in LATAM, that problem is even bigger.
Improving that layer can be the simplest change with the greatest impact on your results.
