Meshyboi commited on
Commit
685a08e
Β·
verified Β·
1 Parent(s): 6c06c2f

Update core/pipeline_3/logic.py

Browse files
Files changed (1) hide show
  1. core/pipeline_3/logic.py +1 -1
core/pipeline_3/logic.py CHANGED
@@ -743,7 +743,7 @@ class PipelineGraphRAG:
743
 
744
  usage = None
745
  for chunk in stream:
746
- if chunk.choices[0].delta.content:
747
  token = chunk.choices[0].delta.content
748
  full_answer += token
749
  yield {"type": "token", "data": token}
 
743
 
744
  usage = None
745
  for chunk in stream:
746
+ if chunk.choices and chunk.choices[0].delta.content:
747
  token = chunk.choices[0].delta.content
748
  full_answer += token
749
  yield {"type": "token", "data": token}