egui: an easy-to-use immediate mode GUI in Rust that runs on both web and native
This report presents the forensic synthetic code analysis of emilk/egui, a Rust project with 30,211 GitHub stars. SynthScan v2.0 examined 136,178 lines of code across 545 source files, recording 743 pattern matches distributed across 9 syntactic categories. The overall adjusted score of 5.8 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).
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.
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.
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.
The scanner identified 743 distinct pattern matches across 9 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.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | lychee.toml | 1 | ################################################################################ | COMMENT |
| LOW | deny.toml | 1 | # Copied from https://github.com/rerun-io/rerun_template | COMMENT |
| LOW | clippy.toml | 21 | COMMENT | |
| LOW | crates/eframe/Cargo.toml | 41 | COMMENT | |
| LOW | crates/eframe/Cargo.toml | 81 | ] | COMMENT |
| LOW | crates/eframe/src/lib.rs | 1 | //! eframe - the [`egui`] framework crate | COMMENT |
| LOW | crates/eframe/src/lib.rs | 21 | //! If your app is only for native, and you don't need advanced features like state persistence, | COMMENT |
| LOW | crates/eframe/src/lib.rs | 41 | //! // for e.g. egui::PaintCallback. | COMMENT |
| LOW | crates/eframe/src/lib.rs | 61 | //! # #[cfg(target_arch = "wasm32")] | COMMENT |
| LOW | crates/eframe/src/lib.rs | 81 | //! } | COMMENT |
| LOW | crates/eframe/src/lib.rs | 101 | //! } | COMMENT |
| LOW | crates/eframe/src/lib.rs | 121 | //! | COMMENT |
| LOW | crates/eframe/src/lib.rs | 241 | /// This is how you start a native (desktop) app. | COMMENT |
| LOW | crates/eframe/src/lib.rs | 261 | /// #[derive(Default)] | COMMENT |
| LOW | crates/eframe/src/lib.rs | 281 | /// ``` | COMMENT |
| LOW | crates/eframe/src/lib.rs | 321 | #[cfg(feature = "wgpu_no_default_features")] | COMMENT |
| LOW | crates/eframe/src/lib.rs | 341 | /// eventloop.set_control_flow(ControlFlow::Poll); | COMMENT |
| LOW | crates/eframe/src/lib.rs | 361 | /// } | COMMENT |
| LOW | crates/eframe/src/lib.rs | 441 | /// The simplest way to get started when writing a native app. | COMMENT |
| LOW | crates/eframe/src/lib.rs | 461 | /// ui.text_edit_singleline(&mut name) | COMMENT |
| LOW | crates/eframe/src/icon_data.rs | 1 | //! Helpers for loading [`egui::IconData`]. | COMMENT |
| LOW | crates/eframe/src/epi.rs | 21 | #[cfg(not(target_arch = "wasm32"))] | COMMENT |
| LOW | crates/eframe/src/epi.rs | 61 | pub integration_info: IntegrationInfo, | COMMENT |
| LOW | crates/eframe/src/epi.rs | 81 | /// | COMMENT |
| LOW | crates/eframe/src/epi.rs | 141 | /// | COMMENT |
| LOW | crates/eframe/src/epi.rs | 161 | /// [`egui::InputState::viewport`], but the rest of [`egui::Context::input`] | COMMENT |
| LOW | crates/eframe/src/epi.rs | 181 | /// (A "viewport" in egui means an native OS window). | COMMENT |
| LOW | crates/eframe/src/epi.rs | 201 | None | COMMENT |
| LOW | crates/eframe/src/epi.rs | 221 | #[cfg(feature = "glow")] | COMMENT |
| LOW | crates/eframe/src/epi.rs | 241 | /// | COMMENT |
| LOW | crates/eframe/src/epi.rs | 261 | } | COMMENT |
| LOW | crates/eframe/src/epi.rs | 281 | COMMENT | |
| LOW | crates/eframe/src/epi.rs | 301 | /// If you don't set an icon, a default egui icon will be used. | COMMENT |
| LOW | crates/eframe/src/epi.rs | 321 | /// Sets the number of bits in the stencil buffer. | COMMENT |
| LOW | crates/eframe/src/epi.rs | 341 | /// When `false`, [`winit::event_loop::EventLoop::run`] is used. | COMMENT |
| LOW | crates/eframe/src/epi.rs | 361 | COMMENT | |
| LOW | crates/eframe/src/epi.rs | 381 | /// The folder where `eframe` will store the app state. If not set, eframe will use a default | COMMENT |
| LOW | crates/eframe/src/epi.rs | 481 | #[cfg(any(feature = "glow", feature = "wgpu_no_default_features"))] | COMMENT |
| LOW | crates/eframe/src/epi.rs | 501 | #[cfg(feature = "wgpu_no_default_features")] | COMMENT |
| LOW | crates/eframe/src/epi.rs | 581 | /// What rendering backend to use. | COMMENT |
| LOW | crates/eframe/src/epi.rs | 761 | COMMENT | |
| LOW | crates/eframe/src/epi.rs | 781 | /// and run eframe using [`Renderer::Glow`]. | COMMENT |
| LOW | crates/eframe/src/epi.rs | 841 | /// Information about the URL. | COMMENT |
| LOW | crates/eframe/src/epi.rs | 861 | COMMENT | |
| LOW | crates/eframe/src/epi.rs | 881 | /// | COMMENT |
| LOW | crates/eframe/src/native/app_icon.rs | 41 | /// We did not set it or failed to do it. In any case we won't try again. | COMMENT |
| LOW | crates/eframe/src/native/winit_integration.rs | 141 | /// so that multiple input events can be handled in one frame. Does not | COMMENT |
| LOW | crates/eframe/src/native/winit_integration.rs | 181 | // Because we can't provide the initial tree synchronously | COMMENT |
| LOW | crates/eframe/src/native/macos.rs | 1 | use egui::Vec2; | COMMENT |
| LOW | crates/eframe/src/native/run.rs | 201 | // On Windows, invisible windows don't receive RedrawRequested | COMMENT |
| LOW | crates/eframe/src/native/wgpu_integration.rs | 901 | // event handler. If this is not done, the compositor will assume that the window does not want | COMMENT |
| LOW | crates/eframe/src/native/glow_integration.rs | 81 | } | COMMENT |
| LOW | crates/eframe/src/native/glow_integration.rs | 881 | &mut self, | COMMENT |
| LOW | crates/eframe/src/web/web_painter.rs | 1 | use egui::{Event, UserData}; | COMMENT |
| LOW | crates/eframe/src/web/web_logger.rs | 81 | COMMENT | |
| LOW | crates/eframe/src/web/web_logger.rs | 101 | COMMENT | |
| LOW | crates/eframe/src/web/text_agent.rs | 201 | /// completions (e.g., `tex|` -> `Texas`) to work correctly. In these | COMMENT |
| LOW | crates/eframe/src/web/web_painter_glow.rs | 181 | COMMENT | |
| LOW | crates/egui_glow/src/painter.rs | 101 | /// Stores outdated OpenGL textures that are yet to be deleted | COMMENT |
| LOW | crates/egui_glow/src/painter.rs | 121 | impl CallbackFn { | COMMENT |
| 637 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | clippy.toml | 3 | # ----------------------------------------------------------------------------- | COMMENT |
| MEDIUM | clippy.toml | 22 | # ----------------------------------------------------------------------------- | COMMENT |
| MEDIUM | clippy.toml | 60 | # ----------------------------------------------------------------------------- | COMMENT |
| MEDIUM | crates/eframe/Cargo.toml | 155 | # ------------------------------------------- | COMMENT |
| MEDIUM | crates/eframe/Cargo.toml | 210 | # ------------------------------------------- | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 10 | /// ┌───────────┐ ┌────────┐ ┌─────────┐ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 12 | /// └───────────┘ └────────┘ └─────────┘ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 13 | /// ┌──────────┐ ┌────────────────────────────────────┐ ┌───────────┐ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 15 | /// └──────────┘ │ │ └───────────┘ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 16 | /// ┌──────────┐ │ │ ┌───────────┐ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 18 | /// └──────────┘ │ │ └───────────┘ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 19 | /// ┌──────────┐ │ │ ┌───────────┐ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 21 | /// └──────────┘ └────────────────────────────────────┘ └───────────┘ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 22 | /// ┌────────────┐ ┌──────┐ ┌──────────┐ | COMMENT |
| MEDIUM⚡ | crates/emath/src/rect_align.rs | 24 | /// └────────────┘ └──────┘ └──────────┘ | COMMENT |
| MEDIUM | scripts/check.sh | 81 | # ------------------------------------------------------------ | COMMENT |
| MEDIUM | scripts/clippy_wasm/clippy.toml | 6 | # ----------------------------------------------------------------------------- | COMMENT |
| MEDIUM | scripts/clippy_wasm/clippy.toml | 25 | # ----------------------------------------------------------------------------- | COMMENT |
| MEDIUM | .github/workflows/rust.yml | 67 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | .github/workflows/rust.yml | 124 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | .github/workflows/rust.yml | 156 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | .github/workflows/rust.yml | 178 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | .github/workflows/rust.yml | 199 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | .github/workflows/rust.yml | 218 | # --------------------------------------------------------------------------- | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | crates/eframe/src/native/glow_integration.rs | 1091 | // Create GL display. This may probably create a window too on most platforms. Definitely on `MS windows`. Never | COMMENT |
| MEDIUM | crates/egui_kittest/src/lib.rs | 789 | /// See also: <https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-harness-field> | COMMENT |
| MEDIUM | crates/egui_kittest/src/lib.rs | 823 | See: https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-harness-field" | CODE |
| MEDIUM | crates/egui_kittest/src/snapshot.rs | 851 | /// # let harness = MockHarness; | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | crates/egui_demo_lib/src/lib.rs | 59 | pub const LOREM_IPSUM: &str = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt | CODE |
| LOW⚡ | crates/egui_demo_lib/src/lib.rs | 59 | pub const LOREM_IPSUM: &str = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt | CODE |
| LOW⚡ | crates/egui_demo_lib/src/lib.rs | 61 | pub const LOREM_IPSUM_LONG: &str = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incid | CODE |
| LOW⚡ | crates/egui_demo_lib/src/lib.rs | 61 | pub const LOREM_IPSUM_LONG: &str = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incid | CODE |
| LOW | crates/egui_demo_lib/src/demo/text_layout.rs | 132 | ui.selectable_value(lorem_ipsum, true, "Lorem Ipsum"); | CODE |
| LOW | crates/egui_demo_lib/src/demo/modals.rs | 21 | name: "John Doe".to_owned(), | CODE |
| LOW | examples/custom_font_style/src/main.rs | 73 | pub const LOREM_IPSUM: &str = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt | CODE |
| LOW | examples/custom_font_style/src/main.rs | 73 | pub const LOREM_IPSUM: &str = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | scripts/accept_snapshots.sh | 3 | # Its main use is in the update_kittest_snapshots CI job, but you can also use it locally. | COMMENT |
| MEDIUM | scripts/build_demo_web.sh | 99 | # if this fails with "error: cannot import from modules (`env`) with `--no-modules`", you can use: | COMMENT |
| LOW | .vscode/settings.json | 24 | // Don't forget to put it in a comment again before committing. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | scripts/generate_changelog.py | 136 | CODE | |
| LOW | scripts/generate_changelog.py | 244 | CODE | |
| LOW | scripts/lint.py | 153 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | .github/workflows/enforce_branch_name.yml | 20 | # Check if PR is from a fork | COMMENT |
| LOW | .github/workflows/enforce_branch_name.yml | 22 | # Check if PR is from the master/main branch of a fork | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | crates/egui_kittest/src/snapshot.rs | 61 | /// Example usage: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | scripts/generate_changelog.py | 49 | def fetch_pr_info_from_commit_info(commit_info: CommitInfo) -> Optional[PrInfo]: | CODE |