Skip to main content

Leveraging on Semantic Textual Similarity for Developing a Portuguese Dialogue System

  • Conference paper
  • First Online:
Book cover Computational Processing of the Portuguese Language (PROPOR 2020)

Abstract

We describe an IR-based dialogue system that, in order to match user interactions with FAQs on a list, leverages on a model for computing the semantic similarity between two fragments of Portuguese text. It was mainly used for answering questions about the economic activity in Portugal and, when no FAQ has a higher score than a threshold, it may search for similar interactions in a corpus of movie subtitles and still tries to give a suitable response. Besides describing the underlying model and its integration, we assess it when answering variations of FAQs and report on an experiment to set the aforementioned threshold.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    FAQs were downloaded from Balcão do Empreendedor (BDE) portal, the Portuguese Entrepreneur’s Desk, on June 2018.

  2. 2.

    https://cloud.google.com/translate/docs/.

  3. 3.

    Whoosh (https://whoosh.readthedocs.io) is a search engine library in Python.

  4. 4.

    Chatterbot (https://chatterbot.readthedocs.io) is a Python library for generating responses to user input.

References

  1. Agirre, E., et al.: SemEval-2016 task 1: semantic textual similarity, monolingual and cross-lingual evaluation. In: Proceedings of 10th International Workshop on Semantic Evaluation (SemEval-2016), pp. 497–511. Association for Computational Linguistics, San Diego, California, June 2016

    Google Scholar 

  2. Agirre, E., Diab, M., Cer, D., Gonzalez-Agirre, A.: Semeval-2012 task 6: a pilot on semantic textual similarity. In: Proceedings of 1st Joint Conference on Lexical and Computational Semantics-vol. 1: Proceedings of Main Conference and Shared Task, and, vol. 2: Proceedings of 6th International Workshop on Semantic Evaluation, pp. 385–393. Association for Computational Linguistics (2012)

    Google Scholar 

  3. Barreiro, A.: Make it simple with paraphrases: Automated paraphrasing for authoring aids and machine translation. Ph.D. thesis, Universidade do Porto (2009)

    Google Scholar 

  4. Bird, S., Klein, E., Loper, E.: Natural Language Processing with Python. O’Reilly Media, Beijing (2009)

    MATH  Google Scholar 

  5. Bojanowski, P., Grave, E., Joulin, A., Mikolov, T.: Enriching word vectors with subword information. Trans. Assoc. Comput. Linguist. 5, 135–146 (2017)

    Article  Google Scholar 

  6. Caputo, A., Degemmis, M., Lops, P., Lovecchio, F., Manzari, V.: Overview of the EVALITA 2016 question answering for frequently asked questions (QA4FAQ) task. In: Proceedings of 3rd Italian Conference on Computational Linguistics (CLiC-it 2016) & 5th Evaluation Campaign of Natural Language Processing and Speech Tools for Italian. Final Workshop (EVALITA 2016). CEUR Workshop Proceedings, vol. 1749. CEUR-WS.org (2016)

    Google Scholar 

  7. Cer, D., Diab, M., Agirre, E., Lopez-Gazpio, I., Specia, L.: SemEval-2017 task 1: semantic textual similarity multilingual and crosslingual focused evaluation. In: Proceedings of 11th International Workshop on Semantic Evaluation (SemEval-2017), pp. 1–14. Association for Computational Linguistics (2017)

    Google Scholar 

  8. Cui, L., Huang, S., Wei, F., Tan, C., Duan, C., Zhou, M.: Superagent: a customer service chatbot for e-commerce websites. In: Proceedings of 55th Annual Meeting of the Association for Computational Linguistics, ACL 2017, System Demonstrations, pp. 97–102. Association for Computational Linguistics (2017)

    Google Scholar 

  9. Devlin, J., Chang, M.W., Lee, K., Toutanova, K.: BERT: pre-training of deep bidirectional transformers for language understanding. In: Proceedings of 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pp. 4171–4186. Association for Computational Linguistics, Minneapolis, Minnesota, June 2019

    Google Scholar 

  10. Ferreira, J., Gonçalo Oliveira, H., Rodrigues, R.: Improving NLTK for processing Portuguese. In: Symposium on Languages, Applications and Technologies (SLATE 2019). OASIcs, vol. 74, pp. 18:1–18:9. Schloss Dagstuhl, June 2019

    Google Scholar 

  11. Fonseca, E., Santos, L., Criscuolo, M., Aluísio, S.: Visão geral da avaliação de similaridade semântica e inferência textual. Linguamática 8(2), 3–13 (2016)

    Google Scholar 

  12. Fonseca, E.R., Magnolini, S., Feltracco, A., Qwaider, M.R.H., Magnini, B.: Tweaking word embeddings for FAQ ranking. In: Proceedings of 5th Evaluation Campaign of Natural Language Processing and Speech Tools for Italian, vol. 1749. CEUR-WS (2016)

    Google Scholar 

  13. Gonçalo Oliveira, H.: Learning word embeddings from portuguese lexical-semantic knowledge bases. In: Villavicencio, A., Moreira, V., Abad, A., Caseli, H., Gamallo, P., Ramisch, C., Gonçalo Oliveira, H., Paetzold, G.H. (eds.) PROPOR 2018. LNCS (LNAI), vol. 11122, pp. 265–271. Springer, Cham (2018). https://doi.org/10.1007/978-3-319-99722-3_27

    Chapter  Google Scholar 

  14. Hartmann, N.S., Fonseca, E.R., Shulby, C.D., Treviso, M.V., Rodrigues, J.S., Aluísio, S.M.: Portuguese word embeddings: evaluating on word analogies and natural language tasks. In: Proceedings of 11th Brazilian Symposium in Information and Human Language Technology. STIL 2017 (2017)

    Google Scholar 

  15. Ji, Z., Lu, Z., Li, H.: An information retrieval approach to short text conversation. ArXiv abs/1408.6988 (2014)

    Google Scholar 

  16. Karan, M., Žmak, L., Šnajder, J.: Frequently asked questions retrieval for Croatian based on semantic textual similarity. In: Proceedings of 4th Biennial Intl. Workshop on Balto-Slavic Natural Language Processing, pp. 24–33. Association for Computational Linguistics, Sofia, Bulgaria, August 2013

    Google Scholar 

  17. Kolomiyets, O., Moens, M.F.: A survey on question answering technology from an information retrieval perspective. Inf. Sci. 181(24), 5412–5434 (2011)

    Article  MathSciNet  Google Scholar 

  18. Kothari, G., Negi, S., Faruquie, T.A., Chakaravarthy, V.T., Subramaniam, L.V.: SMS based interface for FAQ retrieval. In: Proceedings of Joint Conference of the 47th Annual Meeting of the ACL and the 4th International Joint Conference on Natural Language Processing of the AFNLP: Volume 2, pp. 852–860. ACL 2009, Association for Computational Linguistics (2009)

    Google Scholar 

  19. Magarreiro, D., Coheur, L., Melour, F.S.: Using subtitles to deal with out-of-domain interactions. In: Proceedings of 18th Workshop on the Semantics and Pragmatics of Dialogue (SemDial), pp. 98–106 (2014)

    Google Scholar 

  20. Nakov, P., et al.: SemEval-2017 task 3: community question answering. In: Proceedings of 11th International Workshop on Semantic Evaluation (SemEval-2017), pp. 27–48. Association for Computational Linguistics, August 2017

    Google Scholar 

  21. Nakov, P., et al.: SemEval-2016 task 3: community question answering. In: Proceedings of 10th International Workshop on Semantic Evaluation. Association for Computational Linguistics, June 2016

    Google Scholar 

  22. Pedregosa, F., et al.: Scikit-learn: machine learning in Python. J. Mach. Learn. Res. 12, 2825–2830 (2011)

    MathSciNet  MATH  Google Scholar 

  23. Pipitone, A., Tirone, G., Pirrone, R.: ChiLab4It system in the QA4FAQ competition. In: Proceedings of 5th Evaluation Campaign of Natural Language Processing and Speech Tools for Italian, vol. 1749. CEUR-WS (2016). http://ceur-ws.org/Vol-1749/

  24. Real, L., Fonseca, E., Oliveira, H.G.: The assin 2 shared task: a quick overview. In: Computational Processing of the Portuguese Language - 13th International Conference, PROPOR 2020, Évora, Portugal, 2–4 March 2020, Proceedings, LNCS. Springer, Heidelberg (2020). https://doi.org/10.1007/978-3-030-41505-1

  25. Řehůřek, R., Sojka, P.: Software framework for topic modelling with large Corpora. In: Proceedings of LREC 2010 Workshop on New Challenges for NLP Frameworks, pp. 45–50. ELRA, Valletta, Malta, May 2010

    Google Scholar 

  26. Rinaldi, F., Dowdall, J., Hess, M., Mollá, D., Schwitter, R., Kaljurand, K.: Knowledge-based question answering. In: Palade, V., Howlett, R.J., Jain, L. (eds.) KES 2003. LNCS (LNAI), vol. 2773, pp. 785–792. Springer, Heidelberg (2003). https://doi.org/10.1007/978-3-540-45224-9_106

    Chapter  Google Scholar 

  27. Rodrigues, J., Saedi, C., Branco, A., Silva, J.: Semantic equivalence detection: are interrogatives harder than declaratives? In: Proceedings of 11th Language Resources and Evaluation Conference. ELRA, Miyazaki, Japan, May 2018

    Google Scholar 

  28. Speer, R., Chin, J., Havasi, C.: Conceptnet 5.5: an open multilingual graph of general knowledge. In: Proceedings of 31st AAAI Conference on Artificial Intelligence, pp. 4444–4451. San Francisco, California, USA (2017)

    Google Scholar 

  29. Vinyals, O., Le, Q.V.: A neural conversational model. In: Proceedings of ICML 2015 Deep Learning Workshop. Lille, France (2015)

    Google Scholar 

  30. Voorhees, E.M.: The TREC question answering track. Nat. Lang. Eng. 7(4), 361–378 (2001)

    Article  Google Scholar 

Download references

Acknolwedgements

This work was funded by FCT’s INCoDe 2030 initiative, in the scope of the demonstration project AIA, “Apoio Inteligente a empreendedores (chatbots)”.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to José Santos .

Editor information

Editors and Affiliations

A Example Conversation

A Example Conversation

figure a

Rights and permissions

Reprints and permissions

Copyright information

© 2020 Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Santos, J., Alves, A., Gonçalo Oliveira, H. (2020). Leveraging on Semantic Textual Similarity for Developing a Portuguese Dialogue System. In: Quaresma, P., Vieira, R., Aluísio, S., Moniz, H., Batista, F., Gonçalves, T. (eds) Computational Processing of the Portuguese Language. PROPOR 2020. Lecture Notes in Computer Science(), vol 12037. Springer, Cham. https://doi.org/10.1007/978-3-030-41505-1_13

Download citation

  • DOI: https://doi.org/10.1007/978-3-030-41505-1_13

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-030-41504-4

  • Online ISBN: 978-3-030-41505-1

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics