m3triq 0.2.12 → 0.2.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -85,7 +85,7 @@ m3t md results <job-id>
85
85
 
86
86
  ```bash
87
87
  m3t predict esmfold MKFLILLFNILCL... # Fast (~10s, max 1024aa)
88
- m3t predict alphafold2 MKFLILLFNILCL... # Accurate (~15-20min, max 2048aa)
88
+ m3t predict alphafold2 MKFLILLFNILCL... # AF2-ptm monomer via deep MSA + ColabFold (~5-15min)
89
89
 
90
90
  # ESMFold2-Fast — monomer or multi-chain complex (self-hosted A100, max 2048aa total).
91
91
  # Beats AlphaFold3 on antibody-antigen DockQ from single sequence; returns pLDDT/pTM/ipTM.
@@ -95,8 +95,31 @@ m3t predict esmfold2-batch inputs.json # fold N complexes
95
95
 
96
96
  # Boltz-2 — biomolecular complex (protein + DNA/RNA + ligand) with binding affinity
97
97
  m3t predict boltz2 --protein MKFL... --ligand "CC(=O)O" --rna GGUC...
98
+
99
+ # OpenFold3 — AlphaFold3-class complex (protein + DNA/RNA + ligand); real MSAs
100
+ m3t predict openfold3 --protein EVQL... --protein DIQM... # complex, auto-paired
101
+ m3t predict openfold3 --protein MKFL... --ligand ATP --depth exhaustive
98
102
  ```
99
103
 
104
+ ## MSA Generation
105
+
106
+ Generate a multiple-sequence alignment (`.a3m`) — the evolutionary input folders use.
107
+ Two orthogonal knobs: **`--depth`** = coverage (databases), **`--pair`** = species
108
+ pairing (only matters for multi-chain complexes; on by default, a monomer is never paired).
109
+
110
+ ```bash
111
+ m3t msa --sequence MKFL... # standard, monomer
112
+ m3t msa --chain A:EVQL... --chain B:DIQM... # standard complex, auto-paired
113
+ m3t msa --chain A:EVQL... --chain B:DIQM... --no-pair # complex, force unpaired
114
+ m3t msa --sequence MKFL... --depth exhaustive --templates # + metagenomic envDB + PDB templates
115
+ m3t msa --sequence MKFL... --depth custom \
116
+ --databases uniref30,envdb --max-sequences 300 # fine control (max_sequences caps depth)
117
+ ```
118
+
119
+ - `--depth`: `standard` (UniRef30, default) | `exhaustive` (+ metagenomic envDB) | `custom`
120
+ - `--templates`: also save per-chain PDB structural templates (`templates_<chain>.json`)
121
+ - Output: one `.a3m` per chain in the project's Files tab; repeat sequences are cached (instant)
122
+
100
123
  ## Protein Embeddings
101
124
 
102
125
  ```bash
package/dist/cli.js CHANGED
@@ -25,7 +25,7 @@ const program = new Command();
25
25
  program
26
26
  .name('m3t')
27
27
  .description('M3TRIQ — protein-ligand analysis from the terminal')
28
- .version('0.2.12')
28
+ .version('0.2.14')
29
29
  .option('--json', 'Output as JSON (machine-readable)')
30
30
  .hook('preAction', (thisCommand) => {
31
31
  const opts = thisCommand.optsWithGlobals();
package/dist/client.d.ts CHANGED
@@ -87,7 +87,7 @@ export declare class M3triqClient {
87
87
  id: string;
88
88
  sequence: string;
89
89
  }[];
90
- depth: 'fast' | 'deep' | 'exhaustive' | 'custom';
90
+ depth: 'standard' | 'exhaustive' | 'custom' | 'fast' | 'deep';
91
91
  pair: boolean;
92
92
  templates?: boolean;
93
93
  custom?: {
@@ -4,32 +4,34 @@ import { requireProject } from '../config.js';
4
4
  import { output } from '../output.js';
5
5
  import { jobUrl, maybeOpenBrowser } from '../url.js';
6
6
  // m3t msa — generate a multiple-sequence alignment (a3m) for one or more chains,
7
- // all on the self-hosted ColabFold MSA-search engine (GPU-MMseqs2):
8
- // fast = UniRef30, shallow, no pairing (quick triage)
9
- // deep = UniRef30, full depth + species pairing (complexes/hard families)
10
- // exhaustive = deep + the metagenomic envDB (remote-homology / orphan families)
11
- // custom = you pick the databases (+ max_sequences / pairing)
7
+ // all on the self-hosted ColabFold MSA-search engine (GPU-MMseqs2). Two independent
8
+ // knobs:
9
+ // --depth = COVERAGE (which databases): standard (UniRef30) | exhaustive (+envDB,
10
+ // for remote-homology/orphan families) | custom (pick databases)
11
+ // --pair = species PAIRING, only meaningful for a multi-chain complex (on by
12
+ // default; a monomer is never paired). --no-pair to force unpaired.
12
13
  // --templates also searches the PDB and saves per-chain structural templates.
13
14
  // Produces a downloadable .a3m artifact per chain (+ templates_<chain>.json).
14
- const MSA_DEPTHS = ['fast', 'deep', 'exhaustive', 'custom'];
15
+ // (Legacy --depth fast/deep still accepted: fast = standard+unpaired, deep = standard.)
16
+ const MSA_DEPTHS = ['standard', 'exhaustive', 'custom', 'fast', 'deep'];
15
17
  export function registerMsaCommands(program) {
16
18
  program.command('msa')
17
19
  .description('Generate a multiple-sequence alignment (a3m) — per-chain and (for complexes) species-paired')
18
20
  .option('--chain <id:seq>', 'Chain as "id:sequence" or "id:@path". Repeatable for multi-chain (paired) MSAs.', collectArg, [])
19
21
  .option('--sequence <seq>', 'Single-chain shortcut (chain id "A"). Use --chain for multi-chain.')
20
- .option('--depth <tier>', 'MSA depth: fast | deep | exhaustive | custom (see `m3t msa --help`)', 'fast')
22
+ .option('--depth <coverage>', 'Coverage / databases: standard (UniRef30) | exhaustive (+ envDB) | custom', 'standard')
21
23
  .option('--templates', 'Also search the PDB for structural templates; saves a templates_<chain>.json per chain.')
22
24
  .option('--databases <csv>', 'For --depth custom: comma-separated database ids (e.g. "uniref30,envdb"). See get_msa_capabilities.')
23
25
  .option('--max-sequences <n>', 'For --depth custom: alignment depth/breadth cap.', (v) => parseInt(v, 10))
24
- .option('--pair', 'Compute species-paired MSA across chains (complexes). Default on for ≥2 distinct chains.')
25
- .option('--no-pair', 'Skip paired MSA (per-chain only).')
26
+ .option('--pair', 'Species-paired MSA only matters for a multi-chain complex (on by default; a monomer is never paired).')
27
+ .option('--no-pair', 'Force unpaired (per-chain only), even for a complex.')
26
28
  .option('--name <name>', 'Custom job title')
27
29
  .action(async (opts) => {
28
30
  await runMsa(opts);
29
31
  });
30
32
  }
31
33
  async function runMsa(opts) {
32
- const depth = (opts.depth || 'fast').toLowerCase();
34
+ const depth = (opts.depth || 'standard').toLowerCase();
33
35
  if (!MSA_DEPTHS.includes(depth)) {
34
36
  process.stderr.write(`Error: --depth must be one of ${MSA_DEPTHS.join(' | ')}, got "${opts.depth}".\n`);
35
37
  process.exit(1);
@@ -85,11 +87,9 @@ async function runMsa(opts) {
85
87
  const url = jobUrl(consoleUrl, project.id, result.job_id);
86
88
  maybeOpenBrowser(url);
87
89
  const timeEst = depth === 'exhaustive'
88
- ? '~4-6 min (ColabFold UniRef30 + envDB on 2 T4s; +cold start if scaled to zero)'
89
- : depth === 'fast'
90
- ? '~2-4 min (ColabFold UniRef30; +cold start if scaled to zero)'
91
- : '~3-5 min (ColabFold UniRef30 + paired; +cold start if scaled to zero)';
92
- const extras = [pair ? 'paired' : '', templates ? '+templates' : ''].filter(Boolean).join(', ');
90
+ ? `~4-6 min (UniRef30 + envDB on 2 T4s${pair ? ' + paired' : ''}; +cold start if scaled to zero)`
91
+ : `~3-5 min (UniRef30${pair ? ' + paired' : ''}; +cold start if scaled to zero)`;
92
+ const extras = [pair ? 'paired' : 'unpaired', templates ? '+templates' : ''].filter(Boolean).join(', ');
93
93
  const lines = [
94
94
  `MSA job queued (${chains.length} chain${chains.length > 1 ? 's' : ''}, depth=${depth}${extras ? `, ${extras}` : ''})`,
95
95
  `Job ID: ${result.job_id.substring(0, 8)}`,
@@ -13,19 +13,14 @@ export function registerPredictCommands(program) {
13
13
  .action(async (sequence, opts) => {
14
14
  await runPredict(sequence, 'esmfold', opts.name);
15
15
  });
16
- // m3t predict alphafold2 — RETIRED (the alphafold2-nim VM was decommissioned in
17
- // favour of ESMFold2). Kept as a signpost so scripts get a clear redirect instead
18
- // of a job that silently fails on the deleted backend.
16
+ // m3t predict alphafold2 — AF2 (ptm) monomer via the self-hosted ColabFold service
17
+ // (the alphafold2-nim VM was retired; same AF2 weights, deep MSA from m3t_msa_server).
19
18
  predict.command('alphafold2')
20
- .argument('[sequence]', 'Amino acid sequence (single letter codes)')
19
+ .argument('<sequence>', 'Amino acid sequence (single letter codes, max 2048aa)')
21
20
  .option('--name <name>', 'Name for the prediction')
22
- .description('[RETIRED use `predict esmfold2`] AlphaFold2 single-sequence prediction')
23
- .action(async () => {
24
- process.stderr.write('AlphaFold2 has been retired (the self-hosted backend was decommissioned).\n' +
25
- 'Use ESMFold2 instead — higher accuracy and it folds complexes too:\n' +
26
- ' m3t predict esmfold2 --sequence <seq> # monomer\n' +
27
- ' m3t predict esmfold2 --chain A:<seq> --chain B:<seq> # complex\n');
28
- process.exit(2);
21
+ .description('AlphaFold2 (ptm) monomer prediction deep MSA + ColabFold (~5-15 min, +cold start)')
22
+ .action(async (sequence, opts) => {
23
+ await runPredict(sequence, 'alphafold2', opts.name);
29
24
  });
30
25
  // m3t predict esmfold2 — monomer OR multi-chain (antibody-antigen, PPI)
31
26
  predict.command('esmfold2')
@@ -101,7 +96,7 @@ async function runPredict(sequence, method, name) {
101
96
  });
102
97
  const url = jobUrl(consoleUrl, project.id, result.job_id);
103
98
  maybeOpenBrowser(url);
104
- const timeEst = method === 'alphafold2' ? '~15-20 minutes (varies with length)' : '~10 seconds';
99
+ const timeEst = method === 'alphafold2' ? '~5-15 minutes (deep MSA + ColabFold; +cold start)' : '~10 seconds';
105
100
  const data = { job_id: result.job_id, method, sequence_length: sequence.length, url };
106
101
  output(data, `${method} prediction created\nJob ID: ${result.job_id.substring(0, 8)}\nLength: ${sequence.length} residues\nEstimated: ${timeEst}`);
107
102
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "m3triq",
3
- "version": "0.2.12",
3
+ "version": "0.2.14",
4
4
  "description": "M3TRIQ \u2014 protein-ligand analysis from the terminal",
5
5
  "type": "module",
6
6
  "bin": {