armanddemasson commited on
Commit
2463f8b
·
1 Parent(s): 204ecfe

update retriever by PoC

Browse files
climateqa/engine/chains/retrieve_documents.py CHANGED
@@ -668,6 +668,12 @@ def make_POC_by_ToC_retriever_node(
668
  if "POC region" not in state["relevant_content_sources_selection"] :
669
  return {}
670
 
 
 
 
 
 
 
671
 
672
  tocs = get_ToCs(version=version)
673
 
@@ -675,8 +681,12 @@ def make_POC_by_ToC_retriever_node(
675
  POC_questions_index = [i for i, x in enumerate(state["questions_list"]) if x["source_type"] == "POC"]
676
 
677
  state = await retrieve_documents_for_all_questions(
678
- state=state,
 
679
  config=config,
 
 
 
680
  source_type=source_type,
681
  to_handle_questions_index=POC_questions_index,
682
  vectorstore=vectorstore,
 
668
  if "POC region" not in state["relevant_content_sources_selection"] :
669
  return {}
670
 
671
+ search_figures = "Figures (IPCC/IPBES)" in state["relevant_content_sources_selection"]
672
+ search_only = state["search_only"]
673
+ search_only = state["search_only"]
674
+ reports = state["reports"]
675
+ questions_list = state["questions_list"]
676
+ n_questions=state["n_questions"]["total"]
677
 
678
  tocs = get_ToCs(version=version)
679
 
 
681
  POC_questions_index = [i for i, x in enumerate(state["questions_list"]) if x["source_type"] == "POC"]
682
 
683
  state = await retrieve_documents_for_all_questions(
684
+ search_figures=search_figures,
685
+ search_only=search_only,
686
  config=config,
687
+ reports=reports,
688
+ questions_list=questions_list,
689
+ n_questions=n_questions,
690
  source_type=source_type,
691
  to_handle_questions_index=POC_questions_index,
692
  vectorstore=vectorstore,