Repository Analysis

OHF-Voice/piper1-gpl

Fast and local neural text-to-speech engine

7.7 Low AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of OHF-Voice/piper1-gpl, a C++ project with 4,784 GitHub stars. SynthScan v2.0 examined 36,973 lines of code across 91 source files, recording 270 pattern matches distributed across 9 syntactic categories. The overall adjusted score of 7.7 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).

7.7
Adjusted Score
7.7
Raw Score
100%
Time Factor
2026-07-14
Last Push
4.8K
Stars
C++
Language
37.0K
Lines of Code
91
Files
270
Pattern Hits
2026-07-14
Scan Date
0.00
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

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.

No multi-scan history yet — run the scanner again to build trend data.

Severity Breakdown

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.

CRITICAL 0HIGH 0MEDIUM 32LOW 238

Directory Score Breakdown

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.

Pattern Findings

The scanner identified 270 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.

Decorative Section Separators32 hits · 120 pts
SeverityFileLineSnippetContext
MEDIUMtests/test_piper.py457# -----------------------------------------------------------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py165 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py167 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py170 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py172 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py178 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py180 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py183 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py185 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py189 # ------------------------COMMENT
MEDIUMtests/test_chinese_phonemizer.py191 # ------------------------COMMENT
MEDIUMtests/generate_test_voice.py87# -----------------------------------------------------------------------------COMMENT
MEDIUMlibpiper/CMakeLists.txt192# ----------------COMMENT
MEDIUMlibpiper/CMakeLists.txt194# ----------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py55 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py57 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py82 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py84 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py127 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py129 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py135 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py137 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py144 # --------------------COMMENT
MEDIUMsrc/piper/phonemize_chinese.py146 # --------------------COMMENT
MEDIUMsrc/piper/download_voices.py63# -----------------------------------------------------------------------------COMMENT
MEDIUMsrc/piper/download_voices.py135# -----------------------------------------------------------------------------COMMENT
MEDIUMsrc/piper/__main__.py252# -----------------------------------------------------------------------------COMMENT
MEDIUMsrc/piper/train/export_onnx.py40 # -------------------------------------------------------------------------COMMENT
MEDIUMsrc/piper/train/export_onnx.py109# -----------------------------------------------------------------------------COMMENT
MEDIUMsrc/piper/train/export_generator.py36 # -------------------------------------------------------------------------COMMENT
MEDIUMsrc/piper/train/export_generator.py59# -----------------------------------------------------------------------------COMMENT
MEDIUMsrc/piper/train/__main__.py34# -----------------------------------------------------------------------------COMMENT
Over-Commented Block187 hits · 114 pts
SeverityFileLineSnippetContext
LOWlibpiper/include/json.hpp21#include <algorithm> // all_of, find, for_eachCOMMENT
LOWlibpiper/include/json.hpp41// SPDX-FileCopyrightText: 2013-2022 Niels Lohmann <https://nlohmann.me>COMMENT
LOWlibpiper/include/json.hpp61#ifndef JSON_SKIP_LIBRARY_VERSION_CHECKCOMMENT
LOWlibpiper/include/json.hpp81#if JSON_DIAGNOSTICSCOMMENT
LOWlibpiper/include/json.hpp141 {COMMENT
LOWlibpiper/include/json.hpp161#include <algorithm> // transformCOMMENT
LOWlibpiper/include/json.hpp181COMMENT
LOWlibpiper/include/json.hpp201#include <array> // arrayCOMMENT
LOWlibpiper/include/json.hpp221// | | |__ | | | | | | version 3.11.2COMMENT
LOWlibpiper/include/json.hpp321// | | |__ | | | | | | version 3.11.2COMMENT
LOWlibpiper/include/json.hpp341#define JSON_HEDLEY_STRINGIFY_EX(x) #xCOMMENT
LOWlibpiper/include/json.hpp361#define JSON_HEDLEY_CONCAT3_EX(a,b,c) a##b##cCOMMENT
LOWlibpiper/include/json.hpp381#define JSON_HEDLEY_VERSION_DECODE_MINOR(version) (((version) % 1000000) / 1000)COMMENT
LOWlibpiper/include/json.hpp401 #define JSON_HEDLEY_GNUC_VERSION_CHECK(major,minor,patch) (JSON_HEDLEY_GNUC_VERSION >= JSON_HEDLEY_VERSION_ENCODE(maCOMMENT
LOWlibpiper/include/json.hpp421 #define JSON_HEDLEY_MSVC_VERSION_CHECK(major,minor,patch) (0)COMMENT
LOWlibpiper/include/json.hpp441#endifCOMMENT
LOWlibpiper/include/json.hpp461 #define JSON_HEDLEY_INTEL_CL_VERSION_CHECK(major,minor,patch) (0)COMMENT
LOWlibpiper/include/json.hpp481 #undef JSON_HEDLEY_SUNPRO_VERSIONCOMMENT
LOWlibpiper/include/json.hpp501COMMENT
LOWlibpiper/include/json.hpp521#if defined(__CC_ARM) && defined(__ARMCOMPILER_VERSION)COMMENT
LOWlibpiper/include/json.hpp541#elif defined(__xlC__) && defined(__xlC_ver__)COMMENT
LOWlibpiper/include/json.hpp561 ( \COMMENT
LOWlibpiper/include/json.hpp581 #undef JSON_HEDLEY_TI_CL2000_VERSIONCOMMENT
LOWlibpiper/include/json.hpp601#endifCOMMENT
LOWlibpiper/include/json.hpp621#endifCOMMENT
LOWlibpiper/include/json.hpp641 #define JSON_HEDLEY_TI_CL6X_VERSION_CHECK(major,minor,patch) (0)COMMENT
LOWlibpiper/include/json.hpp661 #undef JSON_HEDLEY_TI_CLPRU_VERSIONCOMMENT
LOWlibpiper/include/json.hpp681 #define JSON_HEDLEY_CRAY_VERSION JSON_HEDLEY_VERSION_ENCODE(_RELEASE_MAJOR, _RELEASE_MINOR, _RELEASE_PATCHLEVEL)COMMENT
LOWlibpiper/include/json.hpp701 #define JSON_HEDLEY_IAR_VERSION JSON_HEDLEY_VERSION_ENCODE((__VER__ / 1000000), ((__VER__ / 1000) % 1000), (__VECOMMENT
LOWlibpiper/include/json.hpp721#endifCOMMENT
LOWlibpiper/include/json.hpp741#endifCOMMENT
LOWlibpiper/include/json.hpp761 #define JSON_HEDLEY_COMPCERT_VERSION_CHECK(major,minor,patch) (0)COMMENT
LOWlibpiper/include/json.hpp781 #undef JSON_HEDLEY_MCST_LCC_VERSIONCOMMENT
LOWlibpiper/include/json.hpp821#if defined(JSON_HEDLEY_GCC_VERSION)COMMENT
LOWlibpiper/include/json.hpp841 #undef JSON_HEDLEY_GNUC_HAS_ATTRIBUTECOMMENT
LOWlibpiper/include/json.hpp861#if \COMMENT
LOWlibpiper/include/json.hpp881#elseCOMMENT
LOWlibpiper/include/json.hpp901#endifCOMMENT
LOWlibpiper/include/json.hpp921#if defined(JSON_HEDLEY_GCC_HAS_BUILTIN)COMMENT
LOWlibpiper/include/json.hpp941#endifCOMMENT
LOWlibpiper/include/json.hpp961 #define JSON_HEDLEY_HAS_EXTENSION(extension) __has_extension(extension)COMMENT
LOWlibpiper/include/json.hpp981 #define JSON_HEDLEY_GCC_HAS_EXTENSION(extension,major,minor,patch) JSON_HEDLEY_GCC_VERSION_CHECK(major,minor,patch)COMMENT
LOWlibpiper/include/json.hpp1001COMMENT
LOWlibpiper/include/json.hpp1021 #undef JSON_HEDLEY_GNUC_HAS_WARNINGCOMMENT
LOWlibpiper/include/json.hpp1061 #define JSON_HEDLEY_PRAGMA(value)COMMENT
LOWlibpiper/include/json.hpp1081 JSON_HEDLEY_INTEL_CL_VERSION_CHECK(2021,1,0)COMMENT
LOWlibpiper/include/json.hpp1101 #define JSON_HEDLEY_DIAGNOSTIC_POPCOMMENT
LOWlibpiper/include/json.hpp1141#if defined(JSON_HEDLEY_CONST_CAST)COMMENT
LOWlibpiper/include/json.hpp1161 #undef JSON_HEDLEY_REINTERPRET_CASTCOMMENT
LOWlibpiper/include/json.hpp1181#if defined(__cplusplus)COMMENT
LOWlibpiper/include/json.hpp1201 #undef JSON_HEDLEY_DIAGNOSTIC_DISABLE_DEPRECATEDCOMMENT
LOWlibpiper/include/json.hpp1241 #define JSON_HEDLEY_DIAGNOSTIC_DISABLE_DEPRECATEDCOMMENT
LOWlibpiper/include/json.hpp1261 JSON_HEDLEY_TI_CL6X_VERSION_CHECK(8,0,0) || \COMMENT
LOWlibpiper/include/json.hpp1281 #define JSON_HEDLEY_DIAGNOSTIC_DISABLE_UNKNOWN_CPP_ATTRIBUTES _Pragma("GCC diagnostic ignored \"-Wdeprecated-declaraCOMMENT
LOWlibpiper/include/json.hpp1301#elif JSON_HEDLEY_MCST_LCC_VERSION_CHECK(1,25,10)COMMENT
LOWlibpiper/include/json.hpp1321 #undef JSON_HEDLEY_DIAGNOSTIC_DISABLE_UNUSED_FUNCTIONCOMMENT
LOWlibpiper/include/json.hpp1381 #define JSON_HEDLEY_DEPRECATED(since) __attribute__((__deprecated__))COMMENT
LOWlibpiper/include/json.hpp1401 JSON_HEDLEY_HAS_ATTRIBUTE(warning) || \COMMENT
LOWlibpiper/include/json.hpp1441 #define JSON_HEDLEY_WARN_UNUSED_RESULT_MSG(msg) JSON_HEDLEY_DIAGNOSTIC_DISABLE_CPP98_COMPAT_WRAP_([[nodiscard]])COMMENT
LOWlibpiper/include/json.hpp1461 #define JSON_HEDLEY_SENTINEL(position)COMMENT
127 more matches not shown…
Hyper-Verbose Identifiers27 hits · 27 pts
SeverityFileLineSnippetContext
LOWtests/test_espeak_phonemizer.py65def test_vowel_clusters_without_terminator() -> None:CODE
LOWtests/test_piper.py35def test_phonemize_synthesize() -> None:CODE
LOWtests/test_piper.py111def test_language_switch_flags_removed() -> None:CODE
LOWtests/test_piper.py203def test_synthesize_alignment() -> None:CODE
LOWtests/test_piper.py390def test_add_alignment_output_autodetect() -> None:CODE
LOWtests/test_piper.py410def test_add_alignment_output_errors() -> None:CODE
LOWtests/test_piper.py431def test_load_include_alignments_in_memory(tmp_path: Path) -> None:CODE
LOWtests/test_piper.py450def test_load_include_alignments_no_ceil() -> None:CODE
LOWtests/test_piper.py474def test_phonemize_with_vowel_clusters() -> None:CODE
LOWtests/test_piper.py549def test_training_phonemize_matches_inference_with_vowel_clusters() -> None:CODE
LOWsrc/piper/phonemize_chinese.py348def _split_initial_final_tone(syl: str):CODE
LOWsrc/piper/phonemize_espeak.py74def _merge_known_vowel_clusters(CODE
LOWsrc/piper/tashkeel/__init__.py115 def _annotate_text_with_diacritics(CODE
LOWsrc/piper/tashkeel/__init__.py132 def _annotate_text_with_diacritics_taskeen(CODE
LOWsrc/piper/tashkeel/__init__.py160 def _extract_chars_and_diacritics(CODE
LOWsrc/piper/train/vits/mel_processing.py8def dynamic_range_compression_torch(x, C=1, clip_val=1e-5):CODE
LOWsrc/piper/train/vits/mel_processing.py17def dynamic_range_decompression_torch(x, C=1):CODE
LOWsrc/piper/train/vits/mel_processing.py31def spectral_de_normalize_torch(magnitudes):CODE
LOWsrc/piper/train/vits/transforms.py10def piecewise_rational_quadratic_transform(CODE
LOWsrc/piper/train/vits/transforms.py50def unconstrained_rational_quadratic_spline(CODE
LOWsrc/piper/train/vits/transforms.py101def rational_quadratic_spline(CODE
LOWsrc/piper/train/vits/attentions.py274 def _matmul_with_relative_values(self, x, y):CODE
LOWsrc/piper/train/vits/attentions.py283 def _matmul_with_relative_keys(self, x, y):CODE
LOWsrc/piper/train/vits/attentions.py311 def _relative_position_to_absolute_position(self, x):CODE
LOWsrc/piper/train/vits/attentions.py333 def _absolute_position_to_relative_position(self, x):CODE
LOWsrc/piper/train/vits/commons.py100def fused_add_tanh_sigmoid_multiply(input_a, input_b, n_channels):CODE
LOWsrc/piper/train/vits/lightning.py319 def _warmstart_vocoder_from_ckpt(self, ckpt_path: str):CODE
Deep Nesting8 hits · 8 pts
SeverityFileLineSnippetContext
LOWsrc/piper/http_server.py21CODE
LOWsrc/piper/http_server.py217CODE
LOWsrc/piper/phonemize_chinese.py217CODE
LOWsrc/piper/voice.py300CODE
LOWsrc/piper/__main__.py22CODE
LOWsrc/piper/__main__.py108CODE
LOWsrc/piper/train/vits/models.py349CODE
LOWsrc/piper/train/vits/dataset.py140CODE
AI Structural Patterns7 hits · 7 pts
SeverityFileLineSnippetContext
LOWsrc/piper/train/vits/mel_processing.py28CODE
LOWsrc/piper/train/vits/mel_processing.py33CODE
LOWsrc/piper/train/vits/transforms.py101CODE
LOWsrc/piper/train/vits/attentions.py281CODE
LOWsrc/piper/train/vits/attentions.py290CODE
LOWsrc/piper/train/vits/dataset.py49CODE
LOWsrc/piper/train/vits/lightning.py24CODE
Unused Imports6 hits · 6 pts
SeverityFileLineSnippetContext
LOWsrc/piper/__init__.py3CODE
LOWsrc/piper/__init__.py3CODE
LOWsrc/piper/__init__.py3CODE
LOWsrc/piper/__init__.py4CODE
LOWsrc/piper/__init__.py4CODE
LOWsrc/piper/phonemize_espeak.py6CODE
Redundant / Tautological Comments1 hit · 2 pts
SeverityFileLineSnippetContext
LOWtests/test_piper.py196 # Check if entire text is just phonemesCOMMENT
Modern Structural Boilerplate1 hit · 1 pts
SeverityFileLineSnippetContext
LOWsrc/piper/__init__.py6__all__ = [CODE
Excessive Try-Catch Wrapping1 hit · 1 pts
SeverityFileLineSnippetContext
LOWsrc/piper/audio_playback.py43 except Exception:CODE