Ir para o conteúdo
Logomarca Alfaneo
  • Inicio
  • Soluções
    • Diagnóstico Alfaneo
    • Alfaneo Petição
    • Software Personalizado
    • ChatBot de Atendimento Jurídico com IA
    • IA para Advocacia de massa
    • IA para Perícias de Massa
    • IA para Procuradorias e Defensorias
    • IA para Conselhos Profissionais
  • Casos de Sucesso
    • Clientes
    • Projetos Realizados
    • Pesquisas e Premiações
  • Blog
  • Sobre
    • Sobre a Empresa
    • Liderança
    • Equipe
  • Contato
    • Vendas
    • Suporte
    • Trabalhe Conosco
  • Ajuda
  • Login
  • Inicio
  • Soluções
    • Diagnóstico Alfaneo
    • Alfaneo Petição
    • Software Personalizado
    • ChatBot de Atendimento Jurídico com IA
    • IA para Advocacia de massa
    • IA para Perícias de Massa
    • IA para Procuradorias e Defensorias
    • IA para Conselhos Profissionais
  • Casos de Sucesso
    • Clientes
    • Projetos Realizados
    • Pesquisas e Premiações
  • Blog
  • Sobre
    • Sobre a Empresa
    • Liderança
    • Equipe
  • Contato
    • Vendas
    • Suporte
    • Trabalhe Conosco
  • Ajuda
  • Login
Ajuda
Login Petição

Alfaneo Petição

Sua petição pronta em minutos com IA

IA para Advocacia de massa

Tecnologia sob medida para escalar seu negócio

IA para Perícias de Massa

Laudos periciais prontos em minutos, com máxima precisão!

IA para Procuradorias e Defensorias

IA Estratégica para o Setor Público

IA para Conselhos Profissionais

Pareceres e normativas em minutos: Automação para Conselhos Profissionais

Diagnóstico Alfaneo

Avalie e impulsione a maturidade da sua empresa em IA

Software Personalizado

Seu negócio é único. Sua tecnologia também deve ser.

ChatBot de Atendimento Jurídico com IA

A evolução do atendimento jurídico corporativo

Vendas

Descubra como nossas soluções de IA podem impulsionar suas vendas.

Suporte

Nossa IA e equipe especializada estão prontas para oferecer suporte.

Trabalhe Conosco

Junte-se a nós para moldar o futuro da inteligência artificial!

Sobre a empresa

Conheça nossa história e os valores que nos impulsionam.

Liderança

A liderança da nossa empresa é composta por especialistas apaixonados por IA.

Equipe

Unida pelo objetivo de oferecer soluções tecnológicas avançadas.

Parceiros

Trabalhamos ao lado de empresas e especialistas.

Clientes

Nos orgulhamos de atender empresas de diversos setores.

Projetos realizados

Confira alguns dos nossos projetos de sucesso.

Pesquisas

Investimos em pesquisas avançadas para impulsionar o desenvolvimento tecnológicos.

Pesquisas e Premiações

Nossos esforços e inovações foram reconhecidos por diversas premiações.

  • Artigos, Blog

JurisBERT: A New Approach that Converts a Classification Corpus into an STS One

JurisBERT converte corpus de classificação em STS, ganhando 3,3 % de precisão, 5× menos tempo de treino e usando hardware acessível.
Logomarca Alfaneo

Publicado por

Alfaneo
18 ago 2023

Abstract

We propose in this work a new approach that aims to transform a classification corpus into an STS (Semantic Textual Similarity) one. In that sense, we use BERT (Bidirectional Encoder Representations from Transformers) to validate our hypothesis, i.e., a multi-level classification dataset can be converted into an STS dataset which improves the fine-tuning step and evidences the proposed corpus. Also, in our approach, we trained from scratching a BERT model considering the legal texts, called JurisBert which reveals a considered improvement in fastness and precision, and it requires less computational resources than other approaches. JurisBERT uses the concept of sub-language, i.e., a model pre-trained in a language (Brazilian Portuguese) passes through refining (fine-tuning) to better attend to a specific domain, in our case, the legal field. JurisBERT uses 24k pairs of ementas with degrees of similarity varying from 0 to 3. We got this data from search mechanisms available on the court websites to validate the model with real-world data. Our experiments showed JurisBERT is better than other models such as multilingual BERT and BERTimbau with 3.30%3.30% better precision (F1�1), 5 times reduced training time, and using accessible hardware, i.e., low-cost GPGPU architecture. The source code is available at https://github.com/alfaneo-ai/brazilian-legal-text-dataset and the model is here: https://huggingface.co/alfaneo.

