embedding_similarity
Read-onlyIdempotent
Compute text similarity using local algorithms (Bag of Words, TF-IDF, Character N-grams). No API key needed — runs entirely in-process. NOT real embeddings: true vector embeddings are run_semantic_tests with mode="embeddings" and an OpenAI key. Supports single pair or batch mode with pipe-separated pairs. Useful for RAG retrieval testing, semantic search evaluation, and text deduplication.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| batch | No | Batch mode: array of { text_a, text_b } pairs. Overrides text_a/text_b if provided. | |
| text_a | No | First text to compare (single-pair mode) | |
| text_b | No | Second text to compare (single-pair mode) | |
| methods | No | Algorithms to use (default: all three). Options: "bow", "tfidf", "ngram" |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | ||
| count | No | ||
| scores | No | ||
| text_a | No | ||
| text_b | No | ||
| results | No |