From 890a44b0caba654c7bb3e7fafef422f1ccb80c50 Mon Sep 17 00:00:00 2001 From: Enmanuel Date: Thu, 9 Apr 2026 21:39:59 +0000 Subject: [PATCH] feat: integrar auto-avatar en pipeline de creacion de agentes create-full.sh ahora genera y aplica un avatar automatico tras registrar el agente en Matrix. Usa agentctl auto-avatar internamente. Si falla (sin internet, proveedor caido), continua sin bloquear el pipeline. Co-Authored-By: Claude Opus 4.6 (1M context) --- dev-scripts/agent/create-full.sh | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/dev-scripts/agent/create-full.sh b/dev-scripts/agent/create-full.sh index dcbd918..b18a00d 100755 --- a/dev-scripts/agent/create-full.sh +++ b/dev-scripts/agent/create-full.sh @@ -56,8 +56,8 @@ echo -e "${BLU}═════════════════════ echo "" # ── Paso 1: Scaffold ───────────────────────────────────────────────────── -TOTAL_STEPS=5 -[[ "$TYPE" == "robot" ]] && TOTAL_STEPS=6 +TOTAL_STEPS=6 +[[ "$TYPE" == "robot" ]] && TOTAL_STEPS=7 info "Paso 1/${TOTAL_STEPS} — Scaffold (agent.go, config.yaml, prompts, launcher)" echo "" @@ -114,6 +114,26 @@ if [[ "$TYPE" == "robot" ]]; then echo "" fi +# ── Paso auto-avatar: Generar avatar automatico ───────────────────────── +AVATAR_STEP=$((TOTAL_STEPS - 1)) +info "Paso ${AVATAR_STEP}/${TOTAL_STEPS} — Generando avatar automatico..." +echo "" + +# Resuelve el binario de agentctl +if [[ -f "$REPO_ROOT/bin/agentctl" ]]; then + CTL="$REPO_ROOT/bin/agentctl" +else + CTL="$GO run -tags goolm ./cmd/agentctl" +fi + +if $CTL auto-avatar "$ID" 2>&1; then + ok "Avatar generado y aplicado" +else + warn "No se pudo generar avatar automatico (se puede hacer despues con: agentctl auto-avatar $ID)" +fi + +echo "" + # ── Paso final: Notificar al developer ─────────────────────────────────── NOTIFY_STEP=$TOTAL_STEPS info "Paso ${NOTIFY_STEP}/${TOTAL_STEPS} — Notificando a desarrolladores..."