Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,15 +150,20 @@ Unindexed, tactical log analysis operating at 0.07 GB/sec. It streams massive da
### [AI Agent Guardrails & Codebase Protection](gitgalaxy/tools/ai_guardrails/)
Specialized keyword sensors protecting both your application and your codebase. The AppSec Sensor detects weaponized LLM features (RCE funnels, exfiltration risks), while the Dev Agent Firewall evaluates token mass and blast radius to restrict autonomous coding agents from modifying dangerous over context token-draining files. Helps identify which files need to be chunked to reduce context overload.

## Local Browser-Based 3D Codebase Visualization
## Local Browser-Based 3D Codebase Visualization

If you prefer visual analytics, we've built a non-numerical dashboard where each file represents a star, sized and colored according to specific risk metrics.

Simply drag and drop your generated `your_repo_GPU_galaxy.json` file (or a `.zip` of your raw repository) directly into [GitGalaxy.io](https://gitgalaxy.io/). All rendering and scanning happens entirely in your browser's local memory.

![GitGalaxy 3D structural mapping of API exposure and state flux risks in the Apollo 11 legacy codebase](https://raw.githubusercontent.com/squid-protocol/gitgalaxy/main/docs/wiki/assets/apollo-11_state_flux.png)
### 🔭 Watch GitGalaxy in Action

![GitGalaxy native SQLite3 database schema for AST-free enterprise codebase mapping and cybersecurity auditing](https://raw.githubusercontent.com/squid-protocol/gitgalaxy/main/docs/wiki/assets/sqlite_overview.png)
**Mapping 3.2 Million Lines of C++ in 11 Seconds | OpenCV** [![OpenCV Demo](https://img.youtube.com/vi/3ScQCSUBdZw/maxresdefault.jpg)](https://youtu.be/3ScQCSUBdZw)

**Visualizing Architectural Risk | Ruby on Rails** [![Ruby on Rails Demo](https://img.youtube.com/vi/3ScQCSUBdZw/maxresdefault.jpg)](https://youtu.be/3ScQCSUBdZw)
*(Note: Replace the video IDs in this link with your actual Rails video ID)*

![GitGalaxy Meta Visualizer 3D star map rendering complex software repository structures and K-means clustering archetypes in the browser](https://raw.githubusercontent.com/squid-protocol/gitgalaxy/main/docs/wiki/assets/metavisualizer.png)

## Zero-Trust Data Security

Expand All @@ -168,10 +173,6 @@ Your code never leaves your machine. GitGalaxy performs 100% of its scanning and
* **Ephemeral Memory Processing:** Repositories are unpacked into a volatile memory buffer (RAM) and are automatically purged when the browser tab is closed.
* **Privacy-by-Design:** Even when using the web-based viewer, the data remains behind the user's firewall at all times.

![GitGalaxy interactive WebGPU data HUD displaying real-time software architecture metrics, forensic analysis, and file-level risk telemetry](https://raw.githubusercontent.com/squid-protocol/gitgalaxy/main/docs/wiki/assets/data_hud.png)

![GitGalaxy Meta Visualizer 3D star map rendering complex software repository structures and K-means clustering archetypes in the browser](https://raw.githubusercontent.com/squid-protocol/gitgalaxy/main/docs/wiki/assets/metavisualizer.png)

## License & Copyright

Copyright (c) 2026 Joe Esquibel
Expand Down
29 changes: 29 additions & 0 deletions docs/wiki/LLM-reports/AFNetworking_llm_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Architectural Brief: AFNetworking

## 1. Information Flow & Purpose (The Executive Summary)
The `AFNetworking` repository serves as a robust networking infrastructure layer for Apple platforms, heavily utilizing Objective-C (57.8% of the codebase). The primary information flow ingests HTTP requests, processes them through dedicated serialization objects, executes them asynchronously via session managers, and handles the subsequent response deserialization.

The system maps globally to a `Cluster 4` archetype but registers a high Architectural Drift Z-Score of 5.585. This deviation is characteristic of legacy Objective-C frameworks that rely extensively on category extensions (e.g., the `UIKit+AFNetworking` directory) and heavy delegate/block callbacks, diverging from more modern, strict object-oriented modularity.

## 2. Notable Structures & Architecture
The architecture relies on a clear separation between protocol definitions and high-level orchestration.
* **Foundational Load-Bearers:** Core protocol headers like `AFURLResponseSerialization.h`, `AFURLRequestSerialization.h`, and `AFURLSessionManager.h` act as the structural pillars of the system. They possess the highest inbound dependencies, meaning the rest of the application relies strictly on their contracts.
* **Fragile Orchestrators:** Files like `AFHTTPSessionManager.m` and the umbrella `AFNetworking.h` header exhibit high outbound coupling. `AFHTTPSessionManager.m` acts as the primary traffic controller, bridging serialization logic with NSURLSession APIs, making it highly susceptible to cascading changes if underlying interfaces mutate.

## 3. Security & Vulnerabilities
**✅ SECURE: No Malware Detected.** The XGBoost Structural DNA model found no malicious artifacts, and ecosystem audits confirm 0 binary anomalies and 0 blacklisted dependencies.

The security lens flagged several certificates in the `Example/Certificates` and `Tests/Resources` directories (e.g., `adn.cer`, `root_ca.cer`) with 100% "Hardcoded Payload" exposure. In the context of a networking library, these are safe test fixtures and public keys required for testing SSL/TLS certificate pinning, not leaked secrets. Minor raw memory manipulation signatures in serialization headers are expected given the low-level byte stream parsing required for HTTP body construction.

## 4. Outliers & Extremes
The repository contains several massive central hubs that exhibit concentrated technical debt and complexity bottlenecks:
* **The Serialization God Node:** `AFURLRequestSerialization.m` is a massive structural outlier with a Cumulative Risk of 488.68 and a total Mass of 2330.4. It contains O(2^N) recursive algorithmic bottlenecks in its `requestBySerializingRequest` logic, alongside an 81% Tech Debt exposure and 25 orphaned functions (design slop).
* **House of Cards Interfaces:** `AFURLResponseSerialization.h` and `AFURLSessionManager.h` are highly embedded within the system (1-2 hops from most files) but carry severe Error Risk exposures (66%-70%). A runtime exception or unhandled state mutation here will instantly cascade across the network layer.
* **Blind Bottlenecks:** Core logic files like `AFSecurityPolicy.m` and `AFHTTPSessionManager.m` govern critical execution paths but lack structured documentation or ownership metadata (100% Doc Risk), effectively making modifications to these high-blast-radius files a blind operation.

## 5. Recommended Next Steps (Refactoring for Stability)
To stabilize the architecture and reduce the blast radius of central networking singletons, prioritize the following efforts:

1. **Decompose Request Serialization:** `AFURLRequestSerialization.m` violates the Single Responsibility Principle. Extract the query string parameterization, multipart form boundary construction, and HTTP header management into isolated, testable utility classes to reduce the O(2^N) complexity bottlenecks and cognitive load.
2. **Fortify 'House of Cards' Interfaces:** Add strict nullability annotations, defensive assertions, and robust JSDoc-style docstrings to `AFURLResponseSerialization.h` and `AFURLSessionManager.h`. Because these files are deeply embedded, reducing their Error Risk exposure prevents systemic crashes.
3. **Prune Design Slop:** Execute a targeted cleanup of the graveyard code. Remove the 29 orphaned functions in `AFHTTPSessionManagerTests.m`, 27 in `AFURLSessionManager.m`, and 25 in `AFURLRequestSerialization.m` to eliminate visual clutter and lower the repository's baseline technical debt.
21 changes: 21 additions & 0 deletions docs/wiki/LLM-reports/Adafruit_CircuitPython_Bundle_llm_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Architectural Brief: Adafruit_CircuitPython_Bundle

## 1. Information Flow & Purpose (The Executive Summary)
The `Adafruit_CircuitPython_Bundle` repository functions primarily as a documentation, configuration, and distribution hub rather than a complex execution environment. The scanned visible matter is exceptionally small, consisting of only 8 artifacts comprising 24 lines of executable code, predominantly simple utility scripts (Python, Shell) and Markdown. The presence of 854 "Dark Matter" artifacts indicates the repository heavily relies on unanalyzed binaries, external submodules, or asset bundles. The system aligns with a `Cluster 3` archetype, which is consistent with its role as a static packaging and orchestration repository.

## 2. Notable Structures & Architecture
The architecture is entirely flat and decoupled. The dependency graph registers zero inbound or outbound connections among the core repository files (e.g., `circuitpython_library_list.md`, `requirements.txt`, `README.txt`). This confirms the repository acts as a static collection of assets and metadata rather than a cohesive software application. Execution flow is restricted to isolated utility scripts that do not form a broader dependency tree.

## 3. Security & Vulnerabilities
**✅ SECURE: No Malware Detected.** The XGBoost Structural DNA model found no malicious artifacts. Ecosystem security audits confirm 0 binary anomalies and 0 blacklisted dependencies. The repository is structurally secure from recognized threats, and no agentic RCE, memory corruption, or prompt injection surfaces were detected.

## 4. Outliers & Extremes
While the overall code footprint is negligible, the two execution scripts exhibit high relative risk exposures due to a complete lack of structural guardrails:
* **Utility Script Tech Debt:** `update-submodules.sh` registers a 100% Tech Debt Exposure score and the highest cumulative risk (250.93) in the repository. It contains orphaned functions (design slop) and lacks defensive safety nets.
* **Unverified I/O Operations:** `add_import_names.py` carries 97.7% Verification (Testing) Risk and 100% Specification Match Risk. It represents the highest I/O latency risk in the scanned perimeter but operates without formal test coverage or architectural documentation.

## 5. Recommended Next Steps (Refactoring for Stability)
To stabilize the utility pipelines and reduce the structural risk of the repository's active logic, prioritize the following actions:

1. **Formalize Python Utilities:** Add baseline unit tests and standard docstrings to `add_import_names.py` to mitigate the extreme verification and specification risks. Utilities handling I/O operations must be validated.
2. **Resolve Shell Script Tech Debt:** Audit and refactor `update-submodules.sh` to remove the flagged orphaned functions. Addressing the 100% Tech Debt exposure ensures the submodule synchronization pipeline remains deterministic and maintainable.
30 changes: 30 additions & 0 deletions docs/wiki/LLM-reports/Alamofire_llm_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Architectural Brief: Alamofire

## 1. Information Flow & Purpose (The Executive Summary)
The `Alamofire` repository is a robust, protocol-oriented HTTP networking library for Apple platforms, written predominantly in Swift (67.4% of the codebase). Information flows from public-facing configuration APIs down through request serialization, asynchronous dispatch (via `URLSession` delegates), and response handling.

The system maps globally to a `Cluster 4` archetype but registers a highly abnormal Architectural Drift Z-Score of 7.208. This extreme deviation is characteristic of a framework that heavily leverages Swift extensions, closures, and protocol-oriented programming to wrap and abstract legacy Foundation networking APIs, resulting in a unique structural topology.

## 2. Notable Structures & Architecture
The architecture is anchored by a centralized public API with heavily decoupled internal processing.
* **Foundational Load-Bearers:** `Source/Alamofire.swift` is the primary load-bearing pillar, registering 29 inbound connections. It acts as the central ingress point for the library, meaning its contracts are highly coupled to the rest of the application space.
* **Fragile Orchestrators:** Files like `Source/Features/MultipartFormData.swift` and `Source/Features/Combine.swift` act as orchestrators. They exhibit higher outbound dependencies as they translate specific feature requests (like multipart encoding or Combine publisher streams) into the core networking logic.

## 3. Security & Vulnerabilities
**✅ SECURE: No Malware Detected.** The XGBoost Structural DNA model found no malicious artifacts. Ecosystem audits confirm 0 binary anomalies and 0 blacklisted dependencies.

The rule-based lens flagged several files with 100% "Hardcoded Payload Artifacts" exposure (e.g., `alamofire-root-ca.cer`, `expired.cer`). Given the context of a networking library, these are safely located within the `Tests/Resources/Certificates/` directory. They are benign test fixtures required for validating SSL/TLS certificate pinning and server trust evaluation workflows, not leaked operational secrets.

## 4. Outliers & Extremes
The repository contains concentrated complexity and structural density within core delegate mapping and test files:
* **Algorithmic Choke Points:** `Source/Core/SessionDelegate.swift` exhibits severe O(2^N) recursive algorithmic complexity across multiple overloaded `urlSession` functions. It acts as a massive routing hub for asynchronous callbacks.
* **Blind Bottlenecks:** `Source/Core/SessionDelegate.swift` and `Source/Features/Combine.swift` both carry a 100% Documentation Risk despite having significant blast radii. Modifying these highly embedded files relies heavily on tacit knowledge rather than explicit, documented intent.
* **Test Suite Mass:** `Tests/SessionTests.swift` holds the highest cumulative risk in the repository (522.73). While high risk in test suites is less critical than in production code, it indicates a massive, complex file that frequently mutates.
* **Key Person Silos (Bus Factor):** Jon Shier holds 100% isolated ownership over `Source/Core/AFError.swift` (Mass: 143.72), creating a structural knowledge silo around the library's core error-handling types.

## 5. Recommended Next Steps (Refactoring for Stability)
To stabilize the internal routing architecture and mitigate documentation and ownership risks, prioritize the following engineering efforts:

1. **Refactor the Delegate Hub:** Decompose the overloaded `urlSession` methods within `Source/Core/SessionDelegate.swift`. Extract the specific state management and routing logic into isolated, testable strategy objects to reduce the O(2^N) time complexity and lower the cognitive load.
2. **Illuminate Blind Bottlenecks:** Mandate comprehensive docstrings and structural documentation for `Source/Core/SessionDelegate.swift` and `Source/Features/Combine.swift`. Because they act as core infrastructure bridges, reducing their 100% Documentation Risk is critical to preventing accidental architectural drift.
3. **Distribute Core Error Handling Knowledge:** Break the single-developer ownership isolation on `Source/Core/AFError.swift`. Enforce cross-team code reviews and assign secondary maintainers to this file to eliminate the Key Person dependency.
28 changes: 28 additions & 0 deletions docs/wiki/LLM-reports/Apollo-11_llm_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Architectural Brief: Apollo-11

## 1. Information Flow & Purpose (The Executive Summary)
The `Apollo-11` repository is a historical digitization of the original Apollo Guidance Computer (AGC) source code for both the Command Module (Comanche055) and the Lunar Module (Luminary099). Comprising nearly 75,000 lines of AGC Assembly language (69.5%), the system's primary information flow involves deterministic, real-time interrupt processing, sensor data ingestion (IMU, radar), and highly constrained orbital mechanics and thrust calculations.

The architecture maps to a `Cluster 4` archetype with a highly abnormal Architectural Drift Z-Score of 5.435. This extreme deviation is entirely expected; modern architectural archetypes (which GitGalaxy's engine is trained on) do not map cleanly to 1960s-era rope-memory assembly designed for an esoteric 16-bit processor. The system represents the purest form of "Non-AI / Traditional" deterministic state-machine logic.

## 2. Notable Structures & Architecture
The network topology reveals a Modularity of 0.0, indicating a monolithic, globally coupled structure where isolated micro-boundaries do not exist.
* **Foundational Load-Bearers:** Unlike modern codebases with utility libraries, the AGC codebase relies on shared registers, global memory flags, and absolute hardware addresses. Therefore, specific program files (like `Luminary099/R31.agc`) act as entry points to shared logic blocks rather than traditional imported libraries.
* **Fragile Orchestrators:** Files acting as operational hubs exhibit the highest outbound coupling. `Comanche055/TAGS_FOR_RELATIVE_SETLOC.agc` and `Comanche055/P20-P25.agc` act as massive routing hubs, dispatching subroutine calls and state changes based on DSKY (Display and Keyboard) inputs or interrupt timers.

## 3. Security & Vulnerabilities
**✅ SECURE: No Malware Detected.** The XGBoost Structural DNA model found no malicious artifacts within the source code.

The rule-based lens flagged several files with "Raw Memory Manipulation" signatures (e.g., `PINBALL_NOUN_TABLES.agc`). In the context of AGC assembly, this is fundamental operational behavior. The code relies on hardcoded memory addresses, bit-masking, and raw pointer manipulation to manage its highly constrained RAM and ROM. Additionally, files like `EXTENDED_VERBS.agc` triggered "Exploit Generation Surface" alerts; this reflects the DSKY interface's ability to directly modify execution state based on external (astronaut) input, which in a modern context resembles an injection surface, but here is the designed method of control.

## 4. Outliers & Extremes
The repository contains extreme structural density and cognitive friction, reflecting the constraints of 1960s aerospace engineering:
* **Algorithmic Choke Points:** Severe O(2^N) recursive complexity exists across core executive and autopilot loops (e.g., `EXECUTIVE.agc`, `CM_ENTRY_DIGITAL_AUTOPILOT.agc`). In this context, this represents intentional tight polling loops and interrupt handlers checking hardware states, not modern algorithmic inefficiency.
* **The Interpreter Monoliths:** `Comanche055/INTERPRETER.agc` and `Luminary099/INTERPRETER.agc` exhibit massive cognitive load (~58%) and structural mass. They act as the virtual machine translating complex vector and matrix math into native AGC instructions, serving as a massive 'God Node' bottleneck for all guidance calculations.
* **Extreme Tech Debt via Hardcoding:** Files such as `INTER-BANK_COMMUNICATION.agc` and `ALARM_AND_ABORT.agc` register 99.9% Tech Debt Exposure. This is driven by the extensive use of hardcoded bank switching, absolute memory addresses, and 'magic numbers' required to maneuver logic across physical rope memory banks.

## 5. Recommended Next Steps (Refactoring for Stability)
*(Note: As this is a historical artifact, "refactoring" applies to modernizing the simulation, understanding, or porting of the logic, rather than modifying the original historical source).*

1. **Decompose the Interpreter VMs:** To understand or port the matrix operations, `INTERPRETER.agc` must be conceptually decomposed. Extract and document the individual operational opcodes (like `OPJUMP3` and `MAXDV`) into isolated, testable modules in a modern high-level language before attempting to port the broader orbital equations.
2. **Map the Blind Bottlenecks:** Address the 100% Documentation Risk on critical state hubs like `EXECUTIVE.agc` and `MAIN.agc`. Modern maintainers or researchers should prioritize creating supplementary documentation or AST overlays to map the hardcoded interrupts and bank-switches, as modifying this logic blindly risks breaking the emulated state machine.
Loading
Loading