mirror of
https://github.com/VectifyAI/PageIndex.git
synced 2026-07-03 20:41:02 +02:00
fix(filesystem): avoid duplicate pifs chat output
This commit is contained in:
parent
3625a592f2
commit
3d62293a1e
2 changed files with 38 additions and 5 deletions
|
|
@ -140,7 +140,9 @@ def _run_ask(argv: list[str], *, workspace_default: str | None) -> int:
|
|||
raise ValueError("ask requires a question")
|
||||
|
||||
filesystem = _filesystem_from_workspace(args.workspace)
|
||||
print(run_pifs_agent(filesystem, question, **_agent_kwargs(args)))
|
||||
answer = run_pifs_agent(filesystem, question, **_agent_kwargs(args))
|
||||
if args.stream_mode == "off":
|
||||
print(answer)
|
||||
return 0
|
||||
|
||||
|
||||
|
|
@ -164,7 +166,9 @@ def _run_chat(argv: list[str], *, workspace_default: str | None) -> int:
|
|||
continue
|
||||
if question.lower() in EXIT_COMMANDS:
|
||||
break
|
||||
print(run_pifs_agent(filesystem, question, **_agent_kwargs(args)))
|
||||
answer = run_pifs_agent(filesystem, question, **_agent_kwargs(args))
|
||||
if args.stream_mode == "off":
|
||||
print(answer)
|
||||
return 0
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue