Prompt topics (across all routes of an LLM Proxy)
Configuring a Semantic Service
A semantic service compares incoming requests to the defined prompt topic utterances and sends the request to the route that best matches it. The semantic service also compares the request to the deny list topic utterances to block certain requests.
LLM Proxy supports two types of semantic services:
-
Advanced Scale: For complex semantic routing. Advanced scale semantic services use a vector database to store and compare prompt topic utterances. Advanced scale semantic services support unlimited prompt topics and 2000 utterances per prompt topic.
-
Basic Scale: For simple semantic routing and blocking. Basic scale semantic services support up to 6 prompt topics and 10 utterances per prompt topic.
Configure an Advanced Scale Semantic Service
-
From API Manager, click Semantic Service Configuration.
-
Click + Create a Semantic Service Configuration.
-
Select Advanced Scale.
-
Configure the semantic service parameters:
-
Service label: Label to identify the new service.
-
Embedding Service Provider: The provider of the embedding model. OpenAI or Hugging Face.
-
URL: The URL of the embedding service.
-
Model: The embedding model to use.
-
Auth key: The API authentication key for the embedding service.
-
-
Click Vector connection.
-
Select a Vector Database Provider from these options:
-
Quadrant
-
Pinecone
-
Azure AI Search
-
-
Configure the parameters to connect your database.
-
Create prompt topics:
-
Click Create prompt topics.
-
Define a Prompt topic name.
-
Define prompt utterances or click Upload utterances to upload a plain text file containing your prompt utterances.
-
Create as many prompt topics as neccesary. You can also create new prompt topics later by editing the semantic service.
To deny users from asking about certain subjects, create prompt topics for the subjects and apply them as deny list topics when configuring your LLM Proxy.
-
-
Click Save & download script.
-
Open the downloaded
.shscript file in you database to populate it with your scaled vectors.
Configure a Basic Scale Semantic Service
-
From API Manager, click Semantic Service Configuration.
-
Click + Create a Semantic Service Configuration.
-
Select Basic Scale.
-
Configure the semantic service parameters:
-
Service label: Label to identify the new service.
-
Embedding Service Provider: The provider of the embedding model. OpenAI or Hugging Face.
-
URL: The URL of the embedding service.
-
Model: The embedding model to use.
-
Auth key: The API authentication key for the embedding service.
-
-
Click Deploy.




