Skip to content

Are accents supported at all? #86

Description

@zxul767

The text "Bestias desagradables. No sé por qué acepté apostar" should be classified as Spanish, but it is instead classified as Portuguese with high confidence. If you remove the accents, the phrase is correctly classified as Spanish with high confidence.

By the way, the translation in Portuguese is "Bestas desagradáveis. Não sei por que concordei em apostar". Both languages have words in common, but I think the issue here is that the underlying model wasn't trained with text that contained accents (or maybe accents were removed during training pre-processing, but the same pre-processing pipeline is not running during inference?)

>>> identifier.classify("Bestias desagradables. No sé por qué acepté apostar")
('pt', 0.9686061146305236)

>>> identifier.classify("Bestias desagradables. No se por que acepte apostar")
('es', 0.9599256901062293)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions