Answer Retrieval in Legal Community Question Answering | SpringerLink
Skip to main content

Answer Retrieval in Legal Community Question Answering

  • Conference paper
  • First Online:
Advances in Information Retrieval (ECIR 2024)

Abstract

The task of answer retrieval in the legal domain aims to help users to seek relevant legal advice from massive amounts of professional responses. Two main challenges hinder applying existing answer retrieval approaches in other domains to the legal domain: (1) a huge knowledge gap between lawyers and non-professionals; and (2) a mix of informal and formal content on legal QA websites. To tackle these challenges, we propose CEFS, a novel cross-encoder (CE) re-ranker based on the fine-grained structured inputs. CEFS uses additional structured information in the CQA data to improve the effectiveness of cross-encoder re-rankers. Furthermore, we propose LegalQA: a real-world benchmark dataset for evaluating answer retrieval in the legal domain. Experiments conducted on LegalQA show that our proposed method significantly outperforms strong cross-encoder re-rankers fine-tuned on MS MARCO. Our novel finding is that adding the question tags of each question besides the question description and title into the input of cross-encoder re-rankers structurally boosts the rankers’ effectiveness. While we study our proposed method in the legal domain, we believe that our method can be applied in similar applications in other domains.

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

Access this chapter

Subscribe and save

Springer+ Basic
¥17,985 /Month
  • Get 10 units per month
  • Download Article/Chapter or eBook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Chapter
JPY 3498
Price includes VAT (Japan)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
JPY 13727
Price includes VAT (Japan)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
JPY 17159
Price includes VAT (Japan)
  • 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

Similar content being viewed by others

Notes

  1. 1.

    We interchangeably use the word answer and response to refer to the content written by the professional lawyer.

  2. 2.

    https://stackoverflow.com/.

  3. 3.

    We refer to the person who posts a question as a user or questioner throughout this paper.

  4. 4.

    https://github.com/arian-askari/AnswerRetrieval-Legal.

  5. 5.

    https://www.avvo.com/topics/bankruptcy.

  6. 6.

    We use the implementation available at https://github.com/seatgeek/thefuzz.

