Files
fn_registry/bash/functions/pipelines/audit_registry_paths.md
T
egutierrez 988e901066 docs: params/output semántico en 506 funciones para composabilidad
Añade campos params y output al frontmatter YAML de las 506 funciones del registry.
Cada parámetro tiene descripción semántica (qué representa, unidades, rango típico)
y cada función describe qué produce su output. Permite a agentes razonar sobre
cadenas de composición (ej: prices → log_return → sharpe_ratio) sin leer código.
2026-04-05 18:45:16 +02:00

2.3 KiB

name, kind, lang, domain, version, purity, signature, description, tags, uses_functions, uses_types, returns, returns_optional, error_type, imports, params, output, tested, tests, test_file_path, file_path
name kind lang domain version purity signature description tags uses_functions uses_types returns returns_optional error_type imports params output tested tests test_file_path file_path
audit_registry_paths pipeline bash pipelines 1.0.0 impure audit_registry_paths([output_file: string]) -> void Audita file_path de todas las functions y types en registry.db, verifica que cada ruta apunte a un archivo existente en disco, y genera un txt con las rutas rotas para que agentes puedan corregirlas.
registry
audit
validation
paths
launcher
pipeline
bash
assert_command_exists_bash_shell
assert_file_exists_bash_shell
validate_registry_paths_bash_shell
report_execution_json_bash_shell
exit_with_status_bash_shell
false error_go_core
name desc
output_file archivo de salida con rutas rotas (default: broken_paths.txt en raíz)
sin salida directa; genera archivo con rutas inválidas false
bash/functions/pipelines/audit_registry_paths.sh

Ejemplo

# Con default (genera broken_paths.txt en la raiz)
./bash/functions/pipelines/audit_registry_paths.sh

# Con ruta personalizada
./bash/functions/pipelines/audit_registry_paths.sh /tmp/broken.txt

# Desde fn run (pipeline launcher)
fn run audit_registry_paths

Flujo

  1. assert_command_exists — verifica que sqlite3 esta disponible
  2. assert_file_exists — verifica que registry.db existe y reporta su tamano
  3. validate_registry_paths (functions) — itera todas las functions, verifica cada file_path
  4. validate_registry_paths (types) — itera todos los types, verifica cada file_path
  5. Genera broken_paths.txt con formato legible para agentes
  6. report_execution_json — imprime JSON de ejecucion a stdout
  7. exit_with_status — exit code segun resultado

Formato de salida

# Broken file_path entries in registry.db
# Generated: 2026-04-03T10:00:00Z
# Total: 11 broken paths
#
# Format: id | file_path (in .md) | domain | table
# ---

## Functions (11)
cdp_click_go_browser | functions/infra/cdp_click.go | browser | functions

Notas

El archivo de salida es consumible por agentes: cada linea tiene el ID de la funcion/tipo y el file_path que necesita correccion. El agente puede leer el .md correspondiente, encontrar el archivo real en disco, y actualizar el campo file_path.