Skip to main content

Python client for SynGlue

Project description

git clone https://github.com/the-ahuja-lab/SynGlue.git

SynGlue API Client

SynGlue is a minimal Python client for the SynGlue web API at https://synglue.ahujalab.iiitd.edu.in/. It allows you to submit design and screen jobs, check job status, and download results programmatically.

Installation

Install the package and its only dependency:

pip install synglue requests

Usage Example

from synglue import SynGlue

# Initialize the client
client = SynGlue()

# Submit a design job
design_result = client.submit_design(target="EGFR", threshold=80)
print("Design job response:", design_result)

# Check design job status
design_status = client.design_status(job_id=design_result["job_id"])
print("Design job status:", design_status)

# Download design results (when job is complete)
# client.download_design(job_id=design_result["job_id"], out_path="design_results.zip")

# --- SCREENING EXAMPLE ---

# Submit a screen job with a list of molecules
molecules = [
	{"name": "Aspirin", "smiles": "CC(=O)Oc1ccccc1C(=O)O"},
	{"name": "Imatinib", "smiles": "CC1=CC=CC=C1"}
]
screen_result = client.submit_screen(molecules=molecules)
print("Screen job response:", screen_result)

# Check screen job status
screen_status = client.screen_status(job_id=screen_result["job_id"])
print("Screen job status:", screen_status)

# Download screen results (when job is complete)
# client.download_screen(job_id=screen_result["job_id"], out_path="screen_results.csv")

Methods

  • submit_design(target, threshold=75.0)
  • design_status(job_id)
  • download_design(job_id, out_path)
  • submit_screen(molecules)
  • submit_screen_csv(csv_path)
  • screen_status(job_id)
  • download_screen(job_id, out_path)
  • health_check()

See the source code for full method documentation.

Prerequisites

  • Python 3.7 or higher
  • requests (for API calls)

License

SynGlue is licensed under the MIT License. See LICENSE for more details.

Dependencies

Prerequisites

  • Python 3.7 or higher
  • requests (for API calls)

Install the required package:

pip install requests

No other dependencies are required for the SynGlue API client.

License

SynGlue is licensed under the MIT License. See LICENSE for more details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

synglue-0.1.3.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

synglue-0.1.3-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file synglue-0.1.3.tar.gz.

File metadata

  • Download URL: synglue-0.1.3.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.20

File hashes

Hashes for synglue-0.1.3.tar.gz
Algorithm Hash digest
SHA256 4a4708bd624453337a87a0a7791566b7d2f6420295c8a47234ad68779042370f
MD5 665141f5bb6441b8252f7e6df187b02b
BLAKE2b-256 4d3ad898a4d48ec07caed58ec99c29f66ef86cc266eefa0be816897da510239d

See more details on using hashes here.

File details

Details for the file synglue-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: synglue-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.20

File hashes

Hashes for synglue-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 05340cca78de36ce1907367d5a8635fecf742fa1dd80077c42bab763547e86b0
MD5 4e14603f1b29d93eb136819b65b5d82f
BLAKE2b-256 47705a105256a53b9ed0bdad4b04f6c1d5e4bd1c7e038fe8e9b8fd70c55606db

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page