mol-healer 0.1.1__tar.gz → 0.1.3__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.
- {mol_healer-0.1.1/mol_healer.egg-info → mol_healer-0.1.3}/PKG-INFO +1 -1
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/__init__.py +1 -1
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/cli.py +2 -1
- mol_healer-0.1.3/healer/data/reactions/reaction_tags.txt +116 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/utils/utils.py +16 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/interface.py +4 -6
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/routes.py +1 -0
- mol_healer-0.1.1/healer/web/static/assets/index-26iheSaM.js → mol_healer-0.1.3/healer/web/static/assets/index-CNuOgwuw.js +24 -24
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/index.html +1 -1
- {mol_healer-0.1.1 → mol_healer-0.1.3/mol_healer.egg-info}/PKG-INFO +1 -1
- {mol_healer-0.1.1 → mol_healer-0.1.3}/mol_healer.egg-info/SOURCES.txt +2 -1
- {mol_healer-0.1.1 → mol_healer-0.1.3}/pyproject.toml +3 -2
- {mol_healer-0.1.1 → mol_healer-0.1.3}/LICENSE +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/README.md +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/application/__init__.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/application/healer.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/application/optimizers.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/application/tree_builder.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/data/buildingblocks/test_100_bb.sdf +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/data/buildingblocks/test_100_bb_processed.sdf +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/data/reactions/datamol_rxns.json +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/data/reactions/reactions.json +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/domain/__init__.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/domain/bb_repository.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/domain/building_block.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/domain/composition.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/domain/enumeration_record.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/domain/reaction_template.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/domain/retro_step.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/scripts/__init__.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/scripts/preprocess_bb_source.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/utils/__init__.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/utils/plotting.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/utils/rdkit_monkey_patch.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/__init__.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/app.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/celery_worker.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/models.py +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/assets/index-CKoNYPy6.css +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/favicon.ico +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/healer_logo_no_text.png +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/apple-touch-icon.png +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/apple-touch-icon.png:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/asset-manifest.json +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/asset-manifest.json:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/duo.html +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/duo.html:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/favicon-16x16.png +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/favicon-16x16.png:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/favicon-32x32.png +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/favicon-32x32.png:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/favicon.ico +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/favicon.ico:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/iframe.html +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/iframe.html:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/index.html +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/index.html:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/logo.svg +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/logo.svg:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/manifest.json +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/manifest.json:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/popup.html +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/popup.html:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/robots.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/robots.txt:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/serve.json +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/serve.json:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/css/duo.de62a271.css +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/css/duo.de62a271.css:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/css/main.de62a271.css +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/css/main.de62a271.css:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/css/popup.de62a271.css +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/css/popup.de62a271.css:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/159.79fa9732.chunk.js +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/159.79fa9732.chunk.js:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/269.f5b4f042.chunk.js +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/269.f5b4f042.chunk.js:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/412.aebbbad4.chunk.js +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/412.aebbbad4.chunk.js:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/58.d9a0d434.chunk.js +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/58.d9a0d434.chunk.js.LICENSE.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/58.d9a0d434.chunk.js.LICENSE.txt:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/58.d9a0d434.chunk.js:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/duo.0464b98a.js +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/duo.0464b98a.js.LICENSE.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/duo.0464b98a.js.LICENSE.txt:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/duo.0464b98a.js:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/main.9c6dddff.js +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/main.9c6dddff.js.LICENSE.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/main.9c6dddff.js.LICENSE.txt:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/main.9c6dddff.js:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/popup.a25226a6.js +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/popup.a25226a6.js.LICENSE.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/popup.a25226a6.js.LICENSE.txt:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/healer/web/static/ketcher/static/js/popup.a25226a6.js:Zone.Identifier +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/mol_healer.egg-info/dependency_links.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/mol_healer.egg-info/entry_points.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/mol_healer.egg-info/requires.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/mol_healer.egg-info/top_level.txt +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/setup.cfg +0 -0
- {mol_healer-0.1.1 → mol_healer-0.1.3}/tests/test_tree_builder.py +0 -0
|
@@ -374,7 +374,8 @@ def add_common_args(parser: argparse.ArgumentParser) -> None:
|
|
|
374
374
|
parser.add_argument('--bb-source', default='US_stock',
|
|
375
375
|
help='Building block source: US_stock, EU_stock, Global_stock, or path')
|
|
376
376
|
parser.add_argument('--reactions', default='all',
|
|
377
|
-
help='Comma-separated reaction tags or "all" (default: all)'
|
|
377
|
+
help=f'Comma-separated reaction tags or "all" (default: all). '
|
|
378
|
+
f'Available tags: {", ".join(utils.get_reaction_tags())}')
|
|
378
379
|
parser.add_argument('--shuffle', action='store_true',
|
|
379
380
|
help='Shuffle building block order')
|
|
380
381
|
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
4-hydroxyquinoline
|
|
2
|
+
Barton-Zard
|
|
3
|
+
Biginelli
|
|
4
|
+
Bischler-Mohlau
|
|
5
|
+
Buchwald-Hartwig
|
|
6
|
+
C-C
|
|
7
|
+
C-C bond formation
|
|
8
|
+
C-N
|
|
9
|
+
C-N bond formation
|
|
10
|
+
C-O
|
|
11
|
+
C-O bond formation
|
|
12
|
+
C-S
|
|
13
|
+
C-S bond formation
|
|
14
|
+
CO insertion
|
|
15
|
+
Castro-Stephens
|
|
16
|
+
Chan-Lam
|
|
17
|
+
Claisen
|
|
18
|
+
Conrad-Limpach
|
|
19
|
+
Curtius Rearrangement
|
|
20
|
+
Erlenmeyer-Plochl
|
|
21
|
+
Feist-Benary
|
|
22
|
+
Fischer
|
|
23
|
+
Friedel-Crafts
|
|
24
|
+
Friedlander
|
|
25
|
+
Goldberg
|
|
26
|
+
Guareshi-Thorpe
|
|
27
|
+
Hantzsch
|
|
28
|
+
Heck
|
|
29
|
+
Knorr
|
|
30
|
+
Krohnke
|
|
31
|
+
Mitsunobu
|
|
32
|
+
N-arylation
|
|
33
|
+
Negishi
|
|
34
|
+
Niementowski
|
|
35
|
+
O-arylation
|
|
36
|
+
Paal-Knorr
|
|
37
|
+
Pechmann
|
|
38
|
+
Pictet-Spengler
|
|
39
|
+
S-arylation
|
|
40
|
+
Sonagashira
|
|
41
|
+
Stille
|
|
42
|
+
Suzuki
|
|
43
|
+
Ullman
|
|
44
|
+
Ullmann
|
|
45
|
+
Williamson
|
|
46
|
+
acetylene
|
|
47
|
+
acylation
|
|
48
|
+
alkylation
|
|
49
|
+
alkyne
|
|
50
|
+
all
|
|
51
|
+
amide
|
|
52
|
+
amide coupling
|
|
53
|
+
amination
|
|
54
|
+
amine
|
|
55
|
+
aminothiophene
|
|
56
|
+
arylation
|
|
57
|
+
azlactone
|
|
58
|
+
azole
|
|
59
|
+
benzimidazole
|
|
60
|
+
benzofuran
|
|
61
|
+
benzothiazole
|
|
62
|
+
benzothiophene
|
|
63
|
+
benzoxazole
|
|
64
|
+
beta-ketoester
|
|
65
|
+
biaryl
|
|
66
|
+
biginelli
|
|
67
|
+
boronate
|
|
68
|
+
boronic acid
|
|
69
|
+
boronic ester
|
|
70
|
+
carbamate
|
|
71
|
+
carbamates
|
|
72
|
+
chromanone
|
|
73
|
+
click
|
|
74
|
+
condensation
|
|
75
|
+
coumarin
|
|
76
|
+
cross coupling
|
|
77
|
+
cyclization
|
|
78
|
+
diaryl amine
|
|
79
|
+
diketone
|
|
80
|
+
diyne
|
|
81
|
+
ester
|
|
82
|
+
esterification
|
|
83
|
+
ether
|
|
84
|
+
etherification
|
|
85
|
+
flavone
|
|
86
|
+
furan
|
|
87
|
+
heterocycle
|
|
88
|
+
heterocycle formation
|
|
89
|
+
imidazole
|
|
90
|
+
indole
|
|
91
|
+
organostannane
|
|
92
|
+
oxadiazole
|
|
93
|
+
oxazole
|
|
94
|
+
phthalazinone
|
|
95
|
+
pyrazole
|
|
96
|
+
pyridine
|
|
97
|
+
pyridone
|
|
98
|
+
pyrimidine
|
|
99
|
+
pyrimidinedione
|
|
100
|
+
pyrimidone
|
|
101
|
+
pyrrole
|
|
102
|
+
quinazoline
|
|
103
|
+
quinazolinone
|
|
104
|
+
quinoline
|
|
105
|
+
reductive amination
|
|
106
|
+
spiro-chromanone
|
|
107
|
+
sulfonamide
|
|
108
|
+
tetrazole
|
|
109
|
+
thiazole
|
|
110
|
+
thioether
|
|
111
|
+
thiophene
|
|
112
|
+
thiourea
|
|
113
|
+
triazole
|
|
114
|
+
trifluoroborate
|
|
115
|
+
urea
|
|
116
|
+
ureas
|
|
@@ -6,6 +6,7 @@ import os
|
|
|
6
6
|
import sys
|
|
7
7
|
import json
|
|
8
8
|
import base64
|
|
9
|
+
from pathlib import Path
|
|
9
10
|
from typing import List, Union, Tuple
|
|
10
11
|
from itertools import chain
|
|
11
12
|
|
|
@@ -92,6 +93,21 @@ def read_cxsmiles_file(file_path: str, header: bool=True) -> list[str]:
|
|
|
92
93
|
|
|
93
94
|
return smiles_list
|
|
94
95
|
|
|
96
|
+
def get_reaction_tags() -> list[str]:
|
|
97
|
+
'''
|
|
98
|
+
Retrieves available reaction tags from the reaction_tags.txt file.
|
|
99
|
+
|
|
100
|
+
Returns:
|
|
101
|
+
list of reaction tags as strings.
|
|
102
|
+
'''
|
|
103
|
+
healer_pkg = Path(__file__).parent.parent
|
|
104
|
+
reaction_tags_path = healer_pkg / 'data' / 'reactions' / 'reaction_tags.txt'
|
|
105
|
+
|
|
106
|
+
with open(reaction_tags_path, 'r') as file:
|
|
107
|
+
tags = [line.strip() for line in file if line.strip()]
|
|
108
|
+
|
|
109
|
+
return tags
|
|
110
|
+
|
|
95
111
|
def load_reactions_from_json(file_path: str) -> list[ReactionTemplate21]:
|
|
96
112
|
'''
|
|
97
113
|
Loads reactions from a json file.
|
|
@@ -340,12 +340,10 @@ def format_enumeration_results(results: List[Dict[str, Any]], app_type: str) ->
|
|
|
340
340
|
if result.get(url_key):
|
|
341
341
|
display_result[url_key] = result[url_key]
|
|
342
342
|
elif app_type == 'site':
|
|
343
|
-
if bb_keys and result.get(bb_keys[
|
|
344
|
-
display_result['BB'] = result[bb_keys[
|
|
345
|
-
if result.get('
|
|
346
|
-
display_result['URL'] = result['
|
|
347
|
-
elif result.get('URL1'):
|
|
348
|
-
display_result['URL'] = result['URL1']
|
|
343
|
+
if bb_keys and result.get(bb_keys[1]):
|
|
344
|
+
display_result['BB'] = result[bb_keys[1]]
|
|
345
|
+
if result.get('URL2'):
|
|
346
|
+
display_result['URL'] = result['URL2']
|
|
349
347
|
|
|
350
348
|
rxn_keys = [k for k in result.keys() if k.startswith('Reaction') and k.endswith('_name')]
|
|
351
349
|
if rxn_keys:
|
|
@@ -248,6 +248,7 @@ async def get_reaction_tags():
|
|
|
248
248
|
reaction_tags_path = healer_pkg / 'data' / 'reactions' / 'reaction_tags.txt'
|
|
249
249
|
|
|
250
250
|
if not reaction_tags_path.exists():
|
|
251
|
+
print("Warning: reaction_tags.txt not found, returning default tags")
|
|
251
252
|
return ["amide coupling", "amide", "C-N bond formation", "C-N",
|
|
252
253
|
"alkylation", "N-arylation", "azole", "amination"]
|
|
253
254
|
|