Interactive web app for exploring peptide properties and fibril-forming predictions. Designed with the Landau Group (DESY/CSSB, Professor Meytal Landau's group). Developed with guidance from Dr. Aleksandr Golubev.
๐๏ธ Case-Study Mode
Upload and real computation are disabled in this version.
Use โLoad Example Datasetโ on the home screen to explore the full interface and workflow with synthetic data that mirrors real outputs.
๐ The operational laboratory repository remains private; implementation details are summarized below.
- ๐ค Upload peptide datasets from UniProt (TSV/CSV/XLSX)
- ๐งช Compute biophysical features (Hydrophobicity, Charge, Hydrophobic Moment ฮผH)
- ๐ Integrate Tango (SSW) and JPred results (when local outputs are provided)
- ๐ Visualize cohorts, rank candidates, and export reports/shortlists
- Reframed a stalled prototype into a deployable research tool featuring a React/TypeScript UI, FastAPI backend endpoints, and a normalized data contract for reliable UI rendering.
- Implemented per-run temporary directories, direct binary execution, and a robust parser tolerant of multiple TANGO output formats (tabular/mixed text).
- Executed the JPred โ PSIPRED pivot, replacing brittle dependencies with a probability-based secondary-structure pipeline using P(H)/P(E)/P(C) for accurate %Helix/%Beta predictions and segment mapping.
- Unified column normalization across experiments, ensuring consistent field names, units, and alignment for comparative analytics.
- Added โalways-onโ sequence-only features โ including FF-Helix%, charge, hydrophobicity, and ฮผH โ to preserve utility even when predictors are offline.
- Designed the Upload โ Results โ Detail flow, including triage KPIs, sortable tables, cohort radar visualizations, and a badge system (e.g., chameleon flag).
- Added export options (CSV/PDF) and a roadmap for researcher-tunable parameters (thresholds, weights, and audit-safe defaults).
- Architected for local-only computation within lab environments; prepared a secure PSIPRED server deployment plan for broader access.
- Established a cross-platform runner strategy, eliminating hard-coded paths and OS-specific dependencies.
โ๏ธ In this case-study version, computation is mocked โ but the architecture, data normalization, and UX faithfully mirror the live production environment.
- ๐ Flexible upload: TSV/CSV/XLSX; optional column mapping
- โ Upload QC: invalid sequences reported, download rejected_rows.csv
- ๐ท๏ธ Provenance pill: JPred/Tango ON/OFF + hit counts
- ๐ Six core metrics:
- ๐ฆ Chameleon prediction (SSW)
- ๐ Helix segments (JPred)
- โก Charge
- ๐ง Hydrophobicity
- ๐ Hydrophobic moment (ฮผH)
- ๐งฌ FF-Helix (derived flag)
- ๐ Visualizations
- ๐ Hydrophobicity distribution
- ๐ฏ Hydrophobicity vs ฮผH scatter
- ๐ฆ Chameleon distribution & cohort radar
- ๐ Sliding-window profiles (H & ฮผH) with helix overlays
- ๐๏ธ Smart ranking: sliders for metric weights + Top-N shortlist (CSV)
- ๐ Per-peptide deep dive: segment track, metrics, interpretations
- ๐ Exports: CSV export; PDF Report (one-click)
- โ๏ธ Cloud (optional): Save/Load datasets via Firebase Auth + Firestore
- โ Accepts UniProt exports (TSV/CSV/XLSX)
- ๐ง Normalizes headers; derives
Lengthif missing - ๐งฎ Computes Charge, Hydrophobicity, ฮผH (sequence-based)
- ๐ฎ If local results present and enabled:
- JPred โ
Helix fragments (Jpred),Helix score (Jpred) - Tango โ
SSW prediction,SSW score
- JPred โ
- ๐ Computes FF flags from cohort thresholds
- ๐ค Upload โ ๐ Preview โ ๐ฌ Analyze (calls backend)
- ๐บ๏ธ Optional column mapping
- ๐ Renders dashboards, detail pages, and exports
cd backend
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
# Feature flags (safe defaults)
export USE_TANGO=1 # Tango on (works with mac binary today)
export USE_PSIPRED=true # OK if PSIPRED isn't installed; it will skip cleanly
uvicorn server:app --host 0.0.0.0 --port 8000 --reloadcd ui
npm install
echo "VITE_API_BASE_URL=http://127.0.0.1:8000" > .env.local
npm run dev # open http://127.0.0.1:5173๐ค Upload a UniProt table (CSV/TSV/XLSX) with Entry and Sequence (others optional). ๐ You'll see cohort cards + ranking and a full table. Use Export CSV or Export shortlist.csv.
- Put your mac binary at
backend/Tango/bin/tango
chmod +x backend/Tango/bin/tango- (Apple Silicon only, x86_64 binary) Install Rosetta:
softwareupdate --install-rosetta --agree-to-licenseBuild/pull an image tagged psipred-hhblits and set PSIPRED_DB to your Uniclust folder. If not available, backend prints a warning and continues.
๐ Details are in DEPLOYMENT.md.
The backend can keep running locally in your lab and still be reachable worldwide over HTTPS. Choose one:
- ๐ Keep backend and Tango/PSIPRED on the lab laptop.
- ๐ฏ Serve the frontend either:
- directly from the lab laptop (Nginx), or
- host the static UI on Firebase Hosting/Vercel and proxy
/apito the tunnel URL.
- ๐ฉ๏ธ Use Cloudflare Tunnel to expose
http://127.0.0.1:8000to the internet safely (no open inbound port).
Steps (summary):
- ๐๏ธ Build the UI:
cd ui && npm run build - ๐ Install Nginx (or any static server) and serve
ui/distat/. - ๐ Install Cloudflare Tunnel (
cloudflared), authenticate, and create a tunnel that forwards:/api/*โhttp://localhost:8000/โ local static files (or skip if using Firebase Hosting/Vercel)
- ๐ฏ Point your domain DNS (Cloudflare) to the tunnel. You get free HTTPS.
This keeps sensitive tools and data inside your lab while offering a stable public URL.
- ๐ฅ๏ธ Provision a small VM, install Docker.
- ๐ณ Run backend in a container with Tango/PSIPRED binaries mounted (or baked into the image).
- ๐ Serve UI via Nginx.
- ๐ Add a domain + Let's Encrypt (or Caddy for auto-TLS).
- โ๏ธ Frontend on Firebase Hosting (push
ui/dist/). - ๐ Backend stays on lab laptop. Expose
/apivia Cloudflare Tunnel and setVITE_API_BASE_URL="https://your-tunnel-domain.example/api"in the hosted UI.
๐ All options are fully described in DEPLOYMENT.md with exact commands and example configs.
- ๐จ Single-sequence drawer: PSIPRED curves (P(H)/P(E)/P(C)), Tango ฮฒ-aggregation track, segment ribbons.
- ๐ Auth + Firestore: sign-in, "previous datasets", cloud export of Tango/PSIPRED outputs (schema and rules outlined in
DEV_GUIDE.md). - ๐ UniProt fetcher: type a protein or organism โ fetch, window peptides to CSV, analyze.
This repository is intended for research use. If you need a permissive OSI license, choose Apache-2.0 (recommended) or BSD-3-Clause.
For now, we include a DESY Research License template (LICENSE-DESY-RESEARCH.md).
If you plan a public SaaS, consider switching to Apache-2.0.
- ๐ฅญ Tango: Fernandez-Escamilla et al., Nat Biotechnol 22, 1302โ1306 (2004).
- ๐ง PSIPRED: Jones, J Mol Biol 292, 195โ202 (1999).
- ๐ Thanks to DESY / CSSB (Landau Lab): Said Azaizah & Dr. Aleksandr Golubev for guidance on SSW/FF calculations.