yangdx
commited on
Commit
·
8ec2c2f
1
Parent(s):
11c7a1e
Fix linting
Browse files- README-zh.md +1 -1
- README.md +1 -1
- lightrag/api/utils_api.py +2 -2
README-zh.md
CHANGED
@@ -772,7 +772,7 @@ rag = LightRAG(
|
|
772 |
create INDEX CONCURRENTLY entity_idx_node_id ON dickens."Entity" (ag_catalog.agtype_access_operator(properties, '"node_id"'::agtype));
|
773 |
CREATE INDEX CONCURRENTLY entity_node_id_gin_idx ON dickens."Entity" using gin(properties);
|
774 |
ALTER TABLE dickens."DIRECTED" CLUSTER ON directed_sid_idx;
|
775 |
-
|
776 |
-- 如有必要可以删除
|
777 |
drop INDEX entity_p_idx;
|
778 |
drop INDEX vertex_p_idx;
|
|
|
772 |
create INDEX CONCURRENTLY entity_idx_node_id ON dickens."Entity" (ag_catalog.agtype_access_operator(properties, '"node_id"'::agtype));
|
773 |
CREATE INDEX CONCURRENTLY entity_node_id_gin_idx ON dickens."Entity" using gin(properties);
|
774 |
ALTER TABLE dickens."DIRECTED" CLUSTER ON directed_sid_idx;
|
775 |
+
|
776 |
-- 如有必要可以删除
|
777 |
drop INDEX entity_p_idx;
|
778 |
drop INDEX vertex_p_idx;
|
README.md
CHANGED
@@ -765,7 +765,7 @@ For production level scenarios you will most likely want to leverage an enterpri
|
|
765 |
create INDEX CONCURRENTLY entity_idx_node_id ON dickens."Entity" (ag_catalog.agtype_access_operator(properties, '"node_id"'::agtype));
|
766 |
CREATE INDEX CONCURRENTLY entity_node_id_gin_idx ON dickens."Entity" using gin(properties);
|
767 |
ALTER TABLE dickens."DIRECTED" CLUSTER ON directed_sid_idx;
|
768 |
-
|
769 |
-- drop if necessary
|
770 |
drop INDEX entity_p_idx;
|
771 |
drop INDEX vertex_p_idx;
|
|
|
765 |
create INDEX CONCURRENTLY entity_idx_node_id ON dickens."Entity" (ag_catalog.agtype_access_operator(properties, '"node_id"'::agtype));
|
766 |
CREATE INDEX CONCURRENTLY entity_node_id_gin_idx ON dickens."Entity" using gin(properties);
|
767 |
ALTER TABLE dickens."DIRECTED" CLUSTER ON directed_sid_idx;
|
768 |
+
|
769 |
-- drop if necessary
|
770 |
drop INDEX entity_p_idx;
|
771 |
drop INDEX vertex_p_idx;
|
lightrag/api/utils_api.py
CHANGED
@@ -136,7 +136,7 @@ def get_combined_auth_dependency(api_key: Optional[str] = None):
|
|
136 |
|
137 |
### Authentication failed ####
|
138 |
|
139 |
-
# if password authentication is configured but not provided, ensure 401 error if auth_configured
|
140 |
if auth_configured and not token:
|
141 |
raise HTTPException(
|
142 |
status_code=status.HTTP_401_UNAUTHORIZED,
|
@@ -149,7 +149,7 @@ def get_combined_auth_dependency(api_key: Optional[str] = None):
|
|
149 |
status_code=HTTP_403_FORBIDDEN,
|
150 |
detail="Invalid API Key",
|
151 |
)
|
152 |
-
|
153 |
# if api_key_configured but not provided
|
154 |
if api_key_configured and not api_key_header_value:
|
155 |
raise HTTPException(
|
|
|
136 |
|
137 |
### Authentication failed ####
|
138 |
|
139 |
+
# if password authentication is configured but not provided, ensure 401 error if auth_configured
|
140 |
if auth_configured and not token:
|
141 |
raise HTTPException(
|
142 |
status_code=status.HTTP_401_UNAUTHORIZED,
|
|
|
149 |
status_code=HTTP_403_FORBIDDEN,
|
150 |
detail="Invalid API Key",
|
151 |
)
|
152 |
+
|
153 |
# if api_key_configured but not provided
|
154 |
if api_key_configured and not api_key_header_value:
|
155 |
raise HTTPException(
|