You'll have to pass a Document object in there. Which can be done in the following way.
from llama_index import Document
text_list = [text1, text2, ...]
documents = [Document(text=t) for t in text_list]
# Pass this list of Documents in the index
index = SummaryIndex.from_documents(
documents=documents,
service_context=service_context,
show_progress=True
)
query_engine = index.as_query_engine(
service_context=service_context,
text_qa_template=qa_prompt_template,
use_async=True
)
response = query_engine.query(question)