Skip to content

feat(diann): version-aware precursor q-value + fast-mode flags off by default - #101

Merged
ypriverol merged 6 commits into
devfrom
feat/version-precursor-qvalue
Jun 2, 2026
Merged

ypriverol merged 6 commits into
devfrom
feat/version-precursor-qvalue

Conversation

@ypriverol

Copy link
Copy Markdown
Contributor

Summary

Aligns two DIA-NN defaults with current guidance (discussed with Vadim Demichev; fast-mode report from José Nimo).

1. Version-aware precursor q-value

precursor_qvalue default → null (auto). VersionUtils.resolvePrecursorQvalue(params) resolves by diann_version:

diann_version --qvalue
1.8.1 / 2.1.0 / 2.2.0 / 2.3.2 (< 2.5) 0.01 (1%)
2.5.0+ (>= 2.5) 0.05 (5%)

Applies to the DIA-NN main report (--qvalue) and the MSstats input (--qvalue_threshold). Matrix thresholds (matrix_qvalue, matrix_spec_q) are unchanged.

User override is guaranteed. An explicit --precursor_qvalue (CLI / -c / profile) is non-null and returned verbatim — never overwritten. The schema default: 0.01 was removed so the schema layer can't repopulate the param and silently defeat the auto/override logic; type is now ["number","null"].

2. Fast-mode calibration flags off by default

performance_mode default → false. Per Vadim, --min-corr 2 --corr-diff 1 --time-corr-only can be really harmful to IDs, so they're now opt-in. quick_mass_acc (--quick-mass-acc) is unchanged (fine to keep; only minor run-to-run randomness).

Verification (local)

  • resolvePrecursorQvalue exercised via Nextflow: 1.8.1/2.1.0/2.3.2→0.01, 2.5.0/2.6→0.05, explicit 0.02 on 2.5.0→0.02, explicit 0.05 on 1.8.1→0.05, null version→0.01.
  • nextflow config parses for the default and diann_v2_5_0 profiles (precursor_qvalue=null, performance_mode=false).
  • nf-core pipelines lint: 0 failures. prettier/eof/trailing-whitespace clean.

Open item — 2.5.0 CI coverage

No current test profile pins DIA-NN 2.5.0 (test_dia/test_latest_dia ≤ 2.2.0, test_dda 2.3.2 — all map to 0.01), so CI doesn't yet exercise the 0.05 path. Options: add a 2.5.0 invocation asserting --qvalue 0.05, or bump the "Latest" matrix to 2.5.0. Flagged for discussion.

Design spec: docs/design/2026-06-02-diann-recommended-defaults-design.md.

ypriverol added 4 commits June 2, 2026 09:52
…bration flags by default

precursor_qvalue:
- default -> null (auto). VersionUtils.resolvePrecursorQvalue resolves by
  diann_version: <2.5 -> 0.01 (1%), >=2.5 -> 0.05 (5%). An explicit
  --precursor_qvalue always overrides (null is the only 'auto' sentinel;
  schema default removed so it is never repopulated). final_quantification
  (--qvalue) and diann_msstats (--qvalue_threshold) both use the resolver.
  Matrix thresholds (matrix_qvalue, matrix_spec_q) unchanged.

performance_mode:
- default -> false. The DIA-NN calibration speed flags
  '--min-corr 2 --corr-diff 1 --time-corr-only' can drop IDs (DIA-NN
  guidance) and are now opt-in. quick_mass_acc unchanged (still true).

Updates nextflow.config, lib/VersionUtils.groovy, the two consuming modules,
nextflow_schema.json, docs/parameters.md, CHANGELOG, and the design spec.
@qodo-code-review

Copy link
Copy Markdown

Qodo reviews are paused for this user.

Troubleshooting steps vary by plan Learn more →

On a Teams plan?
Reviews resume once this user has a paid seat and their Git account is linked in Qodo.
Link Git account →

Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center?
These require an Enterprise plan - Contact us
Contact us →

@coderabbitai

coderabbitai Bot commented Jun 2, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9e155cc1-7b81-49d6-961b-f101160854ab

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/version-precursor-qvalue

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions

github-actions Bot commented Jun 2, 2026 •

Copy link
Copy Markdown

nf-core pipelines lint overall result: Passed ✅ ⚠️

Posted for pipeline commit e08eb68

+| ✅ 108 tests passed       |+
#| ❔  18 tests were ignored |#
#| ❔   1 tests had warnings |#
!| ❗   4 tests had warnings |!
Details

❗ Test warnings:

  • files_exist - File not found: conf/igenomes.config
  • files_exist - File not found: conf/igenomes_ignored.config
  • files_exist - File not found: .github/workflows/awstest.yml
  • files_exist - File not found: .github/workflows/awsfulltest.yml

❔ Tests ignored:

❔ Tests fixed:

✅ Tests passed:

Run details

  • nf-core/tools version 4.0.2
  • Run at 2026-06-02 12:46:35

@ypriverol
ypriverol requested a review from yueqixuan June 2, 2026 10:16
@ypriverol
ypriverol merged commit b49e9ce into dev Jun 2, 2026
20 checks passed
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.

1 participant