Skip to main content

Integrating with Postgres Vector Database in Orkes Conductor

To effectively utilize AI and LLM tasks in Orkes Conductor, it's essential to integrate your Orkes Conductor cluster with the necessary Vector Database models.

PGvector is a popular open-source extension for PostgreSQL known for its efficiency and versatility in handling large-scale vector data. This integration empowers you to access, query, and manipulate vector data effectively, enhancing the capabilities of Orkes Conductor in various natural language processing and artificial intelligence applications.

This guide will provide the steps for integrating Postgres as a Vector Database with Orkes Conductor.

Steps to integrate with Postgres Database

Before beginning to integrate with Postgres, you need to get specific configuration parameters from Postgres, such as database username, password, and URL. Now, let’s integrate this with Orkes Conductor.

  1. Navigate to Integrations from the left menu on your Orkes Conductor cluster.
  2. Click +New integration button from the top-right corner.
  3. Under the Vector Databases section, choose Postgres Vector Database.
  4. Click +Add and provide the following parameters:

Create Postgres Integration

ParametersDescription
Integration nameA name for the integration.
Postgres Database UserThe database username.
Postgres Database PasswordThe password associated with the database username.
Postgres Database URLThe database URL.
Embedding dimensionsThe number of dimensions in the embeddings. The embedding dimensions often depend on the AI model used to generate the embeddings.
Distance metricChoose the distance metric, which is a metric to measure the similarity or distance between vectors. Supported values:
  • Cosine Similarity
  • Euclidean Distance
  • Inner Product
Indexing methodChoose the indexing method. Supported methods:
  • hnsv - Hierarchical Navigable Small World graphs
  • ivfflat - Inverted File Flat
Number of inverted lists to create for ivfflat indexThe number of inverted lists to create when using the ivfflat indexing method. This parameter is only relevant if ivfflat is chosen as the indexing method.
DescriptionA description of your integration.
  1. You can toggle-on the Active button to activate the integration instantly.
  2. Click Save.

Adding Indexes to Postgres Integration

Now that you have integrated your Orkes Conductor cluster with the Postgres provider, the next step is to integrate with the specific indexes.

To add a new index to the Postgres integration:

  1. Navigate to the integrations page and click the '+' button next to the integration you created.

Create Indexes for Postgres Integration

  1. Click +New Index.
  2. Provide the index name and an optional description.

Create Indexes for Postgres Integration Model

  1. Toggle-on the Active button to enable immediately.
  2. Click Save.

This ensures the integration model is saved for future use in LLM tasks within Orkes Conductor.

RBAC - Governance on who can use Integrations

The integration with the required models is now ready. Next, we should determine the access control to these models.

The permission can be granted to applications/groups within the Orkes Conductor cluster.

To provide explicit permission to Groups:

  1. Navigate to Access Control > Groups from the left menu on your Orkes Conductor cluster.
  2. Create a new group or choose an existing group.
  3. Under the Permissions section, click +Add Permission.
  4. Under the Integrations tab, select the required integrations with the required permissions.

Add Permissions for Postgres Vector Database Integration

  1. Click Add Permissions. This ensures that all the group members can access these integration models in their workflows.

Similarly, you can also provide permissions to applications.