workspace working
This commit is contained in:
9
extract_early_return.py
Normal file
9
extract_early_return.py
Normal file
@@ -0,0 +1,9 @@
|
||||
import sys
|
||||
with open('LightRAG-main/lightrag/operate.py', 'r', encoding='utf-8') as f:
|
||||
lines = f.readlines()
|
||||
for i, line in enumerate(lines):
|
||||
if 'if not search_result' in line and 'final_entities' in line:
|
||||
print(f'Found at line {i+1}: {line.strip()}')
|
||||
for j in range(max(0, i-2), min(len(lines), i+15)):
|
||||
print(f'{j+1}: {lines[j].rstrip()}')
|
||||
break
|
||||
Reference in New Issue
Block a user