AI Slop Code Risk Monitor

swaggo/swag

SlopCodeMonitor badge for swaggo/swag Adjusted legacy signal; badge bands: 25 / 50 / 75 (different from dashboard bands).

Automatically generate RESTful API documentation with Swagger 2.0 for Go.

3.3 Low pattern signal View on GitHub

Open-Source Code Quality, Security and Technical Debt Review

This report summarizes scanner evidence for swaggo/swag, a Go project with 13,048 GitHub stars. SynthScan examined 39,141 lines of code across 292 source files, recording 125 pattern matches distributed across 3 syntactic categories. The legacy adjusted pattern signal is 3.3 (Low pattern signal); it is not an authorship estimate.

Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.

3.3
Adjusted Signal
3.3
Raw Pattern Score
100%
Time Factor
2026-09-30
Last Push
13.0K
Stars
Go
Language
39.1K
Lines of Code
292
Files
125
Pattern Hits
2026-10-31
Scan Date
0.00
HC Hit Rate

Risk Review · Payload v1

Use each vector to guide manual verification of the underlying findings.

Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.

Cognitive Ownership Risk 14.7/100 · LOW

Can maintainers explain intent, assumptions, and trade-offs? 121 finding(s).

Hallucinated Dependency & Supply Chain Risk 0.6/100 · LOW

Are imports declared and package/API names verified? 4 finding(s).

Agent Over-Engineering Ratio 0.0/100 · LOW

Are wrappers, guards, and repeated structures necessary? 0 finding(s).

PR Review Velocity Impact 15.2/100 · LOW

Which changes need focused human review? 125 finding(s).

What These Metrics Mean

Adjusted Signal
Legacy pattern score normalized per 1,000 scanned lines and multiplied by the repository-level time factor. It is not an estimate of AI authorship.
Raw Pattern Score
Sum of severity- and context-weighted pattern findings before applying the time factor.
Time Factor
A coarse multiplier based on repository last-push metadata. It does not identify when individual code was written.
Pattern Hits
Count of configured pattern findings. Review each location and surrounding code before acting.
HC Hit Rate
High- and critical-severity findings per scanned file. Severity is a configured detector weight, not proof of a vulnerability or authorship.
Lines / Files
Scan coverage denominators used by the legacy normalized score.

Pattern-Signal History

This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.

Severity Breakdown

Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.

CRITICAL 0HIGH 0MEDIUM 2LOW 123

Directory Score Breakdown

This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.

Pattern Findings

The scanner identified 125 distinct pattern matches across 3 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.

