Repository Analysis

gfx-rs/wgpu

A cross-platform, safe, pure-Rust graphics API.

5.4 Low AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of gfx-rs/wgpu, a Rust project with 17,575 GitHub stars. SynthScan v2.0 examined 385,119 lines of code across 1108 source files, recording 2090 pattern matches distributed across 8 syntactic categories. The overall adjusted score of 5.4 places this repository in the Low AI signal band.

The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).

5.4
Adjusted Score
5.4
Raw Score
100%
Time Factor
2026-07-13
Last Push
17.6K
Stars
Rust
Language
385.1K
Lines of Code
1.1K
Files
2.1K
Pattern Hits
2026-07-14
Scan Date
0.00
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.

Severity Breakdown

Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.

CRITICAL 4HIGH 0MEDIUM 22LOW 2064

Directory Score Breakdown

This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.

Pattern Findings

The scanner identified 2090 distinct pattern matches across 8 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. 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 diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.

Over-Commented Block2042 hits · 1926 pts
SeverityFileLineSnippetContext
LOWwgpu-hal/Cargo.toml41 'cfg(windows_angle)',COMMENT
LOWwgpu-hal/Cargo.toml61# to these features, it enables features of platform specific crates. For example, the `vulkan` feature in wgpu-coreCOMMENT
LOWwgpu-hal/src/lib.rs1//! A cross-platform unsafe graphics abstraction.COMMENT
LOWwgpu-hal/src/lib.rs21//! graphics system. If you need safety, the [`wgpu-core`] crate provides aCOMMENT
LOWwgpu-hal/src/lib.rs41//! unlike `wgpu-core`, which refers to objects by ID.COMMENT
LOWwgpu-hal/src/lib.rs61//! do any mutating work.COMMENT
LOWwgpu-hal/src/lib.rs81//! Vulkan bindings. It's also available on macOS, if you install [MoltenVK].COMMENT
LOWwgpu-hal/src/lib.rs101//!COMMENT
LOWwgpu-hal/src/lib.rs121//! available on the system. For example, [`vulkan::Api::Instance::init`][Ii]COMMENT
LOWwgpu-hal/src/lib.rs141//! - [`Api::Surface`] implements the [`Surface`] trait, which represents aCOMMENT
LOWwgpu-hal/src/lib.rs161//! applications, like web browsers, where the API is available to untrustedCOMMENT
LOWwgpu-hal/src/lib.rs181//! A desire for "defense in depth" may suggest performing additional validationCOMMENT
LOWwgpu-hal/src/lib.rs201//! functionality, which is only available in `wgpu-core`.COMMENT
LOWwgpu-hal/src/lib.rs241extern crate alloc;COMMENT
LOWwgpu-hal/src/lib.rs541 #[error("Other reason: {0}")]COMMENT
LOWwgpu-hal/src/lib.rs621 type QuerySet: DynQuerySet;COMMENT
LOWwgpu-hal/src/lib.rs681 /// - All [`AcquiredSurfaceTexture`]s must have been destroyed.COMMENT
LOWwgpu-hal/src/lib.rs701 ///COMMENT
LOWwgpu-hal/src/lib.rs721 /// by passing the [`SurfaceTexture`] and `self` to [`Queue::present`].COMMENT
LOWwgpu-hal/src/lib.rs741 ///COMMENT
LOWwgpu-hal/src/lib.rs761COMMENT
LOWwgpu-hal/src/lib.rs821 /// Creates a [`PresentationTimestamp`] using the adapter's WSI.COMMENT
LOWwgpu-hal/src/lib.rs841/// used for creating resources. Each `Device` has an associated [`Queue`] usedCOMMENT
LOWwgpu-hal/src/lib.rs861/// [`Device::create_texture`] or [`Device::create_shader_module`].COMMENT
LOWwgpu-hal/src/lib.rs881/// [`vulkan::Adapter::device_from_raw`]: vulkan/struct.Adapter.html#method.device_from_rawCOMMENT
LOWwgpu-hal/src/lib.rs901pub trait Device: WasmNotSendSync {COMMENT
LOWwgpu-hal/src/lib.rs921 unsafe fn destroy_buffer(&self, buffer: <Self::A as Api>::Buffer);COMMENT
LOWwgpu-hal/src/lib.rs941 ///COMMENT
LOWwgpu-hal/src/lib.rs961 /// covering that byte that occurs between those two accesses.COMMENT
LOWwgpu-hal/src/lib.rs981 ///COMMENT
LOWwgpu-hal/src/lib.rs1141 /// operation you have already presented to the device is going to store inCOMMENT
LOWwgpu-hal/src/lib.rs1161 timeout: Option<core::time::Duration>,COMMENT
LOWwgpu-hal/src/lib.rs1221 ///COMMENT
LOWwgpu-hal/src/lib.rs1241 /// not synchronized to occur in a particular order, they must pass distinctCOMMENT
LOWwgpu-hal/src/lib.rs1261 /// ([`Texture`][t]s, [`BindGroup`][bg]s, [`RenderPipeline`][rp]s, and soCOMMENT
LOWwgpu-hal/src/lib.rs1281 /// [cb]: Api::CommandBufferCOMMENT
LOWwgpu-hal/src/lib.rs1301 /// [`Surface::acquire_texture`] and not yet presented or discarded.COMMENT
LOWwgpu-hal/src/lib.rs1321 surface: &<Self::A as Api>::Surface,COMMENT
LOWwgpu-hal/src/lib.rs1341/// `CommandEncoder` that created them.COMMENT
LOWwgpu-hal/src/lib.rs1361/// - Call `discard_encoding` on a recording `CommandEncoder` to dropCOMMENT
LOWwgpu-hal/src/lib.rs1381/// It is the user's responsibility to meet this requirements. ThisCOMMENT
LOWwgpu-hal/src/lib.rs1401 /// This puts this `CommandEncoder` in the "closed" state.COMMENT
LOWwgpu-hal/src/lib.rs1421 ///COMMENT
LOWwgpu-hal/src/lib.rs1521 src: &<Self::A as Api>::AccelerationStructure,COMMENT
LOWwgpu-hal/src/lib.rs1541 ///COMMENT
LOWwgpu-hal/src/lib.rs1601 &mut self,COMMENT
LOWwgpu-hal/src/lib.rs1621 ///COMMENT
LOWwgpu-hal/src/lib.rs1741 ///COMMENT
LOWwgpu-hal/src/lib.rs1761 /// [`end_render_pass`]: CommandEncoder::end_render_passCOMMENT
LOWwgpu-hal/src/lib.rs1781COMMENT
LOWwgpu-hal/src/lib.rs1801 /// by a call to [`end_render_pass`].COMMENT
LOWwgpu-hal/src/lib.rs2061 /// region][ar] of a [`Uniform`] buffer, the size of the accessible regionCOMMENT
LOWwgpu-hal/src/lib.rs2121#[derive(Debug, Clone)]COMMENT
LOWwgpu-hal/src/lib.rs2141COMMENT
LOWwgpu-hal/src/lib.rs2281 pub bind_group_layouts: &'a [Option<&'a B>],COMMENT
LOWwgpu-hal/src/lib.rs2301///COMMENT
LOWwgpu-hal/src/lib.rs2321///COMMENT
LOWwgpu-hal/src/lib.rs2341#[derive(Debug)]COMMENT
LOWwgpu-hal/src/lib.rs2401}COMMENT
LOWwgpu-hal/src/lib.rs2721}COMMENT
1982 more matches not shown…
Decorative Section Separators15 hits · 53 pts
SeverityFileLineSnippetContext
MEDIUMnaga/src/front/wgsl/parse/lexer.rs1226 /// D(𝐡) = ───────────────────────────────────────────────────COMMENT
MEDIUMnaga/src/front/wgsl/parse/lexer.rs1231 Token::DocComment("/// D(𝐡) = ───────────────────────────────────────────────────"),CODE
MEDIUMwgpu/Cargo.toml49# --------------------------------------------------------------------COMMENT
MEDIUMwgpu/Cargo.toml109# --------------------------------------------------------------------COMMENT
MEDIUMwgpu/Cargo.toml126# --------------------------------------------------------------------COMMENT
MEDIUMwgpu/Cargo.toml138# --------------------------------------------------------------------COMMENT
MEDIUMwgpu/Cargo.toml152# --------------------------------------------------------------------COMMENT
MEDIUMwgpu-core/Cargo.toml47# --------------------------------------------------------------------COMMENT
MEDIUMwgpu-core/Cargo.toml57# --------------------------------------------------------------------COMMENT
MEDIUMwgpu-core/Cargo.toml64# --------------------------------------------------------------------COMMENT
MEDIUMwgpu-core/Cargo.toml70# --------------------------------------------------------------------COMMENT
MEDIUMwgpu-core/Cargo.toml89# --------------------------------------------------------------------COMMENT
MEDIUMwgpu-core/Cargo.toml101# --------------------------------------------------------------------COMMENT
MEDIUMwgpu-core/Cargo.toml118# --------------------------------------------------------------------COMMENT
MEDIUMwgpu-core/Cargo.toml128# --------------------------------------------------------------------COMMENT
Hallucination Indicators4 hits · 40 pts
SeverityFileLineSnippetContext
CRITICALwgpu-hal/src/metal/command.rs1341 while self.state.stage_infos.ms.work_group_memory_sizes.len()CODE
CRITICALwgpu-hal/src/metal/command.rs1344 self.state.stage_infos.ms.work_group_memory_sizes.push(0);CODE
CRITICALwgpu-core/src/command/render.rs3364 if state.pass.base.device.indirect_validation.is_some()CODE
CRITICALwgpu-core/src/command/render.rs3620 let bundle = state.pass.base.tracker.bundles.insert_single(bundle);CODE
Structural Annotation Overuse15 hits · 26 pts
SeverityFileLineSnippetContext
LOWwgpu-hal/src/dx12/device_creation.rs72 // Step 1: Get ID3D12SDKConfiguration1 via D3D12GetInterfaceCOMMENT
LOWwgpu-hal/src/dx12/device_creation.rs77 // Step 2: Create device factory with the specified SDK version and pathCOMMENT
LOW.claude/skills/cts-triage/SKILL.md10## Step 0: Divide Into Manageable ChunksCOMMENT
LOW.claude/skills/cts-triage/SKILL.md24## Step 1: Get Overall StatisticsCOMMENT
LOW.claude/skills/cts-triage/SKILL.md34## Step 2: Identify Test SubcategoriesCOMMENT
LOW.claude/skills/cts-triage/SKILL.md42## Step 3: Run Each SubcategoryCOMMENT
LOW.claude/skills/cts-triage/SKILL.md56## Step 4: Analyze Failure PatternsCOMMENT
LOW.claude/skills/cts-triage/SKILL.md69## Step 5: Examine Specific FailuresCOMMENT
LOW.claude/skills/cts-triage/SKILL.md84## Step 6: Check CTS Test SourceCOMMENT
LOW.claude/skills/cts-triage/SKILL.md99## Step 7: Categorize IssuesCOMMENT
LOW.claude/skills/cts-triage/SKILL.md126## Step 8: Identify Root CausesCOMMENT
LOW.claude/skills/cts-triage/SKILL.md152## Step 9: Implement FixesCOMMENT
LOW.claude/skills/cts-triage/SKILL.md163## Step 10: Document FindingsCOMMENT
LOW.claude/skills/cts-triage/SKILL.md217## Step 11: Update test.lstCOMMENT
LOW.claude/skills/cts-triage/SKILL.md233## Step 12: Verify and BuildCOMMENT
AI Slop Vocabulary7 hits · 22 pts
SeverityFileLineSnippetContext
MEDIUMwgpu-hal/Cargo.toml51# The interaction of features between wgpu-core and wgpu-hal is a bit nuanced to getCOMMENT
MEDIUMwgpu-hal/src/auxil/dyn_lib.rs25 _ => crate::DeviceError::Unexpected, // could be unreachable!() but we prefer to be more robustCODE
MEDIUMnaga/src/proc/index.rs79 /// Some graphics hardware provides "robust buffer access", a feature thatCOMMENT
MEDIUMnaga/src/proc/overloads/mod.rs165 /// Essentially, if any one of the arguments is not a constant expression,COMMENT
MEDIUMwgpu/Cargo.toml139#! The following features facilitate integration with third-party supporting libraries.COMMENT
MEDIUMwgpu-core/Cargo.toml119#! The following features facilitate integration with third-party supporting libraries.COMMENT
MEDIUMwgpu-core/src/pipeline_cache.rs169 /// We assume that your cache storage system will be relatively robust, and soCOMMENT
Verbosity Indicators3 hits · 6 pts
SeverityFileLineSnippetContext
LOWwgpu-hal/src/dx12/device_creation.rs72 // Step 1: Get ID3D12SDKConfiguration1 via D3D12GetInterfaceCOMMENT
LOWwgpu-hal/src/dx12/device_creation.rs77 // Step 2: Create device factory with the specified SDK version and pathCOMMENT
LOWwgpu-hal/src/vulkan/sampler.rs122 // We need to check if we can create more samplers.COMMENT
Example Usage Blocks2 hits · 3 pts
SeverityFileLineSnippetContext
LOWnaga/src/proc/constant_evaluator.rs453/// Example usage:COMMENT
LOWnaga/src/front/glsl/mod.rs143/// # Example usageCOMMENT
Hyper-Verbose Identifiers2 hits · 2 pts
SeverityFileLineSnippetContext
LOWcts_runner/src/bootstrap.js295 function DOMExceptionOperationError(msg) {CODE
LOWcts_runner/src/bootstrap.js307 function DOMExceptionInvalidCharacterError(msg) {CODE