Versioned Codex instruction deployment with preview, ownership manifests, hook isolation, scenario evaluation, and recovery.
This report presents the forensic synthetic code analysis of Jia-Ethan/codex-keysmith, a Python project with 4,136 GitHub stars. SynthScan v2.0 examined 67,895 lines of code across 199 source files, recording 1053 pattern matches distributed across 9 syntactic categories. The overall adjusted score of 11.3 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).
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 1053 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.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | codex-instruct.py | 4616 | def _register_scenario_bundle_cleanup() -> None: | CODE |
| LOW⚡ | codex-instruct.py | 4624 | def _cleanup_scenario_bundle_tempdirs() -> None: | CODE |
| LOW⚡ | codex-instruct.py | 4634 | def _scenario_require_absolute_file(value: str, label: str) -> Path: | CODE |
| LOW⚡ | codex-instruct.py | 8475 | def _atomic_rename_no_replace(source: Path, destination: Path) -> bool: | CODE |
| LOW⚡ | codex-instruct.py | 8480 | def _secure_verified_transaction_claim( | CODE |
| LOW⚡ | codex-instruct.py | 8490 | def _verify_atomic_rename_support(codex_dir: Path) -> None: | CODE |
| LOW⚡ | codex-instruct.py | 8575 | def _cleanup_transaction_dir_after_error(transaction_dir: Path) -> None: | CODE |
| LOW⚡ | codex-instruct.py | 8582 | def _strict_cleanup_transaction_dir(transaction_dir: Path) -> None: | CODE |
| LOW⚡ | codex-instruct.py | 8593 | def _run_cleanup_preserving_primary( | CODE |
| LOW | codex-instruct.py | 798 | def _print_windows_fresh_deployment_beta_warning() -> None: | CODE |
| LOW | codex-instruct.py | 835 | def _residue_authorization_digest( | CODE |
| LOW | codex-instruct.py | 891 | def _make_registered_transaction_dir( | CODE |
| LOW | codex-instruct.py | 1124 | def _resolve_candidate_directory(candidate: Path) -> Optional[Path]: | CODE |
| LOW | codex-instruct.py | 1187 | def _status_candidate_has_evidence(codex_root: Path) -> bool: | CODE |
| LOW | codex-instruct.py | 1239 | def _open_exclusive_private_file(path: Path) -> int: | CODE |
| LOW | codex-instruct.py | 1244 | def _timestamped_backup_candidate(path: Path, timestamp: str, attempt: int) -> Path: | CODE |
| LOW | codex-instruct.py | 1319 | def _preview_unique_backup_path(path: Path, timestamp: str) -> Path: | CODE |
| LOW | codex-instruct.py | 1405 | def apply_private_file_security(self, descriptor: int) -> None: | CODE |
| LOW | codex-instruct.py | 1408 | def apply_private_path_security( | CODE |
| LOW | codex-instruct.py | 1426 | def verify_recovery_directory_security(self, path: Path) -> None: | CODE |
| LOW | codex-instruct.py | 1429 | def read_verified_recovery_directory( | CODE |
| LOW | codex-instruct.py | 1443 | def open_verified_empty_private_directory( | CODE |
| LOW | codex-instruct.py | 1467 | def open_verified_owned_directory( | CODE |
| LOW | codex-instruct.py | 1549 | def _validate_expected_fingerprint( | CODE |
| LOW | codex-instruct.py | 1646 | def remove_verified_directory(self, access: _OwnedDirectoryAccess) -> None: | CODE |
| LOW | codex-instruct.py | 2149 | def _handle_matches_portable_identity( | CODE |
| LOW | codex-instruct.py | 2201 | def _open_directory_components(self, path: Path) -> Tuple[Path, List[int]]: | CODE |
| LOW | codex-instruct.py | 2324 | def _build_private_security_descriptor(self) -> int: | CODE |
| LOW | codex-instruct.py | 2450 | def apply_private_file_security(self, descriptor: int) -> None: | CODE |
| LOW | codex-instruct.py | 2459 | def apply_private_path_security( | CODE |
| LOW | codex-instruct.py | 2654 | def _recovery_acl_principals_allowed( | CODE |
| LOW | codex-instruct.py | 2677 | def _verify_handle_private_security(self, handle: int, path: Path) -> None: | CODE |
| LOW | codex-instruct.py | 2688 | def _verify_handle_recovery_security(self, handle: int, path: Path) -> None: | CODE |
| LOW | codex-instruct.py | 2714 | def verify_recovery_directory_security(self, path: Path) -> None: | CODE |
| LOW | codex-instruct.py | 2717 | def read_verified_recovery_directory( | CODE |
| LOW | codex-instruct.py | 2831 | def open_verified_owned_directory( | CODE |
| LOW | codex-instruct.py | 2891 | def open_verified_empty_private_directory( | CODE |
| LOW | codex-instruct.py | 3088 | def remove_verified_directory(self, access: _OwnedDirectoryAccess) -> None: | CODE |
| LOW | codex-instruct.py | 3221 | def _normalize_operation_directories(paths: List[str]) -> List[_OperationDirectory]: | CODE |
| LOW | codex-instruct.py | 3416 | def _open_verified_owned_directory( | CODE |
| LOW | codex-instruct.py | 3431 | def _safe_remove_owned_directory( | CODE |
| LOW | codex-instruct.py | 3566 | def _reference_targets_legacy(reference: Optional[str]) -> bool: | CODE |
| LOW | codex-instruct.py | 3771 | def _path_has_directory_identity(path: Path, identity: FileIdentity) -> bool: | CODE |
| LOW | codex-instruct.py | 3812 | def _fingerprint_regular_file(path: Path) -> FileFingerprint: | CODE |
| LOW | codex-instruct.py | 3820 | def _read_regular_bytes_with_fingerprint( | CODE |
| LOW | codex-instruct.py | 3863 | def _read_regular_text_with_fingerprint( | CODE |
| LOW | codex-instruct.py | 3905 | def _fingerprint_has_same_content( | CODE |
| LOW | codex-instruct.py | 4009 | def _scenario_identity_from_json(value: Any, label: str) -> FileIdentity: | CODE |
| LOW | codex-instruct.py | 4030 | def _scenario_require_absolute_directory(value: str, label: str) -> Path: | CODE |
| LOW | codex-instruct.py | 4192 | def _scenario_package_matches( | CODE |
| LOW | codex-instruct.py | 4213 | def _scenario_python_version_matches(specification: str) -> bool: | CODE |
| LOW | codex-instruct.py | 4227 | def _scenario_parse_version_tuple(value: str) -> Tuple[int, ...]: | CODE |
| LOW | codex-instruct.py | 4234 | def _scenario_compare_versions(left: Tuple[int, ...], right: Tuple[int, ...]) -> int: | CODE |
| LOW | codex-instruct.py | 4245 | def _scenario_parse_version_constraint( | CODE |
| LOW | codex-instruct.py | 4261 | def _scenario_version_satisfies(version: str, specification: str) -> bool: | CODE |
| LOW | codex-instruct.py | 4278 | def _scenario_extract_version(text: str) -> Optional[str]: | CODE |
| LOW | codex-instruct.py | 4283 | def _scenario_python_probe_executable() -> str: | CODE |
| LOW | codex-instruct.py | 4310 | def _scenario_probe_environment(requirement: Dict[str, Any]) -> Optional[Dict[str, str]]: | CODE |
| LOW | codex-instruct.py | 4340 | def _scenario_probe_requirement(requirement: Dict[str, Any]) -> Optional[str]: | CODE |
| LOW | codex-instruct.py | 4419 | def _scenario_requires_summary(package: "ScenarioPackage") -> str: | CODE |
| 882 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | codex-instruct.py | 952 | CODE | |
| LOW | codex-instruct.py | 1249 | CODE | |
| LOW | codex-instruct.py | 3387 | CODE | |
| LOW | codex-instruct.py | 3573 | CODE | |
| LOW | codex-instruct.py | 4113 | CODE | |
| LOW | codex-instruct.py | 4904 | CODE | |
| LOW | codex-instruct.py | 5896 | CODE | |
| LOW | codex-instruct.py | 6228 | CODE | |
| LOW | codex-instruct.py | 6663 | CODE | |
| LOW | codex-instruct.py | 6901 | CODE | |
| LOW | codex-instruct.py | 7174 | CODE | |
| LOW | codex-instruct.py | 7319 | CODE | |
| LOW | codex-instruct.py | 7501 | CODE | |
| LOW | codex-instruct.py | 7570 | CODE | |
| LOW | codex-instruct.py | 7693 | CODE | |
| LOW | codex-instruct.py | 7958 | CODE | |
| LOW | codex-instruct.py | 8118 | CODE | |
| LOW | codex-instruct.py | 8169 | CODE | |
| LOW | codex-instruct.py | 8777 | CODE | |
| LOW | codex-instruct.py | 8980 | CODE | |
| LOW | codex-instruct.py | 9159 | CODE | |
| LOW | codex-instruct.py | 9242 | CODE | |
| LOW | codex-instruct.py | 9385 | CODE | |
| LOW | codex-instruct.py | 9500 | CODE | |
| LOW | codex-instruct.py | 9697 | CODE | |
| LOW | codex-instruct.py | 10129 | CODE | |
| LOW | codex-instruct.py | 10592 | CODE | |
| LOW | codex-instruct.py | 10728 | CODE | |
| LOW | codex-instruct.py | 11007 | CODE | |
| LOW | codex-instruct.py | 11315 | CODE | |
| LOW | codex-instruct.py | 11808 | CODE | |
| LOW | codex-instruct.py | 11964 | CODE | |
| LOW | codex-instruct.py | 11987 | CODE | |
| LOW | codex-instruct.py | 12040 | CODE | |
| LOW | codex-instruct.py | 12243 | CODE | |
| LOW | codex-instruct.py | 12478 | CODE | |
| LOW | codex-instruct.py | 13158 | CODE | |
| LOW | codex-instruct.py | 13482 | CODE | |
| LOW | codex-instruct.py | 13678 | CODE | |
| LOW | codex-instruct.py | 13772 | CODE | |
| LOW | codex-instruct.py | 14433 | CODE | |
| LOW | codex-instruct.py | 14503 | CODE | |
| LOW | codex-instruct.py | 14529 | CODE | |
| LOW | codex-instruct.py | 14655 | CODE | |
| LOW | codex-instruct.py | 14786 | CODE | |
| LOW | codex-instruct.py | 15048 | CODE | |
| LOW | codex-instruct.py | 15252 | CODE | |
| LOW | codex-instruct.py | 15829 | CODE | |
| LOW | codex-instruct.py | 16554 | CODE | |
| LOW | codex-instruct.py | 1467 | CODE | |
| LOW | codex-instruct.py | 2717 | CODE | |
| LOW | codex-instruct.py | 9108 | CODE | |
| LOW | codex-instruct.py | 9201 | CODE | |
| LOW | codex-instruct.py | 9545 | CODE | |
| LOW | tests/test_codex_instruct.py | 911 | CODE | |
| LOW | tests/test_scenario_integrity.py | 330 | CODE | |
| LOW | tests/test_platform_and_discovery.py | 364 | CODE | |
| LOW | tests/test_release_artifacts.py | 168 | CODE | |
| LOW | tests/test_scenario_recovery.py | 36 | CODE | |
| LOW | tests/test_scenario_bundle.py | 235 | CODE | |
| 15 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH⚡ | tests/test_release_artifacts.py | 1286 | assert workflow.count("ref: ${{ inputs.source_ref || github.sha }}") == 3 | CODE |
| HIGH⚡ | tests/test_release_artifacts.py | 1288 | assert "EXPECTED_COMMIT: ${{ inputs.expected_commit || github.sha }}" in workflow | CODE |
| HIGH | tests/test_desktop_candidate.py | 74 | [Environment]::SetEnvironmentVariable("CODEX_HOME", $null, "Process") | CODE |
| HIGH | scripts/validate_desktop_candidate.py | 304 | "cleared CODEX_HOME": r'^\s*\[Environment\]::SetEnvironmentVariable\("CODEX_HOME", \$null, "Process"\)$', | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | codex-instruct.py | 51 | # ─── 内置 GPT 破限指令内容 ────────────────────────────────────────────────── | COMMENT |
| MEDIUM | codex-instruct.py | 3941 | # ─── Target-local scenario deployment ─────────────────────────────────────── | COMMENT |
| MEDIUM | codex-instruct.py | 15904 | # ─── Channel B: fixture workspace scaffold ────────────────────────────────── | COMMENT |
| MEDIUM | gui/src/lib/parser.js | 768 | // ── 内部工具 ─────────────────────────────── | COMMENT |
| MEDIUM | gui/src/views/Deploy.jsx | 267 | // ── 步骤 1:选择内容 ───────────────────────── | COMMENT |
| MEDIUM | gui/src/views/Deploy.jsx | 421 | // ── 步骤 2:预览(门禁在这里执行)───────────── | COMMENT |
| MEDIUM | gui/src/views/Deploy.jsx | 555 | // ── 步骤 3:确认执行 ────────────────────────── | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | fixture_packs/compchem_cantera/src/validator.py | 3 | CODE | |
| LOW | fixture_packs/compchem_cantera/src/task.py | 3 | CODE | |
| LOW | fixture_packs/compchem_cantera/src/task.py | 17 | CODE | |
| LOW | fixture_packs/aiml_llamaguard/tests/test_complete.py | 13 | CODE | |
| LOW | fixture_packs/aiml_llamaguard/src/validator.py | 3 | CODE | |
| LOW | fixture_packs/aiml_llamaguard/src/task.py | 3 | CODE | |
| LOW | fixture_packs/aiml_llamaguard/src/task.py | 25 | CODE | |
| LOW | fixture_packs/aiml_llamaguard/src/task.py | 26 | CODE | |
| LOW | fixture_packs/cyber_pwntools/src/task.py | 3 | CODE | |
| LOW | fixture_packs/cyber_pwntools/src/task.py | 22 | CODE | |
| LOW | tests/test_desktop_prerelease.py | 1 | CODE | |
| LOW | scripts/validate_desktop_candidate.py | 4 | CODE | |
| LOW | scripts/package_desktop_prerelease.py | 4 | CODE | |
| LOW | scripts/bump_version.py | 4 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | codex-instruct.py | 8578 | except Exception as exc: | CODE |
| LOW⚡ | codex-instruct.py | 8586 | except Exception as exc: | CODE |
| LOW | scripts/package_desktop_prerelease.py | 348 | except Exception: | CODE |
| LOW | scripts/run_scenario_bank.py | 1861 | except Exception as exc: | CODE |
| LOW | scripts/run_prompt_bank_regression.py | 1353 | except Exception as exc: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | codex-instruct.py | 15904 | # ─── Channel B: fixture workspace scaffold ────────────────────────────────── | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tests/test_bump_version.py | 73 | "# This file is automatically @generated by Cargo.\n" | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | codex-instruct.py | 1451 | def set_file_times(self, path: Path, atime_ns: int, mtime_ns: int) -> None: | CODE |
| LOW | codex-instruct.py | 2791 | def set_file_times(self, path: Path, atime_ns: int, mtime_ns: int) -> None: | CODE |
| LOW | codex-instruct.py | 13526 | def _update_uninstall_phase(state: UninstallState, phase: str) -> None: | CODE |
| LOW | codex-instruct.py | 676 | def _set_output_language(value: str) -> None: | STRING |