from selective_context import SelectiveContext sc = SelectiveContext(model_type='gpt2', lang='en') context_string = "nn".join(context_list) context, reduced_content = sc(context_string, reduce_ratio = 0.5,reduce_level="sent") prompt = qa_template.format(context_str="nn".join(reduced_content), query_str=question) response = llm.complete(prompt) print(str(response))