Repository Analysis

cesanta/mongoose

Embedded web server, with TCP/IP network stack, MQTT and Websocket

6.5 Low AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of cesanta/mongoose, a C project with 13,011 GitHub stars. SynthScan v2.0 examined 1,711,755 lines of code across 2487 source files, recording 17229 pattern matches distributed across 8 syntactic categories. The overall adjusted score of 6.5 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).

6.5
Adjusted Score
6.5
Raw Score
100%
Time Factor
2026-08-28
Last Push
13.0K
Stars
C
Language
1.7M
Lines of Code
2.5K
Files
17.2K
Pattern Hits
2026-08-29
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

This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.

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 7LOW 17222

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

Over-Commented Block17136 hits · 10979 pts
SeverityFileLineSnippetContext
LOWmongoose.h1// Copyright (c) 2004-2013 Sergey LyubkaCOMMENT
LOWmongoose.h21#define MONGOOSE_HCOMMENT
LOWmongoose.h41#define MG_ARCH_CMSIS_RTOS1 9 // CMSIS-RTOS API v1 (Keil RTX)COMMENT
LOWmongoose.h61#if !defined(MG_ARCH) || (MG_ARCH == MG_ARCH_CUSTOM)COMMENT
LOWmongoose.h101#include <stdlib.h>COMMENT
LOWmongoose.h121#include <stdio.h>COMMENT
LOWmongoose.h141#endifCOMMENT
LOWmongoose.h161#ifndef MG_ENABLE_DIRLISTCOMMENT
LOWmongoose.h181#error Select a driver in mongoose_config.hCOMMENT
LOWmongoose.h201// hangs for 10 s, the IWDG fires and the device rolls back.COMMENT
LOWmongoose.h221 } while (0)COMMENT
LOWmongoose.h241#endifCOMMENT
LOWmongoose.h261COMMENT
LOWmongoose.h301#include <errno.h>COMMENT
LOWmongoose.h321#include <soc/soc.h>COMMENT
LOWmongoose.h381 (void) esp_ota_mark_app_invalid_rollback_and_reboot(); \COMMENT
LOWmongoose.h401#include <string.h>COMMENT
LOWmongoose.h421#include <stdarg.h>COMMENT
LOWmongoose.h461#elif defined(CPU_MIMXRT1176DVMAA_cm7) || defined(CPU_MIMXRT1176DVMAA_cm4) || \COMMENT
LOWmongoose.h501#endifCOMMENT
LOWmongoose.h521#define MG_SET_MAC_ADDRESS(mac) (void) (mac)COMMENT
LOWmongoose.h581 RTWDOG_CS_CMD32EN_MASK; \COMMENT
LOWmongoose.h641COMMENT
LOWmongoose.h661#include <pico/unique_id.h>COMMENT
LOWmongoose.h701 BOOT_TYPE_NORMAL | 0x100, 1, 0, 0); \COMMENT
LOWmongoose.h721#include <stdlib.h>COMMENT
LOWmongoose.h741#include <stdint.h>COMMENT
LOWmongoose.h781#if MG_ARCH == MG_ARCH_THREADXCOMMENT
LOWmongoose.h801#endifCOMMENT
LOWmongoose.h821#endifCOMMENT
LOWmongoose.h841COMMENT
LOWmongoose.h861#include <errno.h>COMMENT
LOWmongoose.h881#include <poll.h>COMMENT
LOWmongoose.h901#ifndef MG_ENABLE_POSIX_FSCOMMENT
LOWmongoose.h921#elseCOMMENT
LOWmongoose.h941#ifndef WIN32_LEAN_AND_MEANCOMMENT
LOWmongoose.h961#include <stdarg.h>COMMENT
LOWmongoose.h981typedef int int32_t;COMMENT
LOWmongoose.h1001#if defined(_MSC_VER) && _MSC_VER <= 1200COMMENT
LOWmongoose.h1021#define strdup(x) _strdup(x)COMMENT
LOWmongoose.h1041#define MG_PATH_MAX FILENAME_MAXCOMMENT
LOWmongoose.h1061 WSAGetLastError() == WSAEWOULDBLOCK))COMMENT
LOWmongoose.h1081COMMENT
LOWmongoose.h1101// #include <zephyr/posix/dirent.h>COMMENT
LOWmongoose.h1121#endifCOMMENT
LOWmongoose.h1161#if defined(MG_ENABLE_FREERTOS_TCP) && MG_ENABLE_FREERTOS_TCPCOMMENT
LOWmongoose.h1201#define sin_addr sin_address.ulIP_IPv4COMMENT
LOWmongoose.h1241#if !LWIP_TIMEVAL_PRIVATECOMMENT
LOWmongoose.h1281#endifCOMMENT
LOWmongoose.h1301#define MG_ENABLE_TCPIP 0 // Mongoose built-in network stackCOMMENT
LOWmongoose.h1321#define MG_ENABLE_RL 0 // ARM MDK network stackCOMMENT
LOWmongoose.h1341#define MG_ENABLE_LFS 0COMMENT
LOWmongoose.h1361// mentioned in arch_win32.hCOMMENT
LOWmongoose.h1381COMMENT
LOWmongoose.h1401COMMENT
LOWmongoose.h1421COMMENT
LOWmongoose.h1441 do { \COMMENT
LOWmongoose.h1461#endifCOMMENT
LOWmongoose.h1481#ifndef MG_TCPIP_PREFIX_LENCOMMENT
LOWmongoose.h1501#endifCOMMENT
17076 more matches not shown…
Example Usage Blocks78 hits · 117 pts
SeverityFileLineSnippetContext
LOWmongoose.h1761// Usage example:COMMENT
LOWtest/mongoose.h1761// Usage example:COMMENT
LOWtutorials/websocket/websocket-server/mongoose.h1761// Usage example:COMMENT
LOWtutorials/websocket/json-rpc-over-websocket/mongoose.h1761// Usage example:COMMENT
LOWtutorials/websocket/websocket-client/mongoose.h1761// Usage example:COMMENT
LOW…rt1060-evk-xpresso-baremetal-builtin/source/mongoose.h1761// Usage example:COMMENT
LOW…rdm-rw612-xpresso-freertos-lwip-wifi/source/mongoose.h1761// Usage example:COMMENT
LOW…nxp/frdm-rw612-xpresso-freertos-lwip/source/mongoose.h1761// Usage example:COMMENT
LOW…-rw612-xpresso-freertos-builtin-wifi/source/mongoose.h1761// Usage example:COMMENT
LOWtutorials/core/memory/o1heap/mongoose.h1761// Usage example:COMMENT
LOWtutorials/core/timers/mongoose.h1761// Usage example:COMMENT
LOWtutorials/core/multi-threaded-12m/mongoose.h1761// Usage example:COMMENT
LOWtutorials/core/embedded-filesystem/mongoose.h1761// Usage example:COMMENT
LOWtutorials/core/multi-threaded/mongoose.h1761// Usage example:COMMENT
LOWtutorials/udp/mdns-server/mongoose.h1761// Usage example:COMMENT
LOWtutorials/udp/captive-dns-server/mongoose.h1761// Usage example:COMMENT
LOWtutorials/udp/sntp-time-sync/mongoose.h1761// Usage example:COMMENT
LOWtutorials/udp/mdns-sd-client/mongoose.h1761// Usage example:COMMENT
LOWtutorials/udp/ssdp-search/mongoose.h1761// Usage example:COMMENT
LOWtutorials/udp/mdns-client/mongoose.h1761// Usage example:COMMENT
LOWtutorials/udp/mdns-sd-server/mongoose.h1761// Usage example:COMMENT
LOW…torials/wch/ch32v307-make-baremetal-builtin/mongoose.h1761// Usage example:COMMENT
LOWtutorials/micropython/mongoose/mongoose.h1761// Usage example:COMMENT
LOWtutorials/micropython/esp32/mongoose/mongoose.h1761// Usage example:COMMENT
LOWtutorials/tcp/rtsp-video-stream/mongoose.h1761// Usage example:COMMENT
LOWtutorials/tcp/socks5-server/mongoose.h1761// Usage example:COMMENT
LOWtutorials/tcp/tcp/mongoose.h1761// Usage example:COMMENT
LOWtutorials/tcp/modbus-dashboard/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/redirect-to-https/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/file-upload-multiple-posts/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/huge-response/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/singleton-client/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/http-streaming-client/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/uart-bridge/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/uart-bridge/esp32/main/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/http-server/mongoose.h1761// Usage example:COMMENT
LOW…ials/http/http-server/arduino/teensy41-http/mongoose.h1761// Usage example:COMMENT
LOW…torials/http/http-server/arduino/w5500-http/mongoose.h1761// Usage example:COMMENT
LOW…torials/http/http-server/arduino/esp32-http/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/video-stream/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/http-reverse-proxy/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/link-checker/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/http-client/mongoose.h1761// Usage example:COMMENT
LOW…-client/esp8266/http-client-server/src/main/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/http-proxy-client/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/http-restful-server/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/file-upload-single-post/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/wifi-router-dashboard/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/file-transfer/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/jwt-auth/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/device-dashboard/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/device-dashboard/esp32/main/mongoose.h1761// Usage example:COMMENT
LOW…http/device-dashboard/microchip/same54-xpro/mongoose.h1761// Usage example:COMMENT
LOWtutorials/http/file-upload-html-form/mongoose.h1761// Usage example:COMMENT
LOWtutorials/smtp/smtp-client/mongoose.h1761// Usage example:COMMENT
LOWtutorials/webui/webui-plain/mongoose.h1761// Usage example:COMMENT
LOWtutorials/webui/webui-push-ws/mongoose.h1761// Usage example:COMMENT
LOWtutorials/webui/webui-push-rest/mongoose.h1761// Usage example:COMMENT
LOWtutorials/webui/webui-rest/mongoose.h1761// Usage example:COMMENT
LOWtutorials/webui/webui-preact/mongoose.h1761// Usage example:COMMENT
18 more matches not shown…
Self-Referential Comments5 hits · 15 pts
SeverityFileLineSnippetContext
MEDIUM…12-xpresso-freertos-lwip-wifi/wifi/incl/port/osa/osa.h157 * -# Create a reader writer lockCOMMENT
MEDIUM…m-rw612-xpresso-freertos-lwip/wifi/incl/port/osa/osa.h157 * -# Create a reader writer lockCOMMENT
MEDIUM…-xpresso-freertos-lwip/lwip/codespell_changed_files.sh6# This file is subject to the terms and conditions of the GNU LesserCOMMENT
MEDIUM…dm-rw612-xpresso-freertos-lwip/lwip/codespell_check.sh5# This file is subject to the terms and conditions of the GNU LesserCOMMENT
MEDIUM…xpresso-freertos-builtin-wifi/wifi/incl/port/osa/osa.h157 * -# Create a reader writer lockCOMMENT
Modern AI Meta-Vocabulary2 hits · 5 pts
SeverityFileLineSnippetContext
MEDIUMAGENTS.md237├── ... # IDE-specific project scaffoldingCODE
MEDIUMresources/I-CUBE-Mongoose/README.md172## AI agentic developmentCOMMENT
Slop Phrases2 hits · 3 pts
SeverityFileLineSnippetContext
LOW…rw612-xpresso-freertos-lwip-wifi/lwip/src/core/netif.c281 * IPv6: Don't forget to call netif_create_ip6_linklocal_address() afterCOMMENT
LOW…frdm-rw612-xpresso-freertos-lwip/lwip/src/core/netif.c281 * IPv6: Don't forget to call netif_create_ip6_linklocal_address() afterCOMMENT
AI Slop Vocabulary2 hits · 3 pts
SeverityFileLineSnippetContext
LOW…sso-freertos-lwip-wifi/lwip/src/include/lwip/sockets.h215#define SO_DONTROUTE 0x0010 /* Unimplemented: just use interface addresses */COMMENT
LOW…-xpresso-freertos-lwip/lwip/src/include/lwip/sockets.h215#define SO_DONTROUTE 0x0010 /* Unimplemented: just use interface addresses */COMMENT
Hyper-Verbose Identifiers3 hits · 3 pts
SeverityFileLineSnippetContext
LOW…rtos-lwip-wifi/component/imu_adapter/fsl_adapter_imu.h89typedef hal_imumc_return_status_t (*imumc_rx_callback_t)(void *param, uint8_t *data, uint32_t len);CODE
LOW…-freertos-lwip/component/imu_adapter/fsl_adapter_imu.h88typedef hal_imumc_return_status_t (*imumc_rx_callback_t)(void *param, uint8_t *data, uint32_t len);CODE
LOW…s-builtin-wifi/component/imu_adapter/fsl_adapter_imu.h89typedef hal_imumc_return_status_t (*imumc_rx_callback_t)(void *param, uint8_t *data, uint32_t len);CODE
Verbosity Indicators1 hit · 2 pts
SeverityFileLineSnippetContext
LOW…-rw612-xpresso-freertos-lwip/lwip/src/apps/mdns/mdns.c614 * comparison. So if we get passed the class and type comparison we need to check if theCOMMENT