yangdx
commited on
Commit
·
3e1df32
1
Parent(s):
330ab9a
Remove summary length check for entity relations
Browse files- lightrag/operate.py +5 -2
lightrag/operate.py
CHANGED
@@ -121,8 +121,11 @@ async def _handle_entity_relation_summary(
|
|
121 |
)
|
122 |
|
123 |
tokens = tokenizer.encode(description)
|
124 |
-
|
125 |
-
|
|
|
|
|
|
|
126 |
prompt_template = PROMPTS["summarize_entity_descriptions"]
|
127 |
use_description = tokenizer.decode(tokens[:llm_max_tokens])
|
128 |
context_base = dict(
|
|
|
121 |
)
|
122 |
|
123 |
tokens = tokenizer.encode(description)
|
124 |
+
|
125 |
+
### summarize is not determined here anymore (It's determined by num_fragment now)
|
126 |
+
# if len(tokens) < summary_max_tokens: # No need for summary
|
127 |
+
# return description
|
128 |
+
|
129 |
prompt_template = PROMPTS["summarize_entity_descriptions"]
|
130 |
use_description = tokenizer.decode(tokens[:llm_max_tokens])
|
131 |
context_base = dict(
|