The goal of this thesis is to optimize a conversational chatbot for the insurance domain using natural language processing algorithms and transformer model, specifically the BERT model, to enhance understanding of language and insurance-specific terminology. In the research, the chatbot was trained and tested in comparison with the LSTM model, with experimental results showing that the BERT model performs better due to its ability to understand broader context in user queries. This capability allows the chatbot to interpret complex and contextually rich queries more accurately, which is especially important for providing precise and reliable information in the insurance domain.