agentsclimarketplace

Spectral noise filtering preprocessing

Skill HolobiomicsLab/asb-skill-collections/collections/metabolomics/v2/skills/spectral-noise-filtering-preprocessing

Use when you have raw MS/MS spectral data and plan to calculate spectral similarity scores (whether using entropy distance, dot product, or other algorithms) for compound identification.From its SKILL.md

Install
npx -y skills add HolobiomicsLab/asb-skill-collections --skill spectral-noise-filtering-preprocessing

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 15 stars15 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its file declares

Copied from the file, not written here

The file declares its own license as CC-BY-4.0. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.

SKILL.md

6.9 KB, ~1.1k tokens by cl100k_base, as published. Nobody here has run it

spectral-noise-filtering-preprocessing

Summary

Remove low-intensity peaks from MS/MS spectra prior to similarity calculations to improve compound identification accuracy. This preprocessing step filters noise while preserving signal-bearing peaks by eliminating peaks below a relative intensity threshold.

When to use

Apply this skill when you have raw MS/MS spectral data and plan to calculate spectral similarity scores (whether using entropy distance, dot product, or other algorithms) for compound identification. The presence of low-intensity noise peaks—particularly those arising from instrument artifacts or chemical background—degrades similarity metrics and ranking performance, making this preprocessing step essential before benchmarking or production identification workflows.

When NOT to use

  • Spectra that have already been noise-filtered by the instrument or vendor software; re-filtering may degrade signal.
  • Analysis pipelines where peak intensity variance is itself the object of study (e.g., studying noise patterns or low-abundance metabolite detection); removing low peaks destroys that information.
  • High-resolution or targeted analysis requiring detection of very low-abundance precursor or product ions; the 1% threshold may be too aggressive.

Inputs

  • raw MS/MS spectral data (m/z and intensity pairs)
  • list or array of spectra with peak intensity values

Outputs

  • preprocessed MS/MS spectral data with noise peaks removed
  • filtered peak lists (m/z and intensity pairs above 1% threshold)

How to apply

Remove peaks with intensity less than 1% of the maximum intensity in each spectrum before calculating spectral similarity. This threshold balances noise suppression with signal retention: peaks below 1% maximum intensity contribute noise that degrades compound ranking without providing discriminative information, while peaks above this threshold carry identification signal. Apply this filter uniformly to all spectra in your dataset (both query and library spectra) to ensure consistent preprocessing. The README recommends this step explicitly: 'it's highly recommended to remove spectral noise. For example, peaks have intensity less than 1% maximum intensity can be removed to improve identification performance.' Verify the filtered spectrum retains the majority of peak count and total intensity to confirm the threshold is appropriate.

Related tools

Evaluation signals

  • Peak count reduction: Verify that the number of peaks decreases after filtering (typically 20–50% reduction depending on noise level in raw data).
  • Intensity threshold validation: Confirm that all retained peaks have intensity ≥ 1% of the maximum intensity in each spectrum; all removed peaks have intensity < 1%.
  • Similarity metric improvement: Compare spectral similarity scores or compound ranking accuracy before and after filtering; preprocessed spectra should yield higher dot product or entropy similarity scores and better rank-ordering of true matches.
  • Spectrum integrity: Confirm that base peak (maximum intensity) and major product ion peaks are retained; no critical ions should fall below the 1% threshold.
  • Reproducibility: Apply the same 1% threshold uniformly across all query and reference spectra to ensure fair comparison.

Limitations

  • The 1% intensity threshold is empirical and may require adjustment for different instrument types, ionization methods, or compound classes; spectra from very clean ion sources or highly abundant low-mass products may lose signal with this threshold.
  • The paper does not report threshold sensitivity analysis or recommend adaptive thresholds; practitioners must validate the 1% cutoff against their specific data.
  • This preprocessing step assumes peaks are independent; it does not account for isotope patterns or multiply-charged ion clusters that might span a wide intensity range.
  • The filter is applied post-acquisition; instrumental or vendor-level noise filtering settings should be optimized first; this skill is a secondary confirmation step, not a replacement for instrument configuration.

Evidence

  • [other] Before calculating spectral similarity, it's highly recommended to remove spectral noise: "Before calculating spectral similarity, it's highly recommended to remove spectral noise"
  • [other] peaks have intensity less than 1% maximum intensity can be removed to improve identificaiton performance: "peaks have intensity less than 1% maximum intensity can be removed to improve identificaiton performance"
  • [readme] it's highly recommended to remove spectral noise. For example, peaks have intensity less than 1% maximum intensity can be removed: "it's highly recommended to remove spectral noise. For example, peaks have intensity less than 1% maximum intensity can be removed"

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.