pyobo 0.11.2__tar.gz → 0.12.0.dev0__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.
Files changed (264) hide show
  1. {pyobo-0.11.2/src/pyobo.egg-info → pyobo-0.12.0.dev0}/PKG-INFO +218 -216
  2. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/README.md +172 -163
  3. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/pyproject.toml +38 -35
  4. pyobo-0.12.0.dev0/src/pyobo/.DS_Store +0 -0
  5. pyobo-0.12.0.dev0/src/pyobo/__init__.py +145 -0
  6. pyobo-0.12.0.dev0/src/pyobo/_reference_tmp.py +35 -0
  7. pyobo-0.12.0.dev0/src/pyobo/api/__init__.py +126 -0
  8. pyobo-0.12.0.dev0/src/pyobo/api/alts.py +101 -0
  9. pyobo-0.12.0.dev0/src/pyobo/api/combine.py +38 -0
  10. pyobo-0.12.0.dev0/src/pyobo/api/edges.py +68 -0
  11. pyobo-0.12.0.dev0/src/pyobo/api/hierarchy.py +225 -0
  12. pyobo-0.12.0.dev0/src/pyobo/api/metadata.py +35 -0
  13. pyobo-0.12.0.dev0/src/pyobo/api/names.py +334 -0
  14. pyobo-0.12.0.dev0/src/pyobo/api/properties.py +210 -0
  15. pyobo-0.12.0.dev0/src/pyobo/api/relations.py +181 -0
  16. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/api/species.py +24 -21
  17. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/api/typedefs.py +11 -11
  18. pyobo-0.12.0.dev0/src/pyobo/api/utils.py +156 -0
  19. pyobo-0.12.0.dev0/src/pyobo/api/xrefs.py +174 -0
  20. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/aws.py +23 -22
  21. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/cli/cli.py +1 -47
  22. pyobo-0.12.0.dev0/src/pyobo/cli/database.py +360 -0
  23. pyobo-0.11.2/src/pyobo/xrefdb/xrefs_pipeline.py → pyobo-0.12.0.dev0/src/pyobo/cli/database_utils.py +52 -71
  24. pyobo-0.12.0.dev0/src/pyobo/cli/lookup.py +302 -0
  25. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/cli/utils.py +19 -6
  26. pyobo-0.12.0.dev0/src/pyobo/constants.py +199 -0
  27. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/getters.py +188 -117
  28. pyobo-0.12.0.dev0/src/pyobo/gilda_utils.py +151 -0
  29. pyobo-0.12.0.dev0/src/pyobo/identifier_utils.py +303 -0
  30. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/mocks.py +9 -6
  31. pyobo-0.12.0.dev0/src/pyobo/ner/__init__.py +7 -0
  32. pyobo-0.12.0.dev0/src/pyobo/ner/api.py +72 -0
  33. {pyobo-0.11.2/src/pyobo → pyobo-0.12.0.dev0/src/pyobo/ner}/normalizer.py +37 -43
  34. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/obographs.py +38 -29
  35. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/plugins.py +5 -4
  36. pyobo-0.12.0.dev0/src/pyobo/reader.py +1582 -0
  37. pyobo-0.12.0.dev0/src/pyobo/reader_utils.py +155 -0
  38. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/registries/metaregistry.json +453 -334
  39. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/registries/metaregistry.py +37 -3
  40. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/resource_utils.py +42 -22
  41. pyobo-0.12.0.dev0/src/pyobo/resources/goc.py +75 -0
  42. pyobo-0.12.0.dev0/src/pyobo/resources/goc.tsv +188 -0
  43. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/resources/ncbitaxon.py +4 -5
  44. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/resources/ro.py +3 -2
  45. pyobo-0.12.0.dev0/src/pyobo/sources/README.md +19 -0
  46. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/__init__.py +46 -27
  47. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/antibodyregistry.py +11 -12
  48. pyobo-0.12.0.dev0/src/pyobo/sources/bigg/__init__.py +13 -0
  49. pyobo-0.12.0.dev0/src/pyobo/sources/bigg/bigg_compartment.py +81 -0
  50. pyobo-0.12.0.dev0/src/pyobo/sources/bigg/bigg_metabolite.py +174 -0
  51. pyobo-0.12.0.dev0/src/pyobo/sources/bigg/bigg_model.py +46 -0
  52. pyobo-0.12.0.dev0/src/pyobo/sources/bigg/bigg_reaction.py +71 -0
  53. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/biogrid.py +1 -2
  54. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/ccle.py +7 -12
  55. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/cgnc.py +0 -5
  56. pyobo-0.12.0.dev0/src/pyobo/sources/chembl/__init__.py +9 -0
  57. pyobo-0.11.2/src/pyobo/sources/chembl.py → pyobo-0.12.0.dev0/src/pyobo/sources/chembl/chembl_compound.py +13 -25
  58. pyobo-0.12.0.dev0/src/pyobo/sources/chembl/chembl_target.py +152 -0
  59. pyobo-0.12.0.dev0/src/pyobo/sources/civic_gene.py +94 -0
  60. pyobo-0.12.0.dev0/src/pyobo/sources/clinicaltrials.py +158 -0
  61. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/complexportal.py +24 -24
  62. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/conso.py +14 -22
  63. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/credit.py +1 -9
  64. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/cvx.py +27 -5
  65. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/depmap.py +9 -12
  66. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/dictybase_gene.py +2 -7
  67. pyobo-0.12.0.dev0/src/pyobo/sources/drugbank/__init__.py +9 -0
  68. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/drugbank}/drugbank.py +11 -16
  69. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/drugbank}/drugbank_salt.py +3 -8
  70. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/drugcentral.py +4 -9
  71. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/expasy.py +31 -34
  72. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/famplex.py +13 -18
  73. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/flybase.py +3 -8
  74. pyobo-0.12.0.dev0/src/pyobo/sources/gard.py +62 -0
  75. pyobo-0.12.0.dev0/src/pyobo/sources/geonames/__init__.py +9 -0
  76. pyobo-0.12.0.dev0/src/pyobo/sources/geonames/features.py +28 -0
  77. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/geonames}/geonames.py +87 -26
  78. pyobo-0.12.0.dev0/src/pyobo/sources/geonames/utils.py +115 -0
  79. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/gmt_utils.py +6 -7
  80. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/go.py +20 -13
  81. pyobo-0.12.0.dev0/src/pyobo/sources/gtdb.py +154 -0
  82. pyobo-0.12.0.dev0/src/pyobo/sources/gwascentral/__init__.py +9 -0
  83. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/gwascentral}/gwascentral_phenotype.py +5 -7
  84. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/gwascentral}/gwascentral_study.py +1 -7
  85. pyobo-0.12.0.dev0/src/pyobo/sources/hgnc/__init__.py +9 -0
  86. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/hgnc}/hgnc.py +56 -70
  87. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/hgnc}/hgncgenefamily.py +8 -18
  88. pyobo-0.12.0.dev0/src/pyobo/sources/icd/__init__.py +9 -0
  89. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/icd}/icd10.py +35 -37
  90. pyobo-0.12.0.dev0/src/pyobo/sources/icd/icd11.py +148 -0
  91. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/icd}/icd_utils.py +66 -20
  92. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/interpro.py +4 -9
  93. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/itis.py +0 -5
  94. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/kegg/api.py +16 -38
  95. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/kegg/genes.py +9 -20
  96. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/kegg/genome.py +1 -7
  97. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/kegg/pathway.py +9 -21
  98. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/mesh.py +58 -24
  99. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/mgi.py +3 -10
  100. pyobo-0.12.0.dev0/src/pyobo/sources/mirbase/__init__.py +11 -0
  101. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/mirbase}/mirbase.py +8 -11
  102. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/mirbase}/mirbase_family.py +4 -8
  103. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/mirbase}/mirbase_mature.py +3 -7
  104. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/msigdb.py +64 -38
  105. pyobo-0.12.0.dev0/src/pyobo/sources/ncbi/__init__.py +9 -0
  106. pyobo-0.12.0.dev0/src/pyobo/sources/ncbi/ncbi_gc.py +162 -0
  107. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/ncbi}/ncbigene.py +18 -19
  108. pyobo-0.12.0.dev0/src/pyobo/sources/nih_reporter.py +60 -0
  109. pyobo-0.12.0.dev0/src/pyobo/sources/nlm/__init__.py +9 -0
  110. pyobo-0.12.0.dev0/src/pyobo/sources/nlm/nlm_catalog.py +48 -0
  111. pyobo-0.12.0.dev0/src/pyobo/sources/nlm/nlm_publisher.py +36 -0
  112. pyobo-0.12.0.dev0/src/pyobo/sources/nlm/utils.py +105 -0
  113. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/npass.py +6 -8
  114. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/omim_ps.py +10 -3
  115. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/pathbank.py +4 -8
  116. pyobo-0.12.0.dev0/src/pyobo/sources/pfam/__init__.py +9 -0
  117. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/pfam}/pfam.py +3 -8
  118. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/pfam}/pfam_clan.py +2 -7
  119. pyobo-0.12.0.dev0/src/pyobo/sources/pharmgkb/__init__.py +15 -0
  120. pyobo-0.12.0.dev0/src/pyobo/sources/pharmgkb/pharmgkb_chemical.py +85 -0
  121. pyobo-0.12.0.dev0/src/pyobo/sources/pharmgkb/pharmgkb_disease.py +77 -0
  122. pyobo-0.12.0.dev0/src/pyobo/sources/pharmgkb/pharmgkb_gene.py +108 -0
  123. pyobo-0.12.0.dev0/src/pyobo/sources/pharmgkb/pharmgkb_pathway.py +63 -0
  124. pyobo-0.12.0.dev0/src/pyobo/sources/pharmgkb/pharmgkb_variant.py +84 -0
  125. pyobo-0.12.0.dev0/src/pyobo/sources/pharmgkb/utils.py +86 -0
  126. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/pid.py +1 -6
  127. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/pombase.py +6 -10
  128. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/pubchem.py +4 -9
  129. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/reactome.py +5 -11
  130. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/rgd.py +11 -16
  131. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/rhea.py +37 -36
  132. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/ror.py +59 -39
  133. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/selventa/schem.py +4 -7
  134. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/selventa/scomp.py +1 -6
  135. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/selventa/sdis.py +4 -7
  136. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/selventa/sfam.py +1 -6
  137. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/sgd.py +6 -11
  138. pyobo-0.12.0.dev0/src/pyobo/sources/signor/__init__.py +7 -0
  139. pyobo-0.12.0.dev0/src/pyobo/sources/signor/download.py +41 -0
  140. pyobo-0.12.0.dev0/src/pyobo/sources/signor/signor_complexes.py +103 -0
  141. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/slm.py +9 -13
  142. pyobo-0.12.0.dev0/src/pyobo/sources/umls/__init__.py +9 -0
  143. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/umls/get_synonym_types.py +20 -4
  144. pyobo-0.12.0.dev0/src/pyobo/sources/umls/sty.py +57 -0
  145. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/umls/synonym_types.tsv +1 -1
  146. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/umls/umls.py +18 -22
  147. pyobo-0.12.0.dev0/src/pyobo/sources/unimod.py +46 -0
  148. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/uniprot/uniprot.py +40 -32
  149. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/uniprot/uniprot_ptm.py +4 -34
  150. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/utils.py +3 -2
  151. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/wikipathways.py +7 -10
  152. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/zfin.py +5 -10
  153. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/ssg/__init__.py +12 -16
  154. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/ssg/index.html +26 -13
  155. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/ssg/term.html +12 -2
  156. pyobo-0.12.0.dev0/src/pyobo/struct/__init__.py +80 -0
  157. pyobo-0.12.0.dev0/src/pyobo/struct/functional/__init__.py +1 -0
  158. pyobo-0.12.0.dev0/src/pyobo/struct/functional/dsl.py +2572 -0
  159. pyobo-0.12.0.dev0/src/pyobo/struct/functional/macros.py +423 -0
  160. pyobo-0.12.0.dev0/src/pyobo/struct/functional/obo_to_functional.py +385 -0
  161. pyobo-0.12.0.dev0/src/pyobo/struct/functional/ontology.py +270 -0
  162. pyobo-0.12.0.dev0/src/pyobo/struct/functional/utils.py +112 -0
  163. pyobo-0.12.0.dev0/src/pyobo/struct/reference.py +373 -0
  164. pyobo-0.12.0.dev0/src/pyobo/struct/struct.py +2277 -0
  165. pyobo-0.12.0.dev0/src/pyobo/struct/struct_utils.py +1078 -0
  166. pyobo-0.12.0.dev0/src/pyobo/struct/typedef.py +331 -0
  167. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/struct/utils.py +12 -5
  168. pyobo-0.12.0.dev0/src/pyobo/struct/vocabulary.py +138 -0
  169. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/utils/cache.py +13 -11
  170. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/utils/io.py +17 -31
  171. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/utils/iter.py +5 -5
  172. pyobo-0.12.0.dev0/src/pyobo/utils/misc.py +76 -0
  173. pyobo-0.12.0.dev0/src/pyobo/utils/path.py +147 -0
  174. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/version.py +3 -3
  175. pyobo-0.11.2/MANIFEST.in +0 -11
  176. pyobo-0.11.2/PKG-INFO +0 -711
  177. pyobo-0.11.2/setup.cfg +0 -4
  178. pyobo-0.11.2/src/pyobo/__init__.py +0 -68
  179. pyobo-0.11.2/src/pyobo/api/__init__.py +0 -55
  180. pyobo-0.11.2/src/pyobo/api/alts.py +0 -92
  181. pyobo-0.11.2/src/pyobo/api/hierarchy.py +0 -291
  182. pyobo-0.11.2/src/pyobo/api/metadata.py +0 -40
  183. pyobo-0.11.2/src/pyobo/api/names.py +0 -255
  184. pyobo-0.11.2/src/pyobo/api/properties.py +0 -206
  185. pyobo-0.11.2/src/pyobo/api/relations.py +0 -207
  186. pyobo-0.11.2/src/pyobo/api/utils.py +0 -104
  187. pyobo-0.11.2/src/pyobo/api/xrefs.py +0 -187
  188. pyobo-0.11.2/src/pyobo/cli/database.py +0 -338
  189. pyobo-0.11.2/src/pyobo/cli/lookup.py +0 -334
  190. pyobo-0.11.2/src/pyobo/constants.py +0 -99
  191. pyobo-0.11.2/src/pyobo/gilda_utils.py +0 -272
  192. pyobo-0.11.2/src/pyobo/identifier_utils.py +0 -142
  193. pyobo-0.11.2/src/pyobo/reader.py +0 -620
  194. pyobo-0.11.2/src/pyobo/sources/README.md +0 -15
  195. pyobo-0.11.2/src/pyobo/sources/civic_gene.py +0 -54
  196. pyobo-0.11.2/src/pyobo/sources/icd11.py +0 -105
  197. pyobo-0.11.2/src/pyobo/sources/umls/__init__.py +0 -3
  198. pyobo-0.11.2/src/pyobo/struct/__init__.py +0 -34
  199. pyobo-0.11.2/src/pyobo/struct/reference.py +0 -178
  200. pyobo-0.11.2/src/pyobo/struct/struct.py +0 -1496
  201. pyobo-0.11.2/src/pyobo/struct/typedef.py +0 -379
  202. pyobo-0.11.2/src/pyobo/utils/misc.py +0 -88
  203. pyobo-0.11.2/src/pyobo/utils/path.py +0 -141
  204. pyobo-0.11.2/src/pyobo/xrefdb/__init__.py +0 -1
  205. pyobo-0.11.2/src/pyobo/xrefdb/canonicalizer.py +0 -214
  206. pyobo-0.11.2/src/pyobo/xrefdb/priority.py +0 -59
  207. pyobo-0.11.2/src/pyobo/xrefdb/sources/__init__.py +0 -60
  208. pyobo-0.11.2/src/pyobo/xrefdb/sources/biomappings.py +0 -36
  209. pyobo-0.11.2/src/pyobo/xrefdb/sources/cbms2019.py +0 -91
  210. pyobo-0.11.2/src/pyobo/xrefdb/sources/chembl.py +0 -83
  211. pyobo-0.11.2/src/pyobo/xrefdb/sources/compath.py +0 -82
  212. pyobo-0.11.2/src/pyobo/xrefdb/sources/famplex.py +0 -64
  213. pyobo-0.11.2/src/pyobo/xrefdb/sources/gilda.py +0 -50
  214. pyobo-0.11.2/src/pyobo/xrefdb/sources/intact.py +0 -113
  215. pyobo-0.11.2/src/pyobo/xrefdb/sources/ncit.py +0 -133
  216. pyobo-0.11.2/src/pyobo/xrefdb/sources/pubchem.py +0 -27
  217. pyobo-0.11.2/src/pyobo/xrefdb/sources/wikidata.py +0 -116
  218. pyobo-0.11.2/src/pyobo.egg-info/SOURCES.txt +0 -181
  219. pyobo-0.11.2/src/pyobo.egg-info/dependency_links.txt +0 -1
  220. pyobo-0.11.2/src/pyobo.egg-info/entry_points.txt +0 -2
  221. pyobo-0.11.2/src/pyobo.egg-info/requires.txt +0 -36
  222. pyobo-0.11.2/src/pyobo.egg-info/top_level.txt +0 -1
  223. pyobo-0.11.2/tests/__init__.py +0 -1
  224. pyobo-0.11.2/tests/constants.py +0 -18
  225. pyobo-0.11.2/tests/resources/citations.txt +0 -201
  226. pyobo-0.11.2/tests/resources/test_chebi.obo +0 -436
  227. pyobo-0.11.2/tests/resources/test_msigdb.gmt +0 -3
  228. pyobo-0.11.2/tests/resources/test_wikipathways.gmt +0 -3
  229. pyobo-0.11.2/tests/test_alt_ids.py +0 -91
  230. pyobo-0.11.2/tests/test_caches.py +0 -86
  231. pyobo-0.11.2/tests/test_extract.py +0 -63
  232. pyobo-0.11.2/tests/test_get.py +0 -264
  233. pyobo-0.11.2/tests/test_gmt.py +0 -57
  234. pyobo-0.11.2/tests/test_ground.py +0 -38
  235. pyobo-0.11.2/tests/test_mapper.py +0 -63
  236. pyobo-0.11.2/tests/test_sources/__init__.py +0 -1
  237. pyobo-0.11.2/tests/test_sources/test_famplex.py +0 -14
  238. pyobo-0.11.2/tests/test_sources/test_meta.py +0 -38
  239. pyobo-0.11.2/tests/test_struct.py +0 -51
  240. pyobo-0.11.2/tests/test_utils.py +0 -75
  241. pyobo-0.11.2/tests/test_version_pins.py +0 -44
  242. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/LICENSE +0 -0
  243. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/__main__.py +0 -0
  244. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/cli/__init__.py +0 -0
  245. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/cli/aws.py +0 -0
  246. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/py.typed +0 -0
  247. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/registries/__init__.py +0 -0
  248. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/resources/__init__.py +0 -0
  249. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/resources/ncbitaxon.tsv.gz +0 -0
  250. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/resources/ro.tsv +0 -0
  251. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/resources/so.py +0 -0
  252. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/resources/so.tsv +0 -0
  253. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/agrovoc.py +0 -0
  254. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/chebi.py +1 -1
  255. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/cpt.py +0 -0
  256. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/kegg/__init__.py +0 -0
  257. {pyobo-0.11.2/src/pyobo/sources → pyobo-0.12.0.dev0/src/pyobo/sources/mirbase}/mirbase_constants.py +0 -0
  258. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/selventa/__init__.py +0 -0
  259. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/umls/__main__.py +0 -0
  260. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/sources/uniprot/__init__.py +1 -1
  261. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/ssg/base.html +0 -0
  262. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/ssg/typedef.html +0 -0
  263. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/utils/__init__.py +0 -0
  264. {pyobo-0.11.2 → pyobo-0.12.0.dev0}/src/pyobo/utils/ndex_utils.py +0 -0
@@ -1,36 +1,11 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: pyobo
3
- Version: 0.11.2
3
+ Version: 0.12.0.dev0
4
4
  Summary: A python package for handling and generating OBO
5
- Author-email: Charles Tapley Hoyt <cthoyt@gmail.com>
6
- Maintainer-email: Charles Tapley Hoyt <cthoyt@gmail.com>
7
- License: MIT License
8
-
9
- Copyright (c) 2024 Charles Tapley Hoyt
10
-
11
- Permission is hereby granted, free of charge, to any person obtaining a copy
12
- of this software and associated documentation files (the "Software"), to deal
13
- in the Software without restriction, including without limitation the rights
14
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
15
- copies of the Software, and to permit persons to whom the Software is
16
- furnished to do so, subject to the following conditions:
17
-
18
- The above copyright notice and this permission notice shall be included in all
19
- copies or substantial portions of the Software.
20
-
21
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
27
- SOFTWARE.
28
-
29
- Project-URL: Bug Tracker, https://github.com/biopragmatics/pyobo/issues
30
- Project-URL: Homepage, https://github.com/biopragmatics/pyobo
31
- Project-URL: Repository, https://github.com/biopragmatics/pyobo.git
32
- Project-URL: Documentation, https://pyobo.readthedocs.io
33
5
  Keywords: snekpack,cookiecutter,ontologies,biomedical ontologies,life sciences,natural sciences,bioinformatics,cheminformatics,Open Biomedical Ontologies,OBO
6
+ Author: Charles Tapley Hoyt
7
+ Author-email: Charles Tapley Hoyt <cthoyt@gmail.com>
8
+ License-File: LICENSE
34
9
  Classifier: Development Status :: 4 - Beta
35
10
  Classifier: Environment :: Console
36
11
  Classifier: Intended Audience :: Developers
@@ -39,16 +14,16 @@ Classifier: Operating System :: OS Independent
39
14
  Classifier: Framework :: Pytest
40
15
  Classifier: Framework :: tox
41
16
  Classifier: Framework :: Sphinx
17
+ Classifier: Natural Language :: English
42
18
  Classifier: Programming Language :: Python
43
- Classifier: Programming Language :: Python :: 3.9
44
19
  Classifier: Programming Language :: Python :: 3.10
45
20
  Classifier: Programming Language :: Python :: 3.11
46
21
  Classifier: Programming Language :: Python :: 3.12
22
+ Classifier: Programming Language :: Python :: 3.13
47
23
  Classifier: Programming Language :: Python :: 3 :: Only
24
+ Classifier: Typing :: Typed
48
25
  Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
49
26
  Classifier: Topic :: Scientific/Engineering :: Chemistry
50
- Requires-Python: >=3.9
51
- Description-Content-Type: text/markdown
52
27
  Requires-Dist: obonet>=0.3.0
