docs(space): 0.4.0 benchmark of record (10.91 vs 11.58 on corrected truth)
Maximilian Zinke
10bfe2e
docs(space): corrected benchmark headline
Maximilian Zinke
6e1163d
feat(space): install facet-nmr from PyPI; drop the vendored package and weights
Maximilian Zinke
971ff01
The Space now runs the released package unchanged and resolves weights through
facet.assets, so the demo cannot drift from what pip install facet-nmr gives
users. README rewritten with links to the method, data, benchmark and
limitation documents; version and citation footer; model repository linked.
fix(space): bump Gradio SDK to 6.26.0 to clear the tab-switch effect loop
Maximilian Zinke
784d4f0
The Space pinned sdk_version 6.12.0, which sits inside the window of a
Svelte 5 regression introduced in 6.11.0: a _sync_tab helper ran inside a
reactive context and looped forever when tabs hold heavy components. With
three TabItems each carrying a gr.Image -- plus the Plot and DataFrames
below -- every tab switch threw effect_update_depth_exceeded and froze the
page. The production build stringifies that error to the bare docs URL,
which is why the console showed an "Uncaught" with no message.
Fixed upstream by gradio-app/gradio#13240, first released in 6.16.0.
Going to 6.26.0 rather than the 6.16.0 minimum also picks up the fix for
freezes when one event reveals several components of the same type (which
the predict callback does) and for embedded Spaces growing unbounded in
the Hub iframe.
No app.py changes needed; nothing it uses changed between 6.12 and 6.26.
chore: add .mailmap for the canonical author identity
Maximilian Zinke
2016633
Sync mask-safe shift-retrieval fallback for HA-missing residues (v0.3.1)
Maximilian Zinke
b5ee06c
Routes residues missing HA (e.g. perdeuterated samples) to a mask-aware shift retrieval instead of the collapsing parametric torsion head. Mirrors facet-nmr v0.3.1; bundles facet/weights/facet_shift_reference.npz.
rename: residual-SS tabs → no 'SS' acronym, state-enumerated
Maximilian Zinke
14eb69d
Tabs renamed:
'Sequence + SS' → 'Secondary structure'
'Basin sampling (φ/ψ fingerprint)' → 'Dihedral sampling (α / β / PPII)'
'Cooperative SS — retrieval-based' → 'State populations (H / E / PPII / C)'
'Secondary structure' just spells out the acronym; the other two name
what the bar colours actually show with the class enumeration inline,
dropping the implementation-detail 'retrieval-based' / 'fingerprint'
bits from the label (still explained in the per-tab caption).
Figure titles and visualization.py default titles tracked to match.
version: bump to 0.3.0 to match facet-nmr
Maximilian Zinke
4597045
feat(viz): leave 'other'/'coil' blank in stacked-bar residual SS
Maximilian Zinke
f949509
Mirror of upstream facet-nmr change: stops painting the uninformative
baseline so only α/β/PPII signal gets ink. Keeps faint y=1.0 anchor
and an outlined 'blank' legend swatch for scale.
Renames tabs to disambiguate the three SS readouts:
"Residual SS — geometric (IDP fingerprint)" -> "Basin sampling (φ/ψ fingerprint)"
"Residual SS — structural (d2D-style)" -> "Cooperative SS — retrieval-based"
Adds a short "When to use" caption under each tab explaining which
readout to consult for folded proteins vs IDPs vs ensemble-reweighting
work, and where each can mislead (retrieval-based cooperative mode
over-estimates helix on pure IDPs).
Figure title strings match the new tab labels.
visualization.plot_residual_ss is now a single stacked-bar track per
row (α/β/PPII/other stacked bottom-up, total height 1.0) instead of
four tracks — denser and easier to read as a per-residue mixture.
feat: add retrieval-free SS populations to residue inspector
Maximilian Zinke
9c0592a
Vendors facet.ss_populations from the upstream package and runs it
alongside the main prediction (~100 ms cost, retrieval-free). The
per-residue inspector now shows three SS-population readouts side by
side: geometric basins, kernel-weighted retrieval populations, and
the new Gaussian engine populations, with per-residue nucleus count.
Result carries the Gaussian populations via a ss_populations_d2
attribute so selection callbacks read them without new Gradio state.
phase 3.5: structural-mode inspector + third residual-SS tab
Maximilian Zinke
f603610
Mirror of facet-nmr dea05ca package changes. HF app now:
- Inspector shows both geometric (Ramachandran basin) AND structural
(d2D-style) population bar charts per residue
- New 'Residual SS — structural (d2D-style)' tab alongside the existing
geometric-mode IDP tab
- predict_and_format generates both figures when retrieval is on
Users switch between views with tabs; both figures computed in one
predict() call since the structural populations are a by-product of
the same retrieval step that produces geometric populations.
- Per-residue inspector now surfaces RCI S^2 row with rigidity label.
- Inspector shows top-5 retrieved reference neighbours as a table:
entry id, AA, phi, psi, SS, basin, cosine similarity.
- Status bar shows per-nucleus deuteration ppm corrections under the
'corrected for X' badge when deuteration != protonated.
- Mirror of facet/ package changes from facet-nmr 154bc49 (inference,
formats, writers, retrieval, new rci module).
app: revert light-mode override, follow visitor OS preference
Maximilian Zinke
cd28bc3
Dark mode looks fine on Gradio's default styling; the light-mode forcing
was unnecessary. Keep the trimmed deuteration radio (protonated /
perdeut-exchanged only) from the previous commit.
app: force light mode + trim deuteration options to protonated/perdeut
Maximilian Zinke
de82b78
- Remove 'Perdeuterated, no back-exchange' and 'ILV methyl-protonated'
deuteration options. Neither is relevant for backbone-assigned
experiments (the only thing FACET uses shifts for).
- Force light mode UI regardless of the visitor's OS preference, via
three layers: a custom theme that overrides all *_dark CSS
variables, a small CSS rule setting color-scheme: light, and a load-
time JS that removes any 'dark' class from the root element. The
publication-aesthetic plots (white bg, near-black ink, colored
elements) look muddy on dark panels — consistent light mode matches
the figure output.
app: add 'Auto-correct shift referencing' checkbox in the UI
Maximilian Zinke
6d90949
Enabled by default. When checked, the referencing sanity check
applies its suggested per-nucleus corrections before prediction (via
the new predict(auto_reference=True) path in facet-nmr 9456def). The
post-correction results are reported under a green 'Auto-corrected'
block in the status line, listing the exact ppm subtracted per
nucleus. Uncheck to see the raw-shift warnings only.
Mirrors facet/inference.py and facet/io/formats.py from facet-nmr.
README: IDP basin-interpretation note (mirror)
Maximilian Zinke
5f9876a
visualization: align unassigned-residue rendering across both plots (mirror)
Maximilian Zinke
e6a10fc
app: put sequence-SS and residual-SS figures in switchable tabs
Maximilian Zinke
744d13c
Both figures are generated every run, but only one shows at a time in
the UI. 'Sequence + SS' tab is the default (best for folded proteins);
'Residual SS populations (IDP view)' surfaces the per-residue basin
tracks for flexible / disordered samples.
Mirror of facet-nmr 7e05909. Adds residual-SS image to the Gradio UI
alongside the existing sequence plot. Surfaces retrieval index version
in the status bar.
README: update to honest post-index-cleanup benchmark numbers (mirror)
Maximilian Zinke
0f9762b
inference: demote near-origin 'other'-basin retrievals regardless of SS (mirror)
retrieval: reject spread clusters from DBSCAN chain-merging (mirror)
Maximilian Zinke
5e4b9ab
Unify tier vocabulary to High/Medium/Low/Flexible
Maximilian Zinke
74a67a3
Mirror of facet-nmr: single confidence_class field drives display and
restraint filtering. App table uses the unified FACET vocabulary.
README calibrated numbers per tier from the 745-protein benchmark.
v0.2.0: retrieval-augmented inference
Maximilian Zinke
b1dd0ef
- Bundle 253K-residue kNN + DBSCAN reference index (122 MB LFS)
- Retrieval path in predict() populates tier + basin populations + alt clusters
- App gains Tier and Basin columns, per-residue basin-population bars
- Inspector shows alternative cluster modes for multi-modal residues
Promote deuteration notice to standalone callout
Maximilian Zinke
80fb36e
Fix HF Spaces startup: disable Gradio SSR mode
Maximilian Zinke
384f01b
Gradio 5.x defaults ssr_mode=True, which spawns an internal worker
that fetches http://localhost:7860/gradio_api/startup-events. HF
Spaces sandboxing blocks that loopback, so the startup check fails
with a misleading "shareable link" error. Disable SSR mode.
Sync: propagate polymer sequence from readers to plot
Maximilian Zinke
2d13ec6
BMRB/NMR-STAR/NEF readers now extract the full one-letter sequence and
thread it through FACETResult. plot_sequence_ss fills unassigned slots
(including N/C termini) with dim-gray letters when available, and
accepts an explicit sequence= override.
Sync: sequence/SS plot gap-preserving layout
Maximilian Zinke
2b00b60
Unassigned residues render as empty slots; SS element runs no longer
span seq_id gaps.
Sync: deuteration heuristic SS-aware with significance test
Maximilian Zinke
7101f89
Replaces the crude mean-CA check (which fired on strand-heavy
proteins for the wrong reason and false-positived on tiny samples)
with per-residue SS-corrected residuals on both CA and CB, gated
by n>=20, |bias|>0.15, and z<-2 against within-sample spread.
Verified: BMRB 27468 now fires on CB -0.41 ppm.
- chi1 rotamer softmax in the inspector as a 3-row bar chart
- Neighbor strip (i-2..i+2) on the residue Ramachandran
- "Predict & Download All" primary button; format picker in advanced
accordion
- Empty state message and gradio progress bar
- Deuteration heuristic: warn on upfield CA shifts + protonated choice
- SS_COLORS coil tone matches sequence plot
- Stale confidence_class comment fix
Sync: deuteration flag for 13C isotope shift correction
Maximilian Zinke
225cf5a
Perdeuterated samples (common for large proteins in TROSY workflows)
carry systematic upfield shifts on 13C that can reach ~0.5 ppm on Cα.
FACET was trained on protonated-equivalent data, so feeding raw
perdeuterated shifts silently biased predictions.
- New facet/deuteration.py: DeuterationVector, four presets, and the
analytical correction (Venters 1996, Hansen 1988 coefficients)
- predict() takes a deuteration= kwarg
- CLI --deuteration flag
- Gradio UI: Sample deuteration radio in the inputs sidebar
Sync: interactive Ramachandran inspector + chi1 in summary
Maximilian Zinke
96a262f
- gr.Blocks UI with per-residue Ramachandran inspector
- New facet/ramachandran.py: bundled per-AA density module
- chi1 column added to summary() output
- Neutral language pass on docstrings, comments, and UI text
- requirements.txt: gradio + plotly
Robust checkpoint resolution with multiple fallback paths
Maximilian Zinke
62cd150
Resolve the checkpoint at import time with explicit candidate list and
a diagnostic error listing what was tried. Fails fast with a useful
message if the bundled weights are missing, instead of bubbling up
as a confusing startup-events 500.
Fix: checkpoint path + disable example caching
Maximilian Zinke
9a756ee
The startup-events crash was a double bug:
1. sys.path was set to parent.parent (=/) instead of parent (=/app),
so 'import facet' couldn't find the bundled facet/ directory.
2. CHECKPOINT default fell back to ~/.facet/facet_v3.pt instead of
the bundled facet/weights/facet_v3.pt.
On Gradio 6 Spaces, example caching pre-runs the example at startup.
When that hit the stale checkpoint path the whole app failed to launch
with a confusing startup-events 500 error. Disabled cache_examples
so broken examples don't take down the app.