FriendlyId is the “Swiss Army bulldozer” of slugging and permalink plugins for ActiveRecord. It allows you to create pretty URL’s and work with human-friendly strings as if they were numeric ids for ActiveRecord models.
This report presents the forensic synthetic code analysis of norman/friendly_id, a Ruby project with 6,226 GitHub stars. SynthScan v2.0 examined 5,993 lines of code across 58 source files, recording 83 pattern matches distributed across 7 syntactic categories. The overall adjusted score of 17.4 places this repository in the Moderate 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).
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.
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 83 distinct pattern matches across 7 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 | test/benchmarks/object_utils.rb | 1 | require File.expand_path("../../helper", __FILE__) | COMMENT |
| LOW | lib/friendly_id.rb | 1 | require "active_record" | COMMENT |
| LOW | lib/friendly_id.rb | 21 | # performance and a well-documented codebase. | COMMENT |
| LOW | lib/friendly_id.rb | 61 | # instance variable +@friendly_id_config+ is added. This variable is an | COMMENT |
| LOW | lib/friendly_id/base.rb | 1 | module FriendlyId | COMMENT |
| LOW | lib/friendly_id/base.rb | 21 | # *A note about single table inheritance (STI): you must extend FriendlyId in | COMMENT |
| LOW | lib/friendly_id/base.rb | 41 | # In this case, FriendlyId assumes you want to use the column as-is; it will never | COMMENT |
| LOW | lib/friendly_id/base.rb | 61 | # class Post < ActiveRecord::Base | COMMENT |
| LOW | lib/friendly_id/base.rb | 81 | # end | COMMENT |
| LOW | lib/friendly_id/base.rb | 101 | # friendly_id :title | COMMENT |
| LOW | lib/friendly_id/base.rb | 121 | # friendly_id do |config| | COMMENT |
| LOW | lib/friendly_id/base.rb | 141 | # on-the-fly. For example, let's say you want to make | COMMENT |
| LOW | lib/friendly_id/base.rb | 161 | # {FriendlyId::Reserved :finders}, {FriendlyId::History :history}, | COMMENT |
| LOW | lib/friendly_id/base.rb | 181 | # @option options [Integer] :slug_limit Available when using `:slugged`. | COMMENT |
| LOW | lib/friendly_id/base.rb | 201 | # `/team/1` instead of `/team/number-one`. You can still generate paths | COMMENT |
| LOW | lib/friendly_id/history.rb | 1 | module FriendlyId | COMMENT |
| LOW | lib/friendly_id/history.rb | 21 | # model. | COMMENT |
| LOW | lib/friendly_id/history.rb | 41 | # | COMMENT |
| LOW | lib/friendly_id/reserved.rb | 1 | module FriendlyId | COMMENT |
| LOW | lib/friendly_id/reserved.rb | 21 | # friendly_id :name, use: :slugged | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 1 | require "friendly_id/slug_generator" | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 21 | # end | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 41 | # class Post < ActiveRecord::Base | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 61 | # end | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 81 | # FriendlyId uses. | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 101 | # When you try to insert a record that would generate a duplicate friendly id, | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 121 | # friendly_id :slug_candidates, use: :slugged | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 141 | # To use candidates, make your FriendlyId base method return an array. The | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 161 | # be interpreted as either a friendly slug or a database ID. To prevent this, you can | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 181 | # | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 201 | # friendly_id :title, :use => :slugged | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 221 | # | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 241 | # #### Gotchas: Common Problems | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 281 | # | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 321 | # Public: Resolve conflicts. | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 401 | COMMENT | |
| LOW | lib/friendly_id/initializer.rb | 1 | # FriendlyId Global Configuration | COMMENT |
| LOW | lib/friendly_id/initializer.rb | 21 | COMMENT | |
| LOW | lib/friendly_id/initializer.rb | 41 | # always also configure it on a per-model basis if you prefer. | COMMENT |
| LOW | lib/friendly_id/initializer.rb | 61 | # By default, slug has no size limit, but you can change it if you wish. | COMMENT |
| LOW | lib/friendly_id/initializer.rb | 81 | # nil, but if you're using a column as your base method can change this | COMMENT |
| LOW | lib/friendly_id/initializer.rb | 101 | # | COMMENT |
| LOW | lib/friendly_id/scoped.rb | 1 | require "friendly_id/slugged" | COMMENT |
| LOW | lib/friendly_id/scoped.rb | 21 | # extend FriendlyId | COMMENT |
| LOW | lib/friendly_id/scoped.rb | 41 | # end | COMMENT |
| LOW | lib/friendly_id/scoped.rb | 61 | # | COMMENT |
| LOW | lib/friendly_id/scoped.rb | 81 | # | COMMENT |
| LOW | lib/friendly_id/scoped.rb | 141 | (changed & friendly_id_config.scope_columns).any? || super | COMMENT |
| LOW | lib/friendly_id/object_utils.rb | 21 | module ObjectUtils | COMMENT |
| LOW | lib/friendly_id/simple_i18n.rb | 1 | require "i18n" | COMMENT |
| LOW | lib/friendly_id/simple_i18n.rb | 21 | # ### Example migration | COMMENT |
| LOW | lib/friendly_id/simple_i18n.rb | 41 | # Post.friendly.find("la-guerra-de-las-galaxias") | COMMENT |
| LOW | lib/friendly_id/simple_i18n.rb | 61 | # {FriendlyId::SimpleI18n::Model#set_friendly_id}. This will ensure that the slug | COMMENT |
| LOW | lib/friendly_id/finders.rb | 1 | module FriendlyId | COMMENT |
| LOW | lib/friendly_id/finders.rb | 21 | # not have a public API, which was harder to maintain and at times caused | COMMENT |
| LOW | lib/friendly_id/finders.rb | 41 | # Unless you've chosen to use the `:finders` addon, be sure to modify the finders | COMMENT |
| LOW | lib/friendly_id/finder_methods.rb | 1 | module FriendlyId | COMMENT |
| LOW | lib/friendly_id/finder_methods.rb | 81 | # Parse the given value to make it suitable for use as a slug according to | COMMENT |
| LOW | lib/friendly_id/configuration.rb | 41 | # | COMMENT |
| LOW | lib/friendly_id/configuration.rb | 61 | def uses?(mod) | COMMENT |
| 1 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | lib/friendly_id/candidates.rb | 4 | # This class provides the slug candidate functionality. | COMMENT |
| MEDIUM | lib/friendly_id/slugged.rb | 273 | # This method is not intended to be invoked directly; FriendlyId uses it | COMMENT |
| MEDIUM | lib/friendly_id/simple_i18n.rb | 17 | # This module is most suitable to applications that need to support few locales. | COMMENT |
| MEDIUM | lib/friendly_id/finder_methods.rb | 84 | # This method is not intended to be invoked directly; FriendlyId uses it | COMMENT |
| MEDIUM | lib/friendly_id/configuration.rb | 38 | # This method is invoked by {FriendlyId::Base#friendly_id friendly_id} when | COMMENT |
| MEDIUM | lib/friendly_id/configuration.rb | 68 | # This method is generally only used internally by FriendlyId. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | lib/friendly_id/slugged.rb | 209 | # don't forget to invoke `super` from your implementation: | COMMENT |
| LOW | lib/friendly_id/slugged.rb | 209 | # don't forget to invoke `super` from your implementation: | COMMENT |
| MEDIUM | lib/friendly_id/initializer.rb | 57 | # 'slug', but you can change it if you wish. | COMMENT |
| MEDIUM | lib/friendly_id/initializer.rb | 61 | # By default, slug has no size limit, but you can change it if you wish. | COMMENT |
| LOW | lib/friendly_id/initializer.rb | 100 | # ASCII. If you use this, don't forget to add "babosa" to your Gemfile. | COMMENT |
| LOW | lib/friendly_id/initializer.rb | 100 | # ASCII. If you use this, don't forget to add "babosa" to your Gemfile. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/simple_i18n_test.rb | 16 | journalist = Journalist.new(name: "John Doe") | CODE |
| LOW | test/simple_i18n_test.rb | 33 | journalist = Journalist.new(name: "John Doe") | CODE |
| LOW | test/simple_i18n_test.rb | 39 | journalist = Journalist.new(name: "John Doe") | CODE |
| LOW | test/simple_i18n_test.rb | 74 | journalist.set_friendly_id("John Doe") | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | lib/friendly_id/sequentially_slugged.rb | 9 | def resolve_friendly_id_conflict(candidate_slugs) | CODE |
| LOW | lib/friendly_id/slugged.rb | 337 | def resolve_friendly_id_conflict(candidates) | CODE |
| LOW | lib/friendly_id/finder_methods.rb | 114 | def raise_not_found_exception(id) | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | lib/friendly_id/reserved.rb | 16 | # scaffolding works as expected, one way to accomplish this is to move the error | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | lib/friendly_id/simple_i18n.rb | 67 | # If you don't pass in a locale argument, FriendlyId::SimpleI18n will just use the | COMMENT |
| LOW | lib/generators/friendly_id_generator.rb | 8 | # new table name. Our generator always uses 'friendly_id_slugs', so we just set a random name here. | COMMENT |