Skip to content

Feat: Add ligand_prep primitive#75

Open
vsaravind01 wants to merge 5 commits into
mainfrom
feat-ps-ligand-prep
Open

Feat: Add ligand_prep primitive#75
vsaravind01 wants to merge 5 commits into
mainfrom
feat-ps-ligand-prep

Conversation

@vsaravind01
Copy link
Copy Markdown
Collaborator

Type of change

Please check the option that is related to your PR.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • In this case, we recommend to discuss your modification on GitHub issues before creating the PR
  • Documentations (modification for documents)

Checklist

  • Run lint.sh and ensure that it passes (Use ./lint.sh --fix to fix formatting issues automatically)
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • New unit tests pass locally with my changes
  • I have checked my code and corrected any misspellings

Adds the `ligand_prep` primitive to the `proteome_scan` subpackage
which converts SMILES strings to 3D SDF files via RDKit. Wires the
primitive into the program map and exposes it as POST
/primitive/ligand-prep.
Copy link
Copy Markdown
Contributor

@riya-singh28 riya-singh28 left a comment

Choose a reason for hiding this comment

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

I have left some comments after the first review pass.

"Binimetinib": "[H]OC([H])([H])C([H])([H])ON([H])C(=O)C1=C([H])C2=C(N=C([H])N2C([H])([H])[H])C(F)=C1N(C)C1=C(F)C([H])=C(Br)C([H])=C1[H]",
"Dabrafenib": "[H]C([H])C1=NC([H])=C([H])C(=N1)C1=C(N=C(S1)C(C([H])([H])[H])(C([H])([H])[H])C([H])([H])[H])C1=C(F)C(N([H])S(=O)(=O)C2=C(F)C([H])=C([H])C([H])=C2F)=C([H])C([H])=C1[H]",
"Vemurafenib": "[H]N(C1=C(F)C(C(=O)C2=C([H])N(C)C3=NC([H])=C(C([H])=C23)C2=C([H])C([H])=C(Cl)C([H])=C2[H])=C(F)C([H])=C1[H])S(=O)(=O)C([H])([H])C([H])([H])C([H])([H])[H]",
"TAK-632": "",
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.

Why is this value an empty string here?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I copied this file from ProteomeScan repository which was added by Aryan already. We just use some sample of the smiles in this file for tests.

"Vemurafenib": "[H]N(C1=C(F)C(C(=O)C2=C([H])N(C)C3=NC([H])=C(C([H])=C23)C2=C([H])C([H])=C(Cl)C([H])=C2[H])=C(F)C([H])=C1[H])S(=O)(=O)C([H])([H])C([H])([H])C([H])([H])[H]",
"TAK-632": "",
"Tucatinib": "[H]N(C1=NC(C([H])([H])[H])(C([H])([H])[H])C([H])([H])O1)C1=C([H])C2=C(N=C([H])N=C2C([H])=C1[H])N(C)C1=C([H])C([H])=C(OC2=C([H])C3=NC([H])=NN3C([H])=C2[H])C(=C1[H])C([H])([H])[H]",
"Regorafenib": "",
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.

Same ques as above

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Same as above

"Navitoclax": "[H]C1=C([H])C([H])=C(SC([H])([H])[C@]([H])(N([H])C2=C(S(=O)(=O)C(F)(F)F)C([H])=C(S(=O)(=O)N([H])C(=O)C3=C([H])C([H])=C(N4C([H])([H])C([H])([H])N(C([H])([H])C5=C(C6=C([H])C([H])=C(Cl)C([H])=C6[H])C([H])([H])C([H])([H])C(C([H])([H])[H])(C([H])([H])[H])C5([H])[H])C([H])([H])C4([H])[H])C([H])=C3[H])C([H])=C2[H])C([H])([H])C([H])([H])N2C([H])([H])C([H])([H])OC([H])([H])C2([H])[H])C([H])=C1[H]",
"Paclitaxel": "[H]O[C@]12C(C([H])([H])[H])(C([H])([H])[H])C(=C(C([H])([H])[H])[C@@]([H])(OC(=O)[C@]([H])(O[H])[C@]([H])(C3=C([H])C([H])=C([H])C([H])=C3[H])N([H])C(=O)C3=C([H])C([H])=C([H])C([H])=C3[H])C1([H])[H])[C@@]([H])(OC(=O)C([H])([H])[H])C(=O)[C@@]1(C([H])([H])[H])[C@]([H])([C@]2([H])OC(=O)C2=C([H])C([H])=C([H])C([H])=C2[H])[C@]2(OC(=O)C([H])([H])[H])C([H])([H])O[C@]2([H])C([H])([H])[C@]1([H])O[H]"
},
"methylated_ligand_smiles": {
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.

What's the difference between ligand_smiles and methylated_ligand_smiles?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I'm not sure, but I think it has something to do with additional hydrogen atom. Same as above. I've copied this file as just a test asset.


Examples
--------
>>> addr = ligand_prep("CCO", output="ethanol", ligand_name="EtOH")
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.

Import statements are required.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Will address this in a separate doctest PR

random_seed: Optional[int] = None,
) -> str:
"""
Convert a SMILES string to a 3D SDF file using RDKit.
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.

@vsaravind01 Could you please include the steps involved in ligand preparation in the documentation?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Added

@riya-singh28
Copy link
Copy Markdown
Contributor

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants