Plugin Secure Proxy
The Orama Secure Proxy plugin is an official Orama plugin that allows you to perform vector and hybrid search securely on your browser by masking OpenAI (and other services soon) API keys when generating embeddings.
Installation
First of all, install it via npm (or any other package manager of your choice):
Usage
Now, when creating a new Orama Instance, make sure to install the plugin:
Available models
Right now, the Orama Secure Proxy Plugin supports two different models for generating embeddings:
Model name | Provider | Dimensions |
---|---|---|
orama/gte-small | Orama | 384 |
orama/gte-medium | Orama | 768 |
orama/gte-large | Orama | 1024 |
openai/text-embedding-ada-002 | Openai | 1536 |
openai/text-embedding-3-small | Openai | 1536 |
openai/text-embedding-3-large | Openai | 3072 |
Running queries
By telling on which property to perform search by default (in the example above, 'embeddings'
), the plugin will automatically translate your search term into a vector by calling the OpenAI API for you and setting the result into the vector.value
property.
This will finally allow you to perform hybrid and vector search with the exact same APIs used for full-text search.
Specifying the vector property
If you have a more complex schema with multiple vector properties, you can always override the vector property to perform search on by using the default vector
property: