Business Activities Using Chatbots

In this article, we present a short introduction about chatbots and we describe two original chatbot solutions used in education and tourism. In the first part of the article, we describe the life cycle of a chatbot, presenting the steps needed for its development. We continue with the enumeration and description of the design techniques that developers are using in making the chatbots. The article also presents the architecture of two original chatbot solutions, the design methods and techniques used in their development and implementation and the usefulness and benefits of these two models. Moreover, possible future improvements of these chatbots for having an increased performance are presented. As a conclusion, we highlight the concern of business people for the use of chatbots in any field of activity and the progress that economic activity registers through their use.


Introduction
Science and technology are evolving at a rapid pace, and what we thought was possible in our lives decades ago is fortunately happening today. The multitude of solutions designed by the human mind, creativity and intelligence put at the service of evolution and good work wonders. The progress made in all areas of activity, the efficiency with which robots take over a large part of the activities done until recently by humans, the benefits of using robots in performing various actions, but with accomplishing tasks in a much shorter time and with minimal effort, low costs and the possibility of informing and storing a large amount of data, they have made AI necessary and sought, applied and desired in all areas. Nowadays, we see chat robots used almost everywhere. They are an inexhaustible source of answers and searches to questions from people in any field of activity and a quick way to search for this information. By the ability to store a very large amount of information in all fields, in many foreign languages, by the availability of using the robot 24 hours a day, at any time of day and night, from anywhere, but with a mandatory internet connection, AI is present in the activity of an entrepreneur, in research work, in companies and multinationals that have thousands of employees and therefore a very large amount of information must circulate and be used by all employees in multinationals at levels of development and professional development , in health, in education, in tourism, in business, in economics, in agriculture, in the activity of relaxation and recreation. A chatbot is an AI solution that converses with people. The conversation may be verbal in the case of voice queries or may be based on written text. The chatbot is useful for purchasing information and can be used on a variety of devices. Thus, we can use computers, laptops, tablets, mobile phones, smart watches, all with mandatory internet access. A chatbot has the ability to answer a user's questions or can initiate a topic of discussion based on models of questions and answers that it has included in the knowledge base. Chatbot is an IT solution that has builtin AI and uses NLP. Thus, the knowledge base of the chatbot makes the query of a user find an answer by using specific methods to search for the requested information, to resemble some words, to compare them going to the basic root of each word, the derivation words, their composition, structuring and classification of words in a sentence into parts of speech / parts of sentences. The chatbot even has the ability to understand the meaning of words in sentences and model an appropriate answer even if the user's expression is wrong or if some words were not typed correctly when the user wrote the request in the message by comparing the request with other similar question sets. and sending a close response as understood. When the recorded messages use words that refer to feelings, emotions and feelings, the chatbot even uses emoticons or other drawings, icons, representations of these feelings through which it transmits an answer to the user's query. The chatbot can also become a tool used in promoting activities performed by an entrepreneur or in a company by describing services, products, benefits, features of the solutions offered, how to implement them, possible improvements, development and application of these solutions in different branches of activity, the way they were thought and customized by different developers. Chat dialogue can also be used to promote product services and how to access these services. The developer designs the IT solution so as to meet the needs of users for the product, paying attention to market demand, the needs of the company, the number of people who would use the IT solution, the increased benefits of this solution, the price of the IT solution. on the labor market.

Chatbot life cycle
Amir Shevat describes the chatbot as a user interface that enables it to use services using messaging applications [15]. A chatbot is seen, in other cases, as an application that has a back-end logic and conversation interface developed throughout the life cycle. Chatbots can be developed quickly using bot platforms, such as Chatfuel and Botsify. Because no code is needed, these platforms are used mainly by beginners, people with little knowledge of computer science, people who want to implement these solutions and looking to see how people with experience in the field use them or they explain their functionality, or are used by non-technical users [1]. These platforms limit you to the development of the chatbot. Predefined functions and code are needed to develop chatbots easily and quickly (Microsoft Bot Framework). The chatbot development lifecycle, shown in Figure 1, contains several steps, such as requirements collection and architecture, which are followed when developing traditional software [2]. For the Specifications stage it is necessary to define the chatbot scope. If the chatbot is used in enterprises or multinationals, the chat must contain four details: the main use case that covers the basic functionality of the bot, the extended use case that solves the wider and more complex requests of the users, questions or requests from users about the company and the chatbot manufacturer, dealing with small discussions that require timely solutions to the problems of each employee. The development and testing stages are similar to the development of traditional software, but they also interconnect and are closely related to the development of the chatbot. Developers need to run many different tests to cover the multitude of chatbot use cases, and for chats they need to know what messaging applications users can use. After the implementation, the conversation databases are constantly checked, improved and monitored so that the transformations / changes that are brought to help the chatbot in modeling the answers and sending them to users. In this life cycle, usage is tested by examining the logs and trying to find any weaknesses that would slow down the chatbot or make it difficult to find an answer to the query. The collection of knowledge has been left out of the life cycle, and this is seen, in particular, in the development of the chatbot in healthcare. Here we need clear, precise knowledge that validates the messages and solutions given and gives security to the chatbot in replies.

Fig. 1. Chatbot life cycle
At the requirements stage, the specialist has clearly structured the plan by which the requests sent to the chatbot must meet the needs of the users and sets the high-level requirements, such as whether the dialogue is based on text or voice. With the help of the requirements, a specification is written that defines the functionality of the chatbot. The collection of knowledge that will be implemented in the chatbot database contains data from experts in the field and representations of the links between pieces of knowledge taken from interviews with experts establishing a basic scheme that the chatbot will use in the analysis of every word in the message. Knowledge is entered into the database. Interviews conducted by experts in the field have the role of establishing information in the form of mechanisms through which a quantity of information is copied from the messages in the interviews. Scripts have the role of fulfilling an objective thought at the beginning of the action plan, such as extracting information from the user, selecting and classifying information to the user, dividing the information according to privacy levels or certain user requests. Chatbot scripts are created using the knowledge base, then sent to the expert in the field for validation. It controls, analyzes, modifies, tests, removes, introduces, visualizes all knowledge until it sees that the script fulfills the specified objective. Knowledge collection and scripting are closely linked because scripts are always refined and additional knowledge is added to the knowledge base so that the chatbot is able to formulate and send a response to the user even when his request contains misunderstood words. as a chatbot. In this case, the chatbot uses keywords and applies word or statement similarities to find a suitable answer. The stages of developing possible dialogues between the user and the chatbot, as well as the analysis of the dialogue scenarios are adapted to verify, modify, transform and analyze the chatbot scripts. Analytical thinking has the role of analyzing each structure used in the rendering of the chatbot's message and is organized into categories that reflect the logic of the message and its way of thinking and structuring. These categories include the goals and objectives to be achieved in the message, the information from which it starts initially (premise) and with which it starts on the road in the analysis of the request and in thinking of the action plan to obtain a concrete and correct response for the user, structure, dialogue, character, totality of rules and norms used in the writing of the message by the chatbot or in the vocal rendering of the message (visual grammar), rhythm, conclusion [3]. The developer gathers the information and chooses the development platform that meets the requirements. The front-end and back-end components are defined before the IT solution is developed. Chatbot usage testing is performed before it is implemented. The use of a chatbot can be improved using the creativity and experience of the developer, the demands of companies and personalization of services, the evolution of society as a whole, the demand and supply of the labor market, the desire to improve the specialist who constantly seeks new and high-performance models [4]. An example is the proper integration of users to ensure that they know what the bot can do. Once developed and tested, the chatbot can be implemented and published in the user's chosen environment. The IT solution needs advertising in a wide range of ways so that it is known, demanded in the market, improved by different and personalized approaches, applied in different fields and in a multitude of locations around the world using online. As the number of users increases, controlling and monitoring conversation logs allows the developer to find moments of conversation breaks that are not detected at the testing stage. In this case, after analyzing the conversation logs, the scripts are refined, the moments with zero conversation are analyzed, and the life cycle steps that lead to the improvement of the chatbot are repeated.