53
28
  Requires-Dist: click
54
29
  Requires-Dist: tqdm
@@ -56,33 +31,51 @@ Requires-Dist: pyyaml
56
31
  Requires-Dist: pandas
57
32
  Requires-Dist: requests
58
33
  Requires-Dist: protmapper
59
- Requires-Dist: more_itertools
60
- Requires-Dist: more_click>=0.0.2
34
+ Requires-Dist: more-itertools
35
+ Requires-Dist: more-click>=0.0.2
61
36
  Requires-Dist: humanize
62
37
  Requires-Dist: tabulate
63
38
  Requires-Dist: cachier
64
- Requires-Dist: pystow>=0.2.7
65
- Requires-Dist: bioversions>=0.5.535
66
- Requires-Dist: bioregistry>=0.11.23
67
- Requires-Dist: bioontologies>=0.4.0
68
- Requires-Dist: zenodo-client>=0.0.5
69
- Requires-Dist: class_resolver
39
+ Requires-Dist: pystow>=0.7.0
40
+ Requires-Dist: bioversions>=0.7.0
41
+ Requires-Dist: bioregistry>=0.12.0
42
+ Requires-Dist: bioontologies>=0.5.2
43
+ Requires-Dist: ssslm>=0.0.9
44
+ Requires-Dist: zenodo-client>=0.3.6
45
+ Requires-Dist: class-resolver
70
46
  Requires-Dist: psycopg2-binary
71
47
  Requires-Dist: pydantic>=2.0
72
- Requires-Dist: requests-ftp
73
- Requires-Dist: drugbank_downloader
74
- Requires-Dist: chembl_downloader
75
- Requires-Dist: umls_downloader>=0.1.3
76
- Requires-Dist: typing_extensions
48
+ Requires-Dist: curies>=0.10.6
49
+ Requires-Dist: python-dateutil
50
+ Requires-Dist: networkx>=3.4
51
+ Requires-Dist: drugbank-downloader
52
+ Requires-Dist: chembl-downloader
53
+ Requires-Dist: umls-downloader>=0.1.3
54
+ Requires-Dist: clinicaltrials-downloader>=0.0.2
55
+ Requires-Dist: nih-reporter-downloader>=0.0.1
56
+ Requires-Dist: typing-extensions
77
57
  Requires-Dist: rdflib
78
- Provides-Extra: tests
79
- Requires-Dist: pytest; extra == "tests"
80
- Requires-Dist: coverage; extra == "tests"
58
+ Requires-Dist: sphinx>=8 ; extra == 'docs'
59
+ Requires-Dist: sphinx-rtd-theme>=3.0 ; extra == 'docs'
60
+ Requires-Dist: sphinx-click ; extra == 'docs'
61
+ Requires-Dist: sphinx-automodapi ; extra == 'docs'
62
+ Requires-Dist: ssslm[gilda] ; extra == 'gilda'
63
+ Requires-Dist: ssslm[gilda-slim] ; extra == 'gilda-slim'
64
+ Requires-Dist: pytest ; extra == 'tests'
65
+ Requires-Dist: coverage[toml] ; extra == 'tests'
66
+ Maintainer: Charles Tapley Hoyt
67
+ Maintainer-email: Charles Tapley Hoyt <cthoyt@gmail.com>
68
+ Requires-Python: >=3.10
69
+ Project-URL: Bug Tracker, https://github.com/biopragmatics/pyobo/issues
70
+ Project-URL: Documentation, https://pyobo.readthedocs.io
71
+ Project-URL: Funding, https://github.com/sponsors/cthoyt
72
+ Project-URL: Homepage, https://github.com/biopragmatics/pyobo
73
+ Project-URL: Repository, https://github.com/biopragmatics/pyobo.git
81
74
  Provides-Extra: docs
82
- Requires-Dist: sphinx>=8; extra == "docs"
83
- Requires-Dist: sphinx-rtd-theme>=3.0; extra == "docs"
84
- Requires-Dist: sphinx-click; extra == "docs"
85
- Requires-Dist: sphinx_automodapi; extra == "docs"
75
+ Provides-Extra: gilda
76
+ Provides-Extra: gilda-slim
77
+ Provides-Extra: tests
78
+ Description-Content-Type: text/markdown
86
79
 
87
80
  <!--
88
81
  <p align="center">
@@ -117,25 +110,24 @@ Requires-Dist: sphinx_automodapi; extra == "docs"
117
110
  <img src="https://zenodo.org/badge/DOI/10.5281/zenodo.3381961.svg" alt="DOI"></a>
118
111
  </p>
119
112
 
120
- Tools for biological identifiers, names, synonyms, xrefs, hierarchies, relations, and properties through the
121
- perspective of OBO.
113
+ Tools for biological identifiers, names, synonyms, xrefs, hierarchies,
114
+ relations, and properties through the perspective of OBO.
122
115
 
123
116
  ## Example Usage
124
117
 
125
- Note! PyOBO is no-nonsense. This means that there's no repetitive
126
- prefixes in identifiers. It also means all identifiers are strings,
127
- no exceptions.
118
+ Note! PyOBO is no-nonsense. This means that there's no repetitive prefixes in
119
+ identifiers. It also means all identifiers are strings, no exceptions.
128
120
 
