iachat/enterprise/app
Rodribm10 b561aa8451 revert(hermes): remove camadas 2/3/4 + reabilita memória
A causa raiz dos bugs de "info repetida em turns anteriores" era o
default_scope ASC do Message conflitando com .order(desc) no debounce
(ver commit f1d3a124d). Como já corrigi com .reorder, as Camadas 2, 3 e
4 viraram peso morto que adicionava latência/false positive sem ganho.

Removido:
- Camada 2 (factual sem tool → retrigger force_factual_tool)
- Camada 3 (strip de linhas repetidas com pool de outgoings anteriores)
- Camada 4 (topic gating: bloqueio quando resposta tem tópico não pedido)
- Tracker de tool calls em McpController (suportava Camada 2)
- Snapshot baseline em OutgoingJob (suportava Camada 2)
- Regra "🚨 NÃO CONFIE NA SUA MEMÓRIA" das 4 SOUL.md Hermes

Mantido:
- Camada 1: handoff intencional ("Um momento — vou verificar") +
  loop detection (Jaccard >= 0.50 ou pergunta reformulada com 3+
  keywords). Genuíno pra bot externo (Claro/Vivo) e loops óbvios.
- Label-guard em OutgoingJob (não dispatch se conv tem triagem_humana).
- Auto-react ambient (feature original).
- Reorder fix no combined_incoming_content (causa raiz).

Memory + user_profile reabilitados nos 4 Hermes (config.yaml) e no
template do hermes-provision pra futuros agentes. Sem memória, cliente
precisa repetir nome/CPF/contexto a cada turn — UX horrível.
Contaminação cross-unit que justificava desligar vinha de outro bug
(X-Captain-Assistant-Id apontando pro parent), já corrigido.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-02 18:39:43 -03:00
..
builders Merge branch main into chore/merge-upstream 2025-12-20 12:44:31 -03:00
controllers feat(captain/hermes-builder): aba Verificação com 22+ checks + reparo automático 2026-05-02 15:27:40 -03:00
dispatchers/enterprise feat(ee): Add Captain features (#10665) 2025-01-14 16:15:47 -08:00
drops feat: Add push/email notification support for SLA (#9140) 2024-03-29 20:27:21 +11:00
errors/captain/errors fix: Resolve erros de linting e conclui as correções de prompt customizado 2026-02-27 13:02:44 -03:00
fields fix: Render all account limit fields (#13435) 2026-02-04 20:21:07 +05:30
finders/enterprise feat: Conversation API to return applied_sla and sla_events (#9174) 2024-04-01 23:30:07 +05:30
helpers feat: langfuse logging improvements (#13534) 2026-02-17 13:30:04 +05:30
jobs revert(hermes): remove camadas 2/3/4 + reabilita memória 2026-05-02 18:39:43 -03:00
listeners feat(retention): foundation for customer retention metrics 2026-04-22 09:50:23 -03:00
mailers/enterprise/agent_notifications chore: fix sla email notifications (#9192) 2024-04-04 21:16:49 +05:30
models fix(captain): captain_unit_id em captain_assistants — fim do lookup quebrado 2026-05-02 12:45:53 -03:00
policies fix(retention): cohort endpoint 500 — Pundit policy + SQL binding 2026-04-26 12:46:20 -03:00
presenters/enterprise/conversations feat: UI to show the SLA threshold in chat screen (#9146) 2024-04-04 15:46:46 +05:30
services feat(captain/hermes): camada 3 — strip de linhas repetidas + check FAQs 2026-05-02 18:16:39 -03:00
views feat(captain): engine column + DB-driven Hermes routing + Express pricing 2026-05-02 07:54:01 -03:00