jessicaj_30604
10/09/2024, 9:36 PMgpt-4-turbo to an OpenAI Assistant. The current code in llm_with_func_calling.py uses client.chat.completions.create():
async def draft_response(self, request: ResponseRequiredRequest):
prompt = self.prepare_prompt(request)
stream = await self.client.chat.completions.create(
model="gpt-4-turbo-preview",
messages=prompt,
stream=True,
tools=self.prepare_functions(),
)
Since Assistants use threads/runs/messages instead of chat.completions, do I just replace the completions code with the Assistant invocation? Is there anything specific I need to tweak, or will it even work? Couldn't find any example repos for this setup so any help is appreciated! Or if anyone could share an example? Or ... if RAG is going to be out Monday or something lol , I won't even bother with this 🥴 Thanks!Weijia - Support@Retell
10/10/2024, 3:26 AMNJ
10/10/2024, 6:05 AMNJ
10/10/2024, 6:05 AMjessicaj_30604
10/10/2024, 1:12 PM.teamrick
10/14/2024, 5:02 PM