Chatbot design techniques
The figure below illustrates the processes of the chatbot system. The user must have a computer to access the chatbot (UI) user interface. A text interface will appear on the chatbot interface, where the user can stream text input through the console. The text is divided into words that are then separated to be labeled. Most words are not used at first, they are analyzed and studied to see which will be introduced in the knowledge base of the chatbot. Several phrases often used in communication and which have a major meaning will be used later by matching the words, thus creating similarities between words through the message modeling process [5]. These phrases will be used in communication as keywords facilitating the word matching process. Keywords resulting from the process of blocking certain less frequently used words are then matched to the chatbot template. The process by which keywords match knowledge patterns is called LOGIC BOT [6]. Based on the reviews of several papers, I concluded that designing a chatbot requires several techniques and approaches. Among the most popular techniques used by developers are the following: -AIML means artificial intelligence modeling language. With the help of this language, human interfaces are created, keeping the implementation simple to program, easy to understand and use. The main goal of the AIML language is to direct the transformation of the modeling of the chatbot-user dialogue into a process that responds to the stimulus. This action by which words often used in communication are identified is known as frequent tags. AIML does not require advanced and complex programming language skills. Therefore, this technique is mostly used in the development and implementation of chatbots [7]. AIML 1.0 has poor matching patterns and is difficult to maintain. The content is easy to enter. The main problem with this language is the large amount of information that is entered manually to make the chatbot work. That is why it is used less and less. AIML 2.0 is a new chatbot language that meets all development and implementation requirements and that developers use successfully by fitting into new chatbot models.  [10]. The usefulness of this chatbot can be found in: -viewing the grades and attendance sheet for each student of the university -information regarding the admission to the different profiles / specializations of the university -information about students' exams (year of study, faculty, specialization, day, time, group) -volunteer activities carried out through the university -exchange of experience between universities -specialized practice realized through the partnership of the university with different companies from the country or from abroad -offering specialized support in finding / finding jobs in the field -online tests in different disciplines, by years of study, with simple and multiple answers, with time limit in assessment, through which students test their knowledge and prepare effectively for exams -saving students and teachers time because they do not have to go to university in person every day and can carry out part of their online activity through the chatbot or take the necessary information directly from the chatbot -the student is permanently informed about the activities in the university -saving money -students and staff are free to upload their questions -the chatbot provides a quick search for answers to questions -students receive appropriate links for their question.

Proposed system
When each student asks the chatbot about attendance, grades from each subject accumulated arrear, his place in the ranking of the group he belongs to, fees payable and payment deadline, it is necessary to authenticate in the application by specifying username and password. If this data is invalid, the chatbot sends a message to the student, and the student tries a new authentication communicating the correct data. If the student successfully logs in, the chatbot searches for keywords in the text entered / communicated verbally by the student. Based on these keywords, the chatbot understands what information the student wants and what algorithms will need to apply to obtain this information. At each chatbot conversation with a student, the information is grouped into templates in AIML files. If the student's request matches a template in the AIML files, the chatbot response will be sent to the student. If AIML files have nothing in common with that query pattern, the chatbot uses a phrase-like algorithm (NLP) [8]. This algorithm is applied to the new request by verifying its resemblance to the questions of a set of models whose answers are available in the chatbot. If no question matches the student's request, the request is saved in a log file to search for information and find answers. The administrator can find the answer to this student's question in the chatbot's knowledge base. The student may also receive a random response from the chatbot suggesting that the answer is not yet available.

Fig. 3. Chatbot system
The student asks the chatbot questions to get answers. If the chatbot cannot answer some of the student's questions, the admin will update the chatbot database with new information. This leads to sending an appropriate answer to the student to the questions to which the chatbot had no answer available (Figure 4). If the student is satisfied with the chatbot's response and does not want to continue the discussion, he has the option to disconnect from the system. Once the student has left the system, the bot's input parameters are reset automatically.

Fig. 4. The activity diagram of the answer to the chatbot query
Through the chatbot application the student authenticates and collects the necessary information. Some of the information is obtained by querying the chatbot. The admin has the role of dealing with CRUD operations on the chatbot. Thus, it can add or update certain out-of-date information, it can delete unnecessary information, it can view all student and teacher accounts, it can view the entire data set in the chatbot.

Implementing the solution a). AIML
The chatbot's knowledge base was created with the help of which he could have a conversation with the student / teacher. For this, AIML files were used in which there are sets of questions and answers that the chatbot uses, seeking to understand the meaning of the user's question [9]. When the student asks a question to the chatbot, it is associated with the question and answer sets in the AIML files. The chatbot finds an answer that it sends to the student.

b). Lemmatization and POS Tagging
After the query, the chatbot removes keywords from the statements made by the student. Matching meanings and words similar to those used by the student are identified through the process called POS lemmatization and labeling. This process groups all the words in the database by the root of the base word, considering all the forms of compound words, derived with suffixes / prefixes that can be mapped by the root of each word. In this chatbot was used the WordNet library written in Python with the help of which the POS lemmatization and labeling process is performed.

c). The semantic meaning
The signatory meaning refers to the multitude of combinations through which several students can ask the same question to the chatbot using different words. To solve this problem more easily, the chatbot uses the common points between student queries and answers available in the system based on which it manages to find an answer to each student's request by constantly referring to the set of questions and answers in the database. The percentage of similarity of two sentences is given by calculating the approximations of meaning of each keyword in the two sentences followed. Each keyword in the first statement is compared and associated with each keyword in the second statement. Thus, the chatbot finds the word that most closely resembles the original word. The similarity percentage of a single word is calculated and this similarity score will also indicate how the newly formed sentence will find similarity with the initial one. Calculate the minimum margin number of each word in the statement that resembles another word and create a structure of the statements used.

d). Log file
In the log file, the chatbot addresses all the questions it could not answer. The administrator checks this file and sees what the unanswered questions are, adds these answers by matching statements / phrases to the chatbot's knowledge base.

Chatbot solution improvements
In addition to AIML-based algorithms, other algorithms can be implemented and voice queries can be added. Students / teachers will vocally interrogate the chatbot and the system will send the text to the student / teacher. The successful use of this chatbot in the university field shows that the model can be implemented in other fields of activity, such as sports, health, forensic research and analysis [12]. The model is easy to implement in all areas, finding the necessary information quickly and easily.

Ticketing Chatbot Service 4.2.1 The usefulness of the solution
To find answers to a single request, such as: search for the price of a stay, how much the flight costs, book tickets for one or more people, order additional services, see what walking / sightseeing options we have at the requested destination, we interrogate a human operator. In order to obtain this information, the person in question must search, check what time means. An alternative way to solve these activities is to use the chatbot. It offers 24 hours of service a day, which is an advantage over a personal human assistant. The chatbot processes the natural NLP language, analyzes the request and extracts the information with the help of keywords. The chatbot solution presented below is used in the field of tourism helping people who want to choose pleasant destinations in the country or in the world to get information about different locations quickly, compare the price of flight tickets from different airlines offering users the opportunity to buy the cheaper ticket, reservations can be made as well as flight payments, information on tourist attractions in the area, restaurants / terraces / cafes, ways to travel in the city using different means, cancellation of a stay or a flight when the user does not it also wants to go to the original destination, change or change the time or day of a flight or the destination originally set. An important step in the NLP process is morphological analysis. Thus, part of the speech message (POS) turns into tagging and will help the chatbot analyze the meaning of each word in the statement, as well as the meaning of the entire text in the chat based on a set of questions and answers from the chatbot's knowledge base, as well as based on a set of rules [14]. The rule set includes all the keywords on which the chat text is based. Thus, in the case of this chatbot, the keywords used in the conversation can be: destination city, departure / arrival date, number of people. In confirming the booking of a ticket, NLP helps to analyze the different models and to describe the requests through which the chatbot receives orders from the user, such as to search and find the requested city and date. The chatbot model is an efficient solution through which quickly and easily, a person buys a ticket to the chosen destination, is informed about everything he needs in the trip he is going to make without going to the airport or the counter where he should go. to buy the ticket, do not spend many hours traveling to various locations to pay for various additional travel requests [11].