Keywords

  • Semantic Textual Similarity
  • Retrieving Legal Precedents
  • Sentence Embedding
  • Bert

Notes

  1. 1.

    The Conselho Nacional de Justiça is a public institution that aims to help the Brazilian judiciary. It maintains administrative and procedural control and transparency.

  2. 2.

    STF, STJ, TJRJ, TJMS.

  3. 3.

    It is an operation that reduces the dimensionality of data by applying an aggregation of type max average.

  4. 4.

    It is a dense vector of floating points that aims to capture the semantic of the text in the vector space.

  5. 5.

    The súmulas summarizes the dominant precedent of a given court.

  6. 6.

    Proposed dataset and web scrappers are available here: https://github.com/alfaneo-ai/brazilian-legal-text-dataset, and the models, here: https://huggingface.co/alfaneo.

References

  1. Agirre, E., Cer, D., Diab, M., Gonzalez-Agirre, A.: SemEval-2012 task 6: A pilot on semantic textual similarity. In: *SEM 2012: The First Joint Conference on Lexical and Computational Semantics – Volume 1: Proceedings of the main conference and the shared task, and Volume 2: Proceedings of the Sixth International Workshop on Semantic Evaluation (SemEval 2012), pp. 385–393. Association for Computational Linguistics, Montréal, Canada (7–8 Jun 2012), https://aclanthology.org/S12-1051

  2. Banerjee, S., Mishra, B., Jawanpuria, P., Shrivastava, M.: Generalised spherical text embedding (2022)

    Google Scholar

  3. Beltagy, I., Lo, K., Cohan, A.: Scibert: A pretrained language model for scientific text. In: EMNLP (2019)

    Google Scholar

  4. Cer, D., et al.: Universal sentence encoder for English. In: Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing: System Demonstrations. pp. 169–174. Association for Computational Linguistics, Brussels, Belgium (Nov 2018). https://doi.org/10.18653/v1/D18-2029, https://aclanthology.org/D18-2029

  5. Choi, H., Kim, J., Joe, S., Gwon, Y.: Evaluation of bert and albert sentence embedding performance on downstream nlp tasks (2021). https://doi.org/10.48550/ARXIV.2101.10642, https://arxiv.org/abs/2101.10642

  6. CNJ: Justiça em números 2020: ano-base 2019. Tech. rep., Conselho Nacional de Justiça (2020), https://www.cnj.jus.br/pesquisas-judiciarias/justica-em-numeros/

  7. Cunha, A.S.: Introdução ao estudo do direito. Saraiva (2012)

    Google Scholar

  8. Devlin, J., Chang, M., Lee, K., Toutanova, K.: BERT: pre-training of deep bidirectional transformers for language understanding. CoRR abs/1810.04805 (2018). http://arxiv.org/abs/1810.04805

  9. Fonseca, E.R., Borges dos Santos, L., Criscuolo, M., Aluísio, S.M.: Visão geral da avaliação de similaridade semântica e inferência textual. Linguamática 8(2), 3–13 (Dez 2016). https://linguamatica.com/index.php/linguamatica/article/view/v8n2-1

  10. Hendrycks, D., Gimpel, K.: Gaussian error linear units (gelus) (2016). https://doi.org/10.48550/ARXIV.1606.08415, https://arxiv.org/abs/1606.08415

  11. Jiang, T., et al.: Promptbert: Improving bert sentence embeddings with prompts (2022). https://doi.org/10.48550/ARXIV.2201.04337, https://arxiv.org/abs/2201.04337

  12. Johnson, J., Douze, M., Jégou, H.: Billion-scale similarity search with gpus (2017). https://doi.org/10.48550/ARXIV.1702.08734, https://arxiv.org/abs/1702.08734

  13. Júnior, H.: Curso de direito processual civil, vol. I. Editora Forense (2019)

    Google Scholar

  14. Keskar, N.S., McCann, B., Xiong, C., Socher, R.: Unifying question answering, text classification, and regression via span extraction (2019)

    Google Scholar

  15. Kingma, D.P., Ba, J.: Adam: A method for stochastic optimization (2014). https://doi.org/10.48550/ARXIV.1412.6980, https://arxiv.org/abs/1412.6980

  16. Kiros, R., Zhu, Y., Salakhutdinov, R., Zemel, R.S., Torralba, A., Urtasun, R., Fidler, S.: Skip-thought vectors (2015). https://doi.org/10.48550/ARXIV.1506.06726, https://arxiv.org/abs/1506.06726

  17. Liu, Y., et al.: Roberta: A robustly optimized bert pretraining approach (2019). https://doi.org/10.48550/ARXIV.1907.11692, https://arxiv.org/abs/1907.11692

  18. Meshram, S., Anand Kumar, M.: Long short-term memory network for learning sentences similarity using deep contextual embeddings. International Journal of Information Technology, pp. 1633–1641 (2021)

    Google Scholar

  19. Nguyen, H.T., Nguyen, L.M.: Sublanguage: A Serious Issue Affects Pretrained Models in Legal Domain. arXiv e-prints arXiv:2104.07782 (Apr 2021)

  20. Pennington, J., Socher, R., Manning, C.: GloVe: Global vectors for word representation. In: Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing (EMNLP), pp. 1532–1543. Association for Computational Linguistics, Doha, Qatar (Oct 2014). https://doi.org/10.3115/v1/D14-1162, https://aclanthology.org/D14-1162

  21. Rasmy, L., Xiang, Y., Xie, Z., Tao, C., Zhi, D.: Med-bert: pre-trained contextualized embeddings on large-scale structured electronic health records for disease prediction (2020). https://doi.org/10.48550/ARXIV.2005.12833, https://arxiv.org/abs/2005.12833

  22. Real, L., Fonseca, E., Gonçalo Oliveira, H.: The assin 2 shared task: A quick overview. In: Quaresma, P., Vieira, R., Aluísio, S., Moniz, H., Batista, F., Gonçalves, T. (eds.) Computational Processing of the Portuguese Language, pp. 406–412. Springer International Publishing, Cham (2020)

    CrossRef Google Scholar

  23. Real, L., et al.: SICK-BR: A Portuguese Corpus for Inference: 13th International Conference, PROPOR 2018, Canela, Brazil, September 24–26, 2018, Proceedings, pp. 303–312. Springer, Cham (01 2018). https://doi.org/10.1007/978-3-319-99722-3_31

  24. Reimers, N., Gurevych, I.: Sentence-bert: Sentence embeddings using siamese bert-networks (2019). https://doi.org/10.48550/ARXIV.1908.10084, https://arxiv.org/abs/1908.10084

  25. Song, X., Salcianu, A., Song, Y., Dopson, D., Zhou, D.: Fast wordpiece tokenization (2020). https://doi.org/10.48550/ARXIV.2012.15524, https://arxiv.org/abs/2012.15524

  26. Souza, F., Nogueira, R., Lotufo, R.: Bertimbau: Pretrained bert models for brazilian portuguese. In: Intelligent Systems: 9th Brazilian Conference, BRACIS 2020, Rio Grande, Brazil, October 20–23, 2020, Proceedings, Part I. p. 403–417. Springer-Verlag, Berlin, Heidelberg (2020). https://doi.org/10.1007/978-3-030-61377-8_28

  27. Vaswani, A., et al.: Attention is all you need (2017)

    Google Scholar

  28. Wagner Filho, J.A., Wilkens, R., Idiart, M., Villavicencio, A.: The brwac corpus: A new open resource for brazilian portuguese. In: Proceedings of the Eleventh International Conference on Language Resources and Evaluation (LREC 2018) (2018)

    Google Scholar

  29. Weber, R.: Intelligent jurisprudence research: A new concept. In: Proceedings of the 7th International Conference on Artificial Intelligence and Law. p. 164–172. ICAIL ’99, Association for Computing Machinery, New York, NY, USA (1999). https://doi.org/10.1145/323706.323791, https://doi.org/10.1145/323706.323791

  30. Zhang, G., Lillis, D., Nulty, P.: Can Domain Pre-training Help Interdisciplinary Researchers from Data Annotation Poverty? A Case Study of Legal Argument Mining with BERT-based Transformers. In: Proceedings of the Workshop on Natural Language Processing for Digital Humanities (NLP4DH), pp. 121–130. Association for Computational Linguistics (2021), https://rootroo.com/downloads/nlp4dh_proceedings_draft.pdf

