From 899108e3f873ed5c033c037b7c906604a7392ce1 Mon Sep 17 00:00:00 2001 From: Enmanuel Date: Thu, 9 Apr 2026 20:24:35 +0000 Subject: [PATCH] feat: crear robot test-bot para validar pipeline de creacion MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Robot command-only (type: robot) sin LLM. Scaffold via create-full.sh, registrado en Matrix con E2EE verificado. Config minimo basado en template_robot con encryption habilitada. Archivos: - agents/test-bot/agent.go — Rules() retorna nil (robot) - agents/test-bot/config.yaml — tipo robot, sin LLM - cmd/launcher/main.go — blank import añadido Co-Authored-By: Claude Opus 4.6 (1M context) --- agents/test-bot/agent.go | 18 +++++++++ agents/test-bot/config.yaml | 80 +++++++++++++++++++++++++++++++++++++ cmd/launcher/main.go | 1 + 3 files changed, 99 insertions(+) create mode 100644 agents/test-bot/agent.go create mode 100644 agents/test-bot/config.yaml diff --git a/agents/test-bot/agent.go b/agents/test-bot/agent.go new file mode 100644 index 0000000..eaa2b79 --- /dev/null +++ b/agents/test-bot/agent.go @@ -0,0 +1,18 @@ +// Package test es un agente plantilla (no lanzable). +// Sirve como referencia canonica para crear nuevos agentes. +// Al crear un nuevo agente, new-agent.sh reemplaza test y test-bot. +package test + +import ( + "github.com/enmanuel/agents/agents" + "github.com/enmanuel/agents/pkg/decision" +) + +func init() { + agents.Register("test-bot", Rules) +} + +// Rules devuelve las reglas de este agente (vacio para el template). +func Rules() []decision.Rule { + return nil +} diff --git a/agents/test-bot/config.yaml b/agents/test-bot/config.yaml new file mode 100644 index 0000000..827bca2 --- /dev/null +++ b/agents/test-bot/config.yaml @@ -0,0 +1,80 @@ +# ============================================ +# TEST-BOT — Robot de prueba (command-only, sin LLM) +# ============================================ +# Robot para validar el pipeline de creacion de bots y E2E tests. +# Solo responde a comandos (!xxx). Mensajes normales se ignoran. + +agent: + id: test-bot + name: "Test Bot" + version: "0.1.0" + type: robot + enabled: true + template: false + description: "Robot de prueba para validar el pipeline de creacion de bots" + tags: [test, robot] + +# ============================================ +# PERSONALIDAD (minima para robots) +# ============================================ +personality: + prefix: "" + language: es + +# ============================================ +# MATRIX +# ============================================ +matrix: + homeserver: "${MATRIX_HOMESERVER}" + user_id: "@test-bot:${MATRIX_SERVER_NAME}" + access_token_env: MATRIX_TOKEN_TEST_BOT + device_id: "HXINOYBBUW" + + encryption: + enabled: true + store_path: "./agents/test-bot/data/crypto/" + pickle_key_env: PICKLE_KEY_TEST_BOT + trust_mode: tofu + recovery_key_env: SSSS_RECOVERY_KEY_TEST_BOT + + rooms: + listen: [] + respond: [] + admin: [] + + filters: + command_prefix: "!" + mention_respond: false + dm_respond: false + ignore_bots: true + ignore_users: [] + unauthorized_response: silent + min_power_level: 0 + + threads: + enabled: true + auto_thread: false + +# ============================================ +# SEGURIDAD +# ============================================ +security: + audit: + enabled: false + log_file: "" + log_to_room: "" + include: [] + + secrets: + provider: env + + sanitize: + enabled: false + mode: warn + min_severity: medium + disabled_patterns: [] + + tool_rate_limit: + enabled: false + max_calls_per_min: 10 + cleanup_interval_s: 60 diff --git a/cmd/launcher/main.go b/cmd/launcher/main.go index 678b04b..d7927dc 100644 --- a/cmd/launcher/main.go +++ b/cmd/launcher/main.go @@ -33,6 +33,7 @@ import ( _ "github.com/enmanuel/agents/agents/assistant-bot" _ "github.com/enmanuel/agents/agents/asistente-2" _ "github.com/enmanuel/agents/agents/meteorologo" + _ "github.com/enmanuel/agents/agents/test-bot" ) func main() {