Over-Commented Block119 hits · 119 pts
SeverityFileLineSnippetContext
LOWparser_test.go3021// // run the same code 100 times and check that the output is the same every timeCOMMENT
LOWREADME_pt.md241 "github.com/swaggo/swag/example/celler/model"COMMENT
LOWREADME_pt.md321Por exemplo, utilizarCOMMENT
LOWREADME_pt.md641COMMENT
LOWREADME_zh-CN.md141COMMENT
LOWREADME_zh-CN.md241// ShowAccount godocCOMMENT
LOWREADME_zh-CN.md261 if err != nil {COMMENT
LOWREADME_zh-CN.md561```COMMENT
LOWREADME.md161import "github.com/swaggo/files" // swagger embed filesCOMMENT
LOWREADME.md261)COMMENT
LOWREADME.md281 }COMMENT
LOWREADME.md341COMMENT
LOWREADME.md661COMMENT
LOWformatter_test.go21func Test_FormatMain(t *testing.T) {COMMENT
LOWformatter_test.go41 // @in headerCOMMENT
LOWformatter_test.go61 // @tokenUrl https://example.com/oauth/tokenCOMMENT
LOWformatter_test.go81// @BasePath /v2COMMENT
LOWformatter_test.go121COMMENT
LOWformatter_test.go141COMMENT
LOWformatter_test.go161 func GetStringByInt(w http.ResponseWriter, r *http.Request) {}`COMMENT
LOWtestdata/extensionsFail1.go1package mainCOMMENT
LOWtestdata/extensionsFail2.go1package mainCOMMENT
LOWtestdata/templated.go1package mainCOMMENT
LOWtestdata/templated.go21// @scope.admin Grants read and write access to administrative informationCOMMENT
LOWtestdata/main.go1package mainCOMMENT
LOWtestdata/main.go21// @securityDefinitions.apikey ApiKeyAuthCOMMENT
LOWtestdata/main.go41// @scope.admin Grants read and write access to administrative informationCOMMENT
LOWtestdata/duplicated2/api/api.go1package apiCOMMENT
LOWtestdata/duplicated2/api/api.go21func OptionsFoo(w http.ResponseWriter, r *http.Request) {}COMMENT
LOWtestdata/struct_comment/api/api.go1package apiCOMMENT
LOWtestdata/generics_property/api/api.go41// @Success 203 {object} NestedResponse "ok"COMMENT
LOWtestdata/format_dst/main.go21// @host petstore.swagger.ioCOMMENT
LOWtestdata/format_dst/api/api.go1package apiCOMMENT
LOWtestdata/format_dst/api/api.go21 //write your codeCOMMENT
LOWtestdata/format_dst/api/api.go41// @Security OAuth2Password[admin]COMMENT
LOWtestdata/tags2/main.go1package mainCOMMENT
LOWtestdata/single_file_api/main.go1package mainCOMMENT
LOWtestdata/non_exported_json_fields/main.go21 NestedInternal stringCOMMENT
LOWtestdata/format_test/main.go21// @host petstore.swagger.ioCOMMENT
LOWtestdata/format_test/api/api.go1package apiCOMMENT
LOWtestdata/format_test/api/api.go21 //write your codeCOMMENT
LOWtestdata/format_test/api/api.go41// @Security OAuth2Password[admin]COMMENT
LOWtestdata/tags_nonexistend_tag/main.go1package mainCOMMENT
LOWtestdata/global_security/main.go1package global_securityCOMMENT
LOWtestdata/global_security/api/api.go21// @Router /testapi/basic [get]COMMENT
LOWtestdata/json_field_string/main.go21// @Accept jsonCOMMENT
LOWtestdata/enums/main.go1package mainCOMMENT
LOWtestdata/enums/api/api.go1package apiCOMMENT
LOWtestdata/enums/api/api.go21// @Param typeinpath path types.Type true "type"COMMENT
LOWtestdata/enums/api/api.go41// @Summary test array enums fields in formdata requestCOMMENT
LOWtestdata/golist/api/api.go21 Status string `json:"status"`COMMENT
LOWtestdata/state/api/api_user.go1package apiCOMMENT
LOWtestdata/state/api/api_user.go21// @State userCOMMENT
LOWtestdata/state/api/api_user.go41func GetStructArrayByStringUser(w http.ResponseWriter, r *http.Request) {COMMENT
LOWtestdata/state/api/api.go1package apiCOMMENT
LOWtestdata/state/api/api.go21// @State adminCOMMENT
LOWtestdata/state/api/api.go41func GetStructArrayByString(w http.ResponseWriter, r *http.Request) {COMMENT
LOWtestdata/composition/api/api.go61// @Description get BarCOMMENT
LOWtestdata/composition/api/api.go81}COMMENT
LOWtestdata/composition/api/api.go101 //write your codeCOMMENT
59 more matches not shown…
Slop Phrases2 hits · 5 pts
SeverityFileLineSnippetContext
MEDIUMparser_test.go2054 "description": "This is a sample server Petstore server. You can find out more about Swagger at [http://swaCODE
MEDIUMtestdata/pet/main.go5// @description This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io]COMMENT
Fake / Example Data4 hits · 5 pts
SeverityFileLineSnippetContext
LOWtestdata/description_line_continuation/expected.json13 "description": "This is a mock endpoint description which is long and descriptions that end with backslaCODE
LOWtestdata/description_line_continuation/expected.json13 "description": "This is a mock endpoint description which is long and descriptions that end with backslaCODE
LOWtestdata/description_line_continuation/api/api.go14// @Description Lorem ipsum dolor sit amet \COMMENT
LOWtestdata/description_line_continuation/api/api.go14// @Description Lorem ipsum dolor sit amet \COMMENT