Download references

Acknowledgments

We thank the support of the UFMS (Universidade Federal de Mato Grosso do Sul), FUNDECT, and Finep. We also thank the support of the INCT of the Future Internet for Smart Cities funded by CNPq, proc. 465446/2014-0, Coordenação de Aperfeiçoamento de Pessoal de Nível Superior – Brasil (CAPES) – Finance Code 001, and FAPESP, proc. 2014/50937-1 and 2015/24485-9.

Any opinions, findings, and conclusions or recommendations expressed in this material are those of the authors and do not necessarily reflect the views of FUNDECT, Finep, FAPESP, CAPES, and CNPq.

Author information

Authors and Affiliations

  1. Alfaneo, Goias, 405, 79020-100, Campo Grande, MS, Brazil

    Charles F. O. Viegas & Bruno C. Costa

  2. Federal University of Mato Grosso do Sul, Campo Grande, MS, Brazil

    Renato P. Ishii

Corresponding author

Correspondence to Renato P. Ishii .

Fonte: https://link.springer.com/chapter/10.1007/978-3-031-36805-9_24

Sumário

Newsletter

Fique por dentro das últimas novidades em inteligência artificial!

Faça sua busca
Categorias
  • Artigos
  • Blog
  • Júridico
  • Liderança
  • Negócios
  • Notícias
  • Tecnologia

