feat: sistema de personalidades enriquecido + agente template
Fase 1: Sistema de personalidades enriquecido - Ampliar PersonalityCfg con role, backstory, expertise, limitations - Añadir CommunicationCfg (formality, humor, personality, response_style, quirks, catchphrases) - Crear tipos puros en pkg/personality/traits.go - Implementar BuildPersonalityPrompt() para generar bloque de system prompt - Integrar personalidad en agents/runtime.go (FromConfig + concatenacion al system prompt) Fase 2: Agente plantilla - Añadir campo Template bool a AgentMeta - Filtrar agentes template en launcher (skip si template: true) - Crear agents/_template/ con config.yaml completo y documentado - Incluir TODAS las secciones (skills, shared_knowledge, schedules, security) - agent.go minimo + prompts/system.md plantilla - Actualizar dev-scripts/agent/new-agent.sh para copiar desde _template/ Fase 3: Ejemplos de personalidades - Crear agents/_template/PERSONALITIES.md con 4 perfiles: * DevOps pragmatico * Analista meticuloso * Asistente amigable * Guardian de seguridad 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -37,6 +37,43 @@ const (
|
||||
ErrorDetailed ErrorStyle = "detailed"
|
||||
)
|
||||
|
||||
type Formality string
|
||||
|
||||
const (
|
||||
FormalityFormal Formality = "formal"
|
||||
FormalitySemiformal Formality = "semiformal"
|
||||
FormalityCasual Formality = "casual"
|
||||
FormalityColoquial Formality = "coloquial"
|
||||
)
|
||||
|
||||
type Humor string
|
||||
|
||||
const (
|
||||
HumorNone Humor = "none"
|
||||
HumorSubtle Humor = "subtle"
|
||||
HumorModerate Humor = "moderate"
|
||||
HumorFrequent Humor = "frequent"
|
||||
)
|
||||
|
||||
type PersonalityType string
|
||||
|
||||
const (
|
||||
PersonalityAnalytical PersonalityType = "analytical"
|
||||
PersonalityCreative PersonalityType = "creative"
|
||||
PersonalityPragmatic PersonalityType = "pragmatic"
|
||||
PersonalityEmpathetic PersonalityType = "empathetic"
|
||||
PersonalityAssertive PersonalityType = "assertive"
|
||||
)
|
||||
|
||||
type ResponseStyle string
|
||||
|
||||
const (
|
||||
ResponseStructured ResponseStyle = "structured"
|
||||
ResponseConversational ResponseStyle = "conversational"
|
||||
ResponseBulletPoints ResponseStyle = "bullet_points"
|
||||
ResponseNarrative ResponseStyle = "narrative"
|
||||
)
|
||||
|
||||
type Templates struct {
|
||||
Greeting string
|
||||
UnknownCommand string
|
||||
@@ -55,6 +92,16 @@ type Behavior struct {
|
||||
AcknowledgeReceipt bool
|
||||
}
|
||||
|
||||
type Communication struct {
|
||||
Formality Formality
|
||||
Humor Humor
|
||||
Personality PersonalityType
|
||||
ResponseStyle ResponseStyle
|
||||
Quirks []string
|
||||
AvoidTopics []string
|
||||
Catchphrases []string
|
||||
}
|
||||
|
||||
type Personality struct {
|
||||
Tone Tone
|
||||
Verbosity Verbosity
|
||||
@@ -65,6 +112,18 @@ type Personality struct {
|
||||
ErrorStyle ErrorStyle
|
||||
Templates Templates
|
||||
Behavior Behavior
|
||||
|
||||
// Identidad narrativa
|
||||
Role string
|
||||
Backstory string
|
||||
Expertise []string
|
||||
Limitations []string
|
||||
|
||||
// Estilo de comunicacion
|
||||
Communication Communication
|
||||
|
||||
// Directivas personalizadas
|
||||
CustomDirectives []string
|
||||
}
|
||||
|
||||
// DefaultPersonality returns a sensible baseline.
|
||||
|
||||
Reference in New Issue
Block a user