Repository Analysis

rust-windowing/winit

Window handling library in pure Rust

4.3 Likely human-written View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of rust-windowing/winit, a Rust project with 6,084 GitHub stars. SynthScan v2.0 examined 75,550 lines of code across 277 source files, recording 358 pattern matches distributed across 4 syntactic categories. The overall adjusted score of 4.3 places this repository in the Likely human-written 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).

4.3
Adjusted Score
4.3
Raw Score
100%
Time Factor
2026-07-29
Last Push
6.1K
Stars
Rust
Language
75.5K
Lines of Code
277
Files
358
Pattern Hits
2026-08-02
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

Longitudinal tracking requires multiple scan runs. Once this repository is re-scanned after new commits land, this chart will visualise how the synthetic code signal evolves over time — enabling you to detect whether AI authorship is growing, stabilising, or being actively corrected by human engineers.

No multi-scan history yet — run the scanner again to build trend data.

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 0HIGH 1MEDIUM 2LOW 355

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 358 distinct pattern matches across 4 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 Block354 hits · 311 pts
SeverityFileLineSnippetContext
LOWwinit-appkit/src/monitor.rs301/// the so-called "main" display, with y increasing downwards - which isCOMMENT
LOWwinit-appkit/src/lib.rs1//! # macOS / AppKitCOMMENT
LOWwinit-appkit/src/lib.rs21//! use objc2::rc::Retained;COMMENT
LOWwinit-appkit/src/lib.rs41//! println!("open urls: {application:?}, {urls:?}");COMMENT
LOWwinit-appkit/src/lib.rs101use self::window::Window as AppKitWindow;COMMENT
LOWwinit-appkit/src/lib.rs141 ///COMMENT
LOWwinit-appkit/src/lib.rs161 /// ```COMMENT
LOWwinit-appkit/src/lib.rs181 fn set_borderless_game(&self, borderless_game: bool);COMMENT
LOWwinit-appkit/src/lib.rs341 #[default]COMMENT
LOWwinit-appkit/src/lib.rs521 /// any relevant settings provided in the package manifest.COMMENT
LOWwinit-appkit/src/lib.rs541 /// # }COMMENT
LOWwinit-appkit/src/event.rs481 // Follows what Chromium and Firefox do:COMMENT
LOWwinit-appkit/src/window_delegate.rs301 ///COMMENT
LOWwinit-appkit/src/window_delegate.rs1701 }COMMENT
LOWwinit-appkit/src/window_delegate.rs1881 #[inline]COMMENT
LOWwinit-appkit/src/app.rs61///COMMENT
LOWwinit-appkit/src/view.rs561 self.queue_event(WindowEvent::KeyboardInput {COMMENT
LOWwinit-appkit/src/view.rs821 marked_text: Default::default(),COMMENT
LOWwinit-appkit/src/view.rs841 // specified along with [`ActiveAlways`]."COMMENT
LOWwinit-appkit/src/view.rs1021COMMENT
LOWwinit-win32/src/raw_input.rs221 unsafe { MapVirtualKeyW(keyboard.VKey as u32, MAPVK_VK_TO_VSC_EX) as u16 }COMMENT
LOWwinit-win32/src/raw_input.rs241 // that there's going to be another event coming, from which we can extract theCOMMENT
LOWwinit-win32/src/raw_input.rs281 // wasn't active. The way this is exposed to applications by the system is thatCOMMENT
LOWwinit-win32/src/keyboard_layout.rs181COMMENT
LOWwinit-win32/src/keyboard_layout.rs301 // but map to the numpad.COMMENT
LOWwinit-win32/src/lib.rs41pub use self::monitor::{MonitorHandle, VideoModeHandle};COMMENT
LOWwinit-win32/src/lib.rs61 ///COMMENT
LOWwinit-win32/src/lib.rs121 ///COMMENT
LOWwinit-win32/src/lib.rs161}COMMENT
LOWwinit-win32/src/lib.rs181 /// unspecified, although explicitly not undefined, behavior.COMMENT
LOWwinit-win32/src/lib.rs201 /// # if false { // We can't test this partCOMMENT
LOWwinit-win32/src/lib.rs221 /// let msg = msg as *const MSG;COMMENT
LOWwinit-win32/src/lib.rs241 ///COMMENT
LOWwinit-win32/src/lib.rs261 /// Shows or hides the background drop shadow for undecorated windows.COMMENT
LOWwinit-win32/src/lib.rs281 /// Sets the color of the window title.COMMENT
LOWwinit-win32/src/lib.rs301 ///COMMENT
LOWwinit-win32/src/lib.rs321 ///COMMENT
LOWwinit-win32/src/lib.rs441 /// This function wraps anything that implements `Borrow<Window>` into a structure thatCOMMENT
LOWwinit-win32/src/lib.rs501 }COMMENT
LOWwinit-win32/src/lib.rs521 /// [`WindowAttributes::with_parent_window`]: winit_core::window::WindowAttributes::with_parent_windowCOMMENT
LOWwinit-win32/src/lib.rs661 fn persistent_identifier(&self) -> Option<String> {COMMENT
LOWwinit-win32/src/lib.rs701 /// The valid `ordinal` values range from 1 to [`u16::MAX`] (inclusive). The value `0` is anCOMMENT
LOWwinit-win32/src/lib.rs721 /// icon size from the file.COMMENT
LOWwinit-win32/src/lib.rs741 /// [`from_resource`]: Self::from_resourceCOMMENT
LOWwinit-win32/src/keyboard.rs41}COMMENT
LOWwinit-win32/src/keyboard.rs321 ($vk:expr) => {COMMENT
LOWwinit-win32/src/event_loop.rs321 /// between the argument and a timeout from control flow.COMMENT
LOWwinit-win32/src/event_loop.rs341COMMENT
LOWwinit-win32/src/event_loop.rs621/// Windows will let us look up the current thread's id, but there's no API that lets us check whatCOMMENT
LOWwinit-win32/src/event_loop.rs701 TIMER_ALL_ACCESS,COMMENT
LOWwinit-win32/src/event_loop.rs921 // Store the new ID. Since `RegisterWindowMessageA` returns the same value for any givenCOMMENT
LOWwinit-win32/src/event_loop.rs1201 // Use `MonitorFromRect` instead of `MonitorFromWindow` to selectCOMMENT
LOWwinit-win32/src/event_loop.rs1241 state.set_window_flags_in_place(|f| f.remove(WindowFlags::MARKER_IN_SIZE_MOVE));COMMENT
LOWwinit-win32/src/event_loop/runner.rs461 }COMMENT
LOWwinit-win32/src/event_loop/runner.rs481 /// ^ |COMMENT
LOWdpi/src/lib.rs1//! # DPICOMMENT
LOWdpi/src/lib.rs21//! them to think about growing elderly, resulting in them having an existential crisis. Once usersCOMMENT
LOWdpi/src/lib.rs41//!COMMENT
LOWdpi/src/lib.rs61//! To use this library on a target without the standard library available, you should disableCOMMENT
LOWdpi/src/libm.rs1// Copyright (c) 2018 Jorge AparicioCOMMENT
294 more matches not shown…
AI Response Leakage1 hit · 8 pts
SeverityFileLineSnippetContext
HIGHwinit-appkit/src/window_delegate.rs306 /// will be failed. In this implementation, we will try again by usingCOMMENT
AI Slop Vocabulary2 hits · 6 pts
SeverityFileLineSnippetContext
MEDIUMwinit-core/src/window.rs552 /// the most robust way to track the DPI you need to use to draw.COMMENT
MEDIUMwinit-wayland/src/types/wp_tablet_input_v2.rs286 // NOTE: even though we don't utilize serialsCOMMENT
Structural Annotation Overuse1 hit · 2 pts
SeverityFileLineSnippetContext
LOWwinit-appkit/src/app.rs69/// NOTE: This function assumes that the passed in application object is the one returned fromCOMMENT