Posts relacionados

Como a Alfaneo se tornou case global da AWS
  • Blog

Como a Alfaneo se tornou case global da AWS

26.05.2025
  • Blog

Advocacia Digital: O que está impulsionando os melhores advogados?

28.03.2025
Prepare-se para o Recesso Forense com IA Jurídica e Automações
  • Blog

Prepare-se para o Recesso Forense com IA Jurídica e Automações

05.12.2024

Fique por dentro!

Podemos ajudar?

Busque pela resposta que precisa em nossas Perguntas Frequentes. Caso prefira, entre em contato com a gente pelo Fale Conosco.

Perguntas Frequentes
Fale Conosco

Podemos ajudar?

Confira as Perguntas Frequentes ou fale com a gente.

Perguntas Frequentes
Fale Conosco
Logomarca Alfaneo

Siga nossas redes sociais

Na Alfaneo, não seguimos caminhos prontos, abrimos novas trilhas.

Endereço

R. Pedro Celestino, 3607, Sala 504
Campo Grande, MS
CEP: 79004-560

Contato

67 9 9348.9917

atendimento@alfaneo.ai

Empresas

Software personalizado para Empresas
Implementação da Inteligência Artificial
Automação com IA
Projeto sob medida com IA

Jurídico

Inteligência Artificial para Advogados
Criação de Petição Inicial com IA
Modelos de peças jurídicas
Análise de documentos jurídicos

Perícias

Inteligência Artificial para Peritos
Análise e validação de laudos com IA
Modelos de laudos periciais
Automação de laudos e pareceres

Conselhos de Classe Profissional

Implementação da IA no fluxo de trabalho
Automação de pareceres e decisões
Análise e geração de documentos com IA
Fiscalização e compliance de documentos com IA

Procuradorias e Defensorias

Automação de peças processuais
Análise de contratos e licitações com IA
Peticionamento Inteligente
Produção de peças personalizadas com IA

Alfaneo

Sobre a Empresa
Newsletter
Trabalhe Conosco
Central de Ajuda
Política de Privacidade e Cookies

Alfaneo © 2025

Todos os Direitos Reservados

Desenvolvido por:

Neex Brasil