Commit 2ddd81f
authored
feat(deslop): add buzzword inflation detection (#113)
* feat(deslop): add buzzword inflation detection
Detect quality claims (production-ready, secure, scalable, etc.) in
documentation that lack supporting code evidence. This completes the
AI slop research implementation roadmap (Priority 3, Task #7).
- Add analyzeBuzzwordInflation() function with claim extraction
- Support 6 buzzword categories: production, enterprise, security,
scale, reliability, completeness
- Search for evidence patterns: tests, error handling, logging,
auth, validation, encryption, async, cache, pool
- Distinguish positive claims from TODOs/FIXMEs (reduce false positives)
- Add 50+ tests for new functionality
* fix(deslop): address PR review feedback
- Fix shouldExclude using entry.name instead of full relative path
- Include test files in evidence search (tests are evidence)
- Optimize extractClaims with single combined regex + Map lookup
- Add isFilePathPattern() helper for robust path vs content detection
- Move require statements to top of describe block in tests
* fix(deslop): address Copilot review feedback
- Add buzzword_inflation pattern tests to slop-patterns.test.js
- Fix overly broad errorHandling pattern in completeness category
- Fix documentation regex (remove #.*docstring false positive)
- Remove overly broad /with/ from CLAIM_INDICATORS
- Refine NOT_CLAIM_INDICATORS /make/ pattern to be more specific
- Update exclude property to empty array with explanatory comment
- Optimize searchEvidence to skip file reads for path-only patterns1 parent eff57c0 commit 2ddd81f
6 files changed
Lines changed: 1131 additions & 5 deletions
File tree
- __tests__
- lib/patterns
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
11 | 27 | | |
12 | 28 | | |
13 | 29 | | |
| |||
0 commit comments