Feature Extraction
sentence-transformers
ONNX
Safetensors
multilingual
bidirectional_pplx_qwen3
sentence-similarity
mteb
custom_code
text-embeddings-inference
Instructions to use perplexity-ai/pplx-embed-v1-4b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use perplexity-ai/pplx-embed-v1-4b with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("perplexity-ai/pplx-embed-v1-4b", trust_remote_code=True) sentences = [ "The weather is lovely today.", "It's so sunny outside!", "He drove to the stadium." ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [3, 3] - Notebooks
- Google Colab
- Kaggle
Fix create_causal_mask call for transformers 4.54 - 5.9
#14
by maximilian-schall-ppx - opened
Same fix as perplexity-ai/pplx-embed-v1-0.6b#13. The two repos share the same modeling.py, so they share the same bug:
TypeError: create_causal_mask() got an unexpected keyword argument 'input_embeds'
on transformers 5.9. This change detects the create_causal_mask signature at import time and adjusts the kwargs accordingly:
input_embeds(singular, transformers <= 5.1) vsinputs_embeds(>= 5.2)cache_position(required positional <= 5.3, kept-for-BC 5.6 - 5.8, removed in 5.9)
maximilian-schall-ppx changed pull request status to merged