closurizer 0.2.0__tar.gz → 0.2.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -24,7 +24,7 @@ def _length(value):
|
|
24
24
|
def _length_of_field_values(rec, fields):
|
25
25
|
value = 0
|
26
26
|
for field in fields:
|
27
|
-
if
|
27
|
+
if (field_value := rec[field]) is not None:
|
28
28
|
value += _length(field_value)
|
29
29
|
return value
|
30
30
|
|
@@ -32,7 +32,7 @@ def add_closure(kg_archive: str,
|
|
32
32
|
closure_file: str,
|
33
33
|
output_file: str,
|
34
34
|
fields: List[str] = ['subject', 'object'],
|
35
|
-
evidence_fields: List[str] = ['has_evidence', 'publications', 'primary_knowledge_source'
|
35
|
+
evidence_fields: List[str] = ['has_evidence', 'publications', 'primary_knowledge_source']
|
36
36
|
):
|
37
37
|
print("Generating closure KG...")
|
38
38
|
print(f"kg_archive: {kg_archive}")
|
File without changes
|