AI Slop Code Risk Monitor

microsoft/TypeChat

SlopCodeMonitor badge for microsoft/TypeChat Adjusted legacy signal; badge bands: 25 / 50 / 75 (different from dashboard bands).

TypeChat is a library that makes it easy to build natural language interfaces using types.

7.1 Moderate pattern signal View on GitHub

Open-Source Code Quality, Security and Technical Debt Review

This report summarizes scanner evidence for microsoft/TypeChat, a TypeScript project with 8,691 GitHub stars. SynthScan examined 32,037 lines of code across 278 source files, recording 174 pattern matches distributed across 17 syntactic categories. The legacy adjusted pattern signal is 7.1 (Moderate 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.

7.1
Adjusted Signal
7.1
Raw Pattern Score
100%
Time Factor
2026-10-31
Last Push
8.7K
Stars
TypeScript
Language
32.0K
Lines of Code
278
Files
174
Pattern Hits
2026-10-31
Scan Date
0.03
HC Hit Rate

Risk Review · Payload v1

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

Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.

Cognitive Ownership Risk 20.8/100 · LOW

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

Hallucinated Dependency & Supply Chain Risk 4.0/100 · LOW

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

Agent Over-Engineering Ratio 19.8/100 · LOW

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

PR Review Velocity Impact 29.8/100 · MEDIUM

Which changes need focused human review? 174 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 7MEDIUM 9LOW 158

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 174 distinct pattern matches across 17 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 Identifiers87 hits · 89 pts
SeverityFileLineSnippetContext
LOWpython/tests/test_translator.py42def test_translator_with_immediate_pass(snapshot: Any):CODE
LOWpython/tests/test_translator.py58def test_translator_with_variadic_tuple_unions():CODE
LOW⚡python/tests/test_translator.py71def test_translator_with_single_failure(snapshot: Any):CODE
LOW⚡python/tests/test_translator.py81def test_translator_with_invalid_json(snapshot: Any):CODE
LOW⚡python/tests/test_translator.py91def test_translator_with_single_failure_and_str_preamble(snapshot: Any):CODE
LOWpython/tests/test_translator.py126def test_translator_with_newtype(snapshot: Any):CODE
LOWpython/tests/test_model.py35def test_reads_response_within_size_limit():CODE
LOWpython/tests/test_model.py45def test_rejects_oversized_response_via_content_length():CODE
LOWpython/tests/test_model.py57def test_rejects_oversized_streamed_response_without_content_length():CODE
LOWpython/tests/test_model.py73def test_size_limit_disabled_allows_large_response():CODE
LOWpython/tests/test_sentiment_non_interactive.py30def test_classify_returns_validated_sentiment(sentiment: str) -> None:CODE
LOWpython/tests/test_sentiment_non_interactive.py41def test_classify_reuses_translator_for_independent_requests() -> None:CODE
LOWpython/tests/test_sentiment_non_interactive.py62def test_classify_repairs_invalid_sentiment() -> None:CODE
LOWpython/tests/test_sentiment_non_interactive.py70def test_classify_surfaces_model_failure(monkeypatch: pytest.MonkeyPatch) -> None:CODE
LOWpython/tests/test_sentiment_non_interactive.py88def test_main_closes_model_and_reports_result(CODE
LOWpython/tests/test_sentiment_non_interactive.py133def test_script_requires_text(capsys: pytest.CaptureFixture[str], monkeypatch: pytest.MonkeyPatch) -> None:CODE
LOWpython/tests/test_sentiment_non_interactive.py142def test_quickstart_matches_runnable_example() -> None:CODE
LOWpython/tests/test_create_language_model.py9def test_openai_organization_is_sent_as_organization_header():CODE
LOWpython/tests/test_create_language_model.py20def test_openai_org_is_still_sent_as_organization_header():CODE
LOWpython/tests/test_create_language_model.py31def test_openai_organization_takes_precedence_over_openai_org():CODE
LOW⚡python/tests/test_inline_comments.py83def test_typeddict_inline_comments(snapshot: Any):CODE
LOW⚡python/tests/test_inline_comments.py87def test_doc_takes_priority_over_inline(snapshot: Any):CODE
LOW⚡python/tests/test_inline_comments.py91def test_dataclass_inline_comments(snapshot: Any):CODE
LOWpython/tests/test_inline_comments.py125def test_hashes_in_types_and_defaults_are_not_comments(py_type: type, expected: str):STRING
LOWpython/tests/test_inline_comments.py129def test_explicit_documentation_takes_precedence_even_when_empty():STRING
LOWpython/tests/test_inline_comments.py140def test_nested_class_comments_do_not_leak_into_the_outer_class():STRING
LOWpython/tests/test_inline_comments.py150def test_nested_classes_can_be_translated_independently():STRING
LOWpython/tests/test_inline_comments.py161def test_nested_dataclass_multiline_default_without_comments():STRING
LOWpython/tests/test_inline_comments.py175def test_nested_dataclass_multiline_default_preserves_comment_coordinates():STRING
LOWpython/tests/test_inline_comments.py193def test_nested_typeddict_multiline_literal_preserves_comment_coordinates():STRING
LOWpython/tests/test_inline_comments.py207def test_nested_class_multiline_docstring_preserves_documentation():STRING
LOWpython/tests/test_inline_comments.py226def test_unavailable_source_preserves_types_and_explicit_documentation(STRING
LOWpython/tests/test_inline_comments.py245def test_dynamically_created_types_remain_supported(py_type: type):STRING
LOWpython/tests/test_inline_comments.py254def test_unexpected_source_lookup_failures_are_not_silenced(monkeypatch: pytest.MonkeyPatch):STRING
LOWpython/tests/test_inline_comments.py268def test_invalid_source_is_reported_as_a_conversion_error(monkeypatch: pytest.MonkeyPatch, source: str):STRING
LOWpython/tests/test_inline_comments.py347def test_only_trailing_field_comments_are_attached(STRING
LOWpython/tests/test_inline_comments.py359def test_inline_comments_do_not_hide_unsupported_schema_types():STRING
LOWpython/tests/test_abstract_collections.py26def test_abstract_collections(snapshot: Any):CODE
LOWpython/tests/test_validator.py13def test_dict_valid_as_dataclass():CODE
LOW⚡python/tests/test_failure.py71def test_message_only_failure_has_no_value():CODE
LOW⚡python/tests/test_failure.py80def test_failure_retains_explicit_values(value: object):CODE
LOW⚡python/tests/test_failure.py90def test_validator_retains_the_entire_rejected_value(value: object):CODE
LOW⚡python/tests/test_failure.py98def test_translator_preserves_success():CODE
LOW⚡python/tests/test_failure.py105def test_translator_retains_rejected_data_without_repair():CODE
LOWpython/tests/test_failure.py118def test_translator_preserves_custom_failure_payloads(value: object):CODE
LOWpython/tests/test_failure.py130def test_translator_does_not_mutate_custom_message_only_failures():CODE
LOWpython/tests/test_failure.py142def test_translator_preserves_failure_subclasses_and_metadata():CODE
LOW⚡python/tests/test_failure.py154def test_translator_retains_unparseable_text_without_inventing_data(response_text: str):CODE
LOW⚡python/tests/test_failure.py163def test_translator_propagates_initial_model_failures_unchanged():CODE
LOW⚡python/tests/test_failure.py169def test_translator_preserves_successful_repair():CODE
LOWpython/tests/test_failure.py180def test_translator_returns_latest_rejected_candidate_after_one_repair():CODE
LOWpython/tests/test_failure.py191def test_translator_retains_previous_candidate_when_repair_request_fails():CODE
LOW⚡python/tests/test_failure.py205def test_translator_preserves_context_supplied_by_the_model():CODE
LOW⚡python/tests/test_failure.py211def test_translator_preserves_model_failure_subclasses():CODE
LOW⚡python/tests/test_failure.py221def test_translator_does_not_leak_failure_context_into_another_translation():CODE
LOW⚡python/tests/test_failure.py229def test_translator_retains_previous_candidate_when_repair_cannot_be_parsed(response_text: str):CODE
LOWpython/tests/test_failure.py240def test_python_still_repairs_unparseable_output(response_text: str):CODE
LOWpython/tests/test_newtype.py17def test_newtype_uses_underlying_type():CODE
LOWpython/tests/test_newtype.py52def test_newtype_unsupported_underlying_type_reports_error():CODE
LOWpython/examples/music/client.py96def get_tracks_from_result_list(resultItems: list[Any]) -> list[SimplifiedTrackInfo]:CODE
27 more matches not shown…
Deep Nesting18 hits · 18 pts
SeverityFileLineSnippetContext
LOWpython/examples/music/client.py186CODE
LOWpython/examples/music/demo.py10CODE
LOWpython/examples/music/demo.py17CODE
LOWpython/examples/restaurant/demo.py8CODE
LOWpython/examples/restaurant/demo.py14CODE
LOWpython/examples/drawing/demo.py20CODE
LOWpython/examples/drawing/demo.py35CODE
LOWpython/examples/coffeeShop/demo.py10CODE
LOWpython/examples/coffeeShop/demo.py17CODE
LOWpython/examples/calendar/demo.py9CODE
LOWpython/examples/calendar/demo.py15CODE
LOWpython/src/typechat/_internal/interactive.py3CODE
LOWpython/src/typechat/_internal/translator.py53CODE
LOW…hat/_internal/ts_conversion/python_type_to_ts_nodes.py170CODE
LOW…hat/_internal/ts_conversion/python_type_to_ts_nodes.py212CODE
LOW…hat/_internal/ts_conversion/python_type_to_ts_nodes.py267CODE
LOW…hat/_internal/ts_conversion/python_type_to_ts_nodes.py363CODE
LOW…hat/_internal/ts_conversion/python_type_to_ts_nodes.py412CODE
Decorative Section Separators6 hits · 18 pts
SeverityFileLineSnippetContext
MEDIUMpython/examples/healthData/input.txt8# ================COMMENT
MEDIUMpython/examples/healthData/input.txt10# ================COMMENT
MEDIUMtypescript/examples/healthData/src/input.txt8# ================COMMENT
MEDIUMtypescript/examples/healthData/src/input.txt10# ================COMMENT
MEDIUM.github/workflows/fix-dependabot-alerts.yml125 # ── Final clean build verification ──────────────────────────────COMMENT
MEDIUM.github/workflows/fix-dependabot-alerts.yml150 # ── Create PR ───────────────────────────────────────────────────COMMENT
Structural Annotation Overuse11 hits · 16 pts
SeverityFileLineSnippetContext
LOWpython/examples/README.md22## Step 1: Configure your development environmentCOMMENT
LOWpython/examples/README.md76## Step 2: Configure environment variablesCOMMENT
LOWpython/examples/README.md107## Step 3: Run the examplesCOMMENT
LOWtypescript/examples/README.md21## Step 1: Configure your development environmentCOMMENT
LOWtypescript/examples/README.md56## Step 2: Build TypeChat SamplesCOMMENT
LOWtypescript/examples/README.md64## Step 3: Configure environment variablesCOMMENT
LOWtypescript/examples/README.md116## Step 4: Run the examplesCOMMENT
LOWsite/src/docs/examples.md25## Step 1: Configure development environmentCOMMENT
LOWsite/src/docs/examples.md60## Step 2: Build TypeChat ExamplesCOMMENT
LOWsite/src/docs/examples.md68## Step 3: Configure environment variablesCOMMENT
LOWsite/src/docs/examples.md104## Step 4: Run the examplesCOMMENT
Unused Imports16 hits · 16 pts
SeverityFileLineSnippetContext
LOWpython/examples/math/program.py1CODE
LOWpython/src/typechat/__init__.py5CODE
LOWpython/src/typechat/__init__.py5CODE
LOWpython/src/typechat/__init__.py5CODE
LOWpython/src/typechat/__init__.py5CODE
LOWpython/src/typechat/__init__.py5CODE
LOWpython/src/typechat/__init__.py6CODE
LOWpython/src/typechat/__init__.py6CODE
LOWpython/src/typechat/__init__.py6CODE
LOWpython/src/typechat/__init__.py7CODE
LOWpython/src/typechat/__init__.py8CODE
LOWpython/src/typechat/__init__.py9CODE
LOWpython/src/typechat/__init__.py10CODE
LOWpython/src/typechat/_internal/interactive.py25CODE
LOW…/src/typechat/_internal/ts_conversion/ts_type_nodes.py1CODE
LOW…hat/_internal/ts_conversion/python_type_to_ts_nodes.py1CODE
Cross-File Repetition3 hits · 15 pts
SeverityFileLineSnippetContext
HIGHpython/examples/math/program.py0the following is the user request translated into a json object with 2 spaces of indentation and no properties with the STRING
HIGHpython/examples/healthData/translator.py0the following is the user request translated into a json object with 2 spaces of indentation and no properties with the STRING
HIGHpython/src/typechat/_internal/translator.py0the following is the user request translated into a json object with 2 spaces of indentation and no properties with the STRING
Over-Commented Block14 hits · 14 pts
SeverityFileLineSnippetContext
LOWpython/tests/__init__.py1# SPDX-FileCopyrightText: Microsoft CorporationCOMMENT
LOW…pshots__/test_tuple_errors_1/test_tuples_2.schema.d.ts1// Entry point is: 'TupleContainer'COMMENT
LOWpython/examples/healthData/input.txt1#COMMENT
LOWpython/src/typechat/__about__.py1# SPDX-FileCopyrightText: Microsoft CorporationCOMMENT
LOWtypescript/examples/music/src/chatifyActionsSchema.ts21 // show now playingCOMMENT
LOWtypescript/examples/music/src/chatifyActionsSchema.ts41 setVolume(newVolumeLevel: number): void;COMMENT
LOWtypescript/examples/healthData/src/input.txt1#COMMENT
LOW.github/dependabot.yml1# Dependabot configuration for microsoft/TypeChat.COMMENT
LOW.github/workflows/backlog-assessment.lock.yml1# gh-aw-metadata: {"schema_version":"v4","frontmatter_hash":"be7b78f65a99cbb8ab1f33adf5694cdefca9343f5b2ad21783eeefdf0bdCOMMENT
LOW.github/workflows/backlog-assessment.lock.yml21# - GH_AW_DEFAULT_OTLP_ENDPOINTCOMMENT
LOW.github/workflows/discussion-draft.lock.yml1# gh-aw-metadata: {"schema_version":"v4","frontmatter_hash":"7c8380b1ffb86eb153eb973bf694b44f1f4e8549320f86794635467636bCOMMENT
LOW.github/workflows/discussion-draft.lock.yml21# - GH_AW_GITHUB_TOKENCOMMENT
LOW.github/workflows/fix-dependabot-alerts.yml1# Copyright (c) Microsoft Corporation.COMMENT
LOW.github/workflows/fix-dependabot-alerts.yml121 # cache key. The restore step uses a shared prefix so anyCOMMENT
Empty Error Handlers2 hits · 10 pts
SeverityFileLineSnippetContext
HIGHpython/src/typechat/_internal/model.py152except Exception:CODE
HIGHpython/src/typechat/_internal/interactive.py26except ImportError:CODE
Excessive Try-Catch Wrapping5 hits · 6 pts
SeverityFileLineSnippetContext
LOWpython/examples/music/demo.py27 except Exception as error:CODE
LOWpython/examples/multiSchema/agents.py123 except Exception as error:CODE
LOWpython/src/typechat/_internal/model.py107 except Exception as e:CODE
LOWpython/src/typechat/_internal/model.py152 except Exception:CODE
MEDIUMpython/src/typechat/_internal/model.py149def __del__(self):CODE
Cross-Language Confusion1 hit · 5 pts
SeverityFileLineSnippetContext
HIGHpython/tests/test_translator.py60 '{"values": [1, "two"], "optional_values": ["three", null], "choices": ["yes", "no"]}',CODE
Magic Placeholder Names1 hit · 5 pts
SeverityFileLineSnippetContext
HIGHsite/src/docs/python/non-interactive.md24OPENAI_API_KEY=your-api-keyCODE
Overly Generic Function Names4 hits · 4 pts
SeverityFileLineSnippetContext
LOWpython/tests/test_dataclasses.py25 def do_something(self):CODE
LOWpython/examples/multiSchema/agents.py37 async def handle_request(self, line: str):CODE
LOWpython/examples/multiSchema/agents.py80 async def handle_request(self, line: str):CODE
LOWpython/examples/multiSchema/agents.py108 async def handle_request(self, line: str):CODE
Self-Referential Comments1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUM.github/workflows/fix-dependabot-alerts.yml244 # Create the new PR FIRST, capture its number, THEN closeCOMMENT
Modern AI Meta-Vocabulary1 hit · 2 pts
SeverityFileLineSnippetContext
MEDIUMAUTOMATION.md160[GitHub Agentic Workflows](https://docs.github.com/en/copilot/concepts/agent-capabilities/agent-powered-workflows-and-opCODE
Modern Structural Boilerplate2 hits · 2 pts
SeverityFileLineSnippetContext
LOWpython/src/typechat/__init__.py12__all__ = [CODE
LOWpython/src/typechat/_internal/ts_conversion/__init__.py7__all__ = [CODE
AI Slop Vocabulary1 hit · 2 pts
SeverityFileLineSnippetContext
LOWpython/examples/math/program.py108 # For now, we just pass in `Any` in place of `JsonProgram`.COMMENT
AI Structural Patterns1 hit · 1 pts
SeverityFileLineSnippetContext
LOWpython/examples/music/client.py68CODE