Hi EgNLP, the issue appears to have been resolved. try pip install --upgrade langchain. I updated around 10 EST (30 minutes ago) and the error cleared.
What I had noticed even before but forgot to include in my inquiry is that the penultimate line of the notebook is exactly like you wrore:
response = index.query(query, llm=llm)
and it worked well in that instance.
So now we know that the key was including llm=llm in it.
# account for deprecation of LLM model
import datetime
# Get the current date
current_date = datetime.datetime.now().date()
# Define the date after which the model should be set to “gpt-3.5-turbo”
target_date = datetime.date(2024, 6, 12)
# Set the model variable based on the current date
if current_date > target_date:
llm_model = “gpt-3.5-turbo”
else:
llm_model = “gpt-3.5-turbo-0301”
sets llm_model to gpt-3.5-turbo
But with that
response for below question is coming blank
Yes, i can confirm that this was my experience too. “gpt-3.5-turbo-0301” is the one giving useable outputs. Current code is generating a blank markdown response.