Fish shell like syntax highlighting for Zsh.
This report presents the forensic synthetic code analysis of zsh-users/zsh-syntax-highlighting, a Shell project with 22,912 GitHub stars. SynthScan v2.0 examined 17,624 lines of code across 325 source files, recording 1288 pattern matches distributed across 7 syntactic categories. The overall adjusted score of 177.7 places this repository in the Strong 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 1288 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 |
|---|---|---|---|---|
| MEDIUM | zsh-syntax-highlighting.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 98 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 100 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 339 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 341 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 381 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 383 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 543 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | zsh-syntax-highlighting.zsh | 545 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-highlighting.zsh | 2 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-highlighting.zsh | 26 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-highlighting.zsh | 29 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-perfs.zsh | 2 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-perfs.zsh | 26 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-perfs.zsh | 29 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/generate.zsh | 2 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/generate.zsh | 26 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/generate.zsh | 29 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/tap-colorizer.zsh | 2 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/tap-colorizer.zsh | 26 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/tap-colorizer.zsh | 29 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-zprof.zsh | 2 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-zprof.zsh | 26 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test-zprof.zsh | 29 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/regexp-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/regexp-highlighter.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/regexp-highlighter.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/word-boundary.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/word-boundary.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/word-boundary.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/subexpression.zsh | 2 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/subexpression.zsh | 26 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/subexpression.zsh | 29 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/complex.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/complex.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/regexp/test-data/complex.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/cursor/cursor-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/cursor/cursor-highlighter.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/cursor/cursor-highlighter.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/line/line-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/line/line-highlighter.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/line/line-highlighter.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/root/root-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/root/root-highlighter.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/root/root-highlighter.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/pattern/pattern-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/pattern/pattern-highlighter.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/pattern/pattern-highlighter.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/pattern/test-data/rm-rf.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/pattern/test-data/rm-rf.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/pattern/test-data/rm-rf.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/brackets/brackets-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/brackets/brackets-highlighter.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/brackets/brackets-highlighter.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/brackets/test-data/quoted-patentheses.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/brackets/test-data/quoted-patentheses.zsh | 25 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/brackets/test-data/quoted-patentheses.zsh | 28 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| MEDIUM | highlighters/brackets/test-data/only-error.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| 850 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | zsh-syntax-highlighting.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | zsh-syntax-highlighting.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | zsh-syntax-highlighting.zsh | 141 | # zsh 5.9 or later | COMMENT |
| LOW | zsh-syntax-highlighting.zsh | 301 | # region, paste, isearch, or suffix | COMMENT |
| LOW | zsh-syntax-highlighting.zsh | 381 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | zsh-syntax-highlighting.zsh | 401 | # 2. If zsh has the memo= feature, which is required for interoperability reasons. | COMMENT |
| LOW | tests/test-highlighting.zsh | 1 | #!/usr/bin/env zsh | COMMENT |
| LOW | tests/test-perfs.zsh | 1 | #!/usr/bin/env zsh | COMMENT |
| LOW | tests/test-perfs.zsh | 21 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | COMMENT |
| LOW | tests/generate.zsh | 1 | #!/usr/bin/env zsh | COMMENT |
| LOW | tests/generate.zsh | 21 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | COMMENT |
| LOW | tests/tap-colorizer.zsh | 1 | #!/usr/bin/env zsh | COMMENT |
| LOW | tests/tap-colorizer.zsh | 21 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | COMMENT |
| LOW | tests/test-zprof.zsh | 1 | #!/usr/bin/env zsh | COMMENT |
| LOW | tests/test-zprof.zsh | 21 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | COMMENT |
| LOW | highlighters/regexp/regexp-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/regexp/regexp-highlighter.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | highlighters/regexp/test-data/word-boundary.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/regexp/test-data/subexpression.zsh | 1 | #!/usr/bin/env zsh | COMMENT |
| LOW | highlighters/regexp/test-data/subexpression.zsh | 21 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | COMMENT |
| LOW | highlighters/regexp/test-data/complex.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/cursor/cursor-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/cursor/cursor-highlighter.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | highlighters/line/line-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/line/line-highlighter.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | highlighters/root/root-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/root/root-highlighter.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | highlighters/pattern/pattern-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/pattern/pattern-highlighter.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | highlighters/pattern/test-data/rm-rf.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/brackets-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/test-data/quoted-patentheses.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/test-data/quoted-patentheses.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | highlighters/brackets/test-data/only-error.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/test-data/only-error.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | highlighters/brackets/test-data/loop-styles.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/test-data/nested-parentheses.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | …lighters/brackets/test-data/cursor-matchingbracket.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | …ghlighters/brackets/test-data/mismatch-patentheses.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/test-data/simple-parentheses.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | …ghlighters/brackets/test-data/unclosed-patentheses.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | …hlighters/brackets/test-data/unclosed-patentheses2.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/test-data/near-quotes.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | …ckets/test-data/cursor-matchingbracket-line-finish.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/test-data/empty-styles.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/brackets/test-data/empty-styles.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 201 | # types. | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 321 | typeset -a ZSH_HIGHLIGHT_TOKENS_CONTROL_FLOW | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 501 | # $REPLY: $buf[REPLY] is the last character parsed. | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 521 | # Pattern for parameter names | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 541 | # Only valid when :start: is present | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 561 | # will DTRT regardless of how many elements or repetitions $x has. | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 661 | # The first, outer parenthesis | COMMENT |
| LOW | highlighters/main/test-data/noglob4.zsh | 1 | #!/usr/bin/env zsh | COMMENT |
| LOW | highlighters/main/test-data/path_prefix2.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/main/test-data/vanilla-newline.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/main/test-data/backslash.zsh | 1 | # ------------------------------------------------------------------------------------------------- | COMMENT |
| LOW | highlighters/main/test-data/backslash.zsh | 21 | # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | COMMENT |
| LOW | …hlighters/main/test-data/arithmetic-multiplication.zsh | 1 | #!/usr/bin/env zsh | COMMENT |
| 305 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tests/test-highlighting.zsh | 154 | : ${CURSOR=$#BUFFER} ${PENDING=0} ${WIDGET=z-sy-h-test-harness-test-widget} | CODE |
| MEDIUM | tests/test-highlighting.zsh | 251 | # Run a single test file. The exit status is 1 if the test harness had | COMMENT |
| MEDIUM⚡ | highlighters/main/test-data/precommand-type1.zsh | 38 | # diagnose a message on stdout, and the harness will detect a failure. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | zsh-syntax-highlighting.zsh | 117 | # This function is supposed to be called whenever the ZLE state changes. | COMMENT |
| MEDIUM | highlighters/main/main-highlighter.zsh | 1448 | # This function is currently never called for the command word, so $2 is hard-coded as 0. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | changelog.md | 512 | - Command word after array assignment, `a=(lorem ipsum) pwd`. | CODE |
| LOW⚡ | highlighters/main/test-data/assign-append.zsh | 30 | BUFFER='a+=(lorem ipsum)' | CODE |
| LOW⚡ | highlighters/main/test-data/alias-assignment1.zsh | 32 | aliases[x=y]='lorem ipsum dolor sit amet' | CODE |
| LOW⚡ | highlighters/main/test-data/alias-assignment1.zsh | 32 | aliases[x=y]='lorem ipsum dolor sit amet' | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | highlighters/main/main-highlighter.zsh | 1182 | # Check if $arg is variable assignment | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 1203 | # Check if $1 is a path. | COMMENT |
| LOW | highlighters/main/main-highlighter.zsh | 1235 | # Check if this is a blacklisted path | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test-highlighting.zsh | 134 | # WARNING: The remainder of this anonymous function will run with the test's options in effect | COMMENT |