From f7ced7d3650f1a73c4ed82dab26ecd5602646527 Mon Sep 17 00:00:00 2001 From: miro Date: Fri, 22 Mar 2024 03:03:59 +0000 Subject: [PATCH] fix/converse_intents_no_match "conf" key is not available when padacioso doesn't return any match {'name': None, 'entities': {}} --- ovos_workshop/skills/ovos.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ovos_workshop/skills/ovos.py b/ovos_workshop/skills/ovos.py index 8af6bb7b..b665827a 100644 --- a/ovos_workshop/skills/ovos.py +++ b/ovos_workshop/skills/ovos.py @@ -271,7 +271,7 @@ def _handle_converse_intents(self, message): for utt in message.data['utterances']: match = self.converse_matchers[self.lang].calc_intent(utt) - if match and match["conf"] > best_score: + if match.get("conf", 0) > best_score: best_score = match["conf"] response = message.forward(match["name"], match["entities"])