129
- Note! The first time you run these, they have to download and cache
130
- all resources. We're not in the business of redistributing data,
131
- so all scripts should be completely reproducible. There's some
132
- AWS tools for hosting/downloading pre-compiled versions in
133
- `pyobo.aws` if you don't have time for that.
121
+ Note! The first time you run these, they have to download and cache all
122
+ resources. We're not in the business of redistributing data, so all scripts
123
+ should be completely reproducible. There's some AWS tools for
124
+ hosting/downloading pre-compiled versions in `pyobo.aws` if you don't have time
125
+ for that.
134
126
 
135
- Note! PyOBO can perform grounding in a limited number of cases, but
136
- it is *not* a general solution for named entity recognition (NER) or grounding.
137
- It's suggested to check `Gilda <https://github.com/indralab/gilda>`_
138
- for a no-nonsense solution.
127
+ Note! PyOBO can perform grounding in a limited number of cases, but it is _not_
128
+ a general solution for named entity recognition (NER) or grounding. It's
129
+ suggested to check `Gilda <https://github.com/indralab/gilda>`\_ for a
130
+ no-nonsense solution.
139
131
 
140
132
  ### Mapping Identifiers and CURIEs
141
133
 
@@ -185,6 +177,7 @@ one using alternative identifiers listed in the underlying OBO with:
185
177
 
186
178
  ```python
187
179
  import pyobo
180
+ from pyobo import Reference
188
181
 
189
182
  # Look up DNA-binding transcription factor activity (go:0003700)
190
183
  # based on an old id
@@ -192,13 +185,13 @@ primary_curie = pyobo.get_primary_curie('go:0001071')
192
185
  assert primary_curie == 'go:0003700'
193
186
 
194
187
  # If it's already the primary, it just gets returned
195
- assert 'go:0003700' == pyobo.get_priority_curie('go:0003700')
188
+ assert Reference.from_curie('go:0003700') == pyobo.get_primary_curie('go:0003700')
196
189
  ```
197
190
 
198
191
  ### Mapping Species
199
192
 
200
- Some resources have species information for their term. Get a mapping of WikiPathway identifiers
201
- to species (as NCBI taxonomy identifiers):
193
+ Some resources have species information for their term. Get a mapping of
194
+ WikiPathway identifiers to species (as NCBI taxonomy identifiers):
202
195
 
203
196
  ```python
204
197
  import pyobo
@@ -241,9 +234,9 @@ assert identifier is None
241
234
  assert name is None
242
235
  ```
243
236
 
244
- If you're not really sure which namespace a name might belong to, you
245
- can try a few in a row (prioritize by ones that cover the appropriate
246
- entity type to avoid false positives in case of conflicts):
237
+ If you're not really sure which namespace a name might belong to, you can try a
238
+ few in a row (prioritize by ones that cover the appropriate entity type to avoid
239
+ false positives in case of conflicts):
247
240
 
248
241
  ```python
249
242
  import pyobo
@@ -277,8 +270,8 @@ pubchem_compound_id = pyobo.get_xref('chebi', '132964', 'pubchem.compound')
277
270
  assert pubchem_compound_id == '3033674'
278
271
  ```
279
272
 
280
- Get xrefs from Entrez to HGNC, but they're only available through HGNC,
281
- so you need to flip them:
273
+ Get xrefs from Entrez to HGNC, but they're only available through HGNC, so you
274
+ need to flip them:
282
275
 
283
276
  ```python
284
277
  import pyobo
@@ -292,8 +285,8 @@ mapt_hgnc = ncbigene_id_to_hgnc_id['4137']
292
285
  assert mapt_hgnc == '6893'
293
286
  ```
294
287
 
295
- Since this is a common pattern, there's a keyword argument `flip`
296
- that does this for you:
288
+ Since this is a common pattern, there's a keyword argument `flip` that does this
289
+ for you:
297
290
 
298
291
  ```python
299
292
  import pyobo
@@ -313,45 +306,10 @@ hgnc_id = pyobo.get_xref('hgnc', '4137', 'ncbigene', flip=True)
313
306
  assert hgnc_id == '6893'
314
307
  ```
315
308
 
