hi all, just a short, hopefully not completely stupid, question. I have the following short application (roughly):
d = 1536 # chatGPT embedding
faiss_index = faiss.IndexFlatL2(d)
vector_store = FaissVectorStore(faiss_index)
storage_context = StorageContext.from_defaults(vector_store=vector_store)
llm_predictor2 = LLMPredictor(llm=ChatOpenAI(temperature=0, model_name="gpt-4"))
service_context = ServiceContext.from_defaults(llm_predictor=llm_predictor2)
# initialize an index using our sample data and the client we just created
index = VectorStoreIndex.from_documents(storage_context=storage_context,
documents=documents, service_context=service_context)
query_engine = index.as_query_engine()
From what I understand with using chatgpt-4 the maximum context size is 8192, so i want to make sure i only retrieve k-amount of vectors of size 1536 so that k*1536<8192 (roughly). So my question is, do I have to set k manually somewhere or is there a fundamental misunderstanding?