Skip to content

Commit

Permalink
GML-1602 fix the endpoint to match copilot
Browse files Browse the repository at this point in the history
  • Loading branch information
Lu Zhou authored and Lu Zhou committed Apr 2, 2024
1 parent 061e105 commit 8bcbfe8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pyTigerGraph/ai/ai.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def registerCustomQuery(self, function_header: str, description: str, docstring:
"docstring": docstring,
"param_types": param_types
}
url = self.nlqs_host+"/"+self.conn.graphname+"/registercustomquery"
url = self.nlqs_host+"/"+self.conn.graphname+"/register_docs"
return self.conn._req("POST", url, authMode="pwd", data = data, jsonData=True, resKey=None)

def retrieveDocs(self, query:str, top_k:int = 3):
Expand All @@ -58,7 +58,7 @@ def retrieveDocs(self, query:str, top_k:int = 3):
"query": query
}

url = self.nlqs_host+"/"+self.conn.graphname+"/retrievedocs?top_k="+str(top_k)
url = self.nlqs_host+"/"+self.conn.graphname+"/retrieve_docs?top_k="+str(top_k)
return self.conn._req("POST", url, authMode="pwd", data = data, jsonData=True, resKey=None, skipCheck=True)

def query(self, query):
Expand Down

0 comments on commit 8bcbfe8

Please sign in to comment.