Skip to content

Add Perplexity embedding models #36726

@CaioSBC

Description

@CaioSBC

Checked other resources

  • This is a feature request, not a bug report or usage question.
  • I added a clear and descriptive title that summarizes the feature request.
  • I used the GitHub search to find a similar feature request and didn't find it.
  • I checked the LangChain documentation and API reference to see if this feature already exists.
  • This is not related to the langchain-community package.

Package (Required)

  • langchain
  • langchain-openai
  • langchain-anthropic
  • langchain-classic
  • langchain-core
  • langchain-model-profiles
  • langchain-tests
  • langchain-text-splitters
  • langchain-chroma
  • langchain-deepseek
  • langchain-exa
  • langchain-fireworks
  • langchain-groq
  • langchain-huggingface
  • langchain-mistralai
  • langchain-nomic
  • langchain-ollama
  • langchain-openrouter
  • langchain-perplexity
  • langchain-qdrant
  • langchain-xai
  • Other / not sure / general

Feature Description

I am proposing native support for Perplexity embedding models within the langchain-perplexity module. This integration would enable users to build end-to-end RAG agents exclusively powered by Perplexity services.

Use Case

Currently, developers must manually implement a PerplexityEmbeddings class to build a RAG agent using Perplexity services. Integrating this feature directly into LangChain would significantly streamline the process.

Proposed Solution

A PerplexityEmbeddings class can be implemented within langchain_perplexity.embeddings, mirroring the standard structure of other LangChain embeddings. This implementation leverages the perplexityai SDK to handle service interactions.

Alternatives Considered

No response

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    externalfeature requestRequest for an enhancement / additional functionalityperplexity`langchain-perplexity` package issues & PRs
    No fields configured for Feature.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions