zaheer140 commited on
Commit
eedee9e
·
verified ·
1 Parent(s): 4832a8c

Update rag/retriever.py

Browse files
Files changed (1) hide show
  1. rag/retriever.py +1 -2
rag/retriever.py CHANGED
@@ -234,8 +234,7 @@ def expand_context(top_chunks: list[dict], machine_id: str) -> list[dict]:
234
 
235
  # Traverse forward up to 1 chunk (stricter boundary)
236
  curr = c
237
- for _ in range(8):
238
- # for _ in range(2):
239
  next_id = curr.get("next_chunk")
240
  if next_id and next_id in local_lookup:
241
  nxt = local_lookup[next_id]
 
234
 
235
  # Traverse forward up to 1 chunk (stricter boundary)
236
  curr = c
237
+ for _ in range(2):
 
238
  next_id = curr.get("next_chunk")
239
  if next_id and next_id in local_lookup:
240
  nxt = local_lookup[next_id]