pritmanvar-bacancy commited on
Commit
33af5b5
·
verified ·
1 Parent(s): 6c8ff36

Update tools.py

Browse files
Files changed (1) hide show
  1. tools.py +1 -2
tools.py CHANGED
@@ -328,10 +328,9 @@ def recommand_podcast(prompt: str) -> str:
328
  context+= f"Row {index + 1}: Title: {row['title']} image: {row['cover_image']} referral_link: {row['referral_link']} category_id: {row['category_id']}"
329
  llm = ChatOpenAI(model=settings.OPENAI_MODEL, openai_api_key=settings.OPENAI_KEY, temperature=0.7)
330
  # Define the system prompt
331
- system_template = """ you are give the recommandation of podcast. also you are giving referal link of podcast.
332
  you must use the context only not any other information.
333
  context : {context}
334
- Input: {input}
335
  """
336
  print(system_template.format(context=context, input=prompt))
337
  response = llm.invoke(system_template.format(context=context, input=prompt))
 
328
  context+= f"Row {index + 1}: Title: {row['title']} image: {row['cover_image']} referral_link: {row['referral_link']} category_id: {row['category_id']}"
329
  llm = ChatOpenAI(model=settings.OPENAI_MODEL, openai_api_key=settings.OPENAI_KEY, temperature=0.7)
330
  # Define the system prompt
331
+ system_template = """ you have to give the recommandation of podcast for: {input}. also you are giving referal link of podcast.
332
  you must use the context only not any other information.
333
  context : {context}
 
334
  """
335
  print(system_template.format(context=context, input=prompt))
336
  response = llm.invoke(system_template.format(context=context, input=prompt))