enricorampazzo commited on
Commit
93d5af1
1 Parent(s): c8801b5

now using chatgpt4o

Browse files
Files changed (1) hide show
  1. dam_helper/repository/ondemand.py +1 -1
dam_helper/repository/ondemand.py CHANGED
@@ -36,7 +36,7 @@ class OndemandRepository(Repository):
36
  def send_prompt(self, prompt: str, add_to_history: bool = None) -> dict[str, str]:
37
  self._start_new_session_if_needed()
38
  headers = {"apiKey": os.getenv("API_KEY")}
39
- body = {'endpointId': 'predefined-openai-gpt3.5turbo', 'query': prompt, 'pluginIds': [], 'responseMode': 'sync'}
40
  url = f'https://api.on-demand.io/chat/v1/sessions/{self.session_id}/query'
41
  response = requests.post(url, headers=headers, json=body)
42
  return {"content": response.json()["data"]["answer"]}
 
36
  def send_prompt(self, prompt: str, add_to_history: bool = None) -> dict[str, str]:
37
  self._start_new_session_if_needed()
38
  headers = {"apiKey": os.getenv("API_KEY")}
39
+ body = {'endpointId': 'predefined-openai-gpt4o', 'query': prompt, 'pluginIds': [], 'responseMode': 'sync'}
40
  url = f'https://api.on-demand.io/chat/v1/sessions/{self.session_id}/query'
41
  response = requests.post(url, headers=headers, json=body)
42
  return {"content": response.json()["data"]["answer"]}