Become a cracked AI/ML researcher/engineer with this unconventional textbook covering maths, computing, and ML with intuition.
This report summarizes scanner evidence for HenryNdubuaku/maths-cs-ai-compendium, a TypeScript project with 7,684 GitHub stars. SynthScan examined 30,999 lines of code across 115 source files, recording 36 pattern matches distributed across 5 syntactic categories. The legacy adjusted pattern signal is 2.1 (Low 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.
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.
Can maintainers explain intent, assumptions, and trade-offs? 25 finding(s).
Are imports declared and package/API names verified? 9 finding(s).
Are wrappers, guards, and repeated structures necessary? 10 finding(s).
Which changes need focused human review? 36 finding(s).
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.
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.
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.
The scanner identified 36 distinct pattern matches across 5 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.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | …ogramming/07. vulkan compute and cross-platform GPU.md | 639 | // Step 1: find max (for numerical stability) | COMMENT |
| LOW⚡ | …ogramming/07. vulkan compute and cross-platform GPU.md | 649 | // Step 2: compute exp(x - max) | COMMENT |
| LOW⚡ | …ogramming/07. vulkan compute and cross-platform GPU.md | 654 | // Step 3: sum of exp values | COMMENT |
| LOW⚡ | …ogramming/07. vulkan compute and cross-platform GPU.md | 661 | // Step 4: normalise | COMMENT |
| LOW | …apter 16 - SIMD and GPU programming/03. x86 and AVX.md | 99 | // Step 1: add upper 128 bits to lower 128 bits | COMMENT |
| LOW | …apter 16 - SIMD and GPU programming/03. x86 and AVX.md | 104 | // Step 2: horizontal add within 128-bit register | COMMENT |
| LOW⚡ | chapter 17 - AI inference/04. edge inference.md | 160 | # Step 1: Knowledge distillation (reduce params) | COMMENT |
| LOW⚡ | chapter 17 - AI inference/04. edge inference.md | 165 | # Step 2: Structured pruning (remove 30% of remaining) | COMMENT |
| LOW⚡ | chapter 17 - AI inference/04. edge inference.md | 170 | # Step 3: INT4 quantisation | COMMENT |
| LOW⚡ | …10 - multimodal learning/02. vision language models.md | 309 | # Step 1: Patchify into 4x4 patches -> 4 patches | COMMENT |
| LOW⚡ | …10 - multimodal learning/02. vision language models.md | 315 | # Step 2: Project patches to embedding dim (d=16) | COMMENT |
| LOW⚡ | …10 - multimodal learning/02. vision language models.md | 320 | # Step 3: Create text token embeddings (simulate 3 text tokens) | COMMENT |
| LOW⚡ | …10 - multimodal learning/02. vision language models.md | 323 | # Step 4: Concatenate visual + text tokens | COMMENT |
| LOW⚡ | …10 - multimodal learning/02. vision language models.md | 327 | # Step 5: Single-head self-attention over the combined sequence | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 240 | def d_loss(params, real_data, fake_data): | CODE |
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 242 | fake_score = discriminator(fake_data, params) | CODE |
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 245 | def g_loss(params, fake_data): | CODE |
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 246 | fake_score = discriminator(fake_data, params) | CODE |
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 264 | fake_data = generator(z, params) | CODE |
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 267 | grads = d_grad(params, real_data, fake_data) | CODE |
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 272 | fake_data = generator(z, params) | CODE |
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 273 | grads = g_grad(params, fake_data) | CODE |
| LOW⚡ | …puter vision/04. vision transformers and generation.md | 278 | snapshots.append((step, fake_data.copy())) | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | …putational linguistics/05. advanced text generation.md | 389 | # RAG-style prompt construction | COMMENT |
| MEDIUM | …apter 18 - ML systems design/05. ML design examples.md | 251 | ## 6. Conversational AI (RAG-Based Chatbot) | COMMENT |
| MEDIUM | …apter 18 - ML systems design/05. ML design examples.md | 260 | ### Architecture: Retrieval-Augmented Generation (RAG) | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …IMD and GPU programming/05. triton, TPUs and pallax.md | 312 | def fused_mul_add_relu_kernel(x_ptr, w_ptr, b_ptr, out_ptr, n, BLOCK: tl.constexpr): | CODE |
| LOW | …ta structures and algorithms/05. sorting and search.md | 351 | def longest_common_subsequence(text1, text2): | CODE |
| LOW | …ta structures and algorithms/01. arrays and hashing.md | 333 | def length_of_longest_substring(s): | CODE |
| LOW | chapter 17 - AI inference/01. quantisation.md | 85 | def quantise_tensor_symmetric(tensor, bits=8): | CODE |
| LOW | chapter 17 - AI inference/03. serving and batching.md | 166 | def simulate_continuous_batching(requests, max_batch=8): | CODE |
| LOW | chapter 06 - machine learning/03. deep learning.md | 259 | def scaled_dot_product_attention(Q, K, V): | CODE |
| LOW | …9 - audio and speech/04. speaker and audio analysis.md | 304 | def generate_verification_pairs(key, n_speakers=20, dim=64, n_pairs=2000): | CODE |
| LOW | …tware engineering/04. testing and quality assurance.md | 103 | def test_training_logs_metrics(): | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | chapter 08 - computer vision/05. video and 3D vision.md | 275 | print(f"Error reduction: {(1 - kalman_error/obs_error) * 100:.1f}%") | CODE |
| MEDIUM | chapter 04 - statistics/05. inference.md | 153 | print(f"Error: {abs(pi_estimates[-1] - jnp.pi):.6f}") | CODE |