Skip to content

feat: metabolism tool - #615

Open
sg-s wants to merge 5 commits into
mainfrom
metabolism-tool
Open

feat: metabolism tool#615
sg-s wants to merge 5 commits into
mainfrom
metabolism-tool

Conversation

@sg-s

@sg-s sg-s commented Aug 27, 2026

Copy link
Copy Markdown
Collaborator

https://deeporigin.atlassian.net/browse/DDOS-7477

Merge-ready status

Auto-updated — cycle 2 (final), last updated: 2026-08-27T19:52:00Z

Check Status
Branch vs main ✅ synced at 682838f
Head ef683ce7
CI ✅ green (13/13 checks)
Copilot ✅ reviewed latest push, 0 open threads
Review threads 0 human/Bugbot, 0 Copilot (3 resolved)

Recent activity

  • Copilot flagged 3 nits on the initial push; all fixed and resolved:
    • metabolism.py: preserved the enzymes tuple/list invariant across a re-run.
    • docs/dd/how-to/ligands.md: fixed an undefined ligands variable in an example.
    • constants.py: reverted an out-of-scope pocket_finder tool_version bump (1latest).
  • Pushed fixes as ef683ce7; Copilot re-reviewed and raised no new comments.
  • CI green, merge-ready label applied.

@sg-s
sg-s requested a review from a team as a code owner August 27, 2026 19:27
@sg-s
sg-s requested a lite review from Copilot August 27, 2026 19:27
@sg-s
sg-s deployed to staging August 27, 2026 19:27 — with GitHub Actions Active
@sg-s sg-s self-assigned this Aug 27, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new Drug Discovery SDK wrapper (Metabolism) for the platform tool deeporigin.metabolism, including mock-server support, tests, and documentation so users can run sync site-of-metabolism predictions and retrieve both site- and molecule-level outputs.

Changes:

  • Introduces deeporigin.drug_discovery.metabolism.Metabolism (sync-only) with ligand normalization, enzyme filtering, and result parsing.
  • Extends the local mock server to support deeporigin.metabolism executions and tool definition lookup.
  • Adds unit + local integration tests and wires the tool into docs/navigation and the public deeporigin.drug_discovery namespace.

Reviewed changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
zensical.toml Adds Metabolism entries to docs + notebook navigation.
tests/test_metabolism_unit.py Unit coverage for Metabolism helper validation/parsing utilities.
tests/test_metabolism_local.py Mock-server integration tests for Metabolism end-to-end behavior.
tests/mock_server/routers/tools.py Adds mock tool definition + execution synthesis for deeporigin.metabolism.
src/utils/constants.py Introduces Metabolism constants (enzymes, ligand cap, execution timeout).
src/platform/constants.py Registers metabolism tool key/version; also changes PocketFinder version.
src/drug_discovery/metabolism.py New Metabolism execution wrapper implementation.
src/drug_discovery/class-design.md Documents Metabolism as sync-only run() pattern.
src/drug_discovery/init.py Exposes Metabolism in public API + lazy import map.
docs/notebooks/clean/metabolism.ipynb Adds a demo notebook for Metabolism usage.
docs/dd/tools/metabolism.md Adds user docs for reconnecting to existing Metabolism runs.
docs/dd/ref/metabolism.md Adds API reference page for the metabolism module/class.
docs/dd/how-to/ligands.md Adds a how-to section describing Metabolism usage and constraints.
CONTEXT.md Adds repo-wide context/terminology guidance for the Metabolism feature.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/drug_discovery/metabolism.py Outdated
Comment thread docs/dd/how-to/ligands.md
Comment thread src/platform/constants.py
- Preserve the enzymes tuple/list invariant across a re-run on an
  already-executed Metabolism instance instead of silently unfreezing it
  to a list.
- Fix an undefined `ligands` variable in the ligands how-to docs example.
- Revert an out-of-scope tool_version bump for pocket_finder (1 -> latest)
  that had nothing to do with this PR.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 14 out of 14 changed files in this pull request and generated no new comments.

@sg-s sg-s added the merge-ready All merge-ready checks passed label Aug 27, 2026
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 15 out of 15 changed files in this pull request and generated no new comments.

Metabolism now always returns every CYP isoform the tool scores; the
client no longer exposes an `enzymes` attribute to select/filter a
subset. Simplifies the API surface and removes the tuple/list frozen-
enzymes invariant entirely (superseding the earlier re-run fix in this
PR).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-ready All merge-ready checks passed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants