AI Slop Code RIsk Monitor

faif/python-patterns

A collection of design patterns/idioms in Python

25.2 Elevated pattern signal View on GitHub

Maintenance and Governance Review

This report summarizes scanner evidence for faif/python-patterns, a Python project with 43,045 GitHub stars. SynthScan examined 5,542 lines of code across 84 source files, recording 102 pattern matches distributed across 8 syntactic categories. The legacy adjusted pattern signal is 25.2 (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.

25.2
Adjusted Signal
25.2
Raw Pattern Score
100%
Time Factor
2026-10-09
Last Push
43.0K
Stars
Python
Language
5.5K
Lines of Code
84
Files
102
Pattern Hits
2026-10-12
Scan Date
0.04
HC Hit Rate

Risk Review · v3

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

Cognitive Ownership Risk 66.9/100 · HIGH

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

Hallucinated Dependency & Supply Chain Risk 8.6/100 · LOW

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

Agent Over-Engineering Ratio 64.2/100 · HIGH

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

PR Review Velocity Impact 65.2/100 · HIGH

Which changes need focused human review? 102 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 3MEDIUM 0LOW 99

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 102 distinct pattern matches across 8 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.

Hyper-Verbose Identifiers82 hits · 107 pts
SeverityFileLineSnippetContext
LOWpatterns/dependency_injection.py19 def get_current_time_as_html_fragment(self):STRING
LOWpatterns/dependency_injection.py34 def get_current_time_as_html_fragment(self) -> str:CODE
LOWpatterns/dependency_injection.py46 def get_current_time_as_html_fragment(self, time_provider: Callable) -> str:CODE
LOWpatterns/dependency_injection.py63 def get_current_time_as_html_fragment(self):CODE
LOWpatterns/dependency_injection.py71def production_code_time_provider() -> str:CODE
LOWpatterns/other/hsm/hsm.py51 def _send_diagnostics_request(self):CODE
LOW⚡patterns/other/hsm/hsm.py63 def _send_switchover_response(self):CODE
LOW⚡patterns/other/hsm/hsm.py66 def _send_operator_inservice_response(self):CODE
LOW⚡patterns/other/hsm/hsm.py69 def _send_diagnostics_failure_report(self):CODE
LOW⚡patterns/other/hsm/hsm.py72 def _send_diagnostics_pass_report(self):CODE
LOW⚡tests/test_hsm.py21 def test_initial_state_shall_be_standby(cls):CODE
LOW⚡tests/test_hsm.py24 def test_unsupported_state_shall_raise_exception(cls):CODE
LOW⚡tests/test_hsm.py28 def test_unsupported_message_type_shall_raise_exception(cls):CODE
LOW⚡tests/test_hsm.py32 def test_calling_next_state_shall_change_current_state(cls):CODE
LOW⚡tests/test_hsm.py38 def test_method_perform_switchover_shall_return_specifically(cls):CODE
LOWtests/test_hsm.py57 def test_given_standby_on_message_switchover_shall_set_active(cls):CODE
LOWtests/test_hsm.py61 def test_given_standby_on_message_switchover_shall_call_hsm_methods(cls):CODE
LOW⚡tests/test_hsm.py76 def test_given_standby_on_message_fault_trigger_shall_set_suspect(cls):CODE
LOW⚡tests/test_hsm.py80 def test_given_standby_on_message_diagnostics_failed_shall_raise_exception_and_keep_in_state(CODE
LOW⚡tests/test_hsm.py87 def test_given_standby_on_message_diagnostics_passed_shall_raise_exception_and_keep_in_state(CODE
LOW⚡tests/test_hsm.py94 def test_given_standby_on_message_operator_inservice_shall_raise_exception_and_keep_in_state(CODE
LOWtests/test_graph_search.py4def test_find_shortest_path_bfs_handles_leaf_nodes_without_outgoing_edges():CODE
LOW⚡tests/creational/test_factory.py13 def test_get_localizer_english(self):CODE
LOW⚡tests/creational/test_factory.py19 def test_get_localizer_default(self):CODE
LOW⚡tests/creational/test_factory.py24 def test_get_localizer_unknown_language(self):CODE
LOW⚡tests/creational/test_prototype.py10 def test_cloning_propperty_innate_values(self):CODE
LOW⚡tests/creational/test_prototype.py15 def test_extended_property_values_cloning(self):CODE
LOW⚡tests/creational/test_prototype.py21 def test_cloning_propperty_assigned_values(self):CODE
LOWtests/creational/test_prototype.py41 def test_particular_properties_retrieving(self):CODE
LOWtests/creational/test_prototype.py46 def test_extended_properties_retrieving(self):CODE
LOWtests/creational/test_abstract_factory.py7 def test_dog_pet_shop_shall_show_dog_instance(self):CODE
LOW⚡tests/creational/test_borg.py15 def test_initial_borg_state_shall_be_init(self):CODE
LOW⚡tests/creational/test_borg.py19 def test_changing_instance_attribute_shall_change_borg_state(self):CODE
LOW⚡tests/creational/test_borg.py25 def test_instances_shall_have_own_ids(self):CODE
LOWtests/creational/test_lazy.py15 def test_relatives_not_in_properties(self):CODE
LOWtests/creational/test_lazy.py27 def test_relatives_after_access(self):CODE
LOWtests/creational/test_pool.py35 def test_pool_behavior_with_single_object_inside(self):CODE
LOW⚡tests/behavioral/test_catalog.py9def test_catalog_multiple_methods():CODE
LOW⚡tests/behavioral/test_catalog.py15def test_catalog_multiple_instance_methods():CODE
LOW⚡tests/behavioral/test_catalog.py21def test_catalog_multiple_class_methods():CODE
LOW⚡tests/behavioral/test_catalog.py27def test_catalog_multiple_static_methods():CODE
LOW⚡tests/behavioral/test_strategy.py14def test_discount_function_return(func, order, discount):CODE
LOW⚡tests/behavioral/test_strategy.py21def test_order_discount_strategy_validate_success(func, price):CODE
LOW⚡tests/behavioral/test_strategy.py28def test_order_discount_strategy_validate_error():CODE
LOW⚡tests/behavioral/test_strategy.py38def test_discount_apply_success(func, price, discount):CODE
LOWtests/behavioral/test_memento.py11def test_rollback_on_transaction():CODE
LOWtests/behavioral/test_memento.py28def test_rollback_with_transactional_annotation():CODE
LOWtests/behavioral/test_observer.py24def test_one_data_change_notifies_each_observer_once(observable):CODE
LOW⚡tests/behavioral/test_publish_subscribe.py11 def test_subscriber_shall_be_attachable_to_subscriptions(cls):CODE
LOW⚡tests/behavioral/test_publish_subscribe.py19 def test_subscriber_shall_be_detachable_from_subscriptions(cls):CODE
LOW⚡tests/behavioral/test_publish_subscribe.py28 def test_publisher_shall_append_subscription_message_to_queue(cls):CODE
LOWtests/behavioral/test_publish_subscribe.py39 def test_provider_shall_update_affected_subscribers_with_published_subscription(CODE
LOW⚡tests/behavioral/test_visitor.py11def test_visiting_generic_node(visitor):CODE
LOW⚡tests/behavioral/test_visitor.py17def test_visiting_specific_nodes(visitor):CODE
LOW⚡tests/behavioral/test_visitor.py23def test_visiting_inherited_nodes(visitor):CODE
LOWtests/fundamental/test_delegation.py6def test_delegator_delegates_attribute_and_call():CODE
LOWtests/fundamental/test_delegation.py13def test_delegator_missing_attribute_raises():CODE
LOW⚡tests/structural/test_flyweight_with_metaclass.py4def test_same_arguments_share_an_instance():CODE
LOW⚡tests/structural/test_flyweight_with_metaclass.py9def test_different_arguments_do_not_share_an_instance():CODE
LOW⚡tests/structural/test_flyweight_with_metaclass.py14def test_argument_boundaries_are_part_of_the_key():CODE
22 more matches not shown…
Unused Imports10 hits · 10 pts
SeverityFileLineSnippetContext
LOWpatterns/creational/prototype.py24CODE
LOWpatterns/behavioral/observer.py14CODE
LOWpatterns/behavioral/mediator.py11CODE
LOWpatterns/behavioral/strategy.py10CODE
LOWpatterns/behavioral/iterator_alt.py8CODE
LOWpatterns/behavioral/publish_subscribe.py7CODE
LOWpatterns/behavioral/state.py11CODE
LOWpatterns/behavioral/chaining_method.py1CODE
LOWpatterns/fundamental/delegation_pattern.py9CODE
LOWpatterns/structural/front_controller.py8CODE
Docstring Block Structure2 hits · 10 pts
SeverityFileLineSnippetContext
HIGHpatterns/behavioral/servant.py59 Calculate the area of a given shape. Args: shape: The geometric shape whose area is to be STRING
HIGHpatterns/behavioral/servant.py80 Calculate the perimeter of a given shape. Args: shape: The geometric shape whose perimeterSTRING
Empty Error Handlers1 hit · 5 pts
SeverityFileLineSnippetContext
HIGHpatterns/behavioral/observer.py56except ValueError:CODE
Deep Nesting2 hits · 2 pts
SeverityFileLineSnippetContext
LOWpatterns/other/graph_search.py40CODE
LOWpatterns/other/graph_search.py57CODE
Excessive Try-Catch Wrapping2 hits · 2 pts
SeverityFileLineSnippetContext
LOWpatterns/behavioral/memento.py66 except Exception as e:CODE
LOWpatterns/structural/mvc.py128 except Exception:CODE
Overly Generic Function Names2 hits · 2 pts
SeverityFileLineSnippetContext
LOWpatterns/behavioral/memento.py84 def do_stuff(self) -> None:CODE
LOWpatterns/fundamental/delegation_pattern.py53 def do_something(self, something: str, kw=None) -> str:CODE
AI Slop Vocabulary1 hit · 2 pts
SeverityFileLineSnippetContext
LOWpatterns/structural/flyweight.py43 # If the object exists in the pool - just return itCOMMENT