Recognize self capability questions
This commit is contained in:
@@ -661,7 +661,7 @@ func informationRequestKind(message string, candidate interaction.SemanticCandid
|
||||
if cognitiveSubject && inventoryRequest && inventoryCue {
|
||||
return interaction.InformationRequestCognitiveModelInventory
|
||||
}
|
||||
capabilitySubject := containsStemInTokens(tokens, "уме", "возможност", "способн", "capabilit")
|
||||
capabilitySubject := containsStemInTokens(tokens, "уме", "возможност", "способн", "capabilit") || (containsMeaningfulInterrogative(tokens) && containsToken(tokens, "можешь"))
|
||||
if inquiry && capabilitySubject {
|
||||
return interaction.InformationRequestCapabilityInventory
|
||||
}
|
||||
|
||||
@@ -120,6 +120,7 @@ func TestInformationRequestsAreClassifiedOnceByInteraction(t *testing.T) {
|
||||
{"какие модели доступны?", interaction.InformationRequestCognitiveModelInventory},
|
||||
{"назови доступные модели", interaction.InformationRequestCognitiveModelInventory},
|
||||
{"какая модель отвечает?", interaction.InformationRequestCognitiveCurrentModel},
|
||||
{"что ты можешь сделать без внешних моделей?", interaction.InformationRequestCapabilityInventory},
|
||||
{"что ты умеешь?", interaction.InformationRequestCapabilityInventory},
|
||||
{"проверь состояние локального канала", interaction.InformationRequestCognitiveChannelStatus},
|
||||
{"нет связи с ИИ, восстанови канал", interaction.InformationRequestCognitiveRecovery},
|
||||
|
||||
Reference in New Issue
Block a user