AI Slop Code RIsk Monitor

ratatui/ratatui

A Rust crate for cooking up terminal user interfaces (TUIs) 👨‍🍳🐀 https://ratatui.rs

16.1 Elevated pattern signal View on GitHub

Maintenance and Governance Review

This report summarizes scanner evidence for ratatui/ratatui, a Rust project with 22,931 GitHub stars. SynthScan examined 104,551 lines of code across 374 source files, recording 1275 pattern matches distributed across 9 syntactic categories. The legacy adjusted pattern signal is 16.1 (Elevated 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.

16.1
Adjusted Signal
16.1
Raw Pattern Score
100%
Time Factor
2026-10-10
Last Push
22.9K
Stars
Rust
Language
104.6K
Lines of Code
374
Files
1.3K
Pattern Hits
2026-10-12
Scan Date
0.01
HC Hit Rate

Risk Review · v3

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

Cognitive Ownership Risk 37.7/100 · MEDIUM

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

Hallucinated Dependency & Supply Chain Risk 0.3/100 · LOW

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

Agent Over-Engineering Ratio 28.1/100 · MEDIUM

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

PR Review Velocity Impact 55.4/100 · HIGH

Which changes need focused human review? 1275 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 4MEDIUM 197LOW 1074

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 1275 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 Block1064 hits · 936 pts
SeverityFileLineSnippetContext
LOWratatui-termion/src/lib.rs1// show the feature flags in the generated documentationCOMMENT
LOWratatui-termion/src/lib.rs21//! This crate provides the [Termion] backend implementation for Ratatui.COMMENT
LOWratatui-termion/src/lib.rs61/// This is done by calling [`IntoRawMode::into_raw_mode()`] andCOMMENT
LOWratatui-termion/src/lib.rs81/// let writer = stderr().into_raw_mode()?.into_alternate_screen()?;COMMENT
LOWratatui-termion/src/lib.rs101 writer: W,COMMENT
LOWratatui/Cargo.toml21COMMENT
LOWratatui/Cargo.toml101]COMMENT
LOWratatui/tests/state_serde.rs1//! State like [`ListState`], [`TableState`] and [`ScrollbarState`] can be serialized andCOMMENT
LOWratatui/src/lib.rs1#![no_std]COMMENT
LOWratatui/src/lib.rs21//! </div>COMMENT
LOWratatui/src/lib.rs41//! fn main() -> std::io::Result<()> {COMMENT
LOWratatui/src/lib.rs61//! Most application authors should start with one of these entry points:COMMENT
LOWratatui/src/lib.rs81//!COMMENT
LOWratatui/src/lib.rs101//! - [Breaking Changes] - a list of breaking changes in the library.COMMENT
LOWratatui/src/lib.rs121//! - **Backend crates**: [`ratatui-crossterm`], [`ratatui-termion`], [`ratatui-termina`],COMMENT
LOWratatui/src/lib.rs141//! Ratatui uses [Crossterm] by default as it works on most platforms. See the [Installation]COMMENT
LOWratatui/src/lib.rs161//! loop {COMMENT
LOWratatui/src/lib.rs181//!COMMENT
LOWratatui/src/lib.rs201//!COMMENT
LOWratatui/src/lib.rs221//! method takes a closure that is called with a [`Frame`] instance. The [`Frame`] provides the sizeCOMMENT
LOWratatui/src/lib.rs241//! }COMMENT
LOWratatui/src/lib.rs261//! most applications, return the error and let the surrounding setup path restore terminal stateCOMMENT
LOWratatui/src/lib.rs281//! match event::read()? {COMMENT
LOWratatui/src/lib.rs301//!COMMENT
LOWratatui/src/lib.rs321//! frame.render_widget(Block::bordered().title("Right"), right_area);COMMENT
LOWratatui/src/lib.rs341//! The [`style` module] provides types that represent the various styling options. The mostCOMMENT
LOWratatui/src/lib.rs361//! Style::new()COMMENT
LOWratatui/src/lib.rs381//! }COMMENT
LOWratatui/src/lib.rs401//! [Widgets]: https://ratatui.rs/recipes/widgets/COMMENT
LOWratatui/src/lib.rs421//! [`render_widget`]: Frame::render_widgetCOMMENT
LOWratatui/src/lib.rs441//! [`ratatui-widgets`]: https://crates.io/crates/ratatui-widgetsCOMMENT
LOWratatui/src/lib.rs461//! [Matrix]: https://matrix.to/#/#ratatui:matrix.orgCOMMENT
LOWratatui/src/lib.rs481COMMENT
LOWratatui/src/init.rs1//! Terminal initialization and restoration functions.COMMENT
LOWratatui/src/init.rs21//!COMMENT
LOWratatui/src/init.rs41//! ## TypesCOMMENT
LOWratatui/src/init.rs61//! - [`try_init_with_options`] - Same as [`init_with_options`] but returns a `Result` instead ofCOMMENT
LOWratatui/src/init.rs81//! }COMMENT
LOWratatui/src/init.rs101//! if key.kind == KeyEventKind::Press && key.code == KeyCode::Char('q') =>COMMENT
LOWratatui/src/init.rs121//! let mut terminal = ratatui::try_init()?;COMMENT
LOWratatui/src/init.rs141//! terminal.insert_before(1, |buf| {COMMENT
LOWratatui/src/init.rs161//! // Using try_init_with_options() - returns Result for custom error handlingCOMMENT
LOWratatui/src/init.rs181//! UI](`crate#drawing-the-ui`) and [handle events](`crate#handling-events`). See the [main crateCOMMENT
LOWratatui/src/init.rs221///COMMENT
LOWratatui/src/init.rs241/// ratatui::run(|terminal| {COMMENT
LOWratatui/src/init.rs261/// }COMMENT
LOWratatui/src/init.rs281/// type Result<T> = std::result::Result<T, Box<dyn std::error::Error>>;COMMENT
LOWratatui/src/init.rs301/// fn run(&mut self, terminal: &mut ratatui::DefaultTerminal) -> Result<()> {COMMENT
LOWratatui/src/init.rs321/// }COMMENT
LOWratatui/src/init.rs341/// `run(f)`: despite using the default fullscreen viewport, it does not enter the alternate screenCOMMENT
LOWratatui/src/init.rs361/// viewport: Viewport::Inline(8),COMMENT
LOWratatui/src/init.rs401/// - Raw mode is enabledCOMMENT
LOWratatui/src/init.rs421///COMMENT
LOWratatui/src/init.rs441///COMMENT
LOWratatui/src/init.rs461/// ```no_runCOMMENT
LOWratatui/src/init.rs481/// - Raw mode is enabledCOMMENT
LOWratatui/src/init.rs501///COMMENT
LOWratatui/src/init.rs521/// Try to initialize a terminal with the given options and reasonable defaults.COMMENT
LOWratatui/src/init.rs541/// Generally, you should use [`init_with_options`] instead of this function, as the panic hookCOMMENT
LOWratatui/src/init.rs561 set_panic_hook();COMMENT
1004 more matches not shown…
Decorative Section Separators190 hits · 690 pts
SeverityFileLineSnippetContext
MEDIUM⚡ratatui/src/lib.rs328//! Title Bar───────────────────────────────────COMMENT
MEDIUM⚡ratatui/src/lib.rs329//! ┌Left────────────────┐┌Right───────────────┐COMMENT
MEDIUM⚡ratatui/src/lib.rs331//! └────────────────────┘└────────────────────┘COMMENT
MEDIUM⚡ratatui/src/lib.rs332//! Status Bar──────────────────────────────────COMMENT
MEDIUMexamples/apps/constraint-explorer/src/main.rs62/// ┌──────────────┐COMMENT
MEDIUMexamples/apps/constraint-explorer/src/main.rs65/// └──────────────┘COMMENT
MEDIUMratatui-core/src/layout.rs25//! ┌─────────────→COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs835 // <───────────────────────────────────area_size──────────────────────────────────>COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs838 // ┌────┬───────────────────┬────┬─────variables─────┬────┬───────────────────┬────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs841 // ┌ ┐┌──────────────────┐┌ ┐┌──────────────────┐┌ ┐┌──────────────────┐┌ ┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs843 // └ ┘└──────────────────┘└ ┘└──────────────────┘└ ┘└──────────────────┘└ ┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs846 // └─┬──┶━━━━━━━━━┳━━━━━━━━━┵─┬──┶━━━━━━━━━┳━━━━━━━━━┵─┬──┶━━━━━━━━━┳━━━━━━━━━┵─┬──┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs848 // └────────────╂───────────┴────────────╂───────────┴────────────╂──Spacers──┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs850 // ┗━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━Segments━━━━━━━━┛COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs933 // ┌────┬───────────────────┬────┬─────variables─────┬────┬───────────────────┬────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs936 // ┌ ┐┌──────────────────┐┌ ┐┌──────────────────┐┌ ┐┌──────────────────┐┌ ┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs938 // └ ┘└──────────────────┘└ ┘└──────────────────┘└ ┘└──────────────────┘└ ┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1113/// ┌──────┐┌──────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1115/// └──────┘└──────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1118/// ┌──────┐┌────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1120/// └──────┘└────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1303 /// ┌────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1305 /// └────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1310 /// ┌────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1312 /// └────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1317 /// ┌───────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1319 /// └───────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1324 /// ┌───────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1326 /// └───────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1331 /// ┌────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1333 /// └────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1338 /// ┌────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1340 /// └────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1345 /// ┌────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1347 /// └────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1352 /// ┌─────────────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1354 /// └─────────────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1359 /// ┌────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/layout.rs1361 /// └────────────┘COMMENT
MEDIUMratatui-core/src/layout/layout.rs30// ┌ ┐┌──────────────────┐┌ ┐┌──────────────────┐┌ ┐┌──────────────────┐┌ ┐COMMENT
MEDIUMratatui-core/src/layout/layout.rs32// └ ┘└──────────────────┘└ ┘└──────────────────┘└ ┘└──────────────────┘└ ┘COMMENT
MEDIUMratatui-core/src/layout/layout.rs1373 /// ┌───────┐COMMENT
MEDIUMratatui-core/src/layout/layout.rs1375 /// └───────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs87 /// ┌────────────────────────────┐┌──────────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs89 /// └────────────────────────────┘└──────────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs95 /// ┌──────────────────────────────────────┐┌────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs97 /// └──────────────────────────────────────┘└────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs110 /// ┌────────────────────────────┐┌──────────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs112 /// └────────────────────────────┘└──────────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs118 /// ┌──────────────────────────────────────┐┌────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs120 /// └──────────────────────────────────────┘└────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs133 /// ┌──────────────────┐┌──────────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs135 /// └──────────────────┘└──────────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs141 /// ┌──────────────────┐┌────────────────────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs143 /// └──────────────────┘└────────────────────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs161 /// ┌────────────────────────────────────┐┌──────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs163 /// └────────────────────────────────────┘└──────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs169 /// ┌───────────────────────┐┌───────────────────────┐COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs171 /// └───────────────────────┘└───────────────────────┘COMMENT
MEDIUM⚡ratatui-core/src/layout/constraint.rs185 /// ┌───────────────────────┐┌───────────────────────┐COMMENT
130 more matches not shown…
AI Response Leakage3 hits · 22 pts
SeverityFileLineSnippetContext
HIGHratatui-core/src/text/line.rs833/// In this implementation, the `to_line` method panics if the `Display` implementation returns anCOMMENT
HIGHratatui-core/src/text/span.rs492/// In this implementation, the `to_span` method panics if the `Display` implementation returns anCOMMENT
HIGHratatui-core/src/text/text.rs744/// In this implementation, the `to_text` method panics if the `Display` implementation returns anCOMMENT
AI Slop Vocabulary5 hits · 15 pts
SeverityFileLineSnippetContext
MEDIUM…mples/concepts/state/src/bin/nested-stateful-widget.rs5//! and want to leverage the benefits of the `StatefulWidget` pattern at multiple levels.COMMENT
MEDIUM.github/workflows/ci.yml25# without having to wait for the comprehensive matrix of tests to complete.COMMENT
MEDIUMratatui-core/src/backend.rs71//! This creates a seamless transition between the application and the regular terminal session, asCOMMENT
MEDIUMratatui-widgets/src/clear.rs27/// For a more complete example how to utilize `Clear` to realize popups seeCOMMENT
MEDIUMratatui-widgets/src/block.rs205/// - [Collapse borders recipe] - Techniques for creating seamless layouts (on the ratatui website)COMMENT
Fake / Example Data7 hits · 7 pts
SeverityFileLineSnippetContext
LOWexamples/apps/popup/src/main.rs59 let paragraph = Paragraph::new("Lorem ipsum").block(popup_block);CODE
LOWratatui-widgets/examples/scrollbar.rs109 Line::from_iter(["Lorem ipsum dolor sit amet, consectetur adipiscing elit.".repeat(10)]),CODE
LOWratatui-widgets/examples/scrollbar.rs109 Line::from_iter(["Lorem ipsum dolor sit amet, consectetur adipiscing elit.".repeat(10)]),CODE
LOWratatui-widgets/examples/shadow.rs124 let sentence = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore CODE
LOWratatui-widgets/examples/shadow.rs124 let sentence = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore CODE
LOWratatui-widgets/src/paragraph.rs1243 let paragraph = Paragraph::new("Lorem ipsum");CODE
LOWratatui-widgets/src/paragraph.rs1252 let paragraph = Paragraph::new("Lorem ipsum");CODE
Synthetic Comment Markers1 hit · 5 pts
SeverityFileLineSnippetContext
HIGHCHANGELOG.md641 > This PR was generated by Claude, and validated by me.CODE
Slop Phrases2 hits · 4 pts
SeverityFileLineSnippetContext
LOWexamples/apps/todo-list/src/main.rs80 "Minnak loves to be pet by you! Don't forget to pet and give some treats!",CODE
MEDIUMratatui-core/src/layout.rs82//! Here's a simple example of creating a basic layout using the [`Layout`] struct:COMMENT
Redundant / Tautological Comments2 hits · 3 pts
SeverityFileLineSnippetContext
LOW.github/workflows/check-pr.yml65 # Check if pattern matchesCOMMENT
LOW.github/workflows/ci.yml245 # Check if README.md is up-to-date with the crate's documentation.COMMENT
Self-Referential Comments1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUM.github/workflows/release-plz.yml44 # Create a PR with the new versions and changelog, preparing the next release.COMMENT