71 lines
2.2 KiB
Markdown
71 lines
2.2 KiB
Markdown
---
|
|
name: registry_dashboard
|
|
lang: cpp
|
|
domain: tui
|
|
description: "Dashboard ImGui para visualizar el estado del fn_registry: KPIs, charts, tablas, desglose por lenguaje/dominio/pureza"
|
|
tags: [dashboard, imgui, visualization, registry]
|
|
uses_functions:
|
|
- kpi_card_cpp_viz
|
|
- bar_chart_cpp_viz
|
|
- pie_chart_cpp_viz
|
|
- table_view_cpp_viz
|
|
- sparkline_cpp_viz
|
|
- dashboard_panel_cpp_core
|
|
- dashboard_grid_cpp_core
|
|
- fps_overlay_cpp_core
|
|
- fullscreen_window_cpp_core
|
|
uses_types: []
|
|
framework: "imgui"
|
|
entry_point: "main.cpp"
|
|
dir_path: "apps/registry_dashboard"
|
|
repo_url: ""
|
|
---
|
|
|
|
## Arquitectura
|
|
|
|
Dashboard C++ que lee `registry.db` directamente via SQLite C API y visualiza el estado completo del fn_registry.
|
|
|
|
**Data layer** (`data.cpp`): Carga todas las stats, desgloses y listas en un solo paso desde SQLite. Soporte para reload en caliente.
|
|
|
|
**Views** (`views.cpp`): Compone funciones del registry C++ para renderizar:
|
|
- 6 KPI cards: total functions, types, apps, analysis, tested%, pure%
|
|
- Bar charts: funciones por lenguaje, por dominio, actividad ultimos 30 dias
|
|
- Pie charts: pureza (pure/impure), kind (function/pipeline/component), tested/untested
|
|
- Tablas: ultimas 20 funciones, apps, analysis, tipos
|
|
|
|
**Entrada**: Paths a `registry.db` como argumentos con fallback encadenado.
|
|
|
|
## Build
|
|
|
|
```bash
|
|
# Linux
|
|
cd cpp && cmake -B build/linux -S . && cmake --build build/linux --target registry_dashboard -j$(nproc)
|
|
|
|
# Windows (cross-compile)
|
|
cd cpp && cmake -B build/windows -S . -DCMAKE_TOOLCHAIN_FILE=toolchains/mingw-w64.cmake && cmake --build build/windows --target registry_dashboard -j$(nproc)
|
|
```
|
|
|
|
## Ejecucion
|
|
|
|
```bash
|
|
# Linux
|
|
./cpp/build/linux/apps/registry_dashboard/registry_dashboard /home/lucas/fn_registry/registry.db
|
|
|
|
# Windows (PowerShell) — intenta WSL mount, luego local
|
|
.\registry_dashboard.ps1
|
|
|
|
# Otra maquina — copiar .exe + .db al mismo dir
|
|
registry_dashboard.exe .\registry.db
|
|
```
|
|
|
|
## Roadmap
|
|
|
|
- [ ] Integrar Go runtime (CGo) para ejecutar comandos `fn` desde el GUI
|
|
- [ ] Filtros interactivos por lenguaje/dominio en sidebar
|
|
- [ ] Busqueda FTS5 integrada
|
|
- [ ] Detalles de funcion al hacer click en tabla
|
|
|
|
## Notas
|
|
|
|
SQLite compilado estaticamente en Windows via amalgamation vendoreada. En Linux usa libsqlite3 del sistema.
|