Files
agents_and_robots/agents/asistente-2/agent.go
T
egutierrez 08dcb332b7 refactor: rename agent directories to match agent IDs
Renombrar directorios de agentes para que coincidan exactamente con el
agent.id del config.yaml, eliminando la disonancia entre nombres:
- agents/assistant/ → agents/assistant-bot/ (ID: assistant-bot)
- agents/asistente2/ → agents/asistente-2/ (ID: asistente-2)

Se actualizan los imports en cmd/launcher/main.go, los store_path de
crypto, los paths de storage/logs/audit en ambos configs para que
apunten a ./agents/<agent-id>/data/. También se corrige el memory.db
que se creaba en directorios fantasma fuera del directorio real del
agente.

Se eliminan las referencias a devops-bot en el config de assistant-bot
(peers, delegation).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-06 00:55:09 +00:00

40 lines
1.1 KiB
Go

// Package asistente2 defines the pure rules for the asistente-2 bot.
// This agent uses tool_use (current_time) to demonstrate the tool-use loop.
package asistente2
import (
"github.com/enmanuel/agents/pkg/decision"
)
// Rules returns the decision rules for the asistente-2 bot.
func Rules() []decision.Rule {
return []decision.Rule{
// !help — explicit help command
{
Name: "help",
Match: decision.MatchCommand("help"),
Actions: []decision.Action{{
Kind: decision.ActionKindReply,
Reply: &decision.ReplyAction{
Content: "Soy asistente-2. Puedo responder preguntas y además consultar la hora actual.\n" +
"- Pregúntame cualquier cosa\n" +
"- Puedo decirte la fecha y hora actual\n\n" +
"Escríbeme directamente lo que necesitas.",
},
}},
},
// Any DM or mention → LLM (with tool-use enabled)
{
Name: "llm-all",
Match: func(ctx decision.MessageContext) bool {
return ctx.IsDirectMsg || ctx.IsMention
},
Actions: []decision.Action{{
Kind: decision.ActionKindLLM,
LLM: &decision.LLMAction{},
}},
},
}
}