mirror of
https://github.com/hoshikawa2/first_contas.git
synced 2026-07-10 02:34:20 +00:00
first commit
This commit is contained in:
@@ -0,0 +1,132 @@
|
||||
name: vas_estrategico
|
||||
version: 3
|
||||
start: preparar
|
||||
|
||||
nodes:
|
||||
- id: preparar
|
||||
action: preparar_vas_estrategico
|
||||
input:
|
||||
items: $.input.items
|
||||
linhas: $.input.linhas
|
||||
pause:
|
||||
enabled: true
|
||||
when:
|
||||
eq: [$.output.await_user_input, true]
|
||||
return_from: $.output.mensagem
|
||||
expected_input:
|
||||
key: resposta_usuario
|
||||
allowed_values: ["SIM", "NAO", "OUTRO"]
|
||||
normalize: upper_strip
|
||||
resume_from: decisao
|
||||
|
||||
- id: resposta_bundle
|
||||
action: montar_resposta_texto
|
||||
input:
|
||||
dados:
|
||||
texto_usuario: $.vars.preparar.mensagem_bundle_fechamento
|
||||
|
||||
- id: decisao
|
||||
action: no_op
|
||||
input: {}
|
||||
|
||||
- id: resposta_sim
|
||||
action: montar_resposta_texto
|
||||
input:
|
||||
dados:
|
||||
texto_usuario: $.vars.preparar.mensagem_pos_aceite
|
||||
|
||||
- id: explicar_cancelamento
|
||||
action: montar_explicacao_cancelamento_vas_estrategico
|
||||
input:
|
||||
linhas: $.vars.preparar.linhas
|
||||
orientacoes_cancelamento: $.input.orientacoes_cancelamento
|
||||
|
||||
- id: registrar_sim
|
||||
action: registrar_atendimento_vas_estrategico
|
||||
input:
|
||||
linhas: $.vars.preparar.linhas
|
||||
mensagem_base: $.vars.resposta_sim.mensagem
|
||||
request_status: "Fechado"
|
||||
status: "CLOSED"
|
||||
|
||||
- id: registrar_nao
|
||||
action: registrar_atendimento_vas_estrategico
|
||||
input:
|
||||
linhas: $.vars.preparar.linhas
|
||||
mensagem_base: $.vars.explicar_cancelamento.mensagem
|
||||
request_status: "Fechado"
|
||||
status: "CLOSED"
|
||||
|
||||
- id: registrar_bundle
|
||||
action: registrar_atendimento_vas_estrategico
|
||||
input:
|
||||
linhas: $.vars.preparar.linhas
|
||||
mensagem_base: $.vars.resposta_bundle.mensagem
|
||||
request_status: "Fechado"
|
||||
status: "CLOSED"
|
||||
|
||||
- id: registrar_outro
|
||||
action: registrar_atendimento_vas_estrategico
|
||||
input:
|
||||
linhas: $.vars.preparar.linhas
|
||||
mensagem_base: "Atendimento encerrado sem confirmação de manutenção do serviço."
|
||||
request_status: "Fechado"
|
||||
status: "CLOSED"
|
||||
|
||||
edges:
|
||||
- from: preparar
|
||||
to: decisao
|
||||
priority: 10
|
||||
when:
|
||||
eq: [$.vars.preparar.await_user_input, true]
|
||||
|
||||
- from: preparar
|
||||
to: resposta_bundle
|
||||
priority: 20
|
||||
|
||||
# Bundle puro (sem item estratégico): após a pausa em "sanei sua dúvida?", o
|
||||
# cliente respondeu. O agente não cancela bundle, então fecha com a reafirmação
|
||||
# breve (resposta_bundle) e registra/finaliza, independente de SIM/NAO. Tem
|
||||
# precedência (priority menor) sobre os ramos SIM/NAO do estratégico.
|
||||
- from: decisao
|
||||
to: resposta_bundle
|
||||
priority: 5
|
||||
when:
|
||||
eq: [$.vars.preparar.has_estrategico_items, false]
|
||||
|
||||
- from: decisao
|
||||
to: resposta_sim
|
||||
priority: 10
|
||||
when:
|
||||
eq: [$.input.resposta_usuario, SIM]
|
||||
|
||||
- from: decisao
|
||||
to: explicar_cancelamento
|
||||
priority: 20
|
||||
when:
|
||||
eq: [$.input.resposta_usuario, NAO]
|
||||
|
||||
- from: decisao
|
||||
to: registrar_outro
|
||||
priority: 99
|
||||
|
||||
- from: resposta_sim
|
||||
to: registrar_sim
|
||||
|
||||
- from: explicar_cancelamento
|
||||
to: registrar_nao
|
||||
|
||||
- from: registrar_sim
|
||||
to: END
|
||||
|
||||
- from: registrar_nao
|
||||
to: END
|
||||
|
||||
- from: resposta_bundle
|
||||
to: registrar_bundle
|
||||
|
||||
- from: registrar_bundle
|
||||
to: END
|
||||
|
||||
- from: registrar_outro
|
||||
to: END
|
||||
Reference in New Issue
Block a user