Methods
The figure below shows the system architecture and response flow. The system is divided into three parts: -Node JS Webhook -Wit.AI NPL services -Tiket.com Order API Webhook works as a notification service. A user can enter an application and change data in the application. When people affected by the change in this data need to know this they will be notified via the Webhook. In the case of the chatbot application Webhook works with the help of HTTP verbs POST and GET. The GET application is used when the user registers the application to WebHook services in Facebook. The POST application is used when updating the Facebook chat. The advantage of using Webhook is the easy integration of data. Data processed and saved in one user's request may be reused in another user's request. Webhook makes the NPL service use features defined in Webhook so that data processing is easier to use and faster [13].  The architecture of the chatbot can be seen in Figure 7. The section in which the intentions are classified identifies the users' intentions in the messages they write to the chatbot or in voice calls. The section for recognizing similarities or meaningful similarities between words / statements extracts that personalized information from users' messages grouped into sets of templates. The section where the user's response to the chatbot looking for more information is analyzed helps the chatbot select the best answer for the user's query. Based on the understanding of the user's request, studying the conversational flow and the patterns of questions and answers in the knowledge base, the chatbot provides an answer to the conversation with the user.

Fig. 8. Conversational Flow
The conversation flow is in the NLP services and serves to guide the conversation. After the user queries the chatbot, the answer is searched in the knowledge base and in the sets of models with questions and answers from various users. The chatbot seeks to understand the meaning of the request using the conversation model from Wit.AI by representing the field of activity from which the information is requested and using the keywords. The understanding of the message from the information received from the user is also done by selecting the words according to the keywords found in the message using synonyms of the intention through which the initial word is represented. Wit.AI has features that analyze user demand using NLP.
With the help of NLP is understood the user's message using texts and data sets based on the structure of the initial sentence in the form of subject, predicate, attribute, complement or in the form of parts of speech such as verb, noun, adjective, pronoun. If the user's information has in common with keywords or word patterns found in datasets, then the request sends back NLP entities that have a high percentage of trust, that is, the chatbot finds an answer to the user's request. Wit.AI can find a specific word, such as destination, time of departure, how many people. It is based on the recognition of the entity. Each conversation or question to the chatbot must have some parameters. Thus, if a user wants to know a destination, the chatbot can provide him with the information knowing first when he wants to have the flight and where exactly he wants the user to fly.

Chatbot solution improvements
The NLP algorithm used in the development of this chatbot model can be improved by adding memory cells that can help quickly dial old information into the conversation with the user. The memory cell's role is to save some of the user's voice messages or behavior, all of which are measured and used as conversation patterns [12]. When the chatbot encounters different user behaviors than what conversation patterns and behaviors are included in the database, it will not respond in the same way to instructions received. When the user does not type the statement correctly, the chatbot will be able to understand what the user meant and ask and provide the appropriate answer.

Conclusion
In this paper we highlighted the usefulness of chatbots in different fields of activity and exemplified its use in two different sectorseducation and tourism -bringing arguments for the development and implementation of original IT solutions by listing and describing the steps to follow in achieving these goals. , by presenting the architecture of the solutions, the design methods and techniques, the programming languages used, the algorithms used to create the knowledge base of the chatbot, possible improvements of the two models described. The evolution of the company requires that developers, at the request of managers and business owners, build custom chatbots that perform particular, personalized tasks, depending on the needs of the company, employees, tasks to be performed and objectives to be achieved. It is an upward trend that reflects the high demand for such models designed, built, developed, implemented especially for people working in various industries and face specific problems in solving professional tasks. The development and implementation of a chatbot also requires advanced technical knowledge. They are evaluated and refreshed permanently by continuously informing the specialists in the field, by training courses, by creativity and originality, by studying a multitude of IT solutions that observe and analyze the way they were thought, created, developed, implemented, tested these solutions so that they evolve with the requirements, development and needs of the company, but also with the demand and supply ratio, the upward or downward trend of using IT solutions on the market so that we can talk about progress, profit the company, but also the benefits of society as a whole. The two original solutions described in this paper reflect some of the benefits that these applications bring in education and tourism, but also with the possibility of improvement, development and implementation in all sectors of activity. You can see the steps followed by the developer in building and implementing each chatbot, the field of activity in which it is used, the need to customize the application according to other areas of applicability and customer needs and requirements related to the economic evolution of the company. Through the work I have gathered a part of my research activity on the use of chatbots in various fields of activity. These documentation actions related to the development of the chatbot according to the evolution of the company, the needs of companies and different needs in existing fields of work, how to develop and implement solutions and the growing requirements of the company regarding the chatbot as a necessity in each field, improvements to an implemented application, lead to the improvement of developers, helps specialists in the field to create ingenious solutions tailored to customer expectations.