@Logan M I think 5-7 LLM calls to openai.com
In the logs for my latest
agent_chain.run()
, I see there are 7 lines of
DEBUG:urllib3.connectionpool:https://api.openai.com:443 "POST /v1/chat/completions HTTP/1.1" 200 None
This
agent_chain.run()
consists of 7 LLM calls to openai made up of
- 1 QA prompt
- 6 refine prompts
Here are my settings/indexes:
llm = ChatOpenAI(temperature=0, model_name="gpt-3.5-turbo")
service_context = ServiceContext.from_defaults(
embed_model=OpenAIEmbedding(), llm_predictor=LLMPredictor(llm=llm)
)
index = GPTSimpleVectorIndex.load_from_disk("index.json", service_context=service_context)
index_configs = [
IndexToolConfig(
index=index,
name="Vector Index",
description="No description",
index_query_kwargs={
"similarity_top_k": 3,
"text_qa_template": qa_prompt,
"refine_template": refine_prompt,
},
tool_kwargs={"return_direct": True},
)
]
toolkit = LlamaToolkit(
index_configs=index_configs,
)