tablassert 22.3.0__tar.gz → 22.3.2__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.
- {tablassert-22.3.0 → tablassert-22.3.2}/PKG-INFO +16 -15
- {tablassert-22.3.0 → tablassert-22.3.2}/README.md +15 -14
- {tablassert-22.3.0 → tablassert-22.3.2}/pyproject.toml +1 -1
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/Cargo.lock +4 -4
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/cli.py +23 -3
- {tablassert-22.3.0 → tablassert-22.3.2}/LICENSE +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/Cargo.toml +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/examples/count_tables.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/src/fullmap.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/src/json.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/src/lib.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/src/ndjson.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/src/nlp.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/src/uuid.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/tests/build_golden.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/tests/common/mod.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/tests/extract_prebuilt.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/tests/fixtures/nlp_golden.tsv +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/rust/tests/nlp_golden.rs +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/__init__.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/_lazy.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/biolink.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/cli_entry.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/coerce.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/data/experimental_taxa.yaml +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/data/infores_catalog.yaml +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/enums.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/errors.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/extras.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/fullmap.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/infores_registry.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/ingests.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/lib.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/log.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/models.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/net.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/nlp.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/progress.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/qc.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/rig.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/rs.pyi +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/runcache.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/study.py +0 -0
- {tablassert-22.3.0 → tablassert-22.3.2}/src/tablassert/utils.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: tablassert
|
|
3
|
-
Version: 22.3.
|
|
3
|
+
Version: 22.3.2
|
|
4
4
|
Classifier: License :: OSI Approved :: Apache Software License
|
|
5
5
|
Classifier: Development Status :: 5 - Production/Stable
|
|
6
6
|
Classifier: Intended Audience :: Science/Research
|
|
@@ -73,20 +73,21 @@ configuration reference, and API docs.
|
|
|
73
73
|
|
|
74
74
|
## Statement of need
|
|
75
75
|
|
|
76
|
-
Biomedical knowledge
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
76
|
+
Biomedical knowledge graphs classically rely on bespoke ingest scripts for each source. When data
|
|
77
|
+
sources lack standardization, such as the millions of tables published in biomedical literature,
|
|
78
|
+
bespoke scripts impose three costs that limit scalability. First, mapping each table's rows,
|
|
79
|
+
columns, and cells to biological assertions is idiosyncratic, making them hard to inspect, review,
|
|
80
|
+
or reuse. Second, entity resolution may depend on hosted network services, making graph builds
|
|
81
|
+
unreproducible. Third, and most importantly, because each source requires a new pipeline, most
|
|
82
|
+
published tables are never ingested and remain neither interoperable nor reusable.
|
|
83
|
+
|
|
84
|
+
Tablassert supports knowledge-graph engineers and bioinformaticians working with tabular biomedical
|
|
85
|
+
sources who need standards-conformant output. Declarative YAML recipes make data-to-statement
|
|
86
|
+
mapping scalable, inspectable, and reusable. Batched resolution against an embedded identifier
|
|
87
|
+
database removes runtime service dependencies. These recipes extend beyond journal supplemental
|
|
88
|
+
tables to any relational source (trial registries, drug approval records, or a researcher's own
|
|
89
|
+
tables). Each build can emit a standardized resource descriptor, like the Resource Ingest Guide
|
|
90
|
+
metadata required for integration with Translator.
|
|
90
91
|
|
|
91
92
|
## Getting help
|
|
92
93
|
|
|
@@ -19,20 +19,21 @@ configuration reference, and API docs.
|
|
|
19
19
|
|
|
20
20
|
## Statement of need
|
|
21
21
|
|
|
22
|
-
Biomedical knowledge
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
22
|
+
Biomedical knowledge graphs classically rely on bespoke ingest scripts for each source. When data
|
|
23
|
+
sources lack standardization, such as the millions of tables published in biomedical literature,
|
|
24
|
+
bespoke scripts impose three costs that limit scalability. First, mapping each table's rows,
|
|
25
|
+
columns, and cells to biological assertions is idiosyncratic, making them hard to inspect, review,
|
|
26
|
+
or reuse. Second, entity resolution may depend on hosted network services, making graph builds
|
|
27
|
+
unreproducible. Third, and most importantly, because each source requires a new pipeline, most
|
|
28
|
+
published tables are never ingested and remain neither interoperable nor reusable.
|
|
29
|
+
|
|
30
|
+
Tablassert supports knowledge-graph engineers and bioinformaticians working with tabular biomedical
|
|
31
|
+
sources who need standards-conformant output. Declarative YAML recipes make data-to-statement
|
|
32
|
+
mapping scalable, inspectable, and reusable. Batched resolution against an embedded identifier
|
|
33
|
+
database removes runtime service dependencies. These recipes extend beyond journal supplemental
|
|
34
|
+
tables to any relational source (trial registries, drug approval records, or a researcher's own
|
|
35
|
+
tables). Each build can emit a standardized resource descriptor, like the Resource Ingest Guide
|
|
36
|
+
metadata required for integration with Translator.
|
|
36
37
|
|
|
37
38
|
## Getting help
|
|
38
39
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "tablassert"
|
|
3
|
-
version = "22.3.
|
|
3
|
+
version = "22.3.2"
|
|
4
4
|
description = "Tablassert turns biomedical spreadsheets (Excel, CSV, TSV) into knowledge graphs ready for NCATS Translator. Declare how your columns map to subject–predicate–object statements in YAML; Tablassert resolves free text to standard CURIEs, attaches provenance and statistical annotations, and emits KGX-compliant nodes and edges."
|
|
5
5
|
authors = [
|
|
6
6
|
{ name = "Skye Lane Goetz", email = "sgoetz@isbscience.org" }
|
|
@@ -141,9 +141,9 @@ checksum = "5baebc0774151f905a1a2cc41989300b1e6fbb29aff0ceffa1064fdd3088d582"
|
|
|
141
141
|
|
|
142
142
|
[[package]]
|
|
143
143
|
name = "flate2"
|
|
144
|
-
version = "1.1.
|
|
144
|
+
version = "1.1.11"
|
|
145
145
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
146
|
-
checksum = "
|
|
146
|
+
checksum = "626d4928326b646e70f65ed36fc7cf9f206bdb68a0019ee7c6b4709da4e084c4"
|
|
147
147
|
dependencies = [
|
|
148
148
|
"zlib-rs",
|
|
149
149
|
]
|
|
@@ -626,9 +626,9 @@ checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75"
|
|
|
626
626
|
|
|
627
627
|
[[package]]
|
|
628
628
|
name = "uuid"
|
|
629
|
-
version = "1.29.
|
|
629
|
+
version = "1.29.1"
|
|
630
630
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
631
|
-
checksum = "
|
|
631
|
+
checksum = "4a06f08a856b009bc7bbaf7d3e79808595d032dd19074c0c2ef26e49e03e6bdc"
|
|
632
632
|
dependencies = [
|
|
633
633
|
"js-sys",
|
|
634
634
|
"md-5",
|
|
@@ -5,7 +5,8 @@ import re
|
|
|
5
5
|
import subprocess
|
|
6
6
|
import sys
|
|
7
7
|
import time
|
|
8
|
-
from collections.abc import Callable
|
|
8
|
+
from collections.abc import Callable, Iterator
|
|
9
|
+
from contextlib import contextmanager
|
|
9
10
|
from importlib import import_module
|
|
10
11
|
from importlib.metadata import version as get_version
|
|
11
12
|
from itertools import chain, pairwise
|
|
@@ -35,6 +36,25 @@ else:
|
|
|
35
36
|
pl = LazyModule("polars")
|
|
36
37
|
pydantic = LazyModule("pydantic")
|
|
37
38
|
|
|
39
|
+
|
|
40
|
+
@contextmanager
|
|
41
|
+
def _pipeline_pool() -> Iterator[Any]:
|
|
42
|
+
"""Drain workers normally; terminate only when a pipeline stage fails.
|
|
43
|
+
|
|
44
|
+
Pool.__exit__ terminates even successful workers, bypassing cleanup of
|
|
45
|
+
worker-local logging queues and leaking named semaphores under forkserver.
|
|
46
|
+
"""
|
|
47
|
+
pool = Pool()
|
|
48
|
+
try:
|
|
49
|
+
yield pool
|
|
50
|
+
pool.close()
|
|
51
|
+
pool.join()
|
|
52
|
+
except BaseException:
|
|
53
|
+
pool.terminate()
|
|
54
|
+
pool.join()
|
|
55
|
+
raise
|
|
56
|
+
|
|
57
|
+
|
|
38
58
|
# Pipeline completion events (BUILD, VALIDATE).
|
|
39
59
|
logger = cat("PIPELINE")
|
|
40
60
|
# BABEL downloader events (reuse, restart, done, retry).
|
|
@@ -320,7 +340,7 @@ def build_graph_pipeline(
|
|
|
320
340
|
# index and we reassemble by index to keep raw[i] aligned with g.tables[i].
|
|
321
341
|
start, advance, _ = progress.section_loop(len(g.tables), "Load")
|
|
322
342
|
raw: list[object] = [None for _ in g.tables]
|
|
323
|
-
with
|
|
343
|
+
with _pipeline_pool() as pool:
|
|
324
344
|
for idx, parsed in pool.imap_unordered(_load_table_indexed, enumerate(g.tables)):
|
|
325
345
|
raw[idx] = parsed
|
|
326
346
|
start(str(g.tables[idx]))
|
|
@@ -332,7 +352,7 @@ def build_graph_pipeline(
|
|
|
332
352
|
# flattened sections order is byte-identical to the old starmap result.
|
|
333
353
|
start, advance, _ = progress.section_loop(len(g.tables), "Extract")
|
|
334
354
|
temp: list[list[dict[str, Any]]] = [[] for _ in g.tables]
|
|
335
|
-
with
|
|
355
|
+
with _pipeline_pool() as pool:
|
|
336
356
|
for idx, section_list in pool.imap_unordered(_extract_sections_indexed, zip(range(len(g.tables)), raw, g.tables, strict=True)):
|
|
337
357
|
temp[idx] = section_list
|
|
338
358
|
start(str(g.tables[idx]))
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|