mirror of
https://github.com/khoj-ai/khoj.git
synced 2024-11-27 17:35:07 +01:00
Fix arg to generate_summary_from_file and type of this_iteration
This commit is contained in:
parent
feb6d65ef8
commit
c6c48cfc18
3 changed files with 4 additions and 3 deletions
|
@ -84,7 +84,7 @@ class InformationCollectionIteration:
|
|||
self,
|
||||
tool: str,
|
||||
query: str,
|
||||
context: Dict[str, Dict] = None,
|
||||
context: list = None,
|
||||
onlineContext: dict = None,
|
||||
codeContext: dict = None,
|
||||
summarizedResult: str = None,
|
||||
|
|
|
@ -647,8 +647,8 @@ async def generate_summary_from_files(
|
|||
q,
|
||||
contextual_data,
|
||||
conversation_history=meta_log,
|
||||
subscribed=subscribed,
|
||||
uploaded_image_url=uploaded_image_url,
|
||||
user=user,
|
||||
agent=agent,
|
||||
)
|
||||
response_log = str(response)
|
||||
|
|
|
@ -147,6 +147,7 @@ async def execute_information_collection(
|
|||
code_results: Dict = dict()
|
||||
compiled_references: List[Any] = []
|
||||
inferred_queries: List[Any] = []
|
||||
this_iteration = InformationCollectionIteration(tool=None, query=query)
|
||||
previous_iterations_history = construct_iteration_history(previous_iterations, prompts.previous_iteration)
|
||||
|
||||
async for result in apick_next_tool(
|
||||
|
@ -163,7 +164,7 @@ async def execute_information_collection(
|
|||
):
|
||||
if isinstance(result, dict) and ChatEvent.STATUS in result:
|
||||
yield result[ChatEvent.STATUS]
|
||||
else:
|
||||
elif isinstance(result, InformationCollectionIteration):
|
||||
this_iteration = result
|
||||
|
||||
if this_iteration.tool == ConversationCommand.Notes:
|
||||
|
|
Loading…
Reference in a new issue