runtime: sync router/gateway/config policy and clan role registry
This commit is contained in:
@@ -79,6 +79,7 @@ ACK_TEMPLATES: Dict[str, str] = {
|
||||
"clan": "Spirit на зв'язку. Запитай — відповім.",
|
||||
"eonarch": "EONARCH тут. Чекаю на ваше питання.",
|
||||
"senpai": "SENPAI на зв'язку. Запитайте — допоможу.",
|
||||
"oneok": "1OK на зв'язку. Готовий допомогти з вікнами, заміром і КП.",
|
||||
}
|
||||
|
||||
|
||||
@@ -291,6 +292,7 @@ AGENT_NAME_VARIANTS: Dict[str, List[str]] = {
|
||||
"clan": ["clan", "spirit", "клан", "спіріт", "спирит", "@clanbot"],
|
||||
"eonarch": ["eonarch", "еонарх", "@eonarchbot"],
|
||||
"senpai": ["senpai", "сенпай", "сэнпай", "гордон", "gordon", "@senpai_agent_bot"],
|
||||
"oneok": ["oneok", "1ok", "1ок", "одинок", "асистент віконного майстра", "@oneokbot"],
|
||||
"soul": ["soul", "athena", "атена", "афіна", "афина", "@athena_soul_bot"],
|
||||
"yaromir": ["yaromir", "яромир", "@yaromir_agent_bot"],
|
||||
"sofiia": ["sofiia", "софія", "софия", "софія", "@sofiia_agent_bot"],
|
||||
@@ -300,7 +302,7 @@ AGENT_NAME_VARIANTS: Dict[str, List[str]] = {
|
||||
COMMAND_PREFIXES = [
|
||||
"/ask", "/agent", "/help", "/start", "/status", "/link",
|
||||
"/daarwizz", "/helion", "/greenfood", "/agromatrix", "/alateya",
|
||||
"/nutra", "/druid", "/clan", "/eonarch", "/senpai", "/sofiia",
|
||||
"/nutra", "/druid", "/clan", "/eonarch", "/senpai", "/oneok", "/sofiia",
|
||||
"/ingest", "/бренд", "/презентація", "/job", "/soul", "/athena", "/yaromir",
|
||||
]
|
||||
|
||||
@@ -576,10 +578,20 @@ def analyze_message(
|
||||
|
||||
# --- Priority 1: Training groups ---
|
||||
if decision.is_training_group:
|
||||
decision.should_respond = True
|
||||
decision.action = "FULL"
|
||||
decision.reason = "training_group"
|
||||
return decision
|
||||
# In training chats, do NOT auto-FULL for every agent.
|
||||
# Only the targeted agent (mention/reply) should respond.
|
||||
if is_reply_to_agent:
|
||||
decision.should_respond = True
|
||||
decision.action = "FULL"
|
||||
decision.reason = "training_reply_to_agent"
|
||||
return decision
|
||||
targeted_agent = detect_any_agent_mention(text)
|
||||
if targeted_agent and targeted_agent != agent_id:
|
||||
decision.should_respond = False
|
||||
decision.action = "SILENT"
|
||||
decision.reason = f"training_addressed_to_other_agent_{targeted_agent}"
|
||||
return decision
|
||||
# If targeted_agent == agent_id or no target, continue with standard logic below.
|
||||
|
||||
# --- Priority 2: Private chat (DM) ---
|
||||
if is_private_chat:
|
||||
|
||||
Reference in New Issue
Block a user