References

  1. Abolghasemi, A., Verberne, S., Azzopardi, L.: Improving BERT-based query-by-document retrieval with multi-task optimization. In: Hagen, M., et al. (eds.) ECIR 2022. LNCS, vol. 13186, pp. 3–12. Springer, Cham (2022). https://doi.org/10.1007/978-3-030-99739-7_1

    Chapter  Google Scholar 

  2. Askari, A., Abolghasemi, A., Aliannejadi, M., Kanoulas, E., Verberne, S.: Closer: conversational legal longformer with expertise-aware passage response ranker for long contexts. In: The 32nd ACM International Conference on Information and Knowledge Management (CIKM 2023). ACM (2023)

    Google Scholar 

  3. Askari, A., Abolghasemi, A., Pasi, G., Kraaij, W., Verberne, S.: Injecting the BM25 score as text improves BERT-based re-rankers. In: Advances in Information Retrieval, pp. 66–83. Springer Nature Switzerland, Cham (2023). https://doi.org/10.1007/978-3-031-28244-7_5

  4. Askari, A., Verberne, S., Pasi, G.: Expert finding in legal community question answering. In: Hagen, M., et al. (eds.) Advances in Information Retrieval, pp. 22–30. Springer International Publishing, Cham (2022). https://doi.org/10.1007/978-3-030-99739-7_3

    Chapter  Google Scholar 

  5. Atkinson, J., Figueroa, A., Andrade, C.: Evolutionary optimization for ranking how-to questions based on user-generated contents. Expert Syst. Appl. 40(17), 7060–7068 (2013)

    Article  Google Scholar 

  6. Bian, J., Liu, Y., Agichtein, E., Zha, H.: Finding the right facts in the crowd: factoid question answering over social media. In: Proceedings of the 17th International Conference on World Wide Web, pp. 467–476 (2008)

    Google Scholar 

  7. Boualili, L., Moreno, J.G., Boughanem, M.: MarkedBERT: integrating traditional IR cues in pre-trained language models for passage retrieval. In: Proceedings of the 43rd International ACM SIGIR Conference on Research and Development in Information Retrieval, pp. 1977–1980 (2020)

    Google Scholar 

  8. Budler, L.C., Gosak, L., Stiglic, G.: Review of artificial intelligence-based question-answering systems in healthcare. Wiley Interdisc. Rev.: Data Min. Knowl. Disc. 13(2), e1487 (2023)

    Google Scholar 

  9. Chen, T., Zhang, M., Lu, J., Bendersky, M., Najork, M.: Out-of-domain semantics to the rescue! zero-shot hybrid retrieval models. In: Hagen, M., et al. (eds.) ECIR 2022. LNCS, vol. 13185, pp. 95–110. Springer, Cham (2022). https://doi.org/10.1007/978-3-030-99736-6_7

    Chapter  Google Scholar 

  10. Haigh, R.: Legal English. Routledge (2018)

    Google Scholar 

  11. Han, J., Hong, T., Kim, B., Ko, Y., Seo, J.: Fine-grained post-training for improving retrieval-based dialogue systems. In: Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pp. 1549–1558 (2021)

    Google Scholar 

  12. Hofstätter, S., Althammer, S., Schröder, M., Sertkan, M., Hanbury, A.: Improving efficient neural ranking models with cross-architecture knowledge distillation. arXiv preprint arXiv:2010.02666 (2020)

  13. Kingma, D.P., Ba, J.: Adam: a method for stochastic optimization. arXiv preprint arXiv:1412.6980 (2014)

  14. Levenshtein, V.: Binary codes capable of correcting deletions, insertions and reversals. In: Soviet Physics-Doklady, vol. 10, pp. 707–710 (1966)

    Google Scholar 

  15. Mansouri, B., Campos, R.: FALQU: finding answers to legal questions. arXiv preprint arXiv:2304.05611 (2023)

  16. Martinez-Gil, J.: A survey on legal question-answering systems. Comput. Sci. Rev. 48, 100552 (2023)

    Article  MathSciNet  Google Scholar 

  17. Nguyen, T., et al.: Ms MARCO: a human generated machine reading comprehension dataset. In: CoCo@ NIPs (2016)

    Google Scholar 

  18. Nogueira, R., Cho, K.: Passage re-ranking with BERT. arXiv preprint arXiv:1901.04085 (2019)

  19. Ponte, J.M., Croft, W.B.: A language modeling approach to information retrieval. In: ACM SIGIR Forum, vol. 51, pp. 202–208. ACM New York, NY, USA (2017)

    Google Scholar 

  20. Rau, D., Kamps, J.: The role of complex NLP in transformers for text ranking. In: Proceedings of the 2022 ACM SIGIR International Conference on Theory of Information Retrieval, pp. 153–160 (2022)

    Google Scholar 

  21. Robertson, S.E., Walker, S.: Some simple effective approximations to the 2-poisson model for probabilistic weighted retrieval. In: SIGIR’94, pp. 232–241. Springer, London (1994). https://doi.org/10.1007/978-1-4471-2099-5_24

  22. Roy, P.K., Ahmad, Z., Singh, J.P., Alryalat, M.A.A., Rana, N.P., Dwivedi, Y.K.: Finding and ranking high-quality answers in community question answering sites. Glob. J. Flex. Syst. Manag. 19, 53–68 (2018)

    Article  Google Scholar 

  23. Roy, P.K., Saumya, S., Singh, J.P., Banerjee, S., Gutub, A.: Analysis of community question-answering issues via machine learning and deep learning: state-of-the-art review. CAAI Trans. Intell. Technol. 8(1), 95–117 (2023)

    Article  Google Scholar 

  24. Sentence-BERT: cross-encoder for ms MARCO: ms-marco-minilm-l-12-v2 (2023). https://huggingface.co/cross-encoder/ms-marco-MiniLM-L-12-v2

  25. Tiersma, P.M.: Legal language. University of Chicago Press (1999)

    Google Scholar 

  26. Wang, W., Wei, F., Dong, L., Bao, H., Yang, N., Zhou, M.: MiniLM: deep self-attention distillation for task-agnostic compression of pre-trained transformers. Adv. Neural. Inf. Process. Syst. 33, 5776–5788 (2020)

    Google Scholar 

  27. Williams, C.: Tradition and change in legal English: verbal constructions in prescriptive texts, vol. 20. Peter Lang (2007)

    Google Scholar 

  28. Wolf, T., et al.: Huggingface’s transformers: state-of-the-art natural language processing. arXiv preprint arXiv:1910.03771 (2019)

  29. Xiong, W., et al.: TWEETQA: a social media focused question answering dataset. arXiv preprint arXiv:1907.06292 (2019)

  30. Yang, W., et al.: End-to-end open-domain question answering with BERTserini. arXiv preprint arXiv:1902.01718 (2019)

  31. Yen, S.J., Wu, Y.C., Yang, J.C., Lee, Y.S., Lee, C.J., Liu, J.J.: A support vector machine-based context-ranking model for question answering. Inf. Sci. 224, 77–87 (2013)

    Article  Google Scholar 

  32. Zhang, Z., Sabuncu, M.: Generalized cross entropy loss for training deep neural networks with noisy labels. In: Advances in Neural Information Processing Systems, vol. 31 (2018)

    Google Scholar 

Download references

Acknowledgments

This work was supported by the EU Horizon 2020 ITN/ETN on Domain Specific Systems for Information Extraction and Retrieval (H2020-EU.1.3.1., ID: 860721).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Arian Askari .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2024 The Author(s), under exclusive license to Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Askari, A., Yang, Z., Ren, Z., Verberne, S. (2024). Answer Retrieval in Legal Community Question Answering. In: Goharian, N., et al. Advances in Information Retrieval. ECIR 2024. Lecture Notes in Computer Science, vol 14610. Springer, Cham. https://doi.org/10.1007/978-3-031-56063-7_40

Download citation

  • DOI: https://doi.org/10.1007/978-3-031-56063-7_40

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-031-56062-0

  • Online ISBN: 978-3-031-56063-7

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics