ExposoGraph 0.0.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.
- exposograph-0.0.1/.claude/settings.local.json +17 -0
- exposograph-0.0.1/.github/workflows/ci.yml +47 -0
- exposograph-0.0.1/.github/workflows/publish.yml +21 -0
- exposograph-0.0.1/.gitignore +37 -0
- exposograph-0.0.1/.pre-commit-config.yaml +7 -0
- exposograph-0.0.1/.readthedocs.yaml +15 -0
- exposograph-0.0.1/.streamlit/config.toml +9 -0
- exposograph-0.0.1/.streamlit/secrets.toml.example +5 -0
- exposograph-0.0.1/ExposoGraph/__init__.py +104 -0
- exposograph-0.0.1/ExposoGraph/app.py +1260 -0
- exposograph-0.0.1/ExposoGraph/branding.py +9 -0
- exposograph-0.0.1/ExposoGraph/config.py +41 -0
- exposograph-0.0.1/ExposoGraph/engine.py +148 -0
- exposograph-0.0.1/ExposoGraph/exporter.py +310 -0
- exposograph-0.0.1/ExposoGraph/llm_extractor.py +166 -0
- exposograph-0.0.1/ExposoGraph/models.py +180 -0
- exposograph-0.0.1/ExposoGraph/reference_data.py +674 -0
- exposograph-0.0.1/ExposoGraph/storage.py +261 -0
- exposograph-0.0.1/ExposoGraph_notebook.ipynb +1178 -0
- exposograph-0.0.1/LICENSE +21 -0
- exposograph-0.0.1/PKG-INFO +162 -0
- exposograph-0.0.1/README.md +112 -0
- exposograph-0.0.1/docs/Makefile +14 -0
- exposograph-0.0.1/docs/_build/html/.buildinfo +4 -0
- exposograph-0.0.1/docs/_build/html/.buildinfo.bak +4 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/api/config.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/api/engine.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/api/exporter.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/api/llm_extractor.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/api/models.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/api/reference_data.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/api/storage.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/changelog.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/deployment.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/environment.pickle +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/gene-panels.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/index.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/quickstart.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/.doctrees/schema.doctree +0 -0
- exposograph-0.0.1/docs/_build/html/_modules/ExposoGraph/config.html +173 -0
- exposograph-0.0.1/docs/_build/html/_modules/ExposoGraph/engine.html +313 -0
- exposograph-0.0.1/docs/_build/html/_modules/ExposoGraph/exporter.html +463 -0
- exposograph-0.0.1/docs/_build/html/_modules/ExposoGraph/llm_extractor.html +289 -0
- exposograph-0.0.1/docs/_build/html/_modules/ExposoGraph/models.html +327 -0
- exposograph-0.0.1/docs/_build/html/_modules/ExposoGraph/reference_data.html +812 -0
- exposograph-0.0.1/docs/_build/html/_modules/ExposoGraph/storage.html +411 -0
- exposograph-0.0.1/docs/_build/html/_modules/index.html +125 -0
- exposograph-0.0.1/docs/_build/html/_modules/kg_builder/config.html +173 -0
- exposograph-0.0.1/docs/_build/html/_modules/kg_builder/engine.html +313 -0
- exposograph-0.0.1/docs/_build/html/_modules/kg_builder/exporter.html +463 -0
- exposograph-0.0.1/docs/_build/html/_modules/kg_builder/llm_extractor.html +286 -0
- exposograph-0.0.1/docs/_build/html/_modules/kg_builder/models.html +321 -0
- exposograph-0.0.1/docs/_build/html/_modules/kg_builder/reference_data.html +371 -0
- exposograph-0.0.1/docs/_build/html/_modules/kg_builder/storage.html +411 -0
- exposograph-0.0.1/docs/_build/html/_sources/api/config.rst.txt +14 -0
- exposograph-0.0.1/docs/_build/html/_sources/api/engine.rst.txt +9 -0
- exposograph-0.0.1/docs/_build/html/_sources/api/exporter.rst.txt +8 -0
- exposograph-0.0.1/docs/_build/html/_sources/api/llm_extractor.rst.txt +16 -0
- exposograph-0.0.1/docs/_build/html/_sources/api/models.rst.txt +46 -0
- exposograph-0.0.1/docs/_build/html/_sources/api/reference_data.rst.txt +44 -0
- exposograph-0.0.1/docs/_build/html/_sources/api/storage.rst.txt +16 -0
- exposograph-0.0.1/docs/_build/html/_sources/changelog.rst.txt +18 -0
- exposograph-0.0.1/docs/_build/html/_sources/deployment.rst.txt +63 -0
- exposograph-0.0.1/docs/_build/html/_sources/gene-panels.rst.txt +236 -0
- exposograph-0.0.1/docs/_build/html/_sources/index.rst.txt +55 -0
- exposograph-0.0.1/docs/_build/html/_sources/quickstart.rst.txt +114 -0
- exposograph-0.0.1/docs/_build/html/_sources/schema.rst.txt +137 -0
- exposograph-0.0.1/docs/_build/html/_static/alabaster.css +708 -0
- exposograph-0.0.1/docs/_build/html/_static/basic.css +906 -0
- exposograph-0.0.1/docs/_build/html/_static/custom.css +1 -0
- exposograph-0.0.1/docs/_build/html/_static/doctools.js +149 -0
- exposograph-0.0.1/docs/_build/html/_static/documentation_options.js +13 -0
- exposograph-0.0.1/docs/_build/html/_static/file.png +0 -0
- exposograph-0.0.1/docs/_build/html/_static/language_data.js +192 -0
- exposograph-0.0.1/docs/_build/html/_static/minus.png +0 -0
- exposograph-0.0.1/docs/_build/html/_static/plus.png +0 -0
- exposograph-0.0.1/docs/_build/html/_static/pygments.css +84 -0
- exposograph-0.0.1/docs/_build/html/_static/searchtools.js +635 -0
- exposograph-0.0.1/docs/_build/html/_static/sphinx_highlight.js +154 -0
- exposograph-0.0.1/docs/_build/html/api/config.html +192 -0
- exposograph-0.0.1/docs/_build/html/api/engine.html +329 -0
- exposograph-0.0.1/docs/_build/html/api/exporter.html +329 -0
- exposograph-0.0.1/docs/_build/html/api/llm_extractor.html +167 -0
- exposograph-0.0.1/docs/_build/html/api/models.html +419 -0
- exposograph-0.0.1/docs/_build/html/api/reference_data.html +245 -0
- exposograph-0.0.1/docs/_build/html/api/storage.html +332 -0
- exposograph-0.0.1/docs/_build/html/changelog.html +142 -0
- exposograph-0.0.1/docs/_build/html/deployment.html +183 -0
- exposograph-0.0.1/docs/_build/html/gene-panels.html +417 -0
- exposograph-0.0.1/docs/_build/html/genindex.html +517 -0
- exposograph-0.0.1/docs/_build/html/index.html +241 -0
- exposograph-0.0.1/docs/_build/html/objects.inv +0 -0
- exposograph-0.0.1/docs/_build/html/py-modindex.html +143 -0
- exposograph-0.0.1/docs/_build/html/quickstart.html +233 -0
- exposograph-0.0.1/docs/_build/html/schema.html +298 -0
- exposograph-0.0.1/docs/_build/html/search.html +140 -0
- exposograph-0.0.1/docs/_build/html/searchindex.js +1 -0
- exposograph-0.0.1/docs/api/config.rst +14 -0
- exposograph-0.0.1/docs/api/engine.rst +9 -0
- exposograph-0.0.1/docs/api/exporter.rst +8 -0
- exposograph-0.0.1/docs/api/llm_extractor.rst +16 -0
- exposograph-0.0.1/docs/api/models.rst +46 -0
- exposograph-0.0.1/docs/api/reference_data.rst +44 -0
- exposograph-0.0.1/docs/api/storage.rst +16 -0
- exposograph-0.0.1/docs/changelog.rst +18 -0
- exposograph-0.0.1/docs/conf.py +62 -0
- exposograph-0.0.1/docs/deployment.rst +63 -0
- exposograph-0.0.1/docs/gene-panels.rst +236 -0
- exposograph-0.0.1/docs/index.rst +55 -0
- exposograph-0.0.1/docs/quickstart.rst +122 -0
- exposograph-0.0.1/docs/requirements.txt +3 -0
- exposograph-0.0.1/docs/schema.rst +137 -0
- exposograph-0.0.1/pyproject.toml +77 -0
- exposograph-0.0.1/requirements.txt +5 -0
- exposograph-0.0.1/tests/__init__.py +0 -0
- exposograph-0.0.1/tests/test_config.py +28 -0
- exposograph-0.0.1/tests/test_engine.py +172 -0
- exposograph-0.0.1/tests/test_exporter.py +171 -0
- exposograph-0.0.1/tests/test_models.py +167 -0
- exposograph-0.0.1/tests/test_reference_data.py +161 -0
- exposograph-0.0.1/tests/test_storage.py +109 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
{
|
|
2
|
+
"permissions": {
|
|
3
|
+
"allow": [
|
|
4
|
+
"Bash(git init:*)",
|
|
5
|
+
"Bash(git add:*)",
|
|
6
|
+
"Bash(git commit:*)",
|
|
7
|
+
"Bash(python -m pytest tests/ -v)",
|
|
8
|
+
"Bash(pip install:*)",
|
|
9
|
+
"Bash(python -c \"import openai; print\\(openai.__version__\\)\")",
|
|
10
|
+
"Bash(conda list:*)",
|
|
11
|
+
"Bash(pip list:*)",
|
|
12
|
+
"Bash(conda run:*)",
|
|
13
|
+
"Bash(conda install:*)",
|
|
14
|
+
"WebFetch(domain:www.perplexity.ai)"
|
|
15
|
+
]
|
|
16
|
+
}
|
|
17
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main]
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
lint:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
steps:
|
|
13
|
+
- uses: actions/checkout@v4
|
|
14
|
+
- uses: actions/setup-python@v5
|
|
15
|
+
with:
|
|
16
|
+
python-version: "3.12"
|
|
17
|
+
- run: pip install ruff
|
|
18
|
+
- run: ruff check .
|
|
19
|
+
- run: ruff format --check .
|
|
20
|
+
|
|
21
|
+
test:
|
|
22
|
+
runs-on: ubuntu-latest
|
|
23
|
+
strategy:
|
|
24
|
+
matrix:
|
|
25
|
+
python-version: ["3.10", "3.11", "3.12"]
|
|
26
|
+
steps:
|
|
27
|
+
- uses: actions/checkout@v4
|
|
28
|
+
- uses: actions/setup-python@v5
|
|
29
|
+
with:
|
|
30
|
+
python-version: ${{ matrix.python-version }}
|
|
31
|
+
- run: pip install -e ".[dev]"
|
|
32
|
+
- run: pytest tests/ -v
|
|
33
|
+
|
|
34
|
+
build:
|
|
35
|
+
runs-on: ubuntu-latest
|
|
36
|
+
needs: [lint, test]
|
|
37
|
+
steps:
|
|
38
|
+
- uses: actions/checkout@v4
|
|
39
|
+
- uses: actions/setup-python@v5
|
|
40
|
+
with:
|
|
41
|
+
python-version: "3.12"
|
|
42
|
+
- run: pip install build
|
|
43
|
+
- run: python -m build
|
|
44
|
+
- uses: actions/upload-artifact@v4
|
|
45
|
+
with:
|
|
46
|
+
name: dist
|
|
47
|
+
path: dist/
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
name: Publish to PyPI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
|
|
7
|
+
permissions:
|
|
8
|
+
id-token: write
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
publish:
|
|
12
|
+
runs-on: ubuntu-latest
|
|
13
|
+
environment: pypi
|
|
14
|
+
steps:
|
|
15
|
+
- uses: actions/checkout@v4
|
|
16
|
+
- uses: actions/setup-python@v5
|
|
17
|
+
with:
|
|
18
|
+
python-version: "3.12"
|
|
19
|
+
- run: pip install build
|
|
20
|
+
- run: python -m build
|
|
21
|
+
- uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# Python
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
*.egg-info/
|
|
6
|
+
dist/
|
|
7
|
+
build/
|
|
8
|
+
*.egg
|
|
9
|
+
|
|
10
|
+
# Virtual environments
|
|
11
|
+
.venv/
|
|
12
|
+
venv/
|
|
13
|
+
env/
|
|
14
|
+
|
|
15
|
+
# IDE
|
|
16
|
+
.vscode/
|
|
17
|
+
.idea/
|
|
18
|
+
*.swp
|
|
19
|
+
*.swo
|
|
20
|
+
|
|
21
|
+
# OS
|
|
22
|
+
.DS_Store
|
|
23
|
+
Thumbs.db
|
|
24
|
+
|
|
25
|
+
# Secrets & env
|
|
26
|
+
.env
|
|
27
|
+
.streamlit/secrets.toml
|
|
28
|
+
|
|
29
|
+
# Jupyter
|
|
30
|
+
.ipynb_checkpoints/
|
|
31
|
+
|
|
32
|
+
# Testing
|
|
33
|
+
.pytest_cache/
|
|
34
|
+
.mypy_cache/
|
|
35
|
+
.ruff_cache/
|
|
36
|
+
htmlcov/
|
|
37
|
+
.coverage
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"""ExposoGraph.
|
|
2
|
+
|
|
3
|
+
Build, curate, and export carcinogen metabolism knowledge graphs
|
|
4
|
+
using LLM-powered extraction and manual entry.
|
|
5
|
+
|
|
6
|
+
Parts of this documentation and code were created with assistance
|
|
7
|
+
from ChatGPT Codex and Claude Code.
|
|
8
|
+
"""
|
|
9
|
+
|
|
10
|
+
from .branding import (
|
|
11
|
+
APP_NAME,
|
|
12
|
+
APP_TAGLINE,
|
|
13
|
+
APP_VERSION,
|
|
14
|
+
CONTACT_EMAIL,
|
|
15
|
+
COPYRIGHT_HOLDER,
|
|
16
|
+
DEVELOPED_BY,
|
|
17
|
+
)
|
|
18
|
+
|
|
19
|
+
__version__ = APP_VERSION
|
|
20
|
+
|
|
21
|
+
from .config import AppMode, get_app_mode, normalize_app_mode, persistence_enabled
|
|
22
|
+
from .engine import GraphEngine
|
|
23
|
+
from .exporter import (
|
|
24
|
+
ensure_viewer_bundle,
|
|
25
|
+
export_viewer_bundle,
|
|
26
|
+
parse_graph_artifact,
|
|
27
|
+
parse_graph_data_text,
|
|
28
|
+
parse_graph_html,
|
|
29
|
+
parse_graph_data_js,
|
|
30
|
+
to_gexf,
|
|
31
|
+
to_graph_data_js,
|
|
32
|
+
to_interactive_html,
|
|
33
|
+
to_interactive_html_string,
|
|
34
|
+
to_json,
|
|
35
|
+
)
|
|
36
|
+
from .llm_extractor import extract_graph
|
|
37
|
+
from .models import (
|
|
38
|
+
CurationConfidence,
|
|
39
|
+
CurationRecord,
|
|
40
|
+
CurationStatus,
|
|
41
|
+
Edge,
|
|
42
|
+
EdgeType,
|
|
43
|
+
KnowledgeGraph,
|
|
44
|
+
Node,
|
|
45
|
+
NodeType,
|
|
46
|
+
ProvenanceRecord,
|
|
47
|
+
)
|
|
48
|
+
from .reference_data import (
|
|
49
|
+
ACTIVITY_SCORE_METADATA,
|
|
50
|
+
ACTIVITY_SCORES,
|
|
51
|
+
build_full_panel,
|
|
52
|
+
build_tier1_panel,
|
|
53
|
+
build_tier2_panel,
|
|
54
|
+
get_activity_score_metadata,
|
|
55
|
+
get_activity_score_references,
|
|
56
|
+
get_activity_scores,
|
|
57
|
+
)
|
|
58
|
+
from .storage import GraphRepository, GraphRevision, GraphRevisionSummary
|
|
59
|
+
|
|
60
|
+
__all__ = [
|
|
61
|
+
"ACTIVITY_SCORES",
|
|
62
|
+
"ACTIVITY_SCORE_METADATA",
|
|
63
|
+
"APP_NAME",
|
|
64
|
+
"APP_TAGLINE",
|
|
65
|
+
"APP_VERSION",
|
|
66
|
+
"AppMode",
|
|
67
|
+
"CONTACT_EMAIL",
|
|
68
|
+
"COPYRIGHT_HOLDER",
|
|
69
|
+
"CurationConfidence",
|
|
70
|
+
"CurationRecord",
|
|
71
|
+
"CurationStatus",
|
|
72
|
+
"DEVELOPED_BY",
|
|
73
|
+
"Edge",
|
|
74
|
+
"EdgeType",
|
|
75
|
+
"GraphEngine",
|
|
76
|
+
"GraphRepository",
|
|
77
|
+
"GraphRevision",
|
|
78
|
+
"GraphRevisionSummary",
|
|
79
|
+
"KnowledgeGraph",
|
|
80
|
+
"Node",
|
|
81
|
+
"NodeType",
|
|
82
|
+
"ProvenanceRecord",
|
|
83
|
+
"ensure_viewer_bundle",
|
|
84
|
+
"export_viewer_bundle",
|
|
85
|
+
"parse_graph_artifact",
|
|
86
|
+
"parse_graph_data_text",
|
|
87
|
+
"parse_graph_html",
|
|
88
|
+
"build_full_panel",
|
|
89
|
+
"build_tier1_panel",
|
|
90
|
+
"build_tier2_panel",
|
|
91
|
+
"extract_graph",
|
|
92
|
+
"get_app_mode",
|
|
93
|
+
"get_activity_score_metadata",
|
|
94
|
+
"get_activity_score_references",
|
|
95
|
+
"get_activity_scores",
|
|
96
|
+
"normalize_app_mode",
|
|
97
|
+
"persistence_enabled",
|
|
98
|
+
"to_interactive_html",
|
|
99
|
+
"to_interactive_html_string",
|
|
100
|
+
"parse_graph_data_js",
|
|
101
|
+
"to_gexf",
|
|
102
|
+
"to_graph_data_js",
|
|
103
|
+
"to_json",
|
|
104
|
+
]
|