augmentDrop function exported ✓ 100.0%
Last updated: 2026-02-24T21:07:57.579Z
Metrics
LOC: 4
Complexity: 2
Params: 2
Coverage: 100.0% (2/2 lines, 1929x executed)
Signature
augmentDrop(signals: string, dropRate = 0.2): : string
Summary
Simple augmentation: drop random word(s)
Source Code
export function augmentDrop(signals: string, dropRate = 0.2): string {
const words = signals.split(/\s+/);
return words.filter(() => Math.random() > dropRate).join(" ") || words[0]; // Keep at least one word
}
No outgoing dependencies.
Impact (Incoming)
| Source | Type |
|---|---|
| buildKeywordsFromDictionary | uses |
| augmentTrainingSamples | calls |