Skip to content

Commit

Permalink
Lil fix
Browse files Browse the repository at this point in the history
  • Loading branch information
keell0renz committed Sep 22, 2024
1 parent db479b0 commit 5a94bc2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/example/_multion/router.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class BooksToBuy(BaseModel):
books: List[str] = Field(description="The list of titles of the books mentioned", default=[], min_items=0)


async def retrieve_books_to_buy(transcript: str) -> List[str]:
def retrieve_books_to_buy(transcript: str) -> List[str]:
chat = ChatGroq(temperature=0, model="llama3-groq-8b-8192-tool-use-preview").with_structured_output(BooksToBuy)

response: BooksToBuy = chat.invoke(f'''
Expand Down Expand Up @@ -165,7 +165,7 @@ async def multion_endpoint(memory: Memory, uid: str = Query(...)):
if not user_id:
raise HTTPException(status_code=400, detail="Invalid UID or USERID not found.")

books = await retrieve_books_to_buy(memory.get_transcript())
books = retrieve_books_to_buy(memory.get_transcript())
if not books:
return EndpointResponse(message='No books were suggested or mentioned.')

Expand Down

0 comments on commit 5a94bc2

Please sign in to comment.