Skip to content

Commit a87709b

Browse files
author
chenhuan
committed
python format for opengauss pq acceleration
1 parent b543925 commit a87709b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

api/core/rag/datasource/vdb/opengauss/opengauss.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class OpenGaussConfig(BaseModel):
2525
database: str
2626
min_connection: int
2727
max_connection: int
28-
enable_pq: bool = False # Enable PQ acceleration
28+
enable_pq: bool = False # Enable PQ acceleration
2929

3030
@model_validator(mode="before")
3131
@classmethod
@@ -118,7 +118,7 @@ def _create_index(self, dimension: int):
118118
with self._get_cursor() as cur:
119119
if dimension <= 2000:
120120
if self.pq_enabled:
121-
cur.execute(SQL_CREATE_INDEX_PQ.format(table_name=self.table_name, pq_m=int(dimension/4)))
121+
cur.execute(SQL_CREATE_INDEX_PQ.format(table_name=self.table_name, pq_m=int(dimension / 4)))
122122
cur.execute("SET hnsw_earlystop_threshold = 320")
123123

124124
if not self.pq_enabled:

0 commit comments

Comments
 (0)