AI Slop Code RIsk Monitor

cockroachdb/pebble

RocksDB/LevelDB inspired key-value database in Go

5.8 Moderate pattern signal View on GitHub

Maintenance and Governance Review

This report summarizes scanner evidence for cockroachdb/pebble, a Go project with 6,051 GitHub stars. SynthScan examined 277,584 lines of code across 853 source files, recording 1400 pattern matches distributed across 9 syntactic categories. The legacy adjusted pattern signal is 5.8 (Moderate 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.

5.8
Adjusted Signal
5.8
Raw Pattern Score
100%
Time Factor
2026-10-10
Last Push
6.1K
Stars
Go
Language
277.6K
Lines of Code
853
Files
1.4K
Pattern Hits
2026-10-12
Scan Date
0.03
HC Hit Rate

Risk Review · v3

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

Cognitive Ownership Risk 21.7/100 · LOW

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

Hallucinated Dependency & Supply Chain Risk 4.4/100 · LOW

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

Agent Over-Engineering Ratio 0.1/100 · LOW

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

PR Review Velocity Impact 25.6/100 · MEDIUM

Which changes need focused human review? 1400 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 25HIGH 0MEDIUM 10LOW 1365

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 1400 distinct pattern matches across 9 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 Block1329 hits · 1261 pts
SeverityFileLineSnippetContext
LOWblob_rewrite.go81// rewrites a blob file without rewriting sstables. When the compactionCOMMENT
LOWrange_keys.go61 }COMMENT
LOWrange_keys.go121func containsAnyRangeKeys(iter manifest.LevelIterator) bool {COMMENT
LOWrange_keys.go141// RangeKeyMasking.Suffix, it acts as a mask.COMMENT
LOWrange_keys.go161//COMMENT
LOWrange_keys.go181// IterOptions.RangeKeyMasking field has an optional Filter option. This FilterCOMMENT
LOWrange_keys.go201// property filter interface with two new methods: KeyIsWithinLowerBound andCOMMENT
LOWrange_keys.go221// block property filter indicates that it does NOT intersect, the filter'sCOMMENT
LOWrange_keys.go301// iteration. Whenever a point key is covered by a non-empty Span, theCOMMENT
LOWrange_keys.go321// s 8 | • l@8COMMENT
LOWrange_keys.go361 return falseCOMMENT
LOWrange_keys.go381//COMMENT
LOWrange_keys.go421func (m *rangeKeyMasking) KeyIsWithinLowerBound(key []byte) bool {COMMENT
LOWrange_keys.go441// lazyCombinedIter implements the internalIterator interface, wrapping aCOMMENT
LOWrange_keys.go461// When one is discovered, they set triggered=true and key to the smallestCOMMENT
LOWrange_keys.go481 c.triggered = trueCOMMENT
LOWrange_keys.go521 // switch to combined iteration was itself a seek, and we can use that key.COMMENT
LOWrange_keys.go541 // L6: 000001:[bar.SET.2] 000002:[bax.RANGEKEYSET.8]COMMENT
LOWrange_keys.go581 // iterator that's now initialized with our current state.COMMENT
LOWcheckpoint.go21COMMENT
LOWcheckpoint.go41// performed with Sync = false. Otherwise, the guarantee will already be met.COMMENT
LOWcheckpoint.go201 virtualBackingFiles := make(map[base.DiskFileNum]struct{})COMMENT
LOWrecovery.go241 Path: path,COMMENT
LOWrecovery.go441// replayWAL replays the edits in the specified WAL. If the DB is in readCOMMENT
LOWrecovery.go541 // surfaces record.ErrInvalidChunk or record.ErrZeroedChunk. TheseCOMMENT
LOWtable_stats.go21 "github.com/cockroachdb/pebble/sstable/block"COMMENT
LOWtable_stats.go41// so a completing job triggers a new job if necessary. Only one job runs at aCOMMENT
LOWtable_stats.go441 // If the table is in the last level of the LSM, there is no dataCOMMENT
LOWtable_stats.go461 // deletion is ingested into L5 and subsequently compacted into L6 butCOMMENT
LOWtable_stats.go621 // FileSize RawValueSizeCOMMENT
LOWtable_stats.go641}COMMENT
LOWtable_stats.go661func (d *DB) examineTablesBeneathTombstones(COMMENT
LOWtable_stats.go681 // Determine whether we need to update size estimates andCOMMENT
LOWtable_stats.go821}COMMENT
LOWtable_stats.go861 return 0COMMENT
LOWtable_stats.go881 // point tombstone on average covers 1 key and using average value sizes.COMMENT
LOWtable_stats.go921 // The shadowed keys have the same exact user keys as the tombstonesCOMMENT
LOWtable_stats.go941 return uint64((tombstonesLogicalSize + shadowedLogicalSize) * compressionRatio)COMMENT
LOWtable_stats.go961// of both range deletions and range key deletions.COMMENT
LOWtable_stats.go981// |--------| |-------| RANGEKEYDELCOMMENT
LOWtable_stats.go1061 mIter.Init(comparer, transform, new(keyspanimpl.MergingBuffers))COMMENT
LOWtable_stats.go1081 // SSTables" where the table metadata's effective bounds can again beCOMMENT
LOWingest_test.go2881COMMENT
LOWingest_test.go2901 time.Sleep(100 * time.Millisecond)COMMENT
LOWmerging_iter_v2_slab.go21// merging iterator.COMMENT
LOWmerging_iter_v2_slab.go41}COMMENT
LOWevent.go281 // JobID is the ID of the compaction job.COMMENT
LOWevent.go381 JobID intCOMMENT
LOWevent.go621 }COMMENT
LOWevent.go861 // SINGLEDEL and delete an arbitrary subset of data below that SINGLEDEL.COMMENT
LOWevent.go881 // ways some of these keys can first meet in a compaction.COMMENT
LOWevent.go901 // SET g#40 in L2COMMENT
LOWevent.go921 // violation callback. This example doesn't need multi-level compactions:COMMENT
LOWevent.go981COMMENT
LOWcompaction_value_separation.go181 // existing references.COMMENT
LOWlevel_iter_v2.go21// levelIterV2 provides a merged view of the sstables in a level.COMMENT
LOWlevel_iter_v2.go41//COMMENT
LOWlevel_iter_v2.go61// potentially spurious: it does not necessarily correspond to a change in rangeCOMMENT
LOWlevel_iter_v2.go81 // tableOpts.{Lower,Upper}Bound are nil, the corresponding iteration boundaryCOMMENT
LOWlevel_iter_v2.go101 iterFile *manifest.TableMetadataCOMMENT
1269 more matches not shown…
Hallucination Indicators25 hits · 250 pts
SeverityFileLineSnippetContext
CRITICALcheckpoint.go202 for backing := range d.mu.versions.latest.virtualBackings.All() {CODE
CRITICALcheckpoint.go205 versionBlobFiles := d.mu.versions.latest.blobFiles.Metadatas()CODE
CRITICALdb.go2312 backingStats := d.mu.versions.latest.virtualBackings.Stats()CODE
CRITICALdb.go2313 blobStats, _ := d.mu.versions.latest.blobFiles.Stats()CODE
CRITICALdb.go2748 l0ReadAmp := d.mu.versions.latest.l0Organizer.ReadAmplification()CODE
CRITICALdb.go2938 if err := d.mu.log.metrics.LogWriterMetrics.Merge(&metrics); err != nil {CODE
CRITICALingest.go1034 if backing, ok := d.mu.versions.latest.virtualBackings.Get(n); ok {CODE
CRITICALingest.go1037 d.mu.versions.latest.virtualBackings.Protect(n)CODE
CRITICALingest.go1062 d.mu.versions.latest.virtualBackings.Unprotect(meta.TableBacking.DiskFileNum)CODE
CRITICALcheckpoint_test.go160 fileNums := d.mu.versions.latest.virtualBackings.DiskFileNums()CODE
CRITICALcompaction_test.go1195 s := d.mu.versions.latest.virtualBackings.String()CODE
CRITICALcompaction.go396 if err := d.mu.versions.latest.l0Organizer.UpdateStateForStartedCompaction(l0Inputs, isBase); err != nil {CODE
CRITICALcompaction.go1354 d.mu.versions.latest.l0Organizer.InitCompactingFileInfo(l0InProgress)CODE
CRITICALiterator.go2529 i.readState.db.mu.compact.readCompactions.combine(&i.readSampling.pendingCompactions, i.cmp)CODE
CRITICALsnapshot.go97 s.db.mu.compact.wideTombstones.UpdateWithEarliestSnapshot(e)CODE
CRITICALsnapshot.go424 es.db.mu.compact.cond.Wait()CODE
CRITICALsstable/reader_iter_two_lvl.go525 smallest = i.secondLevel.reader.Comparer.Split.Prefix(smallest)CODE
CRITICALsstable/reader_iter_two_lvl.go527 largest = i.secondLevel.reader.Comparer.Split.Prefix(largest)CODE
CRITICALsstable/reader_iter_two_lvl.go1051 return i.seekPrefixGE(i.secondLevel.reader.Comparer.Split.Prefix(i.secondLevel.synthetic.seekKey),CODE
CRITICALmetamorphic/generator.go911 key = g.keyManager.kf.Comparer.Split.Prefix(key)CODE
CRITICALmetamorphic/cockroachkvs.go268 if !kg.keyManager.prefixExists(kg.keyManager.kf.Comparer.Split.Prefix(key)) {CODE
CRITICALobjstorage/objstorageprovider/cold_writable.go102 w.meta.file, w.err = w.p.st.Local.FS.Create(w.metaPath(), w.diskWriteCategory)CODE
CRITICALobjstorage/objstorageprovider/cold_writable.go167 _ = w.p.st.Local.FS.Remove(w.metaPath())CODE
CRITICALobjstorage/objstorageprovider/vfs.go245 fsDir, err := p.st.Local.ColdTier.FS.OpenDir(p.st.Local.ColdTier.FSDirName)CODE
CRITICALobjstorage/objstorageprovider/vfs.go251 coldListing, err := p.st.Local.ColdTier.FS.List(p.st.Local.ColdTier.FSDirName)CODE
Structural Annotation Overuse15 hits · 31 pts
SeverityFileLineSnippetContext
LOWcompaction.go208// NOTE: This function iterates up to compactionKindVirtualRewrite. If a newCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh125# Step 3: Build clean HEAD test binaryCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh133# Step 4: Run crossversion test WITHOUT the bug (should PASS)COMMENT
LOW⚡scripts/crossversion_smoke_test.sh167# Step 5: Apply the intentional bug patchCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh177# Step 6: Build buggy HEAD test binaryCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh185# Step 7: Test buggy version by itself (should PASS - verifies patch doesn't break single-version)COMMENT
LOW⚡scripts/crossversion_smoke_test.sh219# Step 8: Revert the patchCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh225# Step 9: Run crossversion test WITH the bug multiple times (should FAIL at least once)COMMENT
LOWscripts/crossversion_smoke_test.sh93# Step 1: Find the latest release branchCOMMENT
LOWscripts/crossversion_smoke_test.sh111# Step 2: Build test binary from release branchCOMMENT
LOWscripts/crossversion_smoke_test.sh264# Step 10: Verify that the test failed in phase 2COMMENT
LOW⚡.github/workflows/cockroach-go.yaml55 # Step 1: Fetch the branch tip SHA for cache keyCOMMENT
LOW⚡.github/workflows/cockroach-go.yaml62 # Step 2: Restore cache (per branch + commit SHA)COMMENT
LOW⚡.github/workflows/cockroach-go.yaml69 # Step 3: Install bootstrap Go (needed to build fork)COMMENT
LOW⚡.github/workflows/cockroach-go.yaml75 # Step 4: Run tests with custom GoCOMMENT
Verbosity Indicators14 hits · 29 pts
SeverityFileLineSnippetContext
LOW⚡scripts/crossversion_smoke_test.sh125# Step 3: Build clean HEAD test binaryCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh133# Step 4: Run crossversion test WITHOUT the bug (should PASS)COMMENT
LOW⚡scripts/crossversion_smoke_test.sh167# Step 5: Apply the intentional bug patchCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh177# Step 6: Build buggy HEAD test binaryCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh185# Step 7: Test buggy version by itself (should PASS - verifies patch doesn't break single-version)COMMENT
LOW⚡scripts/crossversion_smoke_test.sh219# Step 8: Revert the patchCOMMENT
LOW⚡scripts/crossversion_smoke_test.sh225# Step 9: Run crossversion test WITH the bug multiple times (should FAIL at least once)COMMENT
LOWscripts/crossversion_smoke_test.sh93# Step 1: Find the latest release branchCOMMENT
LOWscripts/crossversion_smoke_test.sh111# Step 2: Build test binary from release branchCOMMENT
LOWscripts/crossversion_smoke_test.sh264# Step 10: Verify that the test failed in phase 2COMMENT
LOW⚡.github/workflows/cockroach-go.yaml55 # Step 1: Fetch the branch tip SHA for cache keyCOMMENT
LOW⚡.github/workflows/cockroach-go.yaml62 # Step 2: Restore cache (per branch + commit SHA)COMMENT
LOW⚡.github/workflows/cockroach-go.yaml69 # Step 3: Install bootstrap Go (needed to build fork)COMMENT
LOW⚡.github/workflows/cockroach-go.yaml75 # Step 4: Run tests with custom GoCOMMENT
AI Slop Vocabulary9 hits · 27 pts
SeverityFileLineSnippetContext
MEDIUMingest.go1183 // for data overlap is a little more nuanced. Consider the following examples:COMMENT
MEDIUMiterator.go1416 // We also leverage the IterAtLimit <=> i.pos invariant defined in theCOMMENT
MEDIUMsstable/format.go109// The ideal solution for P2 would allow user-facing reads to utilize theCOMMENT
MEDIUMsstable/format.go203// For robust correctness, non-obsolete SINGLEDELs in foreign sstables shouldCOMMENT
MEDIUMsstable/reader_iter.go113// An implication of the above is that if we are going to somehow utilizeCOMMENT
MEDIUMinternal/compact/iterator.go133// that backs a compact.Iter is nuanced and care must be taken whenCOMMENT
MEDIUMinternal/iterv2/iter.go115// A more nuanced example:COMMENT
MEDIUMinternal/base/lazy_value.go176 // iterator that initially provided this LazyValue. Hence, to utilize thisCOMMENT
MEDIUMobjstorage/objstorageprovider/remote_readable.go208 // could enhance this to utilize a suffix of the needed data.COMMENT
Hyper-Verbose Identifiers5 hits · 5 pts
SeverityFileLineSnippetContext
LOWdocs/js/write-throughput.js12function writeThroughputSummaryURL() {CODE
LOWdocs/js/write-throughput.js37function bisectAndRenderWriteThroughputDetail(data, detailDate) {CODE
LOWdocs/js/write-throughput.js64function renderWriteThroughputSummary(allData) {CODE
LOWdocs/js/write-throughput.js304function fetchWriteThroughputSummaryData(file) {CODE
LOWdocs/js/write-throughput.js334function renderWriteThroughputSummaryDetail(workload, date, opsSec, rawData) {CODE
Decorative Section Separators1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUMinternal/rangekeystack/user_iterator.go45// ╭────────────────┴───────────────╮COMMENT
Example Usage Blocks1 hit · 2 pts
SeverityFileLineSnippetContext
LOWsstable/external_reader.go19// Example usage:COMMENT
Slop Phrases1 hit · 1 pts
SeverityFileLineSnippetContext
LOWinternal/lint/lint_test.go361 "Don't forget to add amend the result to the correct commits.",CODE