mobiorigin 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.
Files changed (61) hide show
  1. mobiorigin-0.1.3/CHANGELOG.md +146 -0
  2. mobiorigin-0.1.3/CITATION.cff +27 -0
  3. mobiorigin-0.1.3/LICENSE +674 -0
  4. mobiorigin-0.1.3/PKG-INFO +383 -0
  5. mobiorigin-0.1.3/README.md +358 -0
  6. mobiorigin-0.1.3/docs/INSTALLATION_AND_TUTORIAL.md +346 -0
  7. mobiorigin-0.1.3/docs/MOBIORIGIN_ANNOTATION.md +242 -0
  8. mobiorigin-0.1.3/docs/MOBIORIGIN_DATABASE_SETUP.md +161 -0
  9. mobiorigin-0.1.3/docs/MOBIORIGIN_OUTPUT_SCHEMA.md +30 -0
  10. mobiorigin-0.1.3/docs/RELEASE_NOTES_0.1.0.md +40 -0
  11. mobiorigin-0.1.3/docs/RELEASE_NOTES_0.1.1.md +75 -0
  12. mobiorigin-0.1.3/docs/RELEASE_NOTES_0.1.2.md +69 -0
  13. mobiorigin-0.1.3/docs/RELEASE_NOTES_0.1.3.md +40 -0
  14. mobiorigin-0.1.3/docs/validation/external_validation/README.md +20 -0
  15. mobiorigin-0.1.3/docs/validation/external_validation/claims_and_limitations.md +21 -0
  16. mobiorigin-0.1.3/docs/validation/external_validation/claims_and_limitations_secondary_comparators.md +19 -0
  17. mobiorigin-0.1.3/docs/validation/external_validation/figure_1_external_comparison.svg +7 -0
  18. mobiorigin-0.1.3/docs/validation/external_validation/figure_s2_secondary_comparator_plasmid_binary.svg +45 -0
  19. mobiorigin-0.1.3/docs/validation/external_validation/methods_external_validation.md +5 -0
  20. mobiorigin-0.1.3/docs/validation/external_validation/methods_secondary_comparator_analysis.md +7 -0
  21. mobiorigin-0.1.3/docs/validation/external_validation/table_1_external_comparison.tsv +7 -0
  22. mobiorigin-0.1.3/docs/validation/external_validation/table_s1_co_primary_inference.tsv +3 -0
  23. mobiorigin-0.1.3/docs/validation/external_validation/table_s2_length_bin_descriptive_metrics.tsv +141 -0
  24. mobiorigin-0.1.3/docs/validation/external_validation/table_s3_secondary_comparator_plasmid_binary_metrics.tsv +6 -0
  25. mobiorigin-0.1.3/docs/validation/external_validation/table_s4_secondary_comparator_paired_exploratory.tsv +9 -0
  26. mobiorigin-0.1.3/docs/validation/operational_validation/claims_and_limitations_real_assembly.md +9 -0
  27. mobiorigin-0.1.3/docs/validation/operational_validation/figure_s3_real_assembly_operational_profiles.svg +1 -0
  28. mobiorigin-0.1.3/docs/validation/operational_validation/methods_real_assembly_operational_validation.md +3 -0
  29. mobiorigin-0.1.3/docs/validation/operational_validation/table_s5_real_assembly_operational_summary.tsv +13 -0
  30. mobiorigin-0.1.3/docs/validation/operational_validation/table_s6_real_assembly_agreement.tsv +11 -0
  31. mobiorigin-0.1.3/docs/validation/operational_validation/table_s7_biological_evidence_tiers.tsv +11 -0
  32. mobiorigin-0.1.3/environment.marker-build.yml +8 -0
  33. mobiorigin-0.1.3/environment.mob-database.yml +12 -0
  34. mobiorigin-0.1.3/environment.yml +15 -0
  35. mobiorigin-0.1.3/install.sh +194 -0
  36. mobiorigin-0.1.3/pyproject.toml +103 -0
  37. mobiorigin-0.1.3/scripts/build_mobiorigin_model_bundle.py +69 -0
  38. mobiorigin-0.1.3/scripts/run_mobiorigin_assembly_example.sh +220 -0
  39. mobiorigin-0.1.3/scripts/setup_mobiorigin_databases.sh +233 -0
  40. mobiorigin-0.1.3/src/mobiorigin/__init__.py +3 -0
  41. mobiorigin-0.1.3/src/mobiorigin/__main__.py +6 -0
  42. mobiorigin-0.1.3/src/mobiorigin/annotate.py +1014 -0
  43. mobiorigin-0.1.3/src/mobiorigin/annotation_database_retrieval.py +269 -0
  44. mobiorigin-0.1.3/src/mobiorigin/annotation_database_setup.py +336 -0
  45. mobiorigin-0.1.3/src/mobiorigin/biological_evidence.py +685 -0
  46. mobiorigin-0.1.3/src/mobiorigin/cli.py +324 -0
  47. mobiorigin-0.1.3/src/mobiorigin/data/examples/annotated_assembly_example.fasta +2013 -0
  48. mobiorigin-0.1.3/src/mobiorigin/data/examples/demo.fasta +9 -0
  49. mobiorigin-0.1.3/src/mobiorigin/data/models/dev1/model_manifest.json +49 -0
  50. mobiorigin-0.1.3/src/mobiorigin/database_setup.py +129 -0
  51. mobiorigin-0.1.3/src/mobiorigin/fasta.py +65 -0
  52. mobiorigin-0.1.3/src/mobiorigin/marker_database_builder.py +221 -0
  53. mobiorigin-0.1.3/src/mobiorigin/marker_features.py +295 -0
  54. mobiorigin-0.1.3/src/mobiorigin/model.py +93 -0
  55. mobiorigin-0.1.3/src/mobiorigin/model_setup.py +203 -0
  56. mobiorigin-0.1.3/src/mobiorigin/predict.py +228 -0
  57. mobiorigin-0.1.3/src/mobiorigin/provenance.py +32 -0
  58. mobiorigin-0.1.3/src/mobiorigin/runtime.py +12 -0
  59. mobiorigin-0.1.3/src/mobiorigin/sequence_features.py +113 -0
  60. mobiorigin-0.1.3/src/mobiorigin/visualize.py +363 -0
  61. mobiorigin-0.1.3/src/mobiorigin/workflow.py +208 -0
@@ -0,0 +1,146 @@
1
+ # Changelog
2
+
3
+ All notable MobiOrigin changes are documented here. The project uses semantic versioning for the standalone `mobiorigin` package interface.
4
+
5
+ ## Unreleased
6
+
7
+ ## 0.1.3 — 2026-08-27
8
+
9
+ PyPI transport and supply-chain update for the unchanged frozen
10
+ `mobiorigin-dev1-mob-selective-v1` classifier.
11
+
12
+ ### Added
13
+
14
+ - Atomic, resumable retrieval of the exact frozen dev1 model bundle from a
15
+ versioned GitHub release asset.
16
+ - SHA-256 and byte-count verification of all three checkpoints, marker
17
+ normalization, model manifest, and the complete transport archive.
18
+ - PyPI Trusted Publishing workflow with tag/version matching, separate build and
19
+ publishing jobs, OIDC authentication, attestations, and a fail-closed 100 MB
20
+ per-file gate.
21
+ - Offline model setup through `--model-archive` and configurable model storage
22
+ through `MOBIORIGIN_MODEL_DIR`.
23
+
24
+ ### Changed
25
+
26
+ - Python distributions no longer duplicate the 121 MB frozen model payload.
27
+ Guided installation retrieves the exact bytes once and verifies them before
28
+ making them available to prediction.
29
+ - The database helper now prepares and checks model artifacts before marker
30
+ databases, keeping the standard installation route automatic.
31
+ - `mobiorigin doctor` verifies the resolved model directory as part of the full
32
+ installation check.
33
+
34
+ ### Scientific boundaries
35
+
36
+ - Model transport changed; checkpoint bytes, hashes, architecture, feature
37
+ definitions, ensemble, normalization, threshold, and predictions did not.
38
+ - Prediction remains offline after installation. Missing or changed model bytes
39
+ stop execution rather than triggering a fallback model or network request.
40
+
41
+ ## 0.1.2 — 2026-08-26
42
+
43
+ Installation, database automation, and integrated analysis update for the
44
+ unchanged frozen `mobiorigin-dev1-mob-selective-v1` classifier.
45
+
46
+ ### Added
47
+
48
+ - Guided Conda or Mamba installation with a post-installation doctor check and
49
+ bundled deterministic demonstration.
50
+ - Automatic, resumable setup and cryptographic verification of the comprehensive
51
+ annotation resources, with explicit acceptance of applicable third-party terms.
52
+ - mobileOG-db as the default MGE resource, while retaining legacy ISfinder as an
53
+ optional user-supplied resource.
54
+ - A bundled eight-contig assembly example that demonstrates chromosome, plasmid,
55
+ phage, and unclassified outputs without presenting an accuracy claim.
56
+ - Deterministic SVG, HTML, and tabular visualizations for prediction and annotation
57
+ outputs.
58
+
59
+ ### Changed
60
+
61
+ - `mobiorigin run` now performs prediction, comprehensive biological annotation,
62
+ and integrated visualization by default in one atomic output directory. A
63
+ `--skip-annotation` option preserves the lightweight prediction-only route.
64
+ - Expanded `--threads` from the original validated 1–8 range to 1–128 for
65
+ DIAMOND, AMRFinderPlus, and other external searches. Deterministic neural-network
66
+ inference remains single-threaded, and the model and scientific policy are unchanged.
67
+
68
+ ### Fixed
69
+
70
+ - Separated the CPU-only MobiOrigin runtime from MOB-suite's incompatible legacy
71
+ NumPy/pandas database-building stack.
72
+ - Added a non-overwriting database setup helper with Linux/WSL, Intel macOS, and
73
+ Apple Silicon/Rosetta handling plus actionable failure messages.
74
+ - Prevented Conda from selecting CUDA by pinning the documented runtime to a
75
+ cross-platform CPU PyTorch build.
76
+ - Added CI installation smoke tests, an isolated MOB-suite dependency solve, and
77
+ installation-contract unit tests.
78
+
79
+ ### Scientific boundaries
80
+
81
+ - The classifier checkpoints, feature definitions, ensemble, selective threshold,
82
+ and frozen external-validation results are unchanged from version 0.1.1.
83
+ - Biological annotations remain independent supporting evidence. They do not
84
+ override prediction labels or probabilities and are not clinical risk scores.
85
+ - The bundled assembly is a software demonstration. It is not an accuracy,
86
+ prevalence, or biological-discovery dataset.
87
+
88
+ ## 0.1.1 — 2026-08-23
89
+
90
+ Publication and biological-annotation update for the unchanged frozen
91
+ `mobiorigin-dev1-mob-selective-v1` classifier.
92
+
93
+ ### Added
94
+
95
+ - Prediction-independent `mobiorigin annotate` workflow integrating CARD, SARG,
96
+ official AMRFinderPlus, VFDB, MGE, BacMet2, and MOB-suite evidence without
97
+ changing classifier labels or probabilities.
98
+ - Publication-quality annotation tables, provenance, checksums, and HTML reports,
99
+ including transparent A–E biological evidence-priority tiers that are explicitly
100
+ not clinical risk scores.
101
+ - Post-hoc exploratory external comparisons with PlasClass, PlasFlow v1, PLASMe,
102
+ and Platon under a separately frozen statistical contract.
103
+ - Label-free operational evidence from two deterministic real-assembly subsets,
104
+ covering all 12 dataset–tool runs and 10 pairwise operational comparisons.
105
+ - Validation tables, editable vector figures, methods, limitations, and updated
106
+ repository documentation.
107
+
108
+ ### Changed
109
+
110
+ - Package and citation metadata now identify the expanded publication bundle as
111
+ version 0.1.1.
112
+ - Distribution metadata includes the annotation and operational-validation
113
+ documentation.
114
+
115
+ ### Scientific boundaries
116
+
117
+ - The frozen classifier, three model checkpoints, marker normalization, ensemble,
118
+ and selective threshold are unchanged from version 0.1.0.
119
+ - Secondary comparator findings are exploratory and do not alter the preregistered
120
+ MobiOrigin-versus-geNomad co-primary evidence.
121
+ - Real-assembly results support runtime, call-rate, coverage, agreement, and
122
+ biological-evidence reporting only; they do not support ground-truth accuracy or
123
+ superiority claims.
124
+
125
+ ## 0.1.0 — 2026-08-21
126
+
127
+ Initial research release of the frozen `mobiorigin-dev1-mob-selective-v1` candidate.
128
+
129
+ ### Added
130
+
131
+ - Standalone `mobiorigin predict` interface for chromosome, plasmid, phage, and explicit unclassified predictions.
132
+ - Deterministic 9,557-dimensional sequence-feature extraction and 17-dimensional MOB protein-marker extraction.
133
+ - Three frozen neural-network checkpoints combined by an equal-weight softmax mean.
134
+ - Frozen plasmid selective-abstention rule with threshold `0.19835489988327026`.
135
+ - Safe tensor-only checkpoint loading and exact model, normalization, and database identity verification.
136
+ - Atomic prediction outputs with provenance and SHA-256 checksums.
137
+ - `mobiorigin setup-databases` for atomic retrieval or offline installation of the exact marker databases.
138
+ - Prospective external validation against geNomad 1.12.0/database 1.9 using 3,000 source-disjoint records.
139
+ - Aggregate validation tables, vector figure, methods, and claim boundaries.
140
+
141
+ ### Scientific boundaries
142
+
143
+ - The frozen external cohort is closed to retrospective tuning and record-level error mining.
144
+ - geNomad outputs are not model features or training targets.
145
+ - MobiOrigin does not use hard biological overrides or post-hoc probability transfer.
146
+ - Third-party biological database records are retrieved for local use and are not bundled in the Python distribution.
@@ -0,0 +1,27 @@
1
+ cff-version: 1.2.0
2
+ message: "If you use MobiOrigin, please cite this software release."
3
+ title: "MobiOrigin: sequence-and-marker classification of bacterial replicons"
4
+ type: software
5
+ authors:
6
+ - family-names: Raza
7
+ given-names: Shahbaz
8
+ email: shahbaz.invincible3182@gmail.com
9
+ repository-code: "https://github.com/Raza-pl/MobiOrigin"
10
+ url: "https://github.com/Raza-pl/MobiOrigin"
11
+ version: 0.1.3
12
+ date-released: 2026-08-27
13
+ license: GPL-3.0-only
14
+ keywords:
15
+ - bioinformatics
16
+ - plasmid
17
+ - phage
18
+ - chromosome
19
+ - replicon classification
20
+ - machine learning
21
+ abstract: >-
22
+ MobiOrigin is a CPU-oriented sequence-and-marker classifier that assigns
23
+ bacterial DNA fragments to chromosome, plasmid, phage, or an explicit
24
+ unclassified state. Version 0.1.3 retains the exact frozen three-seed dev1
25
+ model through an independently verified model bundle and provides an integrated
26
+ prediction, annotation, and visualization workflow with automatic database
27
+ setup and publication evidence from prospective and operational comparisons.