316
- Remap a CURIE based on pre-defined priority list and [Inspector Javert's Xref
317
- Database](https://cthoyt.com/2020/04/19/inspector-javerts-xref-database.html):
318
-
319
- ```python
320
-
321
- import pyobo
322
-
323
- # Map to the best source possible
324
- mapt_ncbigene = pyobo.get_priority_curie('hgnc:6893')
325
- assert mapt_ncbigene == 'ncbigene:4137'
326
-
327
- # Sometimes you know you're the best. Own it.
328
- assert 'ncbigene:4137' == pyobo.get_priority_curie('ncbigene:4137')
329
- ```
330
-
331
- Find all CURIEs mapped to a given one using Inspector Javert's Xref Database:
332
-
333
- ```python
334
- import pyobo
335
-
336
- # Get a set of all CURIEs mapped to MAPT
337
- mapt_curies = pyobo.get_equivalent('hgnc:6893')
338
- assert 'ncbigene:4137' in mapt_curies
339
- assert 'ensembl:ENSG00000186868' in mapt_curies
340
- ```
341
-
342
- If you don't want to wait to build the database locally for the `pyobo.get_priority_curie` and
343
- `pyobo.get_equivalent`, you can use the following code to download a release from
344
- [Zenodo](https://zenodo.org/record/3757266):
345
-
346
- ```python
347
- import pyobo.resource_utils
348
-
349
- pyobo.resource_utils.ensure_inspector_javert()
350
- ```
351
-
352
309
  ### Properties
353
310
 
354
- Get properties, like SMILES. The semantics of these are defined on an OBO-OBO basis.
311
+ Get properties, like SMILES. The semantics of these are defined on an OBO-OBO
312
+ basis.
355
313
 
356
314
  ```python
357
315
  import pyobo
@@ -378,47 +336,50 @@ assert smiles == 'C1(=CC=C(N=C1)OC2=CC=C(C=C2)O[C@@H](C(OCCCC)=O)C)C(F)(F)F'
378
336
  Check if an entity is in the hierarchy:
379
337
 
380
338
  ```python
381
- import networkx as nx
382
339
  import pyobo
340
+ from pyobo import Reference
383
341
 
384
342
  # check that go:0008219 ! cell death is an ancestor of go:0006915 ! apoptotic process
385
- assert 'go:0008219' in pyobo.get_ancestors('go', '0006915')
343
+ assert Reference.from_curie('go:0008219') in pyobo.get_ancestors('go', '0006915')
386
344
 
387
345
  # check that go:0070246 ! natural killer cell apoptotic process is a
388
346
  # descendant of go:0006915 ! apoptotic process
389
347
  apopototic_process_descendants = pyobo.get_descendants('go', '0006915')
390
- assert 'go:0070246' in apopototic_process_descendants
348
+ assert Reference.from_curie('go:0070246') in apopototic_process_descendants
391
349
  ```
392
350
 
393
351
  Get the sub-hierarchy below a given node:
394
352
 
395
353
  ```python
396
354
  import pyobo
355
+ from pyobo import Reference
397
356
 
398
357
  # get the descendant graph of go:0006915 ! apoptotic process
399
358
  apopototic_process_subhierarchy = pyobo.get_subhierarchy('go', '0006915')
400
359
 
401
360
  # check that go:0070246 ! natural killer cell apoptotic process is a
402
361
  # descendant of go:0006915 ! apoptotic process through the subhierarchy
403
- assert 'go:0070246' in apopototic_process_subhierarchy
362
+ assert Reference.from_curie('go:0070246') in apopototic_process_subhierarchy
404
363
  ```
405
364
 
406
365
  Get a hierarchy with properties preloaded in the node data dictionaries:
407
366
 
408
367
  ```python
409
368
  import pyobo
369
+ from pyobo import Reference
410
370
 
411
371
  prop = 'http://purl.obolibrary.org/obo/chebi/smiles'
412
372
  chebi_hierarchy = pyobo.get_hierarchy('chebi', properties=[prop])
413
373
 
414
- assert 'chebi:132964' in chebi_hierarchy
374
+ assert Reference.from_curie('chebi:132964') in chebi_hierarchy
415
375
  assert prop in chebi_hierarchy.nodes['chebi:132964']
416
376
  assert chebi_hierarchy.nodes['chebi:132964'][prop] == 'C1(=CC=C(N=C1)OC2=CC=C(C=C2)O[C@@H](C(OCCCC)=O)C)C(F)(F)F'
417
377
  ```
418
378
 
419
379
  ### Relations
420
380
 
421
- Get all orthologies (`ro:HOM0000017`) between HGNC and MGI (note: this is one way)
381
+ Get all orthologies (`ro:HOM0000017`) between HGNC and MGI (note: this is one
382
+ way)
422
383
 
423
384
  ```python
424
385
  >>> import pyobo
@@ -440,11 +401,10 @@ If you want to do it in one line, use:
440
401
 
441
402
  ### Writings Tests that Use PyOBO
442
403
 
443
- If you're writing your own code that relies on PyOBO, and unit
444
- testing it (as you should) in a continuous integration setting,
445
- you've probably realized that loading all of the resources on each
446
- build is not so fast. In those scenarios, you can use some of the
447
- pre-build patches like in the following:
404
+ If you're writing your own code that relies on PyOBO, and unit testing it (as
405
+ you should) in a continuous integration setting, you've probably realized that
406
+ loading all the resources on each build is not so fast. In those scenarios, you
407
+ can use some of the pre-build patches like in the following:
448
408
 
449
409
  ```python
450
410
  import unittest
@@ -464,57 +424,76 @@ class MyTestCase(unittest.TestCase):
464
424
  pyobo.get_name('chebi', '1234')
465
425
  ```
466
426
 
467
-
468
427
  ## Curation of the Bioregistry
469
428
 
470
429
  In order to normalize references and identify resources, PyOBO uses the
471
- [Bioregistry](https://github.com/bioregistry/bioregistry). It used to be a part of PyOBO, but has since
472
- been externalized for more general reuse.
430
+ [Bioregistry](https://github.com/bioregistry/bioregistry). It used to be a part
431
+ of PyOBO, but has since been externalized for more general reuse.
473
432
 
474
- At [src/pyobo/registries/metaregistry.json](https://github.com/pyobo/pyobo/blob/master/src/pyobo/registries/metaregistry.json)
475
- is the curated "metaregistry". This is a source of information that contains
476
- all sorts of fixes for missing/wrong information in MIRIAM, OLS, and OBO Foundry; entries that don't appear in
477
- any of them; additional synonym information for each namespace/prefix; rules for normalizing xrefs and CURIEs, etc.
433
+ At
434
+ [src/pyobo/registries/metaregistry.json](https://github.com/pyobo/pyobo/blob/master/src/pyobo/registries/metaregistry.json)
435
+ is the curated "metaregistry". This is a source of information that contains all
436
+ sorts of fixes for missing/wrong information in MIRIAM, OLS, and OBO Foundry;
437
+ entries that don't appear in any of them; additional synonym information for
438
+ each namespace/prefix; rules for normalizing xrefs and CURIEs, etc.
478
439
 
479
440
  Other entries in the metaregistry:
480
441
 
481
- - The `"remappings"->"full"` entry is a dictionary from strings that might follow `xref:`
482
- in a given OBO file that need to be completely replaced, due to incorrect formatting
483
- - The `"remappings"->"prefix"` entry contains a dictionary of prefixes for xrefs that need
484
- to be remapped. Several rules, for example, remove superfluous spaces that occur inside
485
- CURIEs or and others address instances of the GOGO issue.
486
- - The `"blacklists"` entry contains rules for throwing out malformed xrefs based on
487
- full string, just prefix, or just suffix.
442
+ - The `"remappings"->"full"` entry is a dictionary from strings that might
443
+ follow `xref:` in a given OBO file that need to be completely replaced, due to
444
+ incorrect formatting
445
+ - The `"remappings"->"prefix"` entry contains a dictionary of prefixes for xrefs
446
+ that need to be remapped. Several rules, for example, remove superfluous
447
+ spaces that occur inside CURIEs or and others address instances of the GOGO
448
+ issue.
449
+ - The `"blacklists"` entry contains rules for throwing out malformed xrefs based
450
+ on full string, just prefix, or just suffix.
488
451
 
489
452
  ## Troubleshooting
490
453
 
491
- The OBO Foundry seems to be pretty unstable with respect to the URLs to OBO resources. If you get an error like:
454
+ The OBO Foundry seems to be pretty unstable with respect to the URLs to OBO
455
+ resources. If you get an error like:
492
456
 
493
457
  ```
494
458
  pyobo.getters.MissingOboBuild: OBO Foundry is missing a build for: mondo
495
459
  ```
496
460
 
497
- Then you should check the corresponding page on the OBO Foundry (in this case, http://www.obofoundry.org/ontology/mondo.html)
498
- and make update to the `url` entry for that namespace in the Bioregistry.
461
+ Then you should check the corresponding page on the OBO Foundry (in this case,
462
+ http://www.obofoundry.org/ontology/mondo.html) and make update to the `url`
463
+ entry for that namespace in the Bioregistry.
499
464
 
500
465
  ## 🚀 Installation
501
466
 
502
467
  The most recent release can be installed from
503
- [PyPI](https://pypi.org/project/pyobo/) with:
468
+ [PyPI](https://pypi.org/project/pyobo/) with uv:
504
469
 
505
470
  ```console
506
471
  python3 -m pip install pyobo
472
+ $ uv pip install pyobo
507
473
  ```
508
474
 
509
- The most recent code and data can be installed directly from GitHub with:
475
+ or with pip:
510
476
 
511
477
  ```console
512
- python3 -m pip install git+https://github.com/biopragmatics/pyobo.git
478
+ $ python3 -m pip install pyobo
479
+ ```
480
+
481
+ The most recent code and data can be installed directly from GitHub with uv:
482
+
483
+ ```console
484
+ $ uv pip install git+https://github.com/biopragmatics/pyobo.git
485
+ ```
486
+
487
+ or with pip:
488
+
489
+ ```console
490
+ $ python3 -m pip install git+https://github.com/biopragmatics/pyobo.git
513
491
  ```
514
492
 
515
493
  ## 👐 Contributing
516
494
 
517
- Contributions, whether filing an issue, making a pull request, or forking, are appreciated. See
495
+ Contributions, whether filing an issue, making a pull request, or forking, are
496
+ appreciated. See
518
497
  [CONTRIBUTING.md](https://github.com/biopragmatics/pyobo/blob/master/.github/CONTRIBUTING.md)
519
498
  for more information on getting involved.
520
499
 
@@ -551,49 +530,59 @@ This project has been supported by the following grants:
551
530
 
552
531
  ### 🍪 Cookiecutter
553
532
 
554
- This package was created with [@audreyfeldroy](https://github.com/audreyfeldroy)'s
555
- [cookiecutter](https://github.com/cookiecutter/cookiecutter) package using [@cthoyt](https://github.com/cthoyt)'s
556
- [cookiecutter-snekpack](https://github.com/cthoyt/cookiecutter-snekpack) template.
533
+ This package was created with
534
+ [@audreyfeldroy](https://github.com/audreyfeldroy)'s
535
+ [cookiecutter](https://github.com/cookiecutter/cookiecutter) package using
536
+ [@cthoyt](https://github.com/cthoyt)'s
537
+ [cookiecutter-snekpack](https://github.com/cthoyt/cookiecutter-snekpack)
538
+ template.
557
539
 
558
540
  ## 🛠️ For Developers
559
541
 
560
542
  <details>
561
543
  <summary>See developer instructions</summary>
562
544
 
563
- The final section of the README is for if you want to get involved by making a code contribution.
545
+ The final section of the README is for if you want to get involved by making a
546
+ code contribution.
564
547
 
565
548
  ### Development Installation
566
549
 
567
550
  To install in development mode, use the following:
568
551
 
569
552
  ```console
570
- git clone git+https://github.com/biopragmatics/pyobo.git
571
- cd pyobo
572
- python3 -m pip install -e .
553
+ $ git clone git+https://github.com/biopragmatics/pyobo.git
554
+ $ cd pyobo
555
+ $ uv pip install -e .
556
+ ```
557
+
558
+ Alternatively, install using pip:
559
+
560
+ ```console
561
+ $ python3 -m pip install -e .
573
562
  ```
574
563
 
575
564
  ### Updating Package Boilerplate
576
565
 
577
- This project uses `cruft` to keep boilerplate (i.e., configuration, contribution guidelines, documentation
578
- configuration)
579
- up-to-date with the upstream cookiecutter package. Update with the following:
566
+ This project uses `cruft` to keep boilerplate (i.e., configuration, contribution
567
+ guidelines, documentation configuration) up-to-date with the upstream
568
+ cookiecutter package. Install cruft with either `uv tool install cruft` or
569
+ `python3 -m pip install cruft` then run:
580
570
 
581
571
  ```console
582
- python3 -m pip install cruft
583
- cruft update
572
+ $ cruft update
584
573
  ```
585
574
 
586
- More info on Cruft's update command is
587
- available [here](https://github.com/cruft/cruft?tab=readme-ov-file#updating-a-project).
575
+ More info on Cruft's update command is available
576
+ [here](https://github.com/cruft/cruft?tab=readme-ov-file#updating-a-project).
588
577
 
589
578
  ### 🥼 Testing
590
579
 
591
580
  After cloning the repository and installing `tox` with
592
- `python3 -m pip install tox tox-uv`,
593
- the unit tests in the `tests/` folder can be run reproducibly with:
581
+ `uv tool install tox --with tox-uv` or `python3 -m pip install tox tox-uv`, the
582
+ unit tests in the `tests/` folder can be run reproducibly with:
594
583
 
595
584
  ```console
596
- tox -e py
585
+ $ tox -e py
597
586
  ```
598
587
 
599
588
  Additionally, these tests are automatically re-run with each commit in a
@@ -604,67 +593,77 @@ Additionally, these tests are automatically re-run with each commit in a
604
593
  The documentation can be built locally using the following:
605
594
 
606
595
  ```console
607
- git clone git+https://github.com/biopragmatics/pyobo.git
608
- cd pyobo
609
- tox -e docs
610
- open docs/build/html/index.html
596
+ $ git clone git+https://github.com/biopragmatics/pyobo.git
597
+ $ cd pyobo
598
+ $ tox -e docs
599
+ $ open docs/build/html/index.html
611
600
  ```
612
601
 
613
- The documentation automatically installs the package as well as the `docs`
614
- extra specified in the [`pyproject.toml`](../../Desktop/pyobo/pyproject.toml). `sphinx` plugins
615
- like `texext` can be added there. Additionally, they need to be added to the
616
- `extensions` list in [`docs/source/conf.py`](../../Desktop/pyobo/docs/source/conf.py).
602
+ The documentation automatically installs the package as well as the `docs` extra
603
+ specified in the [`pyproject.toml`](pyproject.toml). `sphinx` plugins like
604
+ `texext` can be added there. Additionally, they need to be added to the
605
+ `extensions` list in [`docs/source/conf.py`](docs/source/conf.py).
617
606
 
618
607
  The documentation can be deployed to [ReadTheDocs](https://readthedocs.io) using
619
- [this guide](https://docs.readthedocs.io/en/stable/intro/import-guide.html).
620
- The [`.readthedocs.yml`](../../Desktop/pyobo/.readthedocs.yml) YAML file contains all the configuration you'll need.
621
- You can also set up continuous integration on GitHub to check not only that
622
- Sphinx can build the documentation in an isolated environment (i.e., with `tox -e docs-test`)
623
- but also that [ReadTheDocs can build it too](https://docs.readthedocs.io/en/stable/pull-requests.html).
608
+ [this guide](https://docs.readthedocs.io/en/stable/intro/import-guide.html). The
609
+ [`.readthedocs.yml`](.readthedocs.yml) YAML file contains all the configuration
610
+ you'll need. You can also set up continuous integration on GitHub to check not
611
+ only that Sphinx can build the documentation in an isolated environment (i.e.,
612
+ with `tox -e docs-test`) but also that
613
+ [ReadTheDocs can build it too](https://docs.readthedocs.io/en/stable/pull-requests.html).
624
614
 
625
615
  #### Configuring ReadTheDocs
626
616
 
627
- 1. Log in to ReadTheDocs with your GitHub account to install the integration
628
- at https://readthedocs.org/accounts/login/?next=/dashboard/
629
- 2. Import your project by navigating to https://readthedocs.org/dashboard/import then clicking the plus icon next to
630
- your repository
631
- 3. You can rename the repository on the next screen using a more stylized name (i.e., with spaces and capital letters)
617
+ 1. Log in to ReadTheDocs with your GitHub account to install the integration at
618
+ https://readthedocs.org/accounts/login/?next=/dashboard/
619
+ 2. Import your project by navigating to https://readthedocs.org/dashboard/import
620
+ then clicking the plus icon next to your repository
621
+ 3. You can rename the repository on the next screen using a more stylized name
622
+ (i.e., with spaces and capital letters)
632
623
  4. Click next, and you're good to go!
633
624
 
634
625
  ### 📦 Making a Release
635
626
 
636
627
  #### Configuring Zenodo
637
628
 
638
- [Zenodo](https://zenodo.org) is a long-term archival system that assigns a DOI to each release of your package.
629
+ [Zenodo](https://zenodo.org) is a long-term archival system that assigns a DOI
630
+ to each release of your package.
639
631
 
640
- 1. Log in to Zenodo via GitHub with this link: https://zenodo.org/oauth/login/github/?next=%2F. This brings you to a
641
- page that lists all of your organizations and asks you to approve installing the Zenodo app on GitHub. Click "grant"
642
- next to any organizations you want to enable the integration for, then click the big green "approve" button. This
632
+ 1. Log in to Zenodo via GitHub with this link:
633
+ https://zenodo.org/oauth/login/github/?next=%2F. This brings you to a page
634
+ that lists all of your organizations and asks you to approve installing the
635
+ Zenodo app on GitHub. Click "grant" next to any organizations you want to
636
+ enable the integration for, then click the big green "approve" button. This
643
637
  step only needs to be done once.
644
- 2. Navigate to https://zenodo.org/account/settings/github/, which lists all of your GitHub repositories (both in your
645
- username and any organizations you enabled). Click the on/off toggle for any relevant repositories. When you make
646
- a new repository, you'll have to come back to this
638
+ 2. Navigate to https://zenodo.org/account/settings/github/, which lists all of
639
+ your GitHub repositories (both in your username and any organizations you
640
+ enabled). Click the on/off toggle for any relevant repositories. When you
641
+ make a new repository, you'll have to come back to this
647
642
 
648
- After these steps, you're ready to go! After you make "release" on GitHub (steps for this are below), you can navigate
649
- to https://zenodo.org/account/settings/github/repository/biopragmatics/pyobo
650
- to see the DOI for the release and link to the Zenodo record for it.
643
+ After these steps, you're ready to go! After you make "release" on GitHub (steps
644
+ for this are below), you can navigate to
645
+ https://zenodo.org/account/settings/github/repository/biopragmatics/pyobo to see
646
+ the DOI for the release and link to the Zenodo record for it.
651
647
 
652
648
  #### Registering with the Python Package Index (PyPI)
653
649
 
654
650
  You only have to do the following steps once.
655
651
 
656
- 1. Register for an account on the [Python Package Index (PyPI)](https://pypi.org/account/register)
657
- 2. Navigate to https://pypi.org/manage/account and make sure you have verified your email address. A verification email
658
- might not have been sent by default, so you might have to click the "options" dropdown next to your address to get to
659
- the "re-send verification email" button
660
- 3. 2-Factor authentication is required for PyPI since the end of 2023 (see
661
- this [blog post from PyPI](https://blog.pypi.org/posts/2023-05-25-securing-pypi-with-2fa/)). This means
662
- you have to first issue account recovery codes, then set up 2-factor authentication
652
+ 1. Register for an account on the
653
+ [Python Package Index (PyPI)](https://pypi.org/account/register)
654
+ 2. Navigate to https://pypi.org/manage/account and make sure you have verified
655
+ your email address. A verification email might not have been sent by default,
656
+ so you might have to click the "options" dropdown next to your address to get
657
+ to the "re-send verification email" button
658
+ 3. 2-Factor authentication is required for PyPI since the end of 2023 (see this
659
+ [blog post from PyPI](https://blog.pypi.org/posts/2023-05-25-securing-pypi-with-2fa/)).
660
+ This means you have to first issue account recovery codes, then set up
661
+ 2-factor authentication
663
662
  4. Issue an API token from https://pypi.org/manage/account/token
664
663
 
665
664
  #### Configuring your machine's connection to PyPI
666
665
 
667
- You have to do the following steps once per machine.
666
+ You have to do the following steps once per machine.
668
667
 
669
668
  ```console
670
669
  $ uv tool install keyring
@@ -676,34 +675,37 @@ Note that this deprecates previous workflows using `.pypirc`.
676
675
 
677
676
  #### Uploading to PyPI
678
677
 
679
- After installing the package in development mode and installing
680
- `tox` with `python3 -m pip install tox tox-uv`,
681
- run the following from the console:
678
+ After installing the package in development mode and installing `tox` with
679
+ `uv tool install tox --with tox-uv` or `python3 -m pip install tox tox-uv`, run
680
+ the following from the console:
682
681
 
683
682
  ```console
684
- tox -e finish
683
+ $ tox -e finish
685
684
  ```
686
685
 
687
686
  This script does the following:
688
687
 
689
- 1. Uses [bump-my-version](https://github.com/callowayproject/bump-my-version) to switch the version number in
690
- the `pyproject.toml`, `CITATION.cff`, `src/pyobo/version.py`,
691
- and [`docs/source/conf.py`](../../Desktop/pyobo/docs/source/conf.py) to not have the `-dev` suffix
688
+ 1. Uses [bump-my-version](https://github.com/callowayproject/bump-my-version) to
689
+ switch the version number in the `pyproject.toml`, `CITATION.cff`,
690
+ `src/pyobo/version.py`, and [`docs/source/conf.py`](docs/source/conf.py) to
691
+ not have the `-dev` suffix
692
692
  2. Packages the code in both a tar archive and a wheel using
693
693
  [`uv build`](https://docs.astral.sh/uv/guides/publish/#building-your-package)
694
- 3. Uploads to PyPI using [`uv publish`](https://docs.astral.sh/uv/guides/publish/#publishing-your-package).
695
- 4. Push to GitHub. You'll need to make a release going with the commit where the version was bumped.
696
- 5. Bump the version to the next patch. If you made big changes and want to bump the version by minor, you can
697
- use `tox -e bumpversion -- minor` after.
694
+ 3. Uploads to PyPI using
695
+ [`uv publish`](https://docs.astral.sh/uv/guides/publish/#publishing-your-package).
696
+ 4. Push to GitHub. You'll need to make a release going with the commit where the
697
+ version was bumped.
698
+ 5. Bump the version to the next patch. If you made big changes and want to bump
699
+ the version by minor, you can use `tox -e bumpversion -- minor` after.
698
700
 
699
701
  #### Releasing on GitHub
700
702
 
701
- 1. Navigate
702
- to https://github.com/biopragmatics/pyobo/releases/new
703
- to draft a new release
704
- 2. Click the "Choose a Tag" dropdown and select the tag corresponding to the release you just made
705
- 3. Click the "Generate Release Notes" button to get a quick outline of recent changes. Modify the title and description
706
- as you see fit
703
+ 1. Navigate to https://github.com/biopragmatics/pyobo/releases/new to draft a
704
+ new release
705
+ 2. Click the "Choose a Tag" dropdown and select the tag corresponding to the
706
+ release you just made
707
+ 3. Click the "Generate Release Notes" button to get a quick outline of recent
708
+ changes. Modify the title and description as you see fit
707
709
  4. Click the big green "Publish Release" button
708
710
 
709
711
  This will trigger Zenodo to assign a DOI to your release as well.