System
The system addresses the challenge of managing data across multiple applications by allowing users to input and manipulate database queries in natural language, enhancing user convenience and efficiency through a generative AI-based SQL generation process.
Patent Information
- Application Number
- JP2024133577
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-08-08
- Publication Date
- 2026-02-20
AI Technical Summary
Current generative AI systems face challenges in referring to long-term records and require data manipulation dependent on specific applications, leading to low user convenience and cumbersome operations due to data being managed in different applications for different purposes.
A system that generates SQL from natural language using a generative AI, allowing users to input database queries in natural language, parse them using a generative AI model, generate structured query language (SQL), send the SQL to a database, and return results to the user, enabling free access and manipulation of data without relying on individual applications.
Enables users to intuitively access and operate databases using natural language, improving convenience and efficiency in data access and manipulation.
Smart Images

Figure 2026030593000001_ABST
Abstract
Description
[Technical Field]
[0001] The technology of the present disclosure relates to a system. [Background technology]
[0002] Patent document 1 discloses a persona chatbot control method performed by at least one processor, the method including the steps of receiving a user utterance, adding the user utterance to a prompt including an instruction sentence related to a description of the chatbot character, encoding the prompt, and inputting the encoded prompt into a language model to generate a chatbot utterance in response to the user utterance. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] Japanese Patent Publication No. 2022-180282 Summary of the Invention [Problem to be solved by the invention]
[0004] Current generative AI systems have the problem of making it difficult to refer to long-term records and requiring data manipulation that is dependent on specific applications, resulting in low user convenience. Furthermore, because data is managed in different applications for different purposes, users face the cumbersome task of switching between and operating multiple applications. This makes it difficult for users to freely access and manipulate information. [Means for solving the problem]
[0005] The present invention solves the above-mentioned problems by providing a system that generates SQL from natural language using a generative AI. Specifically, the system includes a means for a user to input a database query in natural language, a means for parsing the natural language database query using a generative AI, a means for generating a structured query language (SQL) using the analysis results of the generative AI, a means for sending the SQL to a database, and a means for returning the results obtained from the database to the user. This allows users to freely access and manipulate data without relying on individual applications.
[0006] A "user" is a person or entity that utilizes the system to provide natural language input and perform database queries.
[0007] "Natural language" is the language used by people on a daily basis, in unstructured forms of text and speech.
[0008] A "database query" is a command or instruction that instructs an operation to retrieve, insert, update, or delete specified data from a database.
[0009] "Generative AI" refers to models or systems that use artificial intelligence techniques to convert natural language into a structured form (e.g., SQL).
[0010] "Syntax analysis" is the process of analyzing natural language text to understand its meaning and convert it into an appropriate structure.
[0011] "Structured Query Language (SQL)" is a standard query language used in database management systems, consisting of instructions for defining, manipulating, and controlling data.
[0012] A "database" is a collection of data that is managed in a specific structure and can be searched, inserted, updated, and deleted.
[0013] "Transmission" is the process of transferring data or instructions from one system or device to another.
[0014] "Results" are the data or output obtained after executing a database query.
[0015] "Return" is the process in which the server returns the processed results to the original user or terminal. [Brief explanation of the drawings]
[0016] [Figure 1] 1 is a conceptual diagram showing an example of the configuration of a data processing system according to a first embodiment. [Figure 2] 1 is a conceptual diagram showing an example of main functions of a data processing device and a smart device according to a first embodiment. [Figure 3] FIG. 10 is a conceptual diagram showing an example of the configuration of a data processing system according to a second embodiment. [Figure 4] FIG. 10 is a conceptual diagram showing an example of main functions of a data processing device and smart glasses according to a second embodiment. [Figure 5] FIG. 10 is a conceptual diagram showing an example of the configuration of a data processing system according to a third embodiment. [Figure 6] FIG. 11 is a conceptual diagram showing an example of main functions of a data processing device and a headset-type terminal according to a third embodiment. [Figure 7] FIG. 10 is a conceptual diagram showing an example of the configuration of a data processing system according to a fourth embodiment. [Figure 8] FIG. 10 is a conceptual diagram showing an example of main functions of a data processing device and a robot according to a fourth embodiment. [Figure 9] 1 shows an emotion map onto which multiple emotions are mapped. [Figure 10] 1 shows an emotion map onto which multiple emotions are mapped. [Figure 11] FIG. 3 is a sequence diagram showing a processing flow of the data processing system according to the first embodiment. [Figure 12]FIG. 10 is a sequence diagram showing the flow of processing in the data processing system in Application Example 1. [Figure 13] FIG. 10 is a sequence diagram showing the flow of processing in the data processing system according to the second embodiment when an emotion engine is combined. [Figure 14] FIG. 10 is a sequence diagram showing the flow of processing in the data processing system in Application Example 2 when an emotion engine is combined. DETAILED DESCRIPTION OF THE INVENTION
[0017] An example of an embodiment of a system according to the technology of the present disclosure will be described below with reference to the accompanying drawings.
[0018] First, the terms used in the following description will be explained.
[0019] In the following embodiments, a coded processor (hereinafter simply referred to as a "processor") may be a single arithmetic device or a combination of multiple arithmetic devices. Furthermore, a processor may be a single type of arithmetic device or a combination of multiple types of arithmetic devices. Examples of arithmetic devices include a CPU (Central Processing Unit), a GPU (Graphics Processing Unit), a GPGPU (General-Purpose computing on Graphics Processing Units), and an APU (Accelerated Processing Unit).
[0020] In the following embodiments, a coded RAM (Random Access Memory) is a memory in which information is temporarily stored and is used as a working memory by a processor.
[0021] In the following embodiments, the coded storage is one or more non-volatile storage devices that store various programs, various parameters, etc. Examples of non-volatile storage devices include flash memory (SSD (Solid State Drive)), magnetic disks (e.g., hard disks), and magnetic tapes.
[0022] In the following embodiments, a communication I / F (Interface) with a symbol is an interface including a communication processor, an antenna, etc. The communication I / F controls communication between multiple computers. Examples of communication standards applied to the communication I / F include wireless communication standards including 5G (5th Generation Mobile Communication System), Wi-Fi (registered trademark), Bluetooth (registered trademark), etc.
[0023] In the following embodiments, "A and / or B" is synonymous with "at least one of A and B." In other words, "A and / or B" means that it may be only A, only B, or a combination of A and B. Furthermore, in this specification, the same concept as "A and / or B" is also applied when three or more things are expressed connected by "and / or."
[0024] [First embodiment]
[0025] FIG. 1 shows an example of the configuration of a data processing system 10 according to the first embodiment.
[0026] 1, a data processing system 10 includes a data processing device 12 and a smart device 14. An example of the data processing device 12 is a server.
[0027] The data processing device 12 includes a computer 22, a database 24, and a communication I / F 26. The computer 22 is an example of a "computer" according to the technology of the present disclosure. The computer 22 includes a processor 28, a RAM 30, and a storage 32. The processor 28, the RAM 30, and the storage 32 are connected to a bus 34. The database 24 and the communication I / F 26 are also connected to the bus 34. The communication I / F 26 is connected to a network 54. Examples of the network 54 include a WAN (Wide Area Network) and / or a LAN (Local Area Network).
[0028] The smart device 14 includes a computer 36, a reception device 38, an output device 40, a camera 42, and a communication I / F 44. The computer 36 includes a processor 46, a RAM 48, and a storage 50. The processor 46, the RAM 48, and the storage 50 are connected to a bus 52. The reception device 38, the output device 40, and the camera 42 are also connected to the bus 52.
[0029] The reception device 38 includes a touch panel 38A, a microphone 38B, and the like, and receives user input. The touch panel 38A detects contact with an indicator (for example, a pen or a finger) to receive user input by the touch of the indicator. The microphone 38B detects the user's voice to receive user input by voice. The control unit 46A transmits data indicating the user input received by the touch panel 38A and the microphone 38B to the data processing device 12. In the data processing device 12, the specific processing unit 290 acquires the data indicating the user input.
[0030] The output device 40 includes a display 40A and a speaker 40B, and presents data to the user 20 by outputting the data in a form of expression that the user 20 can perceive (for example, audio and / or text). The display 40A displays visible information such as text and images in accordance with instructions from the processor 46. The speaker 40B outputs audio in accordance with instructions from the processor 46. The camera 42 is a compact digital camera equipped with an optical system including a lens, aperture, and shutter, and an imaging element such as a CMOS (Complementary Metal-Oxide-Semiconductor) image sensor or a CCD (Charge Coupled Device) image sensor.
[0031] The communication I / F 44 is connected to a network 54. The communication I / Fs 44 and 26 control the exchange of various information between the processor 46 and the processor 28 via the network 54.
[0032] FIG. 2 shows an example of the main functions of the data processing device 12 and the smart device 14.
[0033] 2, in the data processing device 12, a specific process is performed by the processor 28. A specific processing program 56 is stored in the storage 32. The specific processing program 56 is an example of a "program" according to the technology of the present disclosure. The processor 28 reads the specific processing program 56 from the storage 32 and executes the read specific processing program 56 on the RAM 30. The specific process is realized by the processor 28 operating as a specific processing unit 290 in accordance with the specific processing program 56 executed on the RAM 30.
[0034] The storage 32 stores a data generation model 58 and an emotion identification model 59. The data generation model 58 and the emotion identification model 59 are used by the identification processing unit 290.
[0035] In the smart device 14, the processor 46 performs the reception output process. The storage 50 stores a reception output program 60. The reception output program 60 is used in conjunction with the specific processing program 56 by the data processing system 10. The processor 46 reads the reception output program 60 from the storage 50 and executes the read reception output program 60 on the RAM 48. The reception output process is realized by the processor 46 operating as the control unit 46A in accordance with the reception output program 60 executed on the RAM 48.
[0036] Next, a description will be given of the specific processing performed by the specific processing unit 290 of the data processing device 12. In the following description, the data processing device 12 will be referred to as a "server" and the smart device 14 will be referred to as a "terminal."
[0037] Overall system overview
[0038] This invention is a system in which a generation AI converts requests entered by a user in natural language into SQL queries and executes those queries against a database.
[0039] System configuration
[0040] 1. User input:
[0041] Users can input queries in natural language through the device interface, for example, by entering a specific request such as "Tell me my shopping spending for July 2023."
[0042] 2. Receiving and sending input:
[0043] The device receives natural language input from the user and sends it to the server, which understands the user's intent, converts it into an appropriate data format, and sends it.
[0044] 3. Natural Language Analysis:
[0045] The server passes the received natural language request to a generative AI model for natural language analysis, which allows the system to understand the user's intent and translate it into a structured query language, such as SQL.
[0046] 4. Generate SQL queries:
[0047] The server's generation AI automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0048] 5. Query the database:
[0049] The server sends the generated SQL query to the database to retrieve the specified data.
[0050] 6. Return and display of results:
[0051] The device receives the query results from the server and displays them to the user in a format that is easy for the user to understand. For example, it might say, "Shopping expenses for July 2023 total 15,000 yen."
[0052] Specific examples
[0053] 1. User input:
[0054] The user types "Tell me my shopping expenses for July 2023" into the device interface.
[0055] 2. Receiving and sending input:
[0056] The terminal receives this input and transmits it over the network to the server.
[0057] 3. Natural Language Analysis:
[0058] The server uses generative AI to parse the natural language input, such as "Tell me about my shopping expenses in July 2023," and understand the intent.
[0059] 4. Generate SQL queries:
[0060] The generation AI generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0061] 5. Query the database:
[0062] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[0063] 6. Return and display of results:
[0064] The server receives the results from the database and sends them back to the terminal, which then displays to the user, "The total shopping expenditure for July 2023 is 15,000 yen."
[0065] Program processing overview
[0066] User: Enters a query in natural language into the device.
[0067] Terminal: Sends user input to the server.
[0068] Server: Uses generative AI to analyze natural language queries, generate SQL queries, send the queries to the database, and retrieve the results.
[0069] Terminal: Displays the results received from the server to the user.
[0070] In this way, the present invention enables users to freely access and operate databases using natural language, without relying on a specific application, dramatically improving the convenience of accessing information and manipulating data.
[0071] The processing flow will be explained below.
[0072] Step 1:
[0073] The user enters a query in natural language into the device interface, for example, "What are my shopping expenses for July 2023?"
[0074] Step 2:
[0075] The terminal receives this input and sends the user's natural language query to the server, including the process of converting the input data into an appropriate format for transmission.
[0076] Step 3:
[0077] The server passes the received natural language query to the generative AI model, which then performs syntactic analysis of the natural language and performs processing to accurately understand the user's intent.
[0078] Step 4:
[0079] The generative AI model generates SQL queries based on the analyzed natural language query. For example, it generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" from the input natural language.
[0080] Step 5:
[0081] The server sends the generated SQL query to the database, which searches for data based on the specified criteria.
[0082] Step 6:
[0083] The database executes the query and sends the results back to the server. For example, if the total shopping expenditure for July is 15,000 yen, the results are sent back to the server.
[0084] Step 7:
[0085] The server receives the results returned from the database and returns them to the terminal, formatted in a way that is easy for the user to understand.
[0086] Step 8:
[0087] The terminal displays the results it receives to the user. For example, it displays something like, "The total shopping expenditure for July 2023 is 15,000 yen."
[0088] This concrete processing step allows users to access the database through a natural language interface and intuitively obtain the information they need. The entire system is designed to be simple and user-friendly.
[0089] Example 1
[0090] Next, a description will be given of Example 1. In the following description, the data processing device 12 will be referred to as a "server" and the smart device 14 will be referred to as a "terminal."
[0091] Conventional database interfaces require specialized knowledge, making it difficult for general users to intuitively operate databases. Furthermore, the process of converting natural language into structured queries is complex, resulting in low accuracy and efficiency. This creates challenges that limit fast and accurate access to data.
[0092] The specific processing by the specific processing unit 290 of the data processing device 12 in the first embodiment is realized by the following means.
[0093] In this invention, the server includes: means for a user to input a database query in natural language; means for a terminal to receive the natural language query and transmit it to the server; means for the server to parse the natural language query using a generative AI model; means for generating a structured query language using the analysis results of the generative AI model; means for transmitting the structured query language to a database; means for the server to receive results obtained from the database and return them to the user; and means for the terminal to display the results to the user. This enables users to operate the database in natural language without having specialized knowledge, achieving fast and accurate access to data.
[0094] "User" refers to a person who uses the system to enter database queries in natural language and retrieve desired information.
[0095] A "terminal" is a device used by a user to input a natural language query, and is a device responsible for sending the query to a server and displaying the results received from the server to the user.
[0096] "Server" refers to the central processing unit of the system that receives natural language queries sent by users, analyzes them using a generative AI model, generates structured query language, and sends it to the database.
[0097] A "generative AI model" is an artificial intelligence model that analyzes natural language queries, understands their intent, and converts them into structured query language.
[0098] A "natural language query" is a query entered by a user in everyday language, and is a statement for retrieving specific information from a database.
[0099] A "structured query language" is a form of query language that is generated by a generative AI model based on natural language and can be executed against a database; an example is SQL.
[0100] A "database" is an information management system that receives queries sent using a structured query language, stores and manages corresponding data, and returns data in response to the queries.
[0101] "Results" are data retrieved from a database and information provided based on a user's natural language query.
[0102] This invention is a system in which a generative AI model converts requests entered by a user in natural language into SQL queries and executes the queries against a database. The system consists of the following components:
[0103] composition
[0104] 1. User Input
[0105] Users can use devices such as PCs or smartphones to input queries in natural language, for example, a specific request such as "Tell me my shopping expenditures for July 2023."
[0106] 2. Receiving and Sending Input
[0107] The device receives the user's natural language input and sends it to the server. The device converts the received input into an appropriate data format and sends it to the server as an API request, typically via an HTTP POST request.
[0108] 3. Natural Language Analysis
[0109] The server passes the received natural language request to a generative AI model, such as OpenAI's GPT-4. The server uses the generative AI model to parse the request and understand the user's intent.
[0110] 4. Generating SQL Queries
[0111] The generative AI model generates appropriate SQL queries from the parsed natural language input. For example, for the input "What is my shopping expenditure for July 2023?", it generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'."
[0112] 5. Querying the Database
[0113] The server then sends the generated SQL query to a database to retrieve the specified data, typically a database such as MySQL or PostgreSQL.
[0114] 6. Returning and displaying results
[0115] The server receives the results returned from the database and sends them to the device. The device then displays the received data in a format that is easy for the user to understand. For example, it might present the user with a message like, "The total shopping expenditure for July 2023 is 15,000 yen."
[0116] Specific examples
[0117] 1. User Input
[0118] The user types into the device interface, "Tell me my shopping expenses for July 2023."
[0119] 2. Receiving and Sending Input
[0120] The terminal receives this input and transmits it to the server over the network.
[0121] 3. Natural Language Analysis
[0122] The server uses the generative AI model to analyze the natural language input, such as "Tell me about my shopping expenses in July 2023," and understand the intent.
[0123] 4. Generating SQL Queries
[0124] The generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0125] 5. Querying the Database
[0126] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[0127] 6. Returning and displaying results
[0128] The server receives the results from the database and sends them back to the terminal, which then displays to the user, "The total shopping expenditure for July 2023 is 15,000 yen."
[0129] Prompt Sentence Examples
[0130] The server receives the user's input, "Tell me about my shopping expenses in July 2023," and sends the following prompt to the generative AI model:
[0131] "Convert natural language input: 'What was my shopping spend in July 2023?' into a SQL query."
[0132] This means that users can enter database queries in natural language that meet their intentions, even if they do not have specialized knowledge, and the generative AI model will generate appropriate SQL queries, allowing them to quickly obtain the results.
[0133] The flow of the identification process in the first embodiment will be described with reference to FIG.
[0134] System program processing flow
[0135] Step 1: User Input
[0136] explanation:
[0137] A user uses the terminal interface to enter a query in natural language.
[0138] input:
[0139] Natural language queries (e.g., "What was my shopping spend for July 2023?")
[0140] output:
[0141] Natural language requests
[0142] Specific behavior:
[0143] Users open an application or web browser on their PC or smartphone and type a query in natural language, which is sent through an interface such as a text box.
[0144] Step 2: Receiving and Sending Input
[0145] explanation:
[0146] The terminal receives the user's input and sends it to the server.
[0147] input:
[0148] Natural language requests
[0149] output:
[0150] API requests sent to the server
[0151] Specific behavior:
[0152] A program on the device takes the natural language input and sends it as an HTTP POST request to a server, for example, an API endpoint.
[0153] Step 3: Natural Language Analysis
[0154] explanation:
[0155] The server passes the received natural language request to a generative AI model for analysis.
[0156] input:
[0157] Natural language requests
[0158] output:
[0159] Parsed input data
[0160] Specific behavior:
[0161] The server sends a prompt to the generative AI model, for example:
[0162] "Convert natural language input: 'What was my shopping spend in July 2023?' into a SQL query."
[0163] The generative AI model uses this prompt to parse the input.
[0164] Step 4: Generate SQL queries
[0165] explanation:
[0166] A generative AI model generates appropriate SQL queries from the parsed natural language input.
[0167] input:
[0168] Parsed input data
[0169] output:
[0170] SQL Query
[0171] Specific behavior:
[0172] Based on the prompt, the generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" and returns it to the server.
[0173] Step 5: Query the database
[0174] explanation:
[0175] The server sends the generated SQL query to the database to retrieve the specified data.
[0176] input:
[0177] SQL Query
[0178] output:
[0179] Data retrieved from a database
[0180] Specific behavior:
[0181] The server program establishes a database connection, executes the generated SQL queries, and receives the query results from a database such as MySQL or PostgreSQL.
[0182] Step 6: Return and display results
[0183] explanation:
[0184] The server sends the results obtained from the database to the terminal, which displays them to the user.
[0185] input:
[0186] Data retrieved from a database
[0187] output:
[0188] Results displayed to the user
[0189] Specific behavior:
[0190] The server formats the acquired data in JSON format or similar and returns it to the device as an HTTP response. The device then reformats the received data and displays to the user, "Total shopping expenditures for July 2023 are 15,000 yen."
[0191] (Application example 1)
[0192] Next, a description will be given of Application Example 1. In the following description, the data processing device 12 will be referred to as a "server" and the smart device 14 will be referred to as a "terminal."
[0193] Currently, inventory management at logistics centers requires the use of dedicated terminals and specific software, which often makes operation complicated. It is also difficult to quickly check inventory information in real time or perform statistical analysis of data. This reduces management efficiency and increases the risk of operational errors and delays. The present invention aims to provide a simple interface using natural language to improve the efficiency of inventory management at logistics centers.
[0194] The specific processing by the specific processing unit 290 of the data processing device 12 in the application example 1 is realized by the following means.
[0195] In this invention, the server includes means for a user to input a database query in natural language, means for parsing the natural language database query using a generation AI, means for generating a structured query language using the analysis result by the generation AI, means for transmitting the structured query language to a database, means for returning the results obtained from the database to the user, means for a user to check inventory status in natural language at a logistics center, and means for managing inventory status using the parsed natural language query. This enables easy and fast inventory management using natural language.
[0196] The "means for a user to input a database query in natural language" is an interface that allows a user to input a query to a database using a natural language that is intuitively easy for the user to understand.
[0197] "Generative AI" is an artificial intelligence model used to parse and convert incoming natural language database queries into structured query language.
[0198] "Syntax analysis" is the process of analyzing queries entered in natural language and understanding their meaning and intent.
[0199] "Structured Query Language" refers to a structured form of database query language such as SQL.
[0200] The "means for sending to a database" is a system component for sending the generated structured query language to a database and executing the query.
[0201] The "means for users to check inventory status in natural language at a logistics center" is an interface that accepts natural language queries regarding inventory information at a logistics center, analyzes them, and provides inventory information.
[0202] The "means for managing inventory status using parsed natural language queries" is a system for retrieving information from an inventory database within a logistics center based on parsed natural language queries and managing that information.
[0203] The present invention is realized as an inventory management system in a distribution center. The operation of the entire system will be described in detail below.
[0204] Overall system configuration
[0205] 1. User Input
[0206] Users input queries in natural language through a smartphone or robot interface, making specific requests such as "What is the current stock level of product A?"
[0207] 2. Receiving and Sending Input
[0208] The terminal receives natural language input from the user and sends it to the server, which then understands the user's intent, converts it into an appropriate data format, and sends it.
[0209] 3. Natural Language Analysis
[0210] The server passes the received natural language request to a generative AI model (e.g., the GPT-2 model) for natural language parsing. This parsing process allows the system to understand the user's intent and convert it into a structured SQL query.
[0211] 4. Generating SQL Queries
[0212] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, such as "SELECT quantity FROM inventory WHERE product_name='Product A'".
[0213] 5. Querying the Database
[0214] The server then sends the generated SQL query to a database, typically an SQLite database, to retrieve data that matches the specified criteria.
[0215] 6. Returning and displaying results
[0216] The terminal receives the query results sent back from the server and displays them to the user. The display content is presented in a format that is easy for the user to understand. For example, it may say, "The current stock quantity of product A is 500 units."
[0217] Specific examples
[0218] User input: "What is the current stock quantity of product A?"
[0219] Generated SQL query: "SELECT quantity FROM inventory WHERE product_name='Product A'"
[0220] Return result: "The current stock quantity of product A is 500 units."
[0221] Prompt Sentence Examples
[0222] Prompt: "User: Tell me the current stock quantity of product A.\nGenerating AI:"
[0223] This system allows logistics center managers to quickly and accurately obtain inventory information using natural language. The smartphone and robot-based interface simplifies complex operations, significantly improving management efficiency.
[0224] The flow of the specific processing in the application example 1 will be described with reference to FIG.
[0225] Step 1:
[0226] The user inputs a query in natural language through a smartphone or robot interface. For example, a specific request might be, "Tell me the current stock level of product A." This input is received by the terminal.
[0227] Step 2:
[0228] The terminal transmits natural language queries received from a user to a server. The input is a natural language request, and the output is a request sent to the server. The terminal performs this transmission process over a network.
[0229] Step 3:
[0230] The server passes the received natural language request to a generative AI model (e.g., GPT-2) for syntax analysis. The input here is a natural language query, which the generative AI model analyzes and converts into SQL. This process is performed using a prompt in the form of "User: Tell me the current inventory of product A.\nGenerative AI:"
[0231] Step 4:
[0232] The generative AI model generates an appropriate SQL query from the parsed natural language. The input here is the natural language query passed to the generative AI model, and the output is the generated SQL query. As a specific example, the query generated is "SELECT quantity FROM inventory WHERE product_name='Product A'".
[0233] Step 5:
[0234] The server sends the generated SQL query to the database to retrieve data that matches the specified conditions. The input is the SQL query, and the output from the database is the result of executing the SQL query. This result is specific data such as inventory levels.
[0235] Step 6:
[0236] The server sends the results retrieved from the database to the terminal, which then displays them to the user. The input is the result of the SQL query, and the output is a display in a format that is easy for the user to understand. For example, the display might say, "The current stock quantity for product A is 500 units."
[0237] By the above steps, this invention makes it possible to efficiently manage inventory in a logistics center using natural language.
[0238] Furthermore, an emotion engine that estimates the user's emotion may be combined. That is, the identification processing unit 290 may estimate the user's emotion using the emotion identification model 59 and perform identification processing using the user's emotion.
[0239] Overall system overview
[0240] This invention combines a system in which a user inputs a request in natural language, a generation AI converts it into an SQL query, and executes the query against a database, with an emotion engine that recognizes the user's emotions and adjusts the system's response based on those emotions.
[0241] System configuration
[0242] 1. User input:
[0243] Users can input queries in natural language through the device interface, for example, by entering a specific request such as "Tell me my shopping spending for July 2023."
[0244] 2. Emotion Engine Analysis:
[0245] As the device receives user input, the emotion engine analyzes the user's emotions using voice, text, and even facial expression recognition technology. For example, if the user sounds sad while typing, their emotion will be analyzed.
[0246] 3. Sending input:
[0247] The device transmits the user's natural language input and analyzed emotion information to the server, allowing the server to receive the user's intention and emotion simultaneously.
[0248] 4. Natural Language Analysis:
[0249] The server passes the received natural language request to a generative AI model for natural language analysis, which allows the system to understand the user's intent and translate it into a structured query language, such as SQL.
[0250] 5. Generate SQL queries:
[0251] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0252] 6. Query the database:
[0253] The server sends the generated SQL query to the database to retrieve the specified data.
[0254] 7. Return and Adjustment of Results:
[0255] The server receives the results from the database and passes them to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is sad, the system adjusts to provide a more polite and kind response.
[0256] 8. Displaying the results:
[0257] The adjusted results are sent back to the device and displayed to the user. For example, it may say, "Your total shopping expenditure for July 2023 is 15,000 yen. Please let us know if you have any questions."
[0258] Specific examples
[0259] 1. User input:
[0260] The user types into the device, "Tell me my shopping expenses for July 2023," while speaking in a grumpy voice.
[0261] 2. Emotion Engine Analysis:
[0262] The terminal receives the user's input, and the emotion engine analyzes the user's emotion, which is irritation, from the grumpy voice.
[0263] 3. Sending input:
[0264] The device transmits a natural language request and interpreted emotion information to the server.
[0265] 4. Natural Language Analysis:
[0266] The server uses generative AI to parse the natural language phrase "Tell me about my shopping expenses in July 2023."
[0267] 5. Generate SQL queries:
[0268] The generation AI generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0269] 6. Query the database:
[0270] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[0271] 7. Return and Adjustment of Results:
[0272] The server passes the results to the emotion engine, which then adjusts the response, adding gentle words to calm down an annoyed user.
[0273] 8. Displaying the results:
[0274] The adjusted results are sent back to the device and displayed to the user, such as "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help."
[0275] This specific process allows users to access the database through a natural language interface and receive responses tailored to their emotions at the time. The entire system is designed to be simple and user-friendly.
[0276] The processing flow will be explained below.
[0277] Step 1:
[0278] The user enters a query in natural language into the device interface, for example, "What are my shopping expenses for July 2023?"
[0279] Step 2:
[0280] The device receives user input, and the emotion engine analyzes emotions from the user's input voice or text. The analyzed emotion information is identified as emotion tags such as "irritated" or "sad."
[0281] Step 3:
[0282] The device sends the received natural language input and emotion tag to the server. The transmitted data includes the user's input content and emotion information.
[0283] Step 4:
[0284] The server passes the received natural language request to the generative AI model, which analyzes the input natural language and processes it to understand the user's intent.
[0285] Step 5:
[0286] The server's generative AI model generates appropriate SQL queries from the analyzed natural language. For example, from the input "Tell me about my shopping expenditures in July 2023," the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" is generated.
[0287] Step 6:
[0288] The server sends the generated SQL query to the database to retrieve data based on the specified criteria, and the database executes the query and sends the results back to the server.
[0289] Step 7:
[0290] The server receives the retrieved data and passes it to the emotion engine, which tailors the response message based on the user's emotion tag. For example, if the user is "irritated," it generates a response using more polite and kind language.
[0291] Step 8:
[0292] The server sends the tailored response to the terminal, and the sent data includes the answer to the user's question and the tailored response message.
[0293] Step 9:
[0294] The device displays the results it receives to the user. For example, it might say, "Your total shopping expenditure for July 2023 is 15,000 yen. Please let us know if you have any questions." The user receives a thoughtful response that is in line with their feelings, providing a better user experience.
[0295] This specific processing step allows users to access the database through a natural language interface and receive responses tailored to their current emotions. The entire system is designed to be simple and user-friendly.
[0296] Example 2
[0297] Next, a description will be given of Example 2. In the following description, the data processing device 12 will be referred to as a "server" and the smart device 14 will be referred to as a "terminal."
[0298] Conventional systems have issues with being unable to accurately analyze the intent of users when they input database queries in natural language, and unable to provide responses based on the user's emotions, which can lead to poor user experience and make the system difficult to use.
[0299] The identification process by the identification processing unit 290 of the data processing device 12 in Example 2 is realized by the following means. In this invention, the server includes: means for a user to input a database query in natural language; means for analyzing the input natural language query and the user's emotions; means for parsing the natural language database query using a generation AI; means for generating a structured query language using the analysis result by the generation AI; means for transmitting the structured query language to a database; means for adjusting the result obtained from the database based on the user's emotions; and means for returning the adjusted result to the user. This makes it possible to accurately analyze the user's query input in natural language and provide a response adjusted based on the user's emotions.
[0300] "User" means any person or entity that utilizes the System to enter queries in natural language.
[0301] A "natural language query" refers to a database query entered by a user in natural language.
[0302] "Means for analyzing input natural language queries and user sentiment" refers to software and hardware for analyzing user-input queries and the associated sentiment.
[0303] "Generative AI" refers to artificial intelligence models used to parse natural language database queries.
[0304] "Means of parsing" refers to the process of using generative AI to parse natural language database queries.
[0305] A "structured query language" refers to a query language that can be executed against a database and is created by generative AI through analysis of natural language queries.
[0306] "Database" refers to a collection of data to which structured query languages are submitted.
[0307] "Means for adjusting based on user emotions" refers to software or algorithms for adjusting the obtained results based on the analyzed user emotions.
[0308] "Means for returning adjusted results to the user" refers to a process for returning adjusted results before they are displayed to the user.
[0309] This invention combines a system in which a user inputs a request in natural language, a generative AI converts it into an SQL query, and executes the query against a database, with an emotion engine. The system recognizes the user's emotions and adjusts the system's response based on those emotions.
[0310] System configuration
[0311] 1. The user enters a database query in natural language
[0312] Users input queries in natural language through the device interface, such as "Tell me my shopping spending for July 2023."
[0313] 2. Emotion Engine Analysis
[0314] As the device receives user input, the emotion engine analyzes the user's emotions using voice analysis, text analysis, and even facial expression recognition. For example, if the user's voice sounds irritated while typing, the emotion engine can detect it.
[0315] 3. Sending input data
[0316] The device sends the user's natural language input and analyzed emotion information to the server, allowing the server to receive the user's intention and emotion simultaneously.
[0317] System action
[0318] 1. Natural Language Analysis
[0319] The server passes the received natural language request to a generative AI model, which analyzes the natural language. This analysis allows the system to understand the user's intent and convert it into a structured query language, such as SQL. OpenAI's GPT-3 is one example of a generative AI model.
[0320] 2. Generating SQL Queries
[0321] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0322] 3. Sending a query to the database
[0323] The server sends the generated SQL query to a database, such as PostgreSQL, to retrieve the specified data.
[0324] 4. Adjustment of the results
[0325] The server receives the results from the database and passes them to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is annoyed, the system adjusts the response to use kind words.
[0326] 5. Displaying the results
[0327] The adjusted results are sent back to the device and displayed to the user. For example, it may say something like, "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help."
[0328] Specific examples
[0329] 1. User Input
[0330] The user types into the device, "Tell me my shopping expenses for July 2023," while speaking in a grumpy voice.
[0331] 2. Emotion Engine Analysis
[0332] The terminal receives the user's input, and the emotion engine analyzes the user's emotion, which is irritation, from the grumpy voice.
[0333] 3. Sending input data
[0334] The device transmits a natural language request and interpreted emotion information to the server.
[0335] Prompt Sentence Examples
[0336] "User asks: 'What are my shopping expenses for July 2023?'"
[0337] This specific process allows users to access the database through a natural language interface and receive responses tailored to their emotions at the time. This system provides users with an intuitive and convenient operation experience, while also realizing responses that take emotions into consideration.
[0338] The flow of the identification process in the second embodiment will be described with reference to FIG.
[0339] Specific processing explanation of the system program
[0340] Processing flow
[0341] Step 1:
[0342] The user inputs a query in natural language through the device interface, for example, "Tell me my shopping expenditures for July 2023." Input is done using the keyboard or voice input function of a PC or smartphone.
[0343] Input: Natural language query "What was my shopping spend for July 2023?"
[0344] Output: User input data
[0345] Step 2:
[0346] As soon as the device receives the user's input, the emotion engine analyzes the user's emotion, using, for example, voice analysis or text analysis. Emotions such as irritation are detected.
[0347] Input: User voice or text data
[0348] Output: Sentiment analysis result (e.g., irritation)
[0349] Step 3:
[0350] The device sends a natural language query and analyzed emotion information to the server, which then sends this data to the server using an HTTP request.
[0351] Input: Natural language query and sentiment analysis results
[0352] Output: Request data sent to the server
[0353] Step 4:
[0354] The server passes the received natural language query and sentiment information to a generative AI model, which analyzes the natural language. For example, OpenAI's GPT-3 is used as the generative AI model. The prompt sentence is "User question: 'Tell me about shopping expenses in July 2023.'"
[0355] Input: Natural language query and sentiment information
[0356] Output: Parsing results (structured information that understands the intent)
[0357] Step 5:
[0358] The generative AI model automatically generates appropriate SQL queries from the analyzed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0359] Input: Parsed result
[0360] Output: SQL query
[0361] Step 6:
[0362] The server sends the generated SQL query to a database, such as PostgreSQL, to retrieve the specified data.
[0363] Input: SQL query
[0364] Output: Data retrieved from the database (e.g., shopping expenditure total)
[0365] Step 7:
[0366] The server passes the results from the database to the emotion engine, which tailors the response based on the user's emotions, for example adding kind words to an annoyed user.
[0367] Input: Database results and emotion information
[0368] Output: Reconciled response message
[0369] Step 8:
[0370] The server sends the adjusted results back to the device, which then displays the results to the user. For example, a message like, "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help" may be displayed.
[0371] Input: Tailored response message
[0372] Output: The message displayed to the user
[0373] Specific operation example
[0374] User input: The user uses their smartphone to say, "Tell me my shopping expenses for July 2023."
[0375] Emotion engine analysis: The emotion engine detects irritation from the user's tone of voice.
[0376] Sending input: The device sends the analysis results and natural language query to the server.
[0377] Natural language parsing: The server prompts the generative AI model to parse the query and generate an SQL query.
[0378] SQL query generation: The generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" and returns it to the server.
[0379] Querying the database: The server executes the generated SQL query and retrieves the results from the database.
[0380] Returning and adjusting the results: The server uses the emotion engine to adjust the results and add friendly comments.
[0381] Displaying the results: The adjusted results are sent to the device and displayed to the user.
[0382] This allows users to receive responses based on natural language and emotions, making the entire system intuitive and user-friendly.
[0383] (Application example 2)
[0384] Next, a description will be given of Application Example 2. In the following description, the data processing device 12 will be referred to as a "server" and the smart device 14 will be referred to as a "terminal."
[0385] In modern brick-and-mortar stores, customers are required to provide instant and accurate responses when checking product and inventory information. However, conventional systems have difficulty responding appropriately to customer emotions, which can lead to dissatisfaction and stress. In particular, if a customer is feeling unhappy or irritated, not being able to respond appropriately can lead to a decline in the quality of the customer experience and lower satisfaction.
[0386] The specific processing by the specific processing unit 290 of the data processing device 12 in the application example 2 is realized by the following means.
[0387] In this invention, the server includes a means for a user to input a database query in natural language, a means for parsing the natural language database query using a generation AI, a means for generating a structured query language using the analysis results of the generation AI, and a means including an emotion engine for analyzing the user's emotions, thereby enabling a response to a question input by a customer in natural language to be made in an appropriate tone according to the emotion.
[0388] A "user" is a person who utilizes the system to enter database queries and retrieve information.
[0389] "Natural language" refers to the language used by humans in everyday speech and writing, as opposed to a structured query language.
[0390] A "database query" refers to a question sent to a database to retrieve information.
[0391] "Generative AI" is an artificial intelligence technique for analyzing natural language and converting it into a structured query language.
[0392] An "emotion engine" is a technology that analyzes a user's emotions and adjusts the system's response based on the analysis results.
[0393] "Means for adjusting responses" refers to methods for changing the content and tone of the system's responses based on the analysis results of the emotion engine.
[0394] "Brick and Mortar Store" means a sales and service establishment located at a physical location.
[0395] "Product and inventory questions" refer to inquiries made by customers in physical stores about specific products and their availability.
[0396] "Tone" refers to the tone and mood of speech or writing, and can change depending on emotions.
[0397] The system for implementing this invention is designed to allow users to ask questions about products and inventory in a physical store in natural language and to provide appropriate responses based on their emotions. Specific embodiments are described below.
[0398] Hardware and software used
[0399] Hardware
[0400] Smartphone
[0401] server
[0402] Database (e.g. SQLite)
[0403] software
[0404] Python
[0405] OpenAI GPT-3
[0406] sqlite3 library
[0407] text_to_emotion library
[0408] Text processing libraries (e.g. textblob)
[0409] Data processing and calculation
[0410] User input and sentiment analysis
[0411] When a user uses a smartphone to input a question about a product or inventory in natural language, the voice or text is sent to the system. When the device receives the question, it uses an emotion engine to analyze the user's emotion. For example, it uses the text_to_emotion library to extract emotions (anger, sadness, joy, etc.) from the user's voice or text.
[0412] Natural Language Parsing and Query Generation
[0413] Once the sentiment analysis is complete, the device sends the user's natural language input to the server, which uses a generative AI model (e.g., OpenAI GPT-3) to convert the natural language request into an SQL query, using an example prompt like this:
[0414] Generate a SQL query for: Is this item in stock?
[0415] The generative AI model automatically generates an appropriate SQL query (e.g., SELECT FROM inventory WHERE product_name='product name';) for this prompt statement.
[0416] Database Queries and Response Throttle
[0417] The server then sends the generated SQL query to the database to retrieve the specified data. The results are then passed back to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is frustrated, a softer response such as "We have it in stock. We will help you shortly, so please wait." is generated.
[0418] Specific examples
[0419] 1. User input: A user asks "Is this item in stock?" on their smartphone and types it in an annoyed voice.
[0420] 2. Emotion analysis: The emotion engine analyzes the user's frustration and sends the emotion information to the server.
[0421] 3. Natural language parsing: The server uses a generative AI model to translate natural language questions into SQL queries.
[0422] 4. Database Query: An SQL query is sent to the database to retrieve the appropriate inventory information.
[0423] 5. Response adjustment: Based on the obtained results, the emotion engine creates a response according to the user's emotions.
[0424] 6. Response display: The terminal will display "We have the item in stock. We will assist you shortly, so please wait."
[0425] Prompt Sentence Examples
[0426] Generate a SQL query for: Is this item in stock?
[0427] In this way, users can ask questions about products and inventory in natural language and receive appropriate responses based on their emotions. This system improves the customer experience in physical stores and provides highly satisfying service.
[0428] The flow of the specific processing in the application example 2 will be described with reference to FIG.
[0429] Step 1:
[0430] The user types a question into their smartphone in natural language, such as "Is this item in stock?" The input is sent to the device in voice or text format.
[0431] Step 2:
[0432] The device receives the user's question and uses an emotion engine to analyze the user's emotion from the input question and its voice or text. The emotion engine uses the text_to_emotion library to identify emotions (e.g., irritation, anger, sadness, etc.) from the question text or voice. The input of this process is the user's question, and the output is the emotion information identified by the emotion engine.
[0433] Step 3:
[0434] The device sends the input natural language question and analyzed emotion information to the server. In this step, the user's intention and emotion are passed to the server. The input is the natural language question and emotion information, and the output is data transmission to the server.
[0435] Step 4:
[0436] The server uses a generative AI model (e.g., OpenAI GPT-3) to convert natural language questions into SQL queries. An example prompt sentence is given to the generative AI model: "Generate a SQL query for: Is this item in stock?" The input is the prompt sentence, and the output is the generated SQL query.
[0437] Step 5:
[0438] The server sends the generated SQL query to a database to retrieve the corresponding data. An example of the database used is SQLite. The input of this process is the SQL query, and the output is the retrieved data.
[0439] Step 6:
[0440] The server passes the results retrieved from the database back to the emotion engine, which then adjusts the response based on the emotion. For example, a response such as "We have it in stock" may be generated based on the retrieved inventory information, and then adjusted to a gentler tone, such as "We will help you right away, so please wait," depending on the user's emotion. The input is the results from the database and emotion information, and the output is the adjusted response.
[0441] Step 7:
[0442] The terminal obtains the tailored response and displays or speaks it to the user. For example, it may say, "We have it in stock. We will help you shortly, so please wait." The input is the tailored response, and the output is the displayed or spoken response to the user.
[0443] Through the above steps, users can ask questions about products and inventory in natural language and receive appropriate responses according to their feelings.
[0444] The specific processing unit 290 transmits the result of the specific processing to the smart device 14. In the smart device 14, the control unit 46A causes the output device 40 to output the result of the specific processing. The microphone 38B acquires audio indicating a user input regarding the result of the specific processing. The control unit 46A transmits audio data indicating the user input acquired by the microphone 38B to the data processing device 12. In the data processing device 12, the specific processing unit 290 acquires the audio data.
[0445] The data generation model 58 is a so-called generative AI (Artificial Intelligence). An example of the data generation model 58 is ChatGPT (Internet Search<URL: https: / / openai.com / blog / chatgpt> ), Gemini (Internet search <url: https: gemini.google.com ?hl="ja">) and other generation AIs. The data generation model 58 is obtained by performing deep learning on a neural network. A prompt including an instruction is input to the data generation model 58, and inference data such as voice data indicating voice, text data indicating text, and image data indicating an image is also input. The data generation model 58 performs inference on the input inference data in accordance with the instruction indicated by the prompt, and outputs the inference result in a data format such as voice data and text data. Here, inference refers to, for example, analysis, classification, prediction, and / or summarization.
[0446] In the above embodiment, an example in which the specific process is performed by the data processing device 12 has been given, but the technology of the present disclosure is not limited to this, and the specific process may be performed by the smart device 14.
[0447] [Second embodiment]
[0448] FIG. 3 shows an example of the configuration of a data processing system 210 according to the second embodiment.
[0449] 3, the data processing system 210 includes the data processing device 12 and smart glasses 214. An example of the data processing device 12 is a server.
[0450] The data processing device 12 includes a computer 22, a database 24, and a communication I / F 26. The computer 22 is an example of a "computer" according to the technology of the present disclosure. The computer 22 includes a processor 28, a RAM 30, and a storage 32. The processor 28, the RAM 30, and the storage 32 are connected to a bus 34. The database 24 and the communication I / F 26 are also connected to the bus 34. The communication I / F 26 is connected to a network 54. Examples of the network 54 include a WAN (Wide Area Network) and / or a LAN (Local Area Network).
[0451] The smart glasses 214 include a computer 36, a microphone 238, a speaker 240, a camera 42, and a communication I / F 44. The computer 36 includes a processor 46, a RAM 48, and a storage 50. The processor 46, the RAM 48, and the storage 50 are connected to a bus 52. The microphone 238, the speaker 240, and the camera 42 are also connected to the bus 52.
[0452] The microphone 238 receives instructions and the like from the user 20 by receiving voice uttered by the user 20. The microphone 238 captures the voice uttered by the user 20, converts the captured voice into audio data, and outputs it to the processor 46. The speaker 240 outputs audio in accordance with instructions from the processor 46.
[0453] Camera 42 is a small digital camera equipped with an optical system including a lens, aperture, and shutter, and an imaging element such as a CMOS (Complementary Metal-Oxide-Semiconductor) image sensor or a CCD (Charge Coupled Device) image sensor, and captures images of the surroundings of user 20 (for example, an imaging range defined by an angle of view equivalent to the field of vision of a typical healthy person).
[0454] The communication I / F 44 is connected to a network 54. The communication I / Fs 44 and 26 are responsible for the exchange of various information between the processor 46 and the processor 28 via the network 54. The exchange of various information between the processor 46 and the processor 28 using the communication I / Fs 44 and 26 is carried out in a secure state.
[0455] Fig. 4 shows an example of the main functions of the data processing device 12 and the smart glasses 214. As shown in Fig. 4, in the data processing device 12, a specific process is performed by the processor 28. A specific process program 56 is stored in the storage 32.
[0456] The specific processing program 56 is an example of a "program" according to the technology of the present disclosure. The processor 28 reads the specific processing program 56 from the storage 32 and executes the read specific processing program 56 on the RAM 30. The specific processing is realized by the processor 28 operating as a specific processing unit 290 in accordance with the specific processing program 56 executed on the RAM 30.
[0457] The storage 32 stores a data generation model 58 and an emotion identification model 59. The data generation model 58 and the emotion identification model 59 are used by the identification processing unit 290.
[0458] In the smart glasses 214, the reception output process is performed by the processor 46. A reception output program 60 is stored in the storage 50. The processor 46 reads the reception output program 60 from the storage 50 and executes the read reception output program 60 on the RAM 48. The reception output process is realized by the processor 46 operating as the control unit 46A in accordance with the reception output program 60 executed on the RAM 48.
[0459] Next, a description will be given of the identification process performed by the identification processing unit 290 of the data processing device 12. In the following description, the data processing device 12 will be referred to as the "server" and the smart glasses 214 will be referred to as the "terminal."
[0460] Overall system overview
[0461] This invention is a system in which a generation AI converts requests entered by a user in natural language into SQL queries and executes those queries against a database.
[0462] System configuration
[0463] 1. User input:
[0464] Users can input queries in natural language through the device interface, for example, by entering a specific request such as "Tell me my shopping spending for July 2023."
[0465] 2. Receiving and sending input:
[0466] The device receives natural language input from the user and sends it to the server, which understands the user's intent, converts it into an appropriate data format, and sends it.
[0467] 3. Natural Language Analysis:
[0468] The server passes the received natural language request to a generative AI model for natural language analysis, which allows the system to understand the user's intent and translate it into a structured query language, such as SQL.
[0469] 4. Generate SQL queries:
[0470] The server's generation AI automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0471] 5. Query the database:
[0472] The server sends the generated SQL query to the database to retrieve the specified data.
[0473] 6. Return and display of results:
[0474] The device receives the query results from the server and displays them to the user in a format that is easy for the user to understand. For example, it might say, "Shopping expenses for July 2023 total 15,000 yen."
[0475] Specific examples
[0476] 1. User input:
[0477] The user types "Tell me my shopping expenses for July 2023" into the device interface.
[0478] 2. Receiving and sending input:
[0479] The terminal receives this input and transmits it over the network to the server.
[0480] 3. Natural Language Analysis:
[0481] The server uses generative AI to parse the natural language input, such as "Tell me about my shopping expenses in July 2023," and understand the intent.
[0482] 4. Generate SQL queries:
[0483] The generation AI generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0484] 5. Query the database:
[0485] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[0486] 6. Return and display of results:
[0487] The server receives the results from the database and sends them back to the terminal, which then displays to the user, "The total shopping expenditure for July 2023 is 15,000 yen."
[0488] Program processing overview
[0489] User: Enters a query in natural language into the device.
[0490] Terminal: Sends user input to the server.
[0491] Server: Uses generative AI to analyze natural language queries, generate SQL queries, send the queries to the database, and retrieve the results.
[0492] Terminal: Displays the results received from the server to the user.
[0493] In this way, the present invention enables users to freely access and operate databases using natural language, without relying on a specific application, dramatically improving the convenience of accessing information and manipulating data.
[0494] The processing flow will be explained below.
[0495] Step 1:
[0496] The user enters a query in natural language into the device interface, for example, "What are my shopping expenses for July 2023?"
[0497] Step 2:
[0498] The terminal receives this input and sends the user's natural language query to the server, including the process of converting the input data into an appropriate format for transmission.
[0499] Step 3:
[0500] The server passes the received natural language query to the generative AI model, which then performs syntactic analysis of the natural language and performs processing to accurately understand the user's intent.
[0501] Step 4:
[0502] The generative AI model generates SQL queries based on the analyzed natural language query. For example, it generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" from the input natural language.
[0503] Step 5:
[0504] The server sends the generated SQL query to the database, which searches for data based on the specified criteria.
[0505] Step 6:
[0506] The database executes the query and sends the results back to the server. For example, if the total shopping expenditure for July is 15,000 yen, the results are sent back to the server.
[0507] Step 7:
[0508] The server receives the results returned from the database and returns them to the terminal, formatted in a way that is easy for the user to understand.
[0509] Step 8:
[0510] The terminal displays the results it receives to the user. For example, it displays something like, "The total shopping expenditure for July 2023 is 15,000 yen."
[0511] These specific processing steps allow users to access the database through a natural language interface and intuitively obtain the information they need. The entire system is designed to be simple and user-friendly.
[0512] Example 1
[0513] Next, a description will be given of Example 1. In the following description, the data processing device 12 will be referred to as a "server" and the smart glasses 214 will be referred to as a "terminal."
[0514] Conventional database interfaces require specialized knowledge, making it difficult for general users to intuitively operate databases. Furthermore, the process of converting natural language into structured queries is complex, resulting in low accuracy and efficiency. This creates challenges that limit fast and accurate access to data.
[0515] The specific processing by the specific processing unit 290 of the data processing device 12 in the first embodiment is realized by the following means.
[0516] In this invention, the server includes: means for a user to input a database query in natural language; means for a terminal to receive the natural language query and transmit it to the server; means for the server to parse the natural language query using a generative AI model; means for generating a structured query language using the analysis results of the generative AI model; means for transmitting the structured query language to a database; means for the server to receive results obtained from the database and return them to the user; and means for the terminal to display the results to the user. This enables users to operate the database in natural language without having specialized knowledge, achieving fast and accurate access to data.
[0517] "User" refers to a person who uses the system to enter database queries in natural language and retrieve desired information.
[0518] A "terminal" is a device used by a user to input a natural language query, and is a device responsible for sending the query to a server and displaying the results received from the server to the user.
[0519] "Server" refers to the central processing unit of the system that receives natural language queries sent by users, analyzes them using a generative AI model, generates structured query language, and sends it to the database.
[0520] A "generative AI model" is an artificial intelligence model that analyzes natural language queries, understands their intent, and converts them into structured query language.
[0521] A "natural language query" is a query entered by a user in everyday language, and is a statement for retrieving specific information from a database.
[0522] A "structured query language" is a form of query language that is generated by a generative AI model based on natural language and can be executed against a database; an example is SQL.
[0523] A "database" is an information management system that receives queries sent using a structured query language, stores and manages corresponding data, and returns data in response to the queries.
[0524] "Results" are data retrieved from a database and information provided based on a user's natural language query.
[0525] This invention is a system in which a generative AI model converts requests entered by a user in natural language into SQL queries and executes the queries against a database. The system consists of the following components:
[0526] composition
[0527] 1. User Input
[0528] Users can use devices such as PCs or smartphones to input queries in natural language, for example, a specific request such as "Tell me my shopping expenditures for July 2023."
[0529] 2. Receiving and Sending Input
[0530] The device receives the user's natural language input and sends it to the server. The device converts the received input into an appropriate data format and sends it to the server as an API request, typically via an HTTP POST request.
[0531] 3. Natural Language Analysis
[0532] The server passes the received natural language request to a generative AI model, such as OpenAI's GPT-4. The server uses the generative AI model to parse the request and understand the user's intent.
[0533] 4. Generating SQL Queries
[0534] The generative AI model generates appropriate SQL queries from the parsed natural language input. For example, for the input "What is my shopping expenditure for July 2023?", it generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'."
[0535] 5. Querying the Database
[0536] The server then sends the generated SQL query to a database to retrieve the specified data, typically a database such as MySQL or PostgreSQL.
[0537] 6. Returning and displaying results
[0538] The server receives the results returned from the database and sends them to the device. The device then displays the received data in a format that is easy for the user to understand. For example, it might present the user with a message like, "The total shopping expenditure for July 2023 is 15,000 yen."
[0539] Specific examples
[0540] 1. User Input
[0541] The user types into the device interface, "Tell me my shopping expenses for July 2023."
[0542] 2. Receiving and Sending Input
[0543] The terminal receives this input and transmits it to the server over the network.
[0544] 3. Natural Language Analysis
[0545] The server uses the generative AI model to analyze the natural language input, such as "Tell me about my shopping expenses in July 2023," and understand the intent.
[0546] 4. Generating SQL Queries
[0547] The generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0548] 5. Querying the Database
[0549] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[0550] 6. Returning and displaying results
[0551] The server receives the results from the database and sends them back to the terminal, which then displays to the user, "The total shopping expenditure for July 2023 is 15,000 yen."
[0552] Prompt Sentence Examples
[0553] The server receives the user's input, "Tell me about my shopping expenses in July 2023," and sends the following prompt to the generative AI model:
[0554] "Convert natural language input: 'What was my shopping spend in July 2023?' into a SQL query."
[0555] This means that users can enter database queries in natural language that meet their intentions, even if they do not have specialized knowledge, and the generative AI model will generate appropriate SQL queries, allowing them to quickly obtain the results.
[0556] The flow of the identification process in the first embodiment will be described with reference to FIG.
[0557] System program processing flow
[0558] Step 1: User Input
[0559] explanation:
[0560] A user uses the terminal interface to enter a query in natural language.
[0561] input:
[0562] Natural language queries (e.g., "What was my shopping spend for July 2023?")
[0563] output:
[0564] Natural language requests
[0565] Specific behavior:
[0566] Users open an application or web browser on their PC or smartphone and type a query in natural language, which is sent through an interface such as a text box.
[0567] Step 2: Receiving and Sending Input
[0568] explanation:
[0569] The terminal receives the user's input and sends it to the server.
[0570] input:
[0571] Natural language requests
[0572] output:
[0573] API requests sent to the server
[0574] Specific behavior:
[0575] A program on the device takes the natural language input and sends it as an HTTP POST request to a server, for example, an API endpoint.
[0576] Step 3: Natural Language Analysis
[0577] explanation:
[0578] The server passes the received natural language request to a generative AI model for analysis.
[0579] input:
[0580] Natural language requests
[0581] output:
[0582] Parsed input data
[0583] Specific behavior:
[0584] The server sends a prompt to the generative AI model, for example:
[0585] "Convert natural language input: 'What was my shopping spend in July 2023?' into a SQL query."
[0586] The generative AI model uses this prompt to parse the input.
[0587] Step 4: Generate SQL queries
[0588] explanation:
[0589] A generative AI model generates appropriate SQL queries from the parsed natural language input.
[0590] input:
[0591] Parsed input data
[0592] output:
[0593] SQL Query
[0594] Specific behavior:
[0595] Based on the prompt, the generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" and returns it to the server.
[0596] Step 5: Query the database
[0597] explanation:
[0598] The server sends the generated SQL query to the database to retrieve the specified data.
[0599] input:
[0600] SQL Query
[0601] output:
[0602] Data retrieved from a database
[0603] Specific behavior:
[0604] The server program establishes a database connection, executes the generated SQL queries, and receives the query results from a database such as MySQL or PostgreSQL.
[0605] Step 6: Return and display results
[0606] explanation:
[0607] The server sends the results obtained from the database to the terminal, which displays them to the user.
[0608] input:
[0609] Data retrieved from a database
[0610] output:
[0611] Results displayed to the user
[0612] Specific behavior:
[0613] The server formats the acquired data in JSON format or similar and returns it to the device as an HTTP response. The device then reformats the received data and displays to the user, "Total shopping expenditures for July 2023 are 15,000 yen."
[0614] (Application example 1)
[0615] Next, a description will be given of Application Example 1. In the following description, the data processing device 12 will be referred to as a "server" and the smart glasses 214 will be referred to as a "terminal."
[0616] Currently, inventory management at logistics centers requires the use of dedicated terminals and specific software, which often makes operation complicated. It is also difficult to quickly check inventory information in real time or perform statistical analysis of data. This reduces management efficiency and increases the risk of operational errors and delays. The present invention aims to provide a simple interface using natural language to improve the efficiency of inventory management at logistics centers.
[0617] The specific processing by the specific processing unit 290 of the data processing device 12 in the application example 1 is realized by the following means.
[0618] In this invention, the server includes means for a user to input a database query in natural language, means for parsing the natural language database query using a generation AI, means for generating a structured query language using the analysis result by the generation AI, means for transmitting the structured query language to a database, means for returning the results obtained from the database to the user, means for a user to check inventory status in natural language at a logistics center, and means for managing inventory status using the parsed natural language query. This enables easy and fast inventory management using natural language.
[0619] The "means for a user to input a database query in natural language" is an interface that allows a user to input a query to a database using a natural language that is intuitively easy for the user to understand.
[0620] "Generative AI" is an artificial intelligence model used to parse and convert incoming natural language database queries into structured query language.
[0621] "Syntax analysis" is the process of analyzing queries entered in natural language and understanding their meaning and intent.
[0622] "Structured Query Language" refers to a structured form of database query language such as SQL.
[0623] The "means for sending to a database" is a system component for sending the generated structured query language to a database and executing the query.
[0624] The "means for users to check inventory status in natural language at a logistics center" is an interface that accepts natural language queries regarding inventory information at a logistics center, analyzes them, and provides inventory information.
[0625] The "means for managing inventory status using parsed natural language queries" is a system for retrieving information from an inventory database within a logistics center based on parsed natural language queries and managing that information.
[0626] The present invention is realized as an inventory management system in a distribution center. The operation of the entire system will be described in detail below.
[0627] Overall system configuration
[0628] 1. User Input
[0629] Users input queries in natural language through a smartphone or robot interface, making specific requests such as "What is the current stock level of product A?"
[0630] 2. Receiving and Sending Input
[0631] The terminal receives natural language input from the user and sends it to the server, which then understands the user's intent, converts it into an appropriate data format, and sends it.
[0632] 3. Natural Language Analysis
[0633] The server passes the received natural language request to a generative AI model (e.g., the GPT-2 model) for natural language parsing. This parsing process allows the system to understand the user's intent and convert it into a structured SQL query.
[0634] 4. Generating SQL Queries
[0635] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, such as "SELECT quantity FROM inventory WHERE product_name='Product A'".
[0636] 5. Querying the Database
[0637] The server then sends the generated SQL query to a database, typically an SQLite database, to retrieve data that matches the specified criteria.
[0638] 6. Returning and displaying results
[0639] The terminal receives the query results sent back from the server and displays them to the user. The display content is presented in a format that is easy for the user to understand. For example, it may say, "The current stock quantity of product A is 500 units."
[0640] Specific examples
[0641] User input: "What is the current stock quantity of product A?"
[0642] Generated SQL query: "SELECT quantity FROM inventory WHERE product_name='Product A'"
[0643] Return result: "The current stock quantity of product A is 500 units."
[0644] Prompt Sentence Examples
[0645] Prompt: "User: Tell me the current stock quantity of product A.\nGenerating AI:"
[0646] This system allows logistics center managers to quickly and accurately obtain inventory information using natural language. The smartphone and robot-based interface simplifies complex operations, significantly improving management efficiency.
[0647] The flow of the specific processing in the application example 1 will be described with reference to FIG.
[0648] Step 1:
[0649] The user inputs a query in natural language through a smartphone or robot interface. For example, a specific request might be, "Tell me the current stock level of product A." This input is received by the terminal.
[0650] Step 2:
[0651] The terminal transmits natural language queries received from a user to a server. The input is a natural language request, and the output is a request sent to the server. The terminal performs this transmission process over a network.
[0652] Step 3:
[0653] The server passes the received natural language request to a generative AI model (e.g., GPT-2) for syntax analysis. The input here is a natural language query, which the generative AI model analyzes and converts into SQL. This process is performed using a prompt in the form of "User: Tell me the current inventory of product A.\nGenerative AI:"
[0654] Step 4:
[0655] The generative AI model generates an appropriate SQL query from the parsed natural language. The input here is the natural language query passed to the generative AI model, and the output is the generated SQL query. As a specific example, the query generated is "SELECT quantity FROM inventory WHERE product_name='Product A'".
[0656] Step 5:
[0657] The server sends the generated SQL query to the database to retrieve data that matches the specified conditions. The input is the SQL query, and the output from the database is the result of executing the SQL query. This result is specific data such as inventory levels.
[0658] Step 6:
[0659] The server sends the results retrieved from the database to the terminal, which then displays them to the user. The input is the result of the SQL query, and the output is a display in a format that is easy for the user to understand. For example, the display might say, "The current stock quantity for product A is 500 units."
[0660] By the above steps, this invention makes it possible to efficiently manage inventory in a logistics center using natural language.
[0661] Furthermore, an emotion engine that estimates the user's emotion may be further combined. That is, the identification processing unit 290 may estimate the user's emotion using the emotion identification model 59, and perform identification processing using the user's emotion.
[0662] Overall system overview
[0663] This invention combines a system in which a user inputs a request in natural language, a generation AI converts it into an SQL query, and executes the query against a database, with an emotion engine that recognizes the user's emotions and adjusts the system's response based on those emotions.
[0664] System configuration
[0665] 1. User input:
[0666] Users can input queries in natural language through the device interface, for example, by entering a specific request such as "Tell me my shopping spending for July 2023."
[0667] 2. Emotion Engine Analysis:
[0668] As the device receives user input, the emotion engine analyzes the user's emotions using voice, text, and even facial expression recognition technology. For example, if the user sounds sad while typing, their emotion will be analyzed.
[0669] 3. Sending input:
[0670] The device transmits the user's natural language input and analyzed emotion information to the server, allowing the server to receive the user's intention and emotion simultaneously.
[0671] 4. Natural Language Analysis:
[0672] The server passes the received natural language request to a generative AI model for natural language analysis, which allows the system to understand the user's intent and translate it into a structured query language, such as SQL.
[0673] 5. Generate SQL queries:
[0674] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0675] 6. Query the database:
[0676] The server sends the generated SQL query to the database to retrieve the specified data.
[0677] 7. Return and Adjustment of Results:
[0678] The server receives the results from the database and passes them to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is sad, the system adjusts to provide a more polite and kind response.
[0679] 8. Displaying the results:
[0680] The adjusted results are sent back to the device and displayed to the user. For example, it may say, "Your total shopping expenditure for July 2023 is 15,000 yen. Please let us know if you have any questions."
[0681] Specific examples
[0682] 1. User input:
[0683] The user types into the device, "Tell me my shopping expenses for July 2023," while speaking in a grumpy voice.
[0684] 2. Emotion Engine Analysis:
[0685] The terminal receives the user's input, and the emotion engine analyzes the user's emotion, which is irritation, from the grumpy voice.
[0686] 3. Sending input:
[0687] The device transmits a natural language request and interpreted emotion information to the server.
[0688] 4. Natural Language Analysis:
[0689] The server uses generative AI to parse the natural language phrase "Tell me about my shopping expenses in July 2023."
[0690] 5. Generate SQL queries:
[0691] The generation AI generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0692] 6. Query the database:
[0693] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[0694] 7. Return and Adjustment of Results:
[0695] The server passes the results to the emotion engine, which then adjusts the response, adding gentle words to calm down an annoyed user.
[0696] 8. Displaying the results:
[0697] The adjusted results are sent back to the device and displayed to the user, such as "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help."
[0698] This specific process allows users to access the database through a natural language interface and receive responses tailored to their emotions at the time. The entire system is designed to be simple and user-friendly.
[0699] The processing flow will be explained below.
[0700] Step 1:
[0701] The user enters a query in natural language into the device interface, for example, "What are my shopping expenses for July 2023?"
[0702] Step 2:
[0703] The device receives user input, and the emotion engine analyzes emotions from the user's input voice or text. The analyzed emotion information is identified as emotion tags such as "irritated" or "sad."
[0704] Step 3:
[0705] The device sends the received natural language input and emotion tag to the server. The transmitted data includes the user's input content and emotion information.
[0706] Step 4:
[0707] The server passes the received natural language request to the generative AI model, which analyzes the input natural language and processes it to understand the user's intent.
[0708] Step 5:
[0709] The server's generative AI model generates appropriate SQL queries from the analyzed natural language. For example, from the input "Tell me about my shopping expenditures in July 2023," the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" is generated.
[0710] Step 6:
[0711] The server sends the generated SQL query to the database to retrieve data based on the specified criteria, and the database executes the query and sends the results back to the server.
[0712] Step 7:
[0713] The server receives the retrieved data and passes it to the emotion engine, which tailors the response message based on the user's emotion tag. For example, if the user is "irritated," it generates a response using more polite and kind language.
[0714] Step 8:
[0715] The server sends the tailored response to the terminal, and the sent data includes the answer to the user's question and the tailored response message.
[0716] Step 9:
[0717] The device displays the results it receives to the user. For example, it might say, "Your total shopping expenditure for July 2023 is 15,000 yen. Please let us know if you have any questions." The user receives a thoughtful response that is in line with their feelings, providing a better user experience.
[0718] This specific processing step allows users to access the database through a natural language interface and receive responses tailored to their current emotions. The entire system is designed to be simple and user-friendly.
[0719] Example 2
[0720] Next, a description will be given of Example 2. In the following description, the data processing device 12 will be referred to as a "server" and the smart glasses 214 will be referred to as a "terminal."
[0721] Conventional systems have issues with being unable to accurately analyze the intent of users when they input database queries in natural language, and unable to provide responses based on the user's emotions, which can lead to poor user experience and make the system difficult to use.
[0722] The identification process by the identification processing unit 290 of the data processing device 12 in Example 2 is realized by the following means. In this invention, the server includes: means for a user to input a database query in natural language; means for analyzing the input natural language query and the user's emotions; means for parsing the natural language database query using a generation AI; means for generating a structured query language using the analysis result by the generation AI; means for transmitting the structured query language to a database; means for adjusting the result obtained from the database based on the user's emotions; and means for returning the adjusted result to the user. This makes it possible to accurately analyze the user's query input in natural language and provide a response adjusted based on the user's emotions.
[0723] "User" means any person or entity that utilizes the System to enter queries in natural language.
[0724] A "natural language query" refers to a database query entered by a user in natural language.
[0725] "Means for analyzing input natural language queries and user sentiment" refers to software and hardware for analyzing user-input queries and the associated sentiment.
[0726] "Generative AI" refers to artificial intelligence models used to parse natural language database queries.
[0727] "Means of parsing" refers to the process of using generative AI to parse natural language database queries.
[0728] A "structured query language" refers to a query language that can be executed against a database and is created by generative AI through analysis of natural language queries.
[0729] "Database" refers to a collection of data to which structured query languages are submitted.
[0730] "Means for adjusting based on user emotions" refers to software or algorithms for adjusting the obtained results based on the analyzed user emotions.
[0731] "Means for returning adjusted results to the user" refers to a process for returning adjusted results before they are displayed to the user.
[0732] This invention combines a system in which a user inputs a request in natural language, a generative AI converts it into an SQL query, and executes the query against a database, with an emotion engine. The system recognizes the user's emotions and adjusts the system's response based on those emotions.
[0733] System configuration
[0734] 1. The user enters a database query in natural language
[0735] Users input queries in natural language through the device interface, such as "Tell me my shopping spending for July 2023."
[0736] 2. Emotion Engine Analysis
[0737] As the device receives user input, the emotion engine analyzes the user's emotions using voice analysis, text analysis, and even facial expression recognition. For example, if the user's voice sounds irritated while typing, the emotion engine can detect it.
[0738] 3. Sending input data
[0739] The device sends the user's natural language input and analyzed emotion information to the server, allowing the server to receive the user's intention and emotion simultaneously.
[0740] System action
[0741] 1. Natural Language Analysis
[0742] The server passes the received natural language request to a generative AI model, which analyzes the natural language. This analysis allows the system to understand the user's intent and convert it into a structured query language, such as SQL. OpenAI's GPT-3 is one example of a generative AI model.
[0743] 2. Generating SQL Queries
[0744] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0745] 3. Sending a query to the database
[0746] The server sends the generated SQL query to a database, such as PostgreSQL, to retrieve the specified data.
[0747] 4. Adjustment of the results
[0748] The server receives the results from the database and passes them to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is annoyed, the system adjusts the response to use kind words.
[0749] 5. Displaying the results
[0750] The adjusted results are sent back to the device and displayed to the user. For example, it may say something like, "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help."
[0751] Specific examples
[0752] 1. User Input
[0753] The user types into the device, "Tell me my shopping expenses for July 2023," while speaking in a grumpy voice.
[0754] 2. Emotion Engine Analysis
[0755] The terminal receives the user's input, and the emotion engine analyzes the user's emotion, which is irritation, from the grumpy voice.
[0756] 3. Sending input data
[0757] The device transmits a natural language request and interpreted emotion information to the server.
[0758] Prompt Sentence Examples
[0759] "User asks: 'What are my shopping expenses for July 2023?'"
[0760] This specific process allows users to access the database through a natural language interface and receive responses tailored to their emotions at the time. This system provides users with an intuitive and convenient operation experience, while also realizing responses that take emotions into consideration.
[0761] The flow of the identification process in the second embodiment will be described with reference to FIG.
[0762] Specific processing explanation of the system program
[0763] Processing flow
[0764] Step 1:
[0765] The user inputs a query in natural language through the device interface, for example, "Tell me my shopping expenditures for July 2023." Input is done using the keyboard or voice input function of a PC or smartphone.
[0766] Input: Natural language query "What was my shopping spend for July 2023?"
[0767] Output: User input data
[0768] Step 2:
[0769] As soon as the device receives the user's input, the emotion engine analyzes the user's emotion, using, for example, voice analysis or text analysis. Emotions such as irritation are detected.
[0770] Input: User voice or text data
[0771] Output: Sentiment analysis result (e.g., irritation)
[0772] Step 3:
[0773] The device sends a natural language query and analyzed emotion information to the server, which then sends this data to the server using an HTTP request.
[0774] Input: Natural language query and sentiment analysis results
[0775] Output: Request data sent to the server
[0776] Step 4:
[0777] The server passes the received natural language query and sentiment information to a generative AI model, which analyzes the natural language. For example, OpenAI's GPT-3 is used as the generative AI model. The prompt sentence is "User question: 'Tell me about shopping expenses in July 2023.'"
[0778] Input: Natural language query and sentiment information
[0779] Output: Parsing results (structured information that understands the intent)
[0780] Step 5:
[0781] The generative AI model automatically generates appropriate SQL queries from the analyzed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0782] Input: Parsed result
[0783] Output: SQL query
[0784] Step 6:
[0785] The server sends the generated SQL query to a database, such as PostgreSQL, to retrieve the specified data.
[0786] Input: SQL query
[0787] Output: Data retrieved from the database (e.g., shopping expenditure total)
[0788] Step 7:
[0789] The server passes the results from the database to the emotion engine, which tailors the response based on the user's emotions, for example adding kind words to an annoyed user.
[0790] Input: Database results and emotion information
[0791] Output: Reconciled response message
[0792] Step 8:
[0793] The server sends the adjusted results back to the device, which then displays the results to the user. For example, a message like, "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help" may be displayed.
[0794] Input: Tailored response message
[0795] Output: The message displayed to the user
[0796] Specific operation example
[0797] User input: The user uses their smartphone to say, "Tell me my shopping expenses for July 2023."
[0798] Emotion engine analysis: The emotion engine detects irritation from the user's tone of voice.
[0799] Sending input: The device sends the analysis results and natural language query to the server.
[0800] Natural language parsing: The server prompts the generative AI model to parse the query and generate an SQL query.
[0801] SQL query generation: The generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" and returns it to the server.
[0802] Querying the database: The server executes the generated SQL query and retrieves the results from the database.
[0803] Returning and adjusting the results: The server uses the emotion engine to adjust the results and add friendly comments.
[0804] Displaying the results: The adjusted results are sent to the device and displayed to the user.
[0805] This allows users to receive responses based on natural language and emotions, making the entire system intuitive and user-friendly.
[0806] (Application example 2)
[0807] Next, a description will be given of Application Example 2. In the following description, the data processing device 12 will be referred to as a "server" and the smart glasses 214 will be referred to as a "terminal."
[0808] In modern brick-and-mortar stores, customers are required to provide instant and accurate responses when checking product and inventory information. However, conventional systems have difficulty responding appropriately to customer emotions, which can lead to dissatisfaction and stress. In particular, if a customer is feeling unhappy or irritated, not being able to respond appropriately can lead to a decline in the quality of the customer experience and lower satisfaction.
[0809] The specific processing by the specific processing unit 290 of the data processing device 12 in the application example 2 is realized by the following means.
[0810] In this invention, the server includes a means for a user to input a database query in natural language, a means for parsing the natural language database query using a generation AI, a means for generating a structured query language using the analysis results of the generation AI, and a means including an emotion engine for analyzing the user's emotions, thereby enabling a response to a question input by a customer in natural language to be made in an appropriate tone according to the emotion.
[0811] A "user" is a person who utilizes the system to enter database queries and retrieve information.
[0812] "Natural language" refers to the language used by humans in everyday speech and writing, as opposed to a structured query language.
[0813] A "database query" refers to a question sent to a database to retrieve information.
[0814] "Generative AI" is an artificial intelligence technique for analyzing natural language and converting it into a structured query language.
[0815] An "emotion engine" is a technology that analyzes a user's emotions and adjusts the system's response based on the analysis results.
[0816] "Means for adjusting responses" refers to methods for changing the content and tone of the system's responses based on the analysis results of the emotion engine.
[0817] "Brick and Mortar Store" means a sales and service establishment located at a physical location.
[0818] "Product and inventory questions" refer to inquiries made by customers in physical stores about specific products and their availability.
[0819] "Tone" refers to the tone and mood of speech or writing, and can change depending on emotions.
[0820] The system for implementing this invention is designed to allow users to ask questions about products and inventory in a physical store in natural language and to provide appropriate responses based on their emotions. Specific embodiments are described below.
[0821] Hardware and software used
[0822] Hardware
[0823] Smartphone
[0824] server
[0825] Database (e.g. SQLite)
[0826] software
[0827] Python
[0828] OpenAI GPT-3
[0829] sqlite3 library
[0830] text_to_emotion library
[0831] Text processing libraries (e.g. textblob)
[0832] Data processing and calculation
[0833] User input and sentiment analysis
[0834] When a user uses a smartphone to input a question about a product or inventory in natural language, the voice or text is sent to the system. When the device receives the question, it uses an emotion engine to analyze the user's emotion. For example, it uses the text_to_emotion library to extract emotions (anger, sadness, joy, etc.) from the user's voice or text.
[0835] Natural Language Parsing and Query Generation
[0836] Once the sentiment analysis is complete, the device sends the user's natural language input to the server, which uses a generative AI model (e.g., OpenAI GPT-3) to convert the natural language request into an SQL query, using an example prompt like this:
[0837] Generate a SQL query for: Is this item in stock?
[0838] The generative AI model automatically generates an appropriate SQL query (e.g., SELECT FROM inventory WHERE product_name='product name';) for this prompt statement.
[0839] Database Queries and Response Throttle
[0840] The server then sends the generated SQL query to the database to retrieve the specified data. The results are then passed back to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is frustrated, a softer response such as "We have it in stock. We will help you shortly, so please wait." is generated.
[0841] Specific examples
[0842] 1. User input: A user asks "Is this item in stock?" on their smartphone and types it in an annoyed voice.
[0843] 2. Emotion analysis: The emotion engine analyzes the user's frustration and sends the emotion information to the server.
[0844] 3. Natural language parsing: The server uses a generative AI model to translate natural language questions into SQL queries.
[0845] 4. Database query: An SQL query is sent to the database to retrieve the appropriate inventory information.
[0846] 5. Response adjustment: Based on the obtained results, the emotion engine creates a response according to the user's emotions.
[0847] 6. Response display: The terminal will display "We have the item in stock. We will assist you shortly, so please wait."
[0848] Prompt Sentence Examples
[0849] Generate a SQL query for: Is this item in stock?
[0850] In this way, users can ask questions about products and inventory in natural language and receive appropriate responses based on their emotions. This system improves the customer experience in physical stores and provides highly satisfying service.
[0851] The flow of the specific processing in the application example 2 will be described with reference to FIG.
[0852] Step 1:
[0853] The user types a question into their smartphone in natural language, such as "Is this item in stock?" The input is sent to the device in voice or text format.
[0854] Step 2:
[0855] The device receives the user's question and uses an emotion engine to analyze the user's emotion from the input question and its voice or text. The emotion engine uses the text_to_emotion library to identify emotions (e.g., irritation, anger, sadness, etc.) from the question text or voice. The input of this process is the user's question, and the output is the emotion information identified by the emotion engine.
[0856] Step 3:
[0857] The device sends the input natural language question and analyzed emotion information to the server. In this step, the user's intention and emotion are passed to the server. The input is the natural language question and emotion information, and the output is data transmission to the server.
[0858] Step 4:
[0859] The server uses a generative AI model (e.g., OpenAI GPT-3) to convert natural language questions into SQL queries. An example prompt sentence is given to the generative AI model: "Generate a SQL query for: Is this item in stock?" The input is the prompt sentence, and the output is the generated SQL query.
[0860] Step 5:
[0861] The server sends the generated SQL query to a database to retrieve the corresponding data. An example of the database used is SQLite. The input of this process is the SQL query, and the output is the retrieved data.
[0862] Step 6:
[0863] The server passes the results retrieved from the database back to the emotion engine, which then adjusts the response based on the emotion. For example, a response such as "We have it in stock" may be generated based on the retrieved inventory information, and then adjusted to a gentler tone, such as "We will help you right away, so please wait," depending on the user's emotion. The input is the results from the database and emotion information, and the output is the adjusted response.
[0864] Step 7:
[0865] The terminal obtains the tailored response and displays or speaks it to the user. For example, it may say, "We have it in stock. We will help you shortly, so please wait." The input is the tailored response, and the output is the displayed or spoken response to the user.
[0866] Through the above steps, users can ask questions about products and inventory in natural language and receive appropriate responses according to their feelings.
[0867] The specific processing unit 290 transmits the result of the specific processing to the smart glasses 214. In the smart glasses 214, the control unit 46A causes the speaker 240 to output the result of the specific processing. The microphone 238 acquires audio indicating a user input regarding the result of the specific processing. The control unit 46A transmits audio data indicating the user input acquired by the microphone 238 to the data processing device 12. In the data processing device 12, the specific processing unit 290 acquires the audio data.
[0868] The data generation model 58 is a so-called generative AI (Artificial Intelligence). An example of the data generation model 58 is ChatGPT (Internet Search<URL: https: / / openai.com / blog / chatgpt> ), Gemini (Internet search <url: https: gemini.google.com ?hl="ja">) and other generation AIs. The data generation model 58 is obtained by performing deep learning on a neural network. A prompt including an instruction is input to the data generation model 58, and inference data such as voice data indicating voice, text data indicating text, and image data indicating an image is also input. The data generation model 58 performs inference on the input inference data in accordance with the instruction indicated by the prompt, and outputs the inference result in a data format such as voice data and text data. Here, inference refers to, for example, analysis, classification, prediction, and / or summarization.
[0869] In the above embodiment, an example in which the specific processing is performed by the data processing device 12 has been given, but the technology of the present disclosure is not limited to this, and the specific processing may be performed by the smart glasses 214.
[0870] [Third embodiment]
[0871] FIG. 5 shows an example of the configuration of a data processing system 310 according to the third embodiment.
[0872] 5, the data processing system 310 includes the data processing device 12 and a headset terminal 314. An example of the data processing device 12 is a server.
[0873] The data processing device 12 includes a computer 22, a database 24, and a communication I / F 26. The computer 22 is an example of a "computer" according to the technology of the present disclosure. The computer 22 includes a processor 28, a RAM 30, and a storage 32. The processor 28, the RAM 30, and the storage 32 are connected to a bus 34. The database 24 and the communication I / F 26 are also connected to the bus 34. The communication I / F 26 is connected to a network 54. Examples of the network 54 include a WAN (Wide Area Network) and / or a LAN (Local Area Network).
[0874] The headset type terminal 314 includes a computer 36, a microphone 238, a speaker 240, a camera 42, a communication I / F 44, and a display 343. The computer 36 includes a processor 46, a RAM 48, and a storage 50. The processor 46, the RAM 48, and the storage 50 are connected to a bus 52. The microphone 238, the speaker 240, the camera 42, and the display 343 are also connected to the bus 52.
[0875] The microphone 238 receives instructions and the like from the user 20 by receiving voice uttered by the user 20. The microphone 238 captures the voice uttered by the user 20, converts the captured voice into audio data, and outputs it to the processor 46. The speaker 240 outputs audio in accordance with instructions from the processor 46.
[0876] Camera 42 is a small digital camera equipped with an optical system including a lens, aperture, and shutter, and an imaging element such as a CMOS (Complementary Metal-Oxide-Semiconductor) image sensor or a CCD (Charge Coupled Device) image sensor, and captures images of the surroundings of user 20 (for example, an imaging range defined by an angle of view equivalent to the field of vision of a typical healthy person).
[0877] The communication I / F 44 is connected to a network 54. The communication I / Fs 44 and 26 are responsible for the exchange of various information between the processor 46 and the processor 28 via the network 54. The exchange of various information between the processor 46 and the processor 28 using the communication I / Fs 44 and 26 is carried out in a secure state.
[0878] Fig. 6 shows an example of the main functions of the data processing device 12 and the headset type terminal 314. As shown in Fig. 6, in the data processing device 12, a specific process is performed by the processor 28. A specific process program 56 is stored in the storage 32.
[0879] The specific processing program 56 is an example of a "program" according to the technology of the present disclosure. The processor 28 reads the specific processing program 56 from the storage 32 and executes the read specific processing program 56 on the RAM 30. The specific processing is realized by the processor 28 operating as a specific processing unit 290 in accordance with the specific processing program 56 executed on the RAM 30.
[0880] The storage 32 stores a data generation model 58 and an emotion identification model 59. The data generation model 58 and the emotion identification model 59 are used by the identification processing unit 290.
[0881] In the headset type terminal 314, a reception output process is performed by the processor 46. A reception output program 60 is stored in the storage 50. The processor 46 reads the reception output program 60 from the storage 50 and executes the read reception output program 60 on the RAM 48. The reception output process is realized by the processor 46 operating as the control unit 46A in accordance with the reception output program 60 executed on the RAM 48.
[0882] Next, a description will be given of the identification process performed by the identification processing unit 290 of the data processing device 12. In the following description, the data processing device 12 will be referred to as the "server" and the headset type terminal 314 will be referred to as the "terminal."
[0883] Overall system overview
[0884] This invention is a system in which a generation AI converts requests entered by a user in natural language into SQL queries and executes those queries against a database.
[0885] System configuration
[0886] 1. User input:
[0887] Users can input queries in natural language through the device interface, for example, by entering a specific request such as "Tell me my shopping spending for July 2023."
[0888] 2. Receiving and sending input:
[0889] The device receives natural language input from the user and sends it to the server, which understands the user's intent, converts it into an appropriate data format, and sends it.
[0890] 3. Natural Language Analysis:
[0891] The server passes the received natural language request to a generative AI model for natural language analysis, which allows the system to understand the user's intent and translate it into a structured query language, such as SQL.
[0892] 4. Generate SQL queries:
[0893] The server's generation AI automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0894] 5. Query the database:
[0895] The server sends the generated SQL query to the database to retrieve the specified data.
[0896] 6. Return and display of results:
[0897] The device receives the query results from the server and displays them to the user in a format that is easy for the user to understand. For example, it might say, "Shopping expenses for July 2023 total 15,000 yen."
[0898] Specific examples
[0899] 1. User input:
[0900] The user types "Tell me my shopping expenses for July 2023" into the device interface.
[0901] 2. Receiving and sending input:
[0902] The terminal receives this input and transmits it over the network to the server.
[0903] 3. Natural Language Analysis:
[0904] The server uses generative AI to parse the natural language input, such as "Tell me about my shopping expenses in July 2023," and understand the intent.
[0905] 4. Generate SQL queries:
[0906] The generation AI generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0907] 5. Query the database:
[0908] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[0909] 6. Return and display of results:
[0910] The server receives the results from the database and sends them back to the terminal, which then displays to the user, "The total shopping expenditure for July 2023 is 15,000 yen."
[0911] Program processing overview
[0912] User: Enters a query in natural language into the device.
[0913] Terminal: Sends user input to the server.
[0914] Server: Uses generative AI to analyze natural language queries, generate SQL queries, send the queries to the database, and retrieve the results.
[0915] Terminal: Displays the results received from the server to the user.
[0916] In this way, the present invention enables users to freely access and operate databases using natural language, without relying on a specific application, dramatically improving the convenience of accessing information and manipulating data.
[0917] The processing flow will be explained below.
[0918] Step 1:
[0919] The user enters a query in natural language into the device interface, for example, "What are my shopping expenses for July 2023?"
[0920] Step 2:
[0921] The terminal receives this input and sends the user's natural language query to the server, including the process of converting the input data into an appropriate format for transmission.
[0922] Step 3:
[0923] The server passes the received natural language query to the generative AI model, which then performs syntactic analysis of the natural language and performs processing to accurately understand the user's intent.
[0924] Step 4:
[0925] The generative AI model generates SQL queries based on the analyzed natural language query. For example, it generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" from the input natural language.
[0926] Step 5:
[0927] The server sends the generated SQL query to the database, which searches for data based on the specified criteria.
[0928] Step 6:
[0929] The database executes the query and sends the results back to the server. For example, if the total shopping expenditure for July is 15,000 yen, the results are sent back to the server.
[0930] Step 7:
[0931] The server receives the results returned from the database and returns them to the terminal, formatted in a way that is easy for the user to understand.
[0932] Step 8:
[0933] The terminal displays the results it receives to the user. For example, it displays something like, "The total shopping expenditure for July 2023 is 15,000 yen."
[0934] These specific processing steps allow users to access the database through a natural language interface and intuitively obtain the information they need. The entire system is designed to be simple and user-friendly.
[0935] Example 1
[0936] Next, a description will be given of Example 1. In the following description, the data processing device 12 will be referred to as a "server" and the headset type terminal 314 will be referred to as a "terminal."
[0937] Conventional database interfaces require specialized knowledge, making it difficult for general users to intuitively operate databases. Furthermore, the process of converting natural language into structured queries is complex, resulting in low accuracy and efficiency. This creates challenges that limit fast and accurate access to data.
[0938] The specific processing by the specific processing unit 290 of the data processing device 12 in the first embodiment is realized by the following means.
[0939] In this invention, the server includes: means for a user to input a database query in natural language; means for a terminal to receive the natural language query and transmit it to the server; means for the server to parse the natural language query using a generative AI model; means for generating a structured query language using the analysis results of the generative AI model; means for transmitting the structured query language to a database; means for the server to receive results obtained from the database and return them to the user; and means for the terminal to display the results to the user. This enables users to operate the database in natural language without having specialized knowledge, achieving fast and accurate access to data.
[0940] "User" refers to a person who uses the system to enter database queries in natural language and retrieve desired information.
[0941] A "terminal" is a device used by a user to input a natural language query, and is a device responsible for sending the query to a server and displaying the results received from the server to the user.
[0942] "Server" refers to the central processing unit of the system that receives natural language queries sent by users, analyzes them using a generative AI model, generates structured query language, and sends it to the database.
[0943] A "generative AI model" is an artificial intelligence model that analyzes natural language queries, understands their intent, and converts them into structured query language.
[0944] A "natural language query" is a query entered by a user in everyday language, and is a statement for retrieving specific information from a database.
[0945] A "structured query language" is a form of query language that is generated by a generative AI model based on natural language and can be executed against a database; an example is SQL.
[0946] A "database" is an information management system that receives queries sent using a structured query language, stores and manages corresponding data, and returns data in response to the queries.
[0947] "Results" are data retrieved from a database and information provided based on a user's natural language query.
[0948] This invention is a system in which a generative AI model converts requests entered by a user in natural language into SQL queries and executes the queries against a database. The system consists of the following components:
[0949] composition
[0950] 1. User Input
[0951] Users can use devices such as PCs or smartphones to input queries in natural language, for example, a specific request such as "Tell me my shopping expenditures for July 2023."
[0952] 2. Receiving and Sending Input
[0953] The device receives the user's natural language input and sends it to the server. The device converts the received input into an appropriate data format and sends it to the server as an API request, typically via an HTTP POST request.
[0954] 3. Natural Language Analysis
[0955] The server passes the received natural language request to a generative AI model, such as OpenAI's GPT-4. The server uses the generative AI model to parse the request and understand the user's intent.
[0956] 4. Generating SQL Queries
[0957] The generative AI model generates appropriate SQL queries from the parsed natural language input. For example, for the input "What is my shopping expenditure for July 2023?", it generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'."
[0958] 5. Querying the Database
[0959] The server then sends the generated SQL query to a database to retrieve the specified data, typically a database such as MySQL or PostgreSQL.
[0960] 6. Returning and displaying results
[0961] The server receives the results returned from the database and sends them to the device. The device then displays the received data in a format that is easy for the user to understand. For example, it might present the user with a message like, "The total shopping expenditure for July 2023 is 15,000 yen."
[0962] Specific examples
[0963] 1. User Input
[0964] The user types into the device interface, "Tell me my shopping expenses for July 2023."
[0965] 2. Receiving and Sending Input
[0966] The terminal receives this input and transmits it to the server over the network.
[0967] 3. Natural Language Analysis
[0968] The server uses the generative AI model to analyze the natural language input, such as "Tell me about my shopping expenses in July 2023," and understand the intent.
[0969] 4. Generating SQL Queries
[0970] The generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[0971] 5. Querying the Database
[0972] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[0973] 6. Returning and displaying results
[0974] The server receives the results from the database and sends them back to the terminal, which then displays to the user, "The total shopping expenditure for July 2023 is 15,000 yen."
[0975] Prompt Sentence Examples
[0976] The server receives the user's input, "Tell me about my shopping expenses in July 2023," and sends the following prompt to the generative AI model:
[0977] "Convert natural language input: 'What was my shopping spend in July 2023?' into a SQL query."
[0978] This means that users can enter database queries in natural language that meet their intentions, even if they do not have specialized knowledge, and the generative AI model will generate appropriate SQL queries, allowing them to quickly obtain the results.
[0979] The flow of the identification process in the first embodiment will be described with reference to FIG.
[0980] System program processing flow
[0981] Step 1: User Input
[0982] explanation:
[0983] A user uses the terminal interface to enter a query in natural language.
[0984] input:
[0985] Natural language queries (e.g., "What was my shopping spend for July 2023?")
[0986] output:
[0987] Natural language requests
[0988] Specific behavior:
[0989] Users open an application or web browser on their PC or smartphone and type a query in natural language, which is sent through an interface such as a text box.
[0990] Step 2: Receiving and Sending Input
[0991] explanation:
[0992] The terminal receives the user's input and sends it to the server.
[0993] input:
[0994] Natural language requests
[0995] output:
[0996] API requests sent to the server
[0997] Specific behavior:
[0998] A program on the device takes the natural language input and sends it as an HTTP POST request to a server, for example, an API endpoint.
[0999] Step 3: Natural Language Analysis
[1000] explanation:
[1001] The server passes the received natural language request to a generative AI model for analysis.
[1002] input:
[1003] Natural language requests
[1004] output:
[1005] Parsed input data
[1006] Specific behavior:
[1007] The server sends a prompt to the generative AI model, for example:
[1008] "Convert natural language input: 'What was my shopping spend in July 2023?' into a SQL query."
[1009] The generative AI model uses this prompt to parse the input.
[1010] Step 4: Generate SQL queries
[1011] explanation:
[1012] A generative AI model generates appropriate SQL queries from the parsed natural language input.
[1013] input:
[1014] Parsed input data
[1015] output:
[1016] SQL Query
[1017] Specific behavior:
[1018] Based on the prompt, the generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" and returns it to the server.
[1019] Step 5: Query the database
[1020] explanation:
[1021] The server sends the generated SQL query to the database to retrieve the specified data.
[1022] input:
[1023] SQL Query
[1024] output:
[1025] Data retrieved from a database
[1026] Specific behavior:
[1027] The server program establishes a database connection, executes the generated SQL queries, and receives the query results from a database such as MySQL or PostgreSQL.
[1028] Step 6: Return and display results
[1029] explanation:
[1030] The server sends the results obtained from the database to the terminal, which displays them to the user.
[1031] input:
[1032] Data retrieved from a database
[1033] output:
[1034] Results displayed to the user
[1035] Specific behavior:
[1036] The server formats the acquired data in JSON format or similar and returns it to the device as an HTTP response. The device then reformats the received data and displays to the user, "Total shopping expenditures for July 2023 are 15,000 yen."
[1037] (Application example 1)
[1038] Next, a description will be given of Application Example 1. In the following description, the data processing device 12 will be referred to as a "server" and the headset type terminal 314 will be referred to as a "terminal."
[1039] Currently, inventory management at logistics centers requires the use of dedicated terminals and specific software, which often makes operation complicated. It is also difficult to quickly check inventory information in real time or perform statistical analysis of data. This reduces management efficiency and increases the risk of operational errors and delays. The present invention aims to provide a simple interface using natural language to improve the efficiency of inventory management at logistics centers.
[1040] The specific processing by the specific processing unit 290 of the data processing device 12 in the application example 1 is realized by the following means.
[1041] In this invention, the server includes means for a user to input a database query in natural language, means for parsing the natural language database query using a generation AI, means for generating a structured query language using the analysis result by the generation AI, means for transmitting the structured query language to a database, means for returning the results obtained from the database to the user, means for a user to check inventory status in natural language at a logistics center, and means for managing inventory status using the parsed natural language query. This enables easy and fast inventory management using natural language.
[1042] The "means for a user to input a database query in natural language" is an interface that allows a user to input a query to a database using a natural language that is intuitively easy for the user to understand.
[1043] "Generative AI" is an artificial intelligence model used to parse and convert incoming natural language database queries into structured query language.
[1044] "Syntax analysis" is the process of analyzing queries entered in natural language and understanding their meaning and intent.
[1045] "Structured Query Language" refers to a structured form of database query language such as SQL.
[1046] The "means for sending to a database" is a system component for sending the generated structured query language to a database and executing the query.
[1047] The "means for users to check inventory status in natural language at a logistics center" is an interface that accepts natural language queries regarding inventory information at a logistics center, analyzes them, and provides inventory information.
[1048] The "means for managing inventory status using parsed natural language queries" is a system for retrieving information from an inventory database within a logistics center based on parsed natural language queries and managing that information.
[1049] The present invention is realized as an inventory management system in a distribution center. The operation of the entire system will be described in detail below.
[1050] Overall system configuration
[1051] 1. User Input
[1052] Users input queries in natural language through a smartphone or robot interface, making specific requests such as "What is the current stock level of product A?"
[1053] 2. Receiving and Sending Input
[1054] The terminal receives natural language input from the user and sends it to the server, which then understands the user's intent, converts it into an appropriate data format, and sends it.
[1055] 3. Natural Language Analysis
[1056] The server passes the received natural language request to a generative AI model (e.g., the GPT-2 model) for natural language parsing. This parsing process allows the system to understand the user's intent and convert it into a structured SQL query.
[1057] 4. Generating SQL Queries
[1058] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, such as "SELECT quantity FROM inventory WHERE product_name='Product A'".
[1059] 5. Querying the Database
[1060] The server then sends the generated SQL query to a database, typically an SQLite database, to retrieve data that matches the specified criteria.
[1061] 6. Returning and displaying results
[1062] The terminal receives the query results sent back from the server and displays them to the user. The display content is presented in a format that is easy for the user to understand. For example, it may say, "The current stock quantity of product A is 500 units."
[1063] Specific examples
[1064] User input: "What is the current stock quantity of product A?"
[1065] Generated SQL query: "SELECT quantity FROM inventory WHERE product_name='Product A'"
[1066] Return result: "The current stock quantity of product A is 500 units."
[1067] Prompt Sentence Examples
[1068] Prompt: "User: Tell me the current stock quantity of product A.\nGenerating AI:"
[1069] This system allows logistics center managers to quickly and accurately obtain inventory information using natural language. The smartphone and robot-based interface simplifies complex operations, significantly improving management efficiency.
[1070] The flow of the specific processing in the application example 1 will be described with reference to FIG.
[1071] Step 1:
[1072] The user inputs a query in natural language through a smartphone or robot interface. For example, a specific request might be, "Tell me the current stock level of product A." This input is received by the terminal.
[1073] Step 2:
[1074] The terminal transmits natural language queries received from a user to a server. The input is a natural language request, and the output is a request sent to the server. The terminal performs this transmission process over a network.
[1075] Step 3:
[1076] The server passes the received natural language request to a generative AI model (e.g., GPT-2) for syntax analysis. The input here is a natural language query, which the generative AI model analyzes and converts into SQL. This process is performed using a prompt in the form of "User: Tell me the current inventory of product A.\nGenerative AI:"
[1077] Step 4:
[1078] The generative AI model generates an appropriate SQL query from the parsed natural language. The input here is the natural language query passed to the generative AI model, and the output is the generated SQL query. As a specific example, the query generated is "SELECT quantity FROM inventory WHERE product_name='Product A'".
[1079] Step 5:
[1080] The server sends the generated SQL query to the database to retrieve data that matches the specified conditions. The input is the SQL query, and the output from the database is the result of executing the SQL query. This result is specific data such as inventory levels.
[1081] Step 6:
[1082] The server sends the results retrieved from the database to the terminal, which then displays them to the user. The input is the result of the SQL query, and the output is a display in a format that is easy for the user to understand. For example, the display might say, "The current stock quantity for product A is 500 units."
[1083] By the above steps, this invention makes it possible to efficiently manage inventory in a logistics center using natural language.
[1084] Furthermore, an emotion engine that estimates the user's emotion may be further combined. That is, the identification processing unit 290 may estimate the user's emotion using the emotion identification model 59, and perform identification processing using the user's emotion.
[1085] Overall system overview
[1086] This invention combines a system in which a user inputs a request in natural language, a generation AI converts it into an SQL query, and executes the query against a database, with an emotion engine that recognizes the user's emotions and adjusts the system's response based on those emotions.
[1087] System configuration
[1088] 1. User input:
[1089] Users can input queries in natural language through the device interface, for example, by entering a specific request such as "Tell me my shopping spending for July 2023."
[1090] 2. Emotion Engine Analysis:
[1091] As the device receives user input, the emotion engine analyzes the user's emotions using voice, text, and even facial expression recognition technology. For example, if the user sounds sad while typing, their emotion will be analyzed.
[1092] 3. Sending input:
[1093] The device transmits the user's natural language input and analyzed emotion information to the server, allowing the server to receive the user's intention and emotion simultaneously.
[1094] 4. Natural Language Analysis:
[1095] The server passes the received natural language request to a generative AI model for natural language analysis, which allows the system to understand the user's intent and translate it into a structured query language, such as SQL.
[1096] 5. Generate SQL queries:
[1097] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1098] 6. Query the database:
[1099] The server sends the generated SQL query to the database to retrieve the specified data.
[1100] 7. Return and Adjustment of Results:
[1101] The server receives the results from the database and passes them to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is sad, the system adjusts to provide a more polite and kind response.
[1102] 8. Displaying the results:
[1103] The adjusted results are sent back to the device and displayed to the user. For example, it may say, "Your total shopping expenditure for July 2023 is 15,000 yen. Please let us know if you have any questions."
[1104] Specific examples
[1105] 1. User input:
[1106] The user types into the device, "Tell me my shopping expenses for July 2023," while speaking in a grumpy voice.
[1107] 2. Emotion Engine Analysis:
[1108] The terminal receives the user's input, and the emotion engine analyzes the user's emotion, which is irritation, from the grumpy voice.
[1109] 3. Sending input:
[1110] The device transmits a natural language request and interpreted emotion information to the server.
[1111] 4. Natural Language Analysis:
[1112] The server uses generative AI to parse the natural language phrase "Tell me about my shopping expenses in July 2023."
[1113] 5. Generate SQL queries:
[1114] The generation AI generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1115] 6. Query the database:
[1116] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[1117] 7. Return and Adjustment of Results:
[1118] The server passes the results to the emotion engine, which then adjusts the response, adding gentle words to calm down an annoyed user.
[1119] 8. Displaying the results:
[1120] The adjusted results are sent back to the device and displayed to the user, such as "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help."
[1121] This specific process allows users to access the database through a natural language interface and receive responses tailored to their emotions at the time. The entire system is designed to be simple and user-friendly.
[1122] The processing flow will be explained below.
[1123] Step 1:
[1124] The user enters a query in natural language into the device interface, for example, "What are my shopping expenses for July 2023?"
[1125] Step 2:
[1126] The device receives user input, and the emotion engine analyzes emotions from the user's input voice or text. The analyzed emotion information is identified as emotion tags such as "irritated" or "sad."
[1127] Step 3:
[1128] The device sends the received natural language input and emotion tag to the server. The transmitted data includes the user's input content and emotion information.
[1129] Step 4:
[1130] The server passes the received natural language request to the generative AI model, which analyzes the input natural language and processes it to understand the user's intent.
[1131] Step 5:
[1132] The server's generative AI model generates appropriate SQL queries from the analyzed natural language. For example, from the input "Tell me about my shopping expenditures in July 2023," the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" is generated.
[1133] Step 6:
[1134] The server sends the generated SQL query to the database to retrieve data based on the specified criteria, and the database executes the query and sends the results back to the server.
[1135] Step 7:
[1136] The server receives the retrieved data and passes it to the emotion engine, which tailors the response message based on the user's emotion tag. For example, if the user is "irritated," it generates a response using more polite and kind language.
[1137] Step 8:
[1138] The server sends the tailored response to the terminal, and the sent data includes the answer to the user's question and the tailored response message.
[1139] Step 9:
[1140] The device displays the results it receives to the user. For example, it might say, "Your total shopping expenditure for July 2023 is 15,000 yen. Please let us know if you have any questions." The user receives a thoughtful response that is in line with their feelings, providing a better user experience.
[1141] This specific processing step allows users to access the database through a natural language interface and receive responses tailored to their current emotions. The entire system is designed to be simple and user-friendly.
[1142] Example 2
[1143] Next, a description will be given of Example 2. In the following description, the data processing device 12 will be referred to as a "server" and the headset type terminal 314 will be referred to as a "terminal."
[1144] Conventional systems have issues with being unable to accurately analyze the intent of users when they input database queries in natural language, and unable to provide responses based on the user's emotions, which can lead to poor user experience and make the system difficult to use.
[1145] The identification process by the identification processing unit 290 of the data processing device 12 in Example 2 is realized by the following means. In this invention, the server includes: means for a user to input a database query in natural language; means for analyzing the input natural language query and the user's emotions; means for parsing the natural language database query using a generation AI; means for generating a structured query language using the analysis result by the generation AI; means for transmitting the structured query language to a database; means for adjusting the result obtained from the database based on the user's emotions; and means for returning the adjusted result to the user. This makes it possible to accurately analyze the user's query input in natural language and provide a response adjusted based on the user's emotions.
[1146] "User" means any person or entity that utilizes the System to enter queries in natural language.
[1147] A "natural language query" refers to a database query entered by a user in natural language.
[1148] "Means for analyzing input natural language queries and user sentiment" refers to software and hardware for analyzing user-input queries and the associated sentiment.
[1149] "Generative AI" refers to artificial intelligence models used to parse natural language database queries.
[1150] "Means of parsing" refers to the process of using generative AI to parse natural language database queries.
[1151] A "structured query language" refers to a query language that can be executed against a database and is created by generative AI through analysis of natural language queries.
[1152] "Database" refers to a collection of data to which structured query languages are submitted.
[1153] "Means for adjusting based on user emotions" refers to software or algorithms for adjusting the obtained results based on the analyzed user emotions.
[1154] "Means for returning adjusted results to the user" refers to a process for returning adjusted results before they are displayed to the user.
[1155] This invention combines a system in which a user inputs a request in natural language, a generative AI converts it into an SQL query, and executes the query against a database, with an emotion engine. The system recognizes the user's emotions and adjusts the system's response based on those emotions.
[1156] System configuration
[1157] 1. The user enters a database query in natural language
[1158] Users input queries in natural language through the device interface, such as "Tell me my shopping spending for July 2023."
[1159] 2. Emotion Engine Analysis
[1160] As the device receives user input, the emotion engine analyzes the user's emotions using voice analysis, text analysis, and even facial expression recognition. For example, if the user's voice sounds irritated while typing, the emotion engine can detect it.
[1161] 3. Sending input data
[1162] The device sends the user's natural language input and analyzed emotion information to the server, allowing the server to receive the user's intention and emotion simultaneously.
[1163] System action
[1164] 1. Natural Language Analysis
[1165] The server passes the received natural language request to a generative AI model, which analyzes the natural language. This analysis allows the system to understand the user's intent and convert it into a structured query language, such as SQL. OpenAI's GPT-3 is one example of a generative AI model.
[1166] 2. Generating SQL Queries
[1167] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1168] 3. Sending a query to the database
[1169] The server sends the generated SQL query to a database, such as PostgreSQL, to retrieve the specified data.
[1170] 4. Adjustment of the results
[1171] The server receives the results from the database and passes them to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is annoyed, the system adjusts the response to use kind words.
[1172] 5. Displaying the results
[1173] The adjusted results are sent back to the device and displayed to the user. For example, it may say something like, "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help."
[1174] Specific examples
[1175] 1. User Input
[1176] The user types into the device, "Tell me my shopping expenses for July 2023," while speaking in a grumpy voice.
[1177] 2. Emotion Engine Analysis
[1178] The terminal receives the user's input, and the emotion engine analyzes the user's emotion, which is irritation, from the grumpy voice.
[1179] 3. Sending input data
[1180] The device transmits a natural language request and interpreted emotion information to the server.
[1181] Prompt Sentence Examples
[1182] "User asks: 'What are my shopping expenses for July 2023?'"
[1183] This specific process allows users to access the database through a natural language interface and receive responses tailored to their emotions at the time. This system provides users with an intuitive and convenient operation experience, while also realizing responses that take emotions into consideration.
[1184] The flow of the identification process in the second embodiment will be described with reference to FIG.
[1185] Specific processing explanation of the system program
[1186] Processing flow
[1187] Step 1:
[1188] The user inputs a query in natural language through the device interface, for example, "Tell me my shopping expenditures for July 2023." Input is done using the keyboard or voice input function of a PC or smartphone.
[1189] Input: Natural language query "What was my shopping spend for July 2023?"
[1190] Output: User input data
[1191] Step 2:
[1192] As soon as the device receives the user's input, the emotion engine analyzes the user's emotion, using, for example, voice analysis or text analysis. Emotions such as irritation are detected.
[1193] Input: User voice or text data
[1194] Output: Sentiment analysis result (e.g., irritation)
[1195] Step 3:
[1196] The device sends a natural language query and analyzed emotion information to the server, which then sends this data to the server using an HTTP request.
[1197] Input: Natural language query and sentiment analysis results
[1198] Output: Request data sent to the server
[1199] Step 4:
[1200] The server passes the received natural language query and sentiment information to a generative AI model, which analyzes the natural language. For example, OpenAI's GPT-3 is used as the generative AI model. The prompt sentence is "User question: 'Tell me about shopping expenses in July 2023.'"
[1201] Input: Natural language query and sentiment information
[1202] Output: Parsing results (structured information that understands the intent)
[1203] Step 5:
[1204] The generative AI model automatically generates appropriate SQL queries from the analyzed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1205] Input: Parsed result
[1206] Output: SQL query
[1207] Step 6:
[1208] The server sends the generated SQL query to a database, such as PostgreSQL, to retrieve the specified data.
[1209] Input: SQL query
[1210] Output: Data retrieved from the database (e.g., shopping expenditure total)
[1211] Step 7:
[1212] The server passes the results from the database to the emotion engine, which tailors the response based on the user's emotions, for example adding kind words to an annoyed user.
[1213] Input: Database results and emotion information
[1214] Output: Reconciled response message
[1215] Step 8:
[1216] The server sends the adjusted results back to the device, which then displays the results to the user. For example, a message like, "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help" may be displayed.
[1217] Input: Tailored response message
[1218] Output: The message displayed to the user
[1219] Specific operation example
[1220] User input: The user uses their smartphone to say, "Tell me my shopping expenses for July 2023."
[1221] Emotion engine analysis: The emotion engine detects irritation from the user's tone of voice.
[1222] Sending input: The device sends the analysis results and natural language query to the server.
[1223] Natural language parsing: The server prompts the generative AI model to parse the query and generate an SQL query.
[1224] SQL query generation: The generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" and returns it to the server.
[1225] Querying the database: The server executes the generated SQL query and retrieves the results from the database.
[1226] Returning and adjusting the results: The server uses the emotion engine to adjust the results and add friendly comments.
[1227] Displaying the results: The adjusted results are sent to the device and displayed to the user.
[1228] This allows users to receive responses based on natural language and emotions, making the entire system intuitive and user-friendly.
[1229] (Application example 2)
[1230] Next, a description will be given of Application Example 2. In the following description, the data processing device 12 will be referred to as a "server" and the headset type terminal 314 will be referred to as a "terminal."
[1231] In modern brick-and-mortar stores, customers are required to provide instant and accurate responses when checking product and inventory information. However, conventional systems have difficulty responding appropriately to customer emotions, which can lead to dissatisfaction and stress. In particular, if a customer is feeling unhappy or irritated, not being able to respond appropriately can lead to a decline in the quality of the customer experience and lower satisfaction.
[1232] The specific processing by the specific processing unit 290 of the data processing device 12 in the application example 2 is realized by the following means.
[1233] In this invention, the server includes a means for a user to input a database query in natural language, a means for parsing the natural language database query using a generation AI, a means for generating a structured query language using the analysis results of the generation AI, and a means including an emotion engine for analyzing the user's emotions, thereby enabling a response to a question input by a customer in natural language to be made in an appropriate tone according to the emotion.
[1234] A "user" is a person who utilizes the system to enter database queries and retrieve information.
[1235] "Natural language" refers to the language used by humans in everyday speech and writing, as opposed to a structured query language.
[1236] A "database query" refers to a question sent to a database to retrieve information.
[1237] "Generative AI" is an artificial intelligence technique for analyzing natural language and converting it into a structured query language.
[1238] An "emotion engine" is a technology that analyzes a user's emotions and adjusts the system's response based on the analysis results.
[1239] "Means for adjusting responses" refers to methods for changing the content and tone of the system's responses based on the analysis results of the emotion engine.
[1240] "Brick and Mortar Store" means a sales and service establishment located at a physical location.
[1241] "Product and inventory questions" refer to inquiries made by customers in physical stores about specific products and their availability.
[1242] "Tone" refers to the tone and mood of speech or writing, and can change depending on emotions.
[1243] The system for implementing this invention is designed to allow users to ask questions about products and inventory in a physical store in natural language and to provide appropriate responses based on their emotions. Specific embodiments are described below.
[1244] Hardware and software used
[1245] Hardware
[1246] Smartphone
[1247] server
[1248] Database (e.g. SQLite)
[1249] software
[1250] Python
[1251] OpenAI GPT-3
[1252] sqlite3 library
[1253] text_to_emotion library
[1254] Text processing libraries (e.g. textblob)
[1255] Data processing and calculation
[1256] User input and sentiment analysis
[1257] When a user uses a smartphone to input a question about a product or inventory in natural language, the voice or text is sent to the system. When the device receives the question, it uses an emotion engine to analyze the user's emotion. For example, it uses the text_to_emotion library to extract emotions (anger, sadness, joy, etc.) from the user's voice or text.
[1258] Natural Language Parsing and Query Generation
[1259] Once the sentiment analysis is complete, the device sends the user's natural language input to the server, which uses a generative AI model (e.g., OpenAI GPT-3) to convert the natural language request into an SQL query, using an example prompt like this:
[1260] Generate a SQL query for: Is this item in stock?
[1261] The generative AI model automatically generates an appropriate SQL query (e.g., SELECT FROM inventory WHERE product_name='product name';) for this prompt statement.
[1262] Database Queries and Response Throttle
[1263] The server then sends the generated SQL query to the database to retrieve the specified data. The results are then passed back to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is frustrated, a softer response such as "We have it in stock. We will help you shortly, so please wait." is generated.
[1264] Specific examples
[1265] 1. User input: A user asks "Is this item in stock?" on their smartphone and types it in an annoyed voice.
[1266] 2. Emotion analysis: The emotion engine analyzes the user's frustration and sends the emotion information to the server.
[1267] 3. Natural language parsing: The server uses a generative AI model to translate natural language questions into SQL queries.
[1268] 4. Database query: An SQL query is sent to the database to retrieve the appropriate inventory information.
[1269] 5. Response adjustment: Based on the obtained results, the emotion engine creates a response according to the user's emotions.
[1270] 6. Response display: The terminal will display "We have the item in stock. We will assist you shortly, so please wait."
[1271] Prompt Sentence Examples
[1272] Generate a SQL query for: Is this item in stock?
[1273] In this way, users can ask questions about products and inventory in natural language and receive appropriate responses based on their emotions. This system improves the customer experience in physical stores and provides highly satisfying service.
[1274] The flow of the specific processing in the application example 2 will be described with reference to FIG.
[1275] Step 1:
[1276] The user types a question into their smartphone in natural language, such as "Is this item in stock?" The input is sent to the device in voice or text format.
[1277] Step 2:
[1278] The device receives the user's question and uses an emotion engine to analyze the user's emotion from the input question and its voice or text. The emotion engine uses the text_to_emotion library to identify emotions (e.g., irritation, anger, sadness, etc.) from the question text or voice. The input of this process is the user's question, and the output is the emotion information identified by the emotion engine.
[1279] Step 3:
[1280] The device sends the input natural language question and analyzed emotion information to the server. In this step, the user's intention and emotion are passed to the server. The input is the natural language question and emotion information, and the output is data transmission to the server.
[1281] Step 4:
[1282] The server uses a generative AI model (e.g., OpenAI GPT-3) to convert natural language questions into SQL queries. An example prompt sentence is given to the generative AI model: "Generate a SQL query for: Is this item in stock?" The input is the prompt sentence, and the output is the generated SQL query.
[1283] Step 5:
[1284] The server sends the generated SQL query to a database to retrieve the corresponding data. An example of the database used is SQLite. The input of this process is the SQL query, and the output is the retrieved data.
[1285] Step 6:
[1286] The server passes the results retrieved from the database back to the emotion engine, which then adjusts the response based on the emotion. For example, a response such as "We have it in stock" may be generated based on the retrieved inventory information, and then adjusted to a gentler tone, such as "We will help you right away, so please wait," depending on the user's emotion. The input is the results from the database and emotion information, and the output is the adjusted response.
[1287] Step 7:
[1288] The terminal obtains the tailored response and displays or speaks it to the user. For example, it may say, "We have it in stock. We will help you shortly, so please wait." The input is the tailored response, and the output is the displayed or spoken response to the user.
[1289] Through the above steps, users can ask questions about products and inventory in natural language and receive appropriate responses according to their feelings.
[1290] The specific processing unit 290 transmits the result of the specific processing to the headset type terminal 314. In the headset type terminal 314, the control unit 46A causes the speaker 240 and the display 343 to output the result of the specific processing. The microphone 238 acquires audio indicating a user input regarding the result of the specific processing. The control unit 46A transmits audio data indicating the user input acquired by the microphone 238 to the data processing device 12. In the data processing device 12, the specific processing unit 290 acquires the audio data.
[1291] The data generation model 58 is a so-called generative AI (Artificial Intelligence). An example of the data generation model 58 is ChatGPT (Internet Search<URL: https: / / openai.com / blog / chatgpt> ), Gemini (Internet search <url: https: gemini.google.com ?hl="ja">) and other generation AIs. The data generation model 58 is obtained by performing deep learning on a neural network. A prompt including an instruction is input to the data generation model 58, and inference data such as voice data indicating voice, text data indicating text, and image data indicating an image is also input. The data generation model 58 performs inference on the input inference data in accordance with the instruction indicated by the prompt, and outputs the inference result in a data format such as voice data and text data. Here, inference refers to, for example, analysis, classification, prediction, and / or summarization.
[1292] In the above embodiment, an example was given in which the specific processing is performed by the data processing device 12, but the technology of the present disclosure is not limited to this, and the specific processing may be performed by the headset type terminal 314.
[1293] [Fourth embodiment]
[1294] FIG. 7 shows an example of the configuration of a data processing system 410 according to the fourth embodiment.
[1295] 7, a data processing system 410 includes a data processing device 12 and a robot 414. An example of the data processing device 12 is a server.
[1296] The data processing device 12 includes a computer 22, a database 24, and a communication I / F 26. The computer 22 is an example of a "computer" according to the technology of the present disclosure. The computer 22 includes a processor 28, a RAM 30, and a storage 32. The processor 28, the RAM 30, and the storage 32 are connected to a bus 34. The database 24 and the communication I / F 26 are also connected to the bus 34. The communication I / F 26 is connected to a network 54. Examples of the network 54 include a WAN (Wide Area Network) and / or a LAN (Local Area Network).
[1297] The robot 414 includes a computer 36, a microphone 238, a speaker 240, a camera 42, a communication I / F 44, and a control target 443. The computer 36 includes a processor 46, a RAM 48, and a storage 50. The processor 46, the RAM 48, and the storage 50 are connected to a bus 52. The microphone 238, the speaker 240, the camera 42, and the control target 443 are also connected to the bus 52.
[1298] The microphone 238 receives instructions and the like from the user 20 by receiving voice uttered by the user 20. The microphone 238 captures the voice uttered by the user 20, converts the captured voice into audio data, and outputs it to the processor 46. The speaker 240 outputs audio in accordance with instructions from the processor 46.
[1299] Camera 42 is a small digital camera equipped with an optical system including a lens, aperture, and shutter, and an imaging element such as a CMOS (Complementary Metal-Oxide-Semiconductor) image sensor or a CCD (Charge Coupled Device) image sensor, and captures images of the surroundings of user 20 (for example, an imaging range defined by an angle of view equivalent to the field of vision of a typical healthy person).
[1300] The communication I / F 44 is connected to a network 54. The communication I / Fs 44 and 26 are responsible for the exchange of various information between the processor 46 and the processor 28 via the network 54. The exchange of various information between the processor 46 and the processor 28 using the communication I / Fs 44 and 26 is carried out in a secure state.
[1301] The control object 443 includes a display device, LEDs in the eyes, and motors for driving the arms, hands, and feet. The posture and gestures of the robot 414 are controlled by controlling the motors of the arms, hands, and feet. Some of the emotions of the robot 414 can be expressed by controlling these motors. In addition, the facial expressions of the robot 414 can also be expressed by controlling the light emission state of the LEDs in the eyes of the robot 414.
[1302] Fig. 8 shows an example of the main functions of the data processing device 12 and the robot 414. As shown in Fig. 8, in the data processing device 12, a specific process is performed by the processor 28. A specific process program 56 is stored in the storage 32.
[1303] The specific processing program 56 is an example of a "program" according to the technology of the present disclosure. The processor 28 reads the specific processing program 56 from the storage 32 and executes the read specific processing program 56 on the RAM 30. The specific processing is realized by the processor 28 operating as a specific processing unit 290 in accordance with the specific processing program 56 executed on the RAM 30.
[1304] The storage 32 stores a data generation model 58 and an emotion identification model 59. The data generation model 58 and the emotion identification model 59 are used by the identification processing unit 290.
[1305] In the robot 414, the processor 46 performs the reception output process. A reception output program 60 is stored in the storage 50. The processor 46 reads the reception output program 60 from the storage 50 and executes the read reception output program 60 on the RAM 48. The reception output process is realized by the processor 46 operating as the control unit 46A in accordance with the reception output program 60 executed on the RAM 48.
[1306] Next, a description will be given of the specific processing performed by the specific processing unit 290 of the data processing device 12. In the following description, the data processing device 12 will be referred to as a "server" and the robot 414 will be referred to as a "terminal."
[1307] Overall system overview
[1308] This invention is a system in which a generation AI converts requests entered by a user in natural language into SQL queries and executes those queries against a database.
[1309] System configuration
[1310] 1. User input:
[1311] Users can input queries in natural language through the device interface, for example, by entering a specific request such as "Tell me my shopping spending for July 2023."
[1312] 2. Receiving and sending input:
[1313] The device receives natural language input from the user and sends it to the server, which understands the user's intent, converts it into an appropriate data format, and sends it.
[1314] 3. Natural Language Analysis:
[1315] The server passes the received natural language request to a generative AI model for natural language analysis, which allows the system to understand the user's intent and translate it into a structured query language, such as SQL.
[1316] 4. Generate SQL queries:
[1317] The server's generation AI automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1318] 5. Query the database:
[1319] The server sends the generated SQL query to the database to retrieve the specified data.
[1320] 6. Return and display of results:
[1321] The device receives the query results from the server and displays them to the user in a format that is easy for the user to understand. For example, it might say, "Shopping expenses for July 2023 total 15,000 yen."
[1322] Specific examples
[1323] 1. User input:
[1324] The user types "Tell me my shopping expenses for July 2023" into the device interface.
[1325] 2. Receiving and sending input:
[1326] The terminal receives this input and transmits it over the network to the server.
[1327] 3. Natural Language Analysis:
[1328] The server uses generative AI to parse the natural language input, such as "Tell me about my shopping expenses in July 2023," and understand the intent.
[1329] 4. Generate SQL queries:
[1330] The generation AI generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1331] 5. Query the database:
[1332] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[1333] 6. Return and display of results:
[1334] The server receives the results from the database and sends them back to the terminal, which then displays to the user, "The total shopping expenditure for July 2023 is 15,000 yen."
[1335] Program processing overview
[1336] User: Enters a query in natural language into the device.
[1337] Terminal: Sends user input to the server.
[1338] Server: Uses generative AI to analyze natural language queries, generate SQL queries, send the queries to the database, and retrieve the results.
[1339] Terminal: Displays the results received from the server to the user.
[1340] In this way, the present invention enables users to freely access and operate databases using natural language, without relying on a specific application, dramatically improving the convenience of accessing information and manipulating data.
[1341] The processing flow will be explained below.
[1342] Step 1:
[1343] The user enters a query in natural language into the device interface, for example, "What are my shopping expenses for July 2023?"
[1344] Step 2:
[1345] The terminal receives this input and sends the user's natural language query to the server, including the process of converting the input data into an appropriate format for transmission.
[1346] Step 3:
[1347] The server passes the received natural language query to the generative AI model, which then performs syntactic analysis of the natural language and performs processing to accurately understand the user's intent.
[1348] Step 4:
[1349] The generative AI model generates SQL queries based on the analyzed natural language query. For example, it generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" from the input natural language.
[1350] Step 5:
[1351] The server sends the generated SQL query to the database, which searches for data based on the specified criteria.
[1352] Step 6:
[1353] The database executes the query and sends the results back to the server. For example, if the total shopping expenditure for July is 15,000 yen, the results are sent back to the server.
[1354] Step 7:
[1355] The server receives the results returned from the database and returns them to the terminal, formatted in a way that is easy for the user to understand.
[1356] Step 8:
[1357] The terminal displays the results it receives to the user. For example, it displays something like, "The total shopping expenditure for July 2023 is 15,000 yen."
[1358] These specific processing steps allow users to access the database through a natural language interface and intuitively obtain the information they need. The entire system is designed to be simple and user-friendly.
[1359] Example 1
[1360] Next, a description will be given of Example 1. In the following description, the data processing device 12 will be referred to as a "server" and the robot 414 will be referred to as a "terminal."
[1361] Conventional database interfaces require specialized knowledge, making it difficult for general users to intuitively operate databases. Furthermore, the process of converting natural language into structured queries is complex, resulting in low accuracy and efficiency. This creates challenges that limit fast and accurate access to data.
[1362] The specific processing by the specific processing unit 290 of the data processing device 12 in the first embodiment is realized by the following means.
[1363] In this invention, the server includes: means for a user to input a database query in natural language; means for a terminal to receive the natural language query and transmit it to the server; means for the server to parse the natural language query using a generative AI model; means for generating a structured query language using the analysis results of the generative AI model; means for transmitting the structured query language to a database; means for the server to receive results obtained from the database and return them to the user; and means for the terminal to display the results to the user. This enables users to operate the database in natural language without having specialized knowledge, achieving fast and accurate access to data.
[1364] "User" refers to a person who uses the system to enter database queries in natural language and retrieve desired information.
[1365] A "terminal" is a device used by a user to input a natural language query, and is a device responsible for sending the query to a server and displaying the results received from the server to the user.
[1366] "Server" refers to the central processing unit of the system that receives natural language queries sent by users, analyzes them using a generative AI model, generates structured query language, and sends it to the database.
[1367] A "generative AI model" is an artificial intelligence model that analyzes natural language queries, understands their intent, and converts them into structured query language.
[1368] A "natural language query" is a query entered by a user in everyday language, and is a statement for retrieving specific information from a database.
[1369] A "structured query language" is a form of query language that is generated by a generative AI model based on natural language and can be executed against a database; an example is SQL.
[1370] A "database" is an information management system that receives queries sent using a structured query language, stores and manages corresponding data, and returns data in response to the queries.
[1371] "Results" are data retrieved from a database and information provided based on a user's natural language query.
[1372] This invention is a system in which a generative AI model converts requests entered by a user in natural language into SQL queries and executes the queries against a database. The system consists of the following components:
[1373] composition
[1374] 1. User Input
[1375] Users can use devices such as PCs or smartphones to input queries in natural language, for example, a specific request such as "Tell me my shopping expenditures for July 2023."
[1376] 2. Receiving and Sending Input
[1377] The device receives the user's natural language input and sends it to the server. The device converts the received input into an appropriate data format and sends it to the server as an API request, typically via an HTTP POST request.
[1378] 3. Natural Language Analysis
[1379] The server passes the received natural language request to a generative AI model, such as OpenAI's GPT-4. The server uses the generative AI model to parse the request and understand the user's intent.
[1380] 4. Generating SQL Queries
[1381] The generative AI model generates appropriate SQL queries from the parsed natural language input. For example, for the input "What is my shopping expenditure for July 2023?", it generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'."
[1382] 5. Querying the Database
[1383] The server then sends the generated SQL query to a database to retrieve the specified data, typically a database such as MySQL or PostgreSQL.
[1384] 6. Returning and displaying results
[1385] The server receives the results returned from the database and sends them to the device. The device then displays the received data in a format that is easy for the user to understand. For example, it might present the user with a message like, "The total shopping expenditure for July 2023 is 15,000 yen."
[1386] Specific examples
[1387] 1. User Input
[1388] The user types into the device interface, "Tell me my shopping expenses for July 2023."
[1389] 2. Receiving and Sending Input
[1390] The terminal receives this input and transmits it to the server over the network.
[1391] 3. Natural Language Analysis
[1392] The server uses the generative AI model to analyze the natural language input, such as "Tell me about my shopping expenses in July 2023," and understand the intent.
[1393] 4. Generating SQL Queries
[1394] The generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1395] 5. Querying the Database
[1396] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[1397] 6. Returning and displaying results
[1398] The server receives the results from the database and sends them back to the terminal, which then displays to the user, "The total shopping expenditure for July 2023 is 15,000 yen."
[1399] Prompt Sentence Examples
[1400] The server receives the user's input, "Tell me about my shopping expenses in July 2023," and sends the following prompt to the generative AI model:
[1401] "Convert natural language input: 'What was my shopping spend in July 2023?' into a SQL query."
[1402] This means that users can enter database queries in natural language that meet their intentions, even if they do not have specialized knowledge, and the generative AI model will generate appropriate SQL queries, allowing them to quickly obtain the results.
[1403] The flow of the identification process in the first embodiment will be described with reference to FIG.
[1404] System program processing flow
[1405] Step 1: User Input
[1406] explanation:
[1407] A user uses the terminal interface to enter a query in natural language.
[1408] input:
[1409] Natural language queries (e.g., "What was my shopping spend for July 2023?")
[1410] output:
[1411] Natural language requests
[1412] Specific behavior:
[1413] Users open an application or web browser on their PC or smartphone and type a query in natural language, which is sent through an interface such as a text box.
[1414] Step 2: Receiving and Sending Input
[1415] explanation:
[1416] The terminal receives the user's input and sends it to the server.
[1417] input:
[1418] Natural language requests
[1419] output:
[1420] API requests sent to the server
[1421] Specific behavior:
[1422] A program on the device takes the natural language input and sends it as an HTTP POST request to a server, for example, an API endpoint.
[1423] Step 3: Natural Language Analysis
[1424] explanation:
[1425] The server passes the received natural language request to a generative AI model for analysis.
[1426] input:
[1427] Natural language requests
[1428] output:
[1429] Parsed input data
[1430] Specific behavior:
[1431] The server sends a prompt to the generative AI model, for example:
[1432] "Convert natural language input: 'What was my shopping spend in July 2023?' into a SQL query."
[1433] The generative AI model uses this prompt to parse the input.
[1434] Step 4: Generate SQL queries
[1435] explanation:
[1436] A generative AI model generates appropriate SQL queries from the parsed natural language input.
[1437] input:
[1438] Parsed input data
[1439] output:
[1440] SQL Query
[1441] Specific behavior:
[1442] Based on the prompt, the generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" and returns it to the server.
[1443] Step 5: Query the database
[1444] explanation:
[1445] The server sends the generated SQL query to the database to retrieve the specified data.
[1446] input:
[1447] SQL Query
[1448] output:
[1449] Data retrieved from a database
[1450] Specific behavior:
[1451] The server program establishes a database connection, executes the generated SQL queries, and receives the query results from a database such as MySQL or PostgreSQL.
[1452] Step 6: Return and display results
[1453] explanation:
[1454] The server sends the results obtained from the database to the terminal, which displays them to the user.
[1455] input:
[1456] Data retrieved from a database
[1457] output:
[1458] Results displayed to the user
[1459] Specific behavior:
[1460] The server formats the acquired data in JSON format or similar and returns it to the device as an HTTP response. The device then reformats the received data and displays to the user, "Total shopping expenditures for July 2023 are 15,000 yen."
[1461] (Application example 1)
[1462] Next, a description will be given of Application Example 1. In the following description, the data processing device 12 will be referred to as a "server" and the robot 414 will be referred to as a "terminal."
[1463] Currently, inventory management at logistics centers requires the use of dedicated terminals and specific software, which often makes operation complicated. It is also difficult to quickly check inventory information in real time or perform statistical analysis of data. This reduces management efficiency and increases the risk of operational errors and delays. The present invention aims to provide a simple interface using natural language to improve the efficiency of inventory management at logistics centers.
[1464] The specific processing by the specific processing unit 290 of the data processing device 12 in the application example 1 is realized by the following means.
[1465] In this invention, the server includes means for a user to input a database query in natural language, means for parsing the natural language database query using a generation AI, means for generating a structured query language using the analysis result by the generation AI, means for transmitting the structured query language to a database, means for returning the results obtained from the database to the user, means for a user to check inventory status in natural language at a logistics center, and means for managing inventory status using the parsed natural language query. This enables easy and fast inventory management using natural language.
[1466] The "means for a user to input a database query in natural language" is an interface that allows a user to input a query to a database using a natural language that is intuitively easy for the user to understand.
[1467] "Generative AI" is an artificial intelligence model used to parse and convert incoming natural language database queries into structured query language.
[1468] "Syntax analysis" is the process of analyzing queries entered in natural language and understanding their meaning and intent.
[1469] "Structured Query Language" refers to a structured form of database query language such as SQL.
[1470] The "means for sending to a database" is a system component for sending the generated structured query language to a database and executing the query.
[1471] The "means for users to check inventory status in natural language at a logistics center" is an interface that accepts natural language queries regarding inventory information at a logistics center, analyzes them, and provides inventory information.
[1472] The "means for managing inventory status using parsed natural language queries" is a system for retrieving information from an inventory database within a logistics center based on parsed natural language queries and managing that information.
[1473] The present invention is realized as an inventory management system in a distribution center. The operation of the entire system will be described in detail below.
[1474] Overall system configuration
[1475] 1. User Input
[1476] Users input queries in natural language through a smartphone or robot interface, making specific requests such as "What is the current stock level of product A?"
[1477] 2. Receiving and Sending Input
[1478] The terminal receives natural language input from the user and sends it to the server, which then understands the user's intent, converts it into an appropriate data format, and sends it.
[1479] 3. Natural Language Analysis
[1480] The server passes the received natural language request to a generative AI model (e.g., the GPT-2 model) for natural language parsing. This parsing process allows the system to understand the user's intent and convert it into a structured SQL query.
[1481] 4. Generating SQL Queries
[1482] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, such as "SELECT quantity FROM inventory WHERE product_name='Product A'".
[1483] 5. Querying the Database
[1484] The server then sends the generated SQL query to a database, typically an SQLite database, to retrieve data that matches the specified criteria.
[1485] 6. Returning and displaying results
[1486] The terminal receives the query results sent back from the server and displays them to the user. The display content is presented in a format that is easy for the user to understand. For example, it may say, "The current stock quantity of product A is 500 units."
[1487] Specific examples
[1488] User input: "What is the current stock quantity of product A?"
[1489] Generated SQL query: "SELECT quantity FROM inventory WHERE product_name='Product A'"
[1490] Return result: "The current stock quantity of product A is 500 units."
[1491] Prompt Sentence Examples
[1492] Prompt: "User: Tell me the current stock quantity of product A.\nGenerating AI:"
[1493] This system allows logistics center managers to quickly and accurately obtain inventory information using natural language. The smartphone and robot-based interface simplifies complex operations, significantly improving management efficiency.
[1494] The flow of the specific processing in the application example 1 will be described with reference to FIG.
[1495] Step 1:
[1496] The user inputs a query in natural language through a smartphone or robot interface. For example, a specific request might be, "Tell me the current stock level of product A." This input is received by the terminal.
[1497] Step 2:
[1498] The terminal transmits natural language queries received from a user to a server. The input is a natural language request, and the output is a request sent to the server. The terminal performs this transmission process over a network.
[1499] Step 3:
[1500] The server passes the received natural language request to a generative AI model (e.g., GPT-2) for syntax analysis. The input here is a natural language query, which the generative AI model analyzes and converts into SQL. This process is performed using a prompt in the form of "User: Tell me the current inventory of product A.\nGenerative AI:"
[1501] Step 4:
[1502] The generative AI model generates an appropriate SQL query from the parsed natural language. The input here is the natural language query passed to the generative AI model, and the output is the generated SQL query. As a specific example, the query generated is "SELECT quantity FROM inventory WHERE product_name='Product A'".
[1503] Step 5:
[1504] The server sends the generated SQL query to the database to retrieve data that matches the specified conditions. The input is the SQL query, and the output from the database is the result of executing the SQL query. This result is specific data such as inventory levels.
[1505] Step 6:
[1506] The server sends the results retrieved from the database to the terminal, which then displays them to the user. The input is the result of the SQL query, and the output is a display in a format that is easy for the user to understand. For example, the display might say, "The current stock quantity for product A is 500 units."
[1507] By the above steps, this invention makes it possible to efficiently manage inventory in a logistics center using natural language.
[1508] Furthermore, an emotion engine that estimates the user's emotion may be further combined. That is, the identification processing unit 290 may estimate the user's emotion using the emotion identification model 59, and perform identification processing using the user's emotion.
[1509] Overall system overview
[1510] This invention combines a system in which a user inputs a request in natural language, a generation AI converts it into an SQL query, and executes the query against a database, with an emotion engine that recognizes the user's emotions and adjusts the system's response based on those emotions.
[1511] System configuration
[1512] 1. User input:
[1513] Users can input queries in natural language through the device interface, for example, by entering a specific request such as "Tell me my shopping spending for July 2023."
[1514] 2. Emotion Engine Analysis:
[1515] As the device receives user input, the emotion engine analyzes the user's emotions using voice, text, and even facial expression recognition technology. For example, if the user sounds sad while typing, their emotion will be analyzed.
[1516] 3. Sending input:
[1517] The device transmits the user's natural language input and analyzed emotion information to the server, allowing the server to receive the user's intention and emotion simultaneously.
[1518] 4. Natural Language Analysis:
[1519] The server passes the received natural language request to a generative AI model for natural language analysis, which allows the system to understand the user's intent and translate it into a structured query language, such as SQL.
[1520] 5. Generate SQL queries:
[1521] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1522] 6. Query the database:
[1523] The server sends the generated SQL query to the database to retrieve the specified data.
[1524] 7. Return and Adjustment of Results:
[1525] The server receives the results from the database and passes them to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is sad, the system adjusts to provide a more polite and kind response.
[1526] 8. Displaying the results:
[1527] The adjusted results are sent back to the device and displayed to the user. For example, it may say, "Your total shopping expenditure for July 2023 is 15,000 yen. Please let us know if you have any questions."
[1528] Specific examples
[1529] 1. User input:
[1530] The user types into the device, "Tell me my shopping expenses for July 2023," while speaking in a grumpy voice.
[1531] 2. Emotion Engine Analysis:
[1532] The terminal receives the user's input, and the emotion engine analyzes the user's emotion, which is irritation, from the grumpy voice.
[1533] 3. Sending input:
[1534] The device transmits a natural language request and interpreted emotion information to the server.
[1535] 4. Natural Language Analysis:
[1536] The server uses generative AI to parse the natural language phrase "Tell me about my shopping expenses in July 2023."
[1537] 5. Generate SQL queries:
[1538] The generation AI generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1539] 6. Query the database:
[1540] The server sends this SQL query to the database to retrieve data that matches the specified conditions.
[1541] 7. Return and Adjustment of Results:
[1542] The server passes the results to the emotion engine, which then adjusts the response, adding gentle words to calm down an annoyed user.
[1543] 8. Displaying the results:
[1544] The adjusted results are sent back to the device and displayed to the user, such as "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help."
[1545] This specific process allows users to access the database through a natural language interface and receive responses tailored to their emotions at the time. The entire system is designed to be simple and user-friendly.
[1546] The processing flow will be explained below.
[1547] Step 1:
[1548] The user enters a query in natural language into the device interface, for example, "What are my shopping expenses for July 2023?"
[1549] Step 2:
[1550] The device receives user input, and the emotion engine analyzes emotions from the user's input voice or text. The analyzed emotion information is identified as emotion tags such as "irritated" or "sad."
[1551] Step 3:
[1552] The device sends the received natural language input and emotion tag to the server. The transmitted data includes the user's input content and emotion information.
[1553] Step 4:
[1554] The server passes the received natural language request to the generative AI model, which analyzes the input natural language and processes it to understand the user's intent.
[1555] Step 5:
[1556] The server's generative AI model generates appropriate SQL queries from the analyzed natural language. For example, from the input "Tell me about my shopping expenditures in July 2023," the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" is generated.
[1557] Step 6:
[1558] The server sends the generated SQL query to the database to retrieve data based on the specified criteria, and the database executes the query and sends the results back to the server.
[1559] Step 7:
[1560] The server receives the retrieved data and passes it to the emotion engine, which tailors the response message based on the user's emotion tag. For example, if the user is "irritated," it generates a response using more polite and kind language.
[1561] Step 8:
[1562] The server sends the tailored response to the terminal, and the sent data includes the answer to the user's question and the tailored response message.
[1563] Step 9:
[1564] The device displays the results it receives to the user. For example, it might say, "Your total shopping expenditure for July 2023 is 15,000 yen. Please let us know if you have any questions." The user receives a thoughtful response that is in line with their feelings, providing a better user experience.
[1565] This specific processing step allows users to access the database through a natural language interface and receive responses tailored to their current emotions. The entire system is designed to be simple and user-friendly.
[1566] Example 2
[1567] Next, a description will be given of Example 2. In the following description, the data processing device 12 will be referred to as a "server" and the robot 414 will be referred to as a "terminal."
[1568] Conventional systems have issues with being unable to accurately analyze the intent of users when they input database queries in natural language, and unable to provide responses based on the user's emotions, which can lead to poor user experience and make the system difficult to use.
[1569] The identification process by the identification processing unit 290 of the data processing device 12 in Example 2 is realized by the following means. In this invention, the server includes: means for a user to input a database query in natural language; means for analyzing the input natural language query and the user's emotions; means for parsing the natural language database query using a generation AI; means for generating a structured query language using the analysis result by the generation AI; means for transmitting the structured query language to a database; means for adjusting the result obtained from the database based on the user's emotions; and means for returning the adjusted result to the user. This makes it possible to accurately analyze the user's query input in natural language and provide a response adjusted based on the user's emotions.
[1570] "User" means any person or entity that utilizes the System to enter queries in natural language.
[1571] A "natural language query" refers to a database query entered by a user in natural language.
[1572] "Means for analyzing input natural language queries and user sentiment" refers to software and hardware for analyzing user-input queries and the associated sentiment.
[1573] "Generative AI" refers to artificial intelligence models used to parse natural language database queries.
[1574] "Means of parsing" refers to the process of using generative AI to parse natural language database queries.
[1575] A "structured query language" refers to a query language that can be executed against a database and is created by generative AI through analysis of natural language queries.
[1576] "Database" refers to a collection of data to which structured query languages are submitted.
[1577] "Means for adjusting based on user emotions" refers to software or algorithms for adjusting the obtained results based on the analyzed user emotions.
[1578] "Means for returning adjusted results to the user" refers to a process for returning adjusted results before they are displayed to the user.
[1579] This invention combines a system in which a user inputs a request in natural language, a generative AI converts it into an SQL query, and executes the query against a database, with an emotion engine. The system recognizes the user's emotions and adjusts the system's response based on those emotions.
[1580] System configuration
[1581] 1. The user enters a database query in natural language
[1582] Users input queries in natural language through the device interface, such as "Tell me my shopping spending for July 2023."
[1583] 2. Emotion Engine Analysis
[1584] As the device receives user input, the emotion engine analyzes the user's emotions using voice analysis, text analysis, and even facial expression recognition. For example, if the user's voice sounds irritated while typing, the emotion engine can detect it.
[1585] 3. Sending input data
[1586] The device sends the user's natural language input and analyzed emotion information to the server, allowing the server to receive the user's intention and emotion simultaneously.
[1587] System action
[1588] 1. Natural Language Analysis
[1589] The server passes the received natural language request to a generative AI model, which analyzes the natural language. This analysis allows the system to understand the user's intent and convert it into a structured query language, such as SQL. OpenAI's GPT-3 is one example of a generative AI model.
[1590] 2. Generating SQL Queries
[1591] The generative AI model automatically generates appropriate SQL queries from the parsed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1592] 3. Sending a query to the database
[1593] The server sends the generated SQL query to a database, such as PostgreSQL, to retrieve the specified data.
[1594] 4. Adjustment of the results
[1595] The server receives the results from the database and passes them to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is annoyed, the system adjusts the response to use kind words.
[1596] 5. Displaying the results
[1597] The adjusted results are sent back to the device and displayed to the user. For example, it may say something like, "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help."
[1598] Specific examples
[1599] 1. User Input
[1600] The user types into the device, "Tell me my shopping expenses for July 2023," while speaking in a grumpy voice.
[1601] 2. Emotion Engine Analysis
[1602] The terminal receives the user's input, and the emotion engine analyzes the user's emotion, which is irritation, from the grumpy voice.
[1603] 3. Sending input data
[1604] The device transmits a natural language request and interpreted emotion information to the server.
[1605] Prompt Sentence Examples
[1606] "User asks: 'What are my shopping expenses for July 2023?'"
[1607] This specific process allows users to access the database through a natural language interface and receive responses tailored to their emotions at the time. This system provides users with an intuitive and convenient operation experience, while also realizing responses that take emotions into consideration.
[1608] The flow of the identification process in the second embodiment will be described with reference to FIG.
[1609] Specific processing explanation of the system program
[1610] Processing flow
[1611] Step 1:
[1612] The user inputs a query in natural language through the device interface, for example, "Tell me my shopping expenditures for July 2023." Input is done using the keyboard or voice input function of a PC or smartphone.
[1613] Input: Natural language query "What was my shopping spend for July 2023?"
[1614] Output: User input data
[1615] Step 2:
[1616] As soon as the device receives the user's input, the emotion engine analyzes the user's emotion, using, for example, voice analysis or text analysis. Emotions such as irritation are detected.
[1617] Input: User voice or text data
[1618] Output: Sentiment analysis result (e.g., irritation)
[1619] Step 3:
[1620] The device sends a natural language query and analyzed emotion information to the server, which then sends this data to the server using an HTTP request.
[1621] Input: Natural language query and sentiment analysis results
[1622] Output: Request data sent to the server
[1623] Step 4:
[1624] The server passes the received natural language query and sentiment information to a generative AI model, which analyzes the natural language. For example, OpenAI's GPT-3 is used as the generative AI model. The prompt sentence is "User question: 'Tell me about shopping expenses in July 2023.'"
[1625] Input: Natural language query and sentiment information
[1626] Output: Parsing results (structured information that understands the intent)
[1627] Step 5:
[1628] The generative AI model automatically generates appropriate SQL queries from the analyzed natural language, for example, "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'".
[1629] Input: Parsed result
[1630] Output: SQL query
[1631] Step 6:
[1632] The server sends the generated SQL query to a database, such as PostgreSQL, to retrieve the specified data.
[1633] Input: SQL query
[1634] Output: Data retrieved from the database (e.g., shopping expenditure total)
[1635] Step 7:
[1636] The server passes the results from the database to the emotion engine, which tailors the response based on the user's emotions, for example adding kind words to an annoyed user.
[1637] Input: Database results and emotion information
[1638] Output: Reconciled response message
[1639] Step 8:
[1640] The server sends the adjusted results back to the device, which then displays the results to the user. For example, a message like, "Your total shopping expenditure for July 2023 is 15,000 yen. Please contact us if you need any help" may be displayed.
[1641] Input: Tailored response message
[1642] Output: The message displayed to the user
[1643] Specific operation example
[1644] User input: The user uses their smartphone to say, "Tell me my shopping expenses for July 2023."
[1645] Emotion engine analysis: The emotion engine detects irritation from the user's tone of voice.
[1646] Sending input: The device sends the analysis results and natural language query to the server.
[1647] Natural language parsing: The server prompts the generative AI model to parse the query and generate an SQL query.
[1648] SQL query generation: The generative AI model generates the SQL query "SELECT SUM(amount) FROM transactions WHERE category='shopping' AND date LIKE '2023-07%'" and returns it to the server.
[1649] Querying the database: The server executes the generated SQL query and retrieves the results from the database.
[1650] Returning and adjusting the results: The server uses the emotion engine to adjust the results and add friendly comments.
[1651] Displaying the results: The adjusted results are sent to the device and displayed to the user.
[1652] This allows users to receive responses based on natural language and emotions, making the entire system intuitive and user-friendly.
[1653] (Application example 2)
[1654] Next, a description will be given of Application Example 2. In the following description, the data processing device 12 will be referred to as a "server" and the robot 414 will be referred to as a "terminal."
[1655] In modern brick-and-mortar stores, customers are required to provide instant and accurate responses when checking product and inventory information. However, conventional systems have difficulty responding appropriately to customer emotions, which can lead to dissatisfaction and stress. In particular, if a customer is feeling unhappy or irritated, not being able to respond appropriately can lead to a decline in the quality of the customer experience and lower satisfaction.
[1656] The specific processing by the specific processing unit 290 of the data processing device 12 in the application example 2 is realized by the following means.
[1657] In this invention, the server includes a means for a user to input a database query in natural language, a means for parsing the natural language database query using a generation AI, a means for generating a structured query language using the analysis results of the generation AI, and a means including an emotion engine for analyzing the user's emotions, thereby enabling a response to a question input by a customer in natural language to be made in an appropriate tone according to the emotion.
[1658] A "user" is a person who utilizes the system to enter database queries and retrieve information.
[1659] "Natural language" refers to the language used by humans in everyday speech and writing, as opposed to a structured query language.
[1660] A "database query" refers to a question sent to a database to retrieve information.
[1661] "Generative AI" is an artificial intelligence technique for analyzing natural language and converting it into a structured query language.
[1662] An "emotion engine" is a technology that analyzes a user's emotions and adjusts the system's response based on the analysis results.
[1663] "Means for adjusting responses" refers to methods for changing the content and tone of the system's responses based on the analysis results of the emotion engine.
[1664] "Brick and Mortar Store" means a sales and service establishment located at a physical location.
[1665] "Product and inventory questions" refer to inquiries made by customers in physical stores about specific products and their availability.
[1666] "Tone" refers to the tone and mood of speech or writing, and can change depending on emotions.
[1667] The system for implementing this invention is designed to allow users to ask questions about products and inventory in a physical store in natural language and to provide appropriate responses based on their emotions. Specific embodiments are described below.
[1668] Hardware and software used
[1669] Hardware
[1670] Smartphone
[1671] server
[1672] Database (e.g. SQLite)
[1673] software
[1674] Python
[1675] OpenAI GPT-3
[1676] sqlite3 library
[1677] text_to_emotion library
[1678] Text processing libraries (e.g. textblob)
[1679] Data processing and calculation
[1680] User input and sentiment analysis
[1681] When a user uses a smartphone to input a question about a product or inventory in natural language, the voice or text is sent to the system. When the device receives the question, it uses an emotion engine to analyze the user's emotion. For example, it uses the text_to_emotion library to extract emotions (anger, sadness, joy, etc.) from the user's voice or text.
[1682] Natural Language Parsing and Query Generation
[1683] Once the sentiment analysis is complete, the device sends the user's natural language input to the server, which uses a generative AI model (e.g., OpenAI GPT-3) to convert the natural language request into an SQL query, using an example prompt like this:
[1684] Generate a SQL query for: Is this item in stock?
[1685] The generative AI model automatically generates an appropriate SQL query (e.g., SELECT FROM inventory WHERE product_name='product name';) for this prompt statement.
[1686] Database Queries and Response Throttle
[1687] The server then sends the generated SQL query to the database to retrieve the specified data. The results are then passed back to the emotion engine, which adjusts the response based on the user's emotions. For example, if the user is frustrated, a softer response such as "We have it in stock. We will help you shortly, so please wait." is generated.
[1688] Specific examples
[1689] 1. User input: A user asks "Is this item in stock?" on their smartphone and types it in an annoyed voice.
[1690] 2. Emotion analysis: The emotion engine analyzes the user's frustration and sends the emotion information to the server.
[1691] 3. Natural language parsing: The server uses a generative AI model to translate natural language questions into SQL queries.
[1692] 4. Database query: An SQL query is sent to the database to retrieve the appropriate inventory information.
[1693] 5. Response adjustment: Based on the obtained results, the emotion engine creates a response according to the user's emotions.
[1694] 6. Response display: The terminal will display "We have the item in stock. We will assist you shortly, so please wait."
[1695] Prompt Sentence Examples
[1696] Generate a SQL query for: Is this item in stock?
[1697] In this way, users can ask questions about products and inventory in natural language and receive appropriate responses based on their emotions. This system improves the customer experience in physical stores and provides highly satisfying service.
[1698] The flow of the specific processing in the application example 2 will be described with reference to FIG.
[1699] Step 1:
[1700] The user types a question into their smartphone in natural language, such as "Is this item in stock?" The input is sent to the device in voice or text format.
[1701] Step 2:
[1702] The device receives the user's question and uses an emotion engine to analyze the user's emotion from the input question and its voice or text. The emotion engine uses the text_to_emotion library to identify emotions (e.g., irritation, anger, sadness, etc.) from the question text or voice. The input of this process is the user's question, and the output is the emotion information identified by the emotion engine.
[1703] Step 3:
[1704] The device sends the input natural language question and analyzed emotion information to the server. In this step, the user's intention and emotion are passed to the server. The input is the natural language question and emotion information, and the output is data transmission to the server.
[1705] Step 4:
[1706] The server uses a generative AI model (e.g., OpenAI GPT-3) to convert natural language questions into SQL queries. An example prompt sentence is given to the generative AI model: "Generate a SQL query for: Is this item in stock?" The input is the prompt sentence, and the output is the generated SQL query.
[1707] Step 5:
[1708] The server sends the generated SQL query to a database to retrieve the corresponding data. An example of the database used is SQLite. The input of this process is the SQL query, and the output is the retrieved data.
[1709] Step 6:
[1710] The server passes the results retrieved from the database back to the emotion engine, which then adjusts the response based on the emotion. For example, a response such as "We have it in stock" may be generated based on the retrieved inventory information, and then adjusted to a gentler tone, such as "We will help you right away, so please wait," depending on the user's emotion. The input is the results from the database and emotion information, and the output is the adjusted response.
[1711] Step 7:
[1712] The terminal obtains the tailored response and displays or speaks it to the user. For example, it may say, "We have it in stock. We will help you shortly, so please wait." The input is the tailored response, and the output is the displayed or spoken response to the user.
[1713] Through the above steps, users can ask questions about products and inventory in natural language and receive appropriate responses according to their feelings.
[1714] The specific processing unit 290 transmits the result of the specific processing to the robot 414. In the robot 414, the control unit 46A causes the speaker 240 and the control target 443 to output the result of the specific processing. The microphone 238 acquires voice indicating a user input regarding the result of the specific processing. The control unit 46A transmits voice data indicating the user input acquired by the microphone 238 to the data processing device 12. In the data processing device 12, the specific processing unit 290 acquires the voice data.
[1715] The data generation model 58 is a so-called generative AI (Artificial Intelligence). An example of the data generation model 58 is ChatGPT (Internet Search<URL: https: / / openai.com / blog / chatgpt> ), Gemini (Internet search <url: https: gemini.google.com ?hl="ja">) and other generation AIs. The data generation model 58 is obtained by performing deep learning on a neural network. A prompt including an instruction is input to the data generation model 58, and inference data such as voice data indicating voice, text data indicating text, and image data indicating an image is also input. The data generation model 58 performs inference on the input inference data in accordance with the instruction indicated by the prompt, and outputs the inference result in a data format such as voice data and text data. Here, inference refers to, for example, analysis, classification, prediction, and / or summarization.
[1716] In the above embodiment, an example in which the specific processing is performed by the data processing device 12 has been given, but the technology of the present disclosure is not limited to this, and the specific processing may be performed by the robot 414.
[1717] The emotion identification model 59 as an emotion engine may determine the user's emotion according to a specific mapping. Specifically, the emotion identification model 59 may determine the user's emotion according to an emotion map (see FIG. 9), which is a specific mapping. Similarly, the emotion identification model 59 may determine the robot's emotion, and the identification processing unit 290 may perform identification processing using the robot's emotion.
[1718] FIG. 9 is a diagram illustrating an emotion map 400 on which multiple emotions are mapped. In the emotion map 400, emotions are arranged in concentric circles radiating from the center. Emotions closer to the center of the concentric circles are more primitive. Emotions representing states and actions arising from a state of mind are arranged on the outer edges of the concentric circles. The concept of emotion includes both affect and mental states. Emotions generally generated from reactions occurring in the brain are arranged on the left side of the concentric circles. Emotions generally induced by situational judgment are arranged on the right side of the concentric circles. Emotions generally generated from reactions occurring in the brain and induced by situational judgment are arranged on the upper and lower sides of the concentric circles. Furthermore, the emotion of "pleasure" is arranged on the upper side of the concentric circles, and the emotion of "discomfort" is arranged on the lower side. In this way, in the emotion map 400, multiple emotions are mapped based on the structure by which emotions are generated, and emotions that tend to occur simultaneously are mapped close to each other.
[1719] These emotions are distributed in the 3 o'clock direction on emotion map 400, and typically fluctuate between relief and anxiety. In the right half of emotion map 400, situational awareness dominates over internal sensations, resulting in a sense of calm.
[1720] The inside of emotion map 400 represents what is going on in the mind, and the outside of emotion map 400 represents behavior, so the further you go outside emotion map 400, the more visible the emotions become (the more they are expressed in behavior).
[1721] Human emotions are based on various balances, such as posture and blood sugar levels. When these balances deviate from the ideal, a state of discomfort is indicated, and when they approach the ideal, a state of pleasure is indicated. Emotions can also be created for robots, automobiles, and motorcycles, based on various balances, such as posture and remaining battery life. When these balances deviate from the ideal, a state of discomfort is indicated, and when they approach the ideal, a state of pleasure is indicated. An emotion map can be generated, for example, based on Dr. Mitsuyoshi's emotion map (Research on Voice Emotion Recognition and Emotional Brain Physiological Signal Analysis Systems, Tokushima University, Doctoral Dissertation: https: / / ci.nii.ac.jp / naid / 500000375379). The left half of the emotion map lists emotions belonging to the "reaction" domain, where sensation is dominant. The right half of the emotion map lists emotions belonging to the "situation" domain, where situational awareness is dominant.
[1722] The emotion map defines two emotions that promote learning. One is a negative emotion on the situation side, around the middle of "repentance" or "reflection." In other words, this occurs when the robot experiences negative emotions such as "I never want to feel this way again" or "I don't want to be scolded again." The other is a positive emotion on the response side, around "desire." In other words, this occurs when the robot experiences positive feelings such as "I want more" or "I want to know more."
[1723] The emotion identification model 59 inputs user input into a pre-trained neural network, obtains emotion values indicating each emotion shown in the emotion map 400, and determines the user's emotion. This neural network is pre-trained based on multiple pieces of training data that are combinations of user input and emotion values indicating each emotion shown in the emotion map 400. Furthermore, this neural network is trained so that emotions that are located close to each other have similar values, as in the emotion map 900 shown in FIG. 10. FIG. 10 shows an example in which multiple emotions, "relieved," "calm," and "reassuring," have similar emotion values.
[1724] The system according to the present disclosure has been described above mainly with respect to the functions of the data processing device 12, but the system according to the present disclosure is not necessarily implemented on a server. The system according to the present disclosure may be implemented as a general information processing system. The present disclosure may be implemented, for example, as a software program running on a personal computer or an application running on a smartphone, etc. The method according to the present disclosure may be provided to users in the form of SaaS (Software as a Service).
[1725] In the above embodiment, an example was given in which the specific processing is performed by one computer 22, but the technology of the present disclosure is not limited to this, and the specific processing may be distributed and performed by a plurality of computers including the computer 22. For example, the data generation model 58 may be provided in an external device of the data processing device 12, and data may be generated in the external device in accordance with input data.
[1726] In the above embodiment, an example in which the specific processing program 56 is stored in the storage 32 has been described, but the technology of the present disclosure is not limited to this. For example, the specific processing program 56 may be stored in a portable, computer-readable, non-transitory storage medium such as a USB (Universal Serial Bus) memory. The specific processing program 56 stored in the non-transitory storage medium is installed in the computer 22 of the data processing device 12. The processor 28 executes the specific processing in accordance with the specific processing program 56.
[1727] Alternatively, the specific processing program 56 may be stored in a storage device such as a server connected to the data processing device 12 via the network 54, and the specific processing program 56 may be downloaded and installed on the computer 22 in response to a request from the data processing device 12.
[1728] It is not necessary to store all of the specific processing program 56 in a storage device such as a server connected to the data processing device 12 via the network 54, or to store all of the specific processing program 56 in the storage 32; only a portion of the specific processing program 56 may be stored.
[1729] The hardware resource for executing a specific process can be any of the following processors: An example of a processor is a CPU, which is a general-purpose processor that functions as a hardware resource for executing a specific process by executing software, i.e., a program. Another example of a processor is a dedicated electrical circuit, such as an FPGA (Field-Programmable Gate Array), a PLD (Programmable Logic Device), or an ASIC (Application Specific Integrated Circuit), which is a processor with a circuit configuration designed specifically for executing a specific process. Each processor has built-in or connected memory, and each processor uses the memory to execute the specific process.
[1730] The hardware resource that executes the specific processing may be configured with one of these various processors, or may be configured with a combination of two or more processors of the same or different types (for example, a combination of multiple FPGAs, or a combination of a CPU and an FPGA). Also, the hardware resource that executes the specific processing may be a single processor.
[1731] As an example of a system configured with a single processor, first, one processor is configured by combining one or more CPUs and software, and this processor functions as a hardware resource that executes a specific process. Second, there is a system that uses a processor that realizes the functions of an entire system including multiple hardware resources that execute a specific process on a single IC chip, as typified by SoC (System-on-a-chip). In this way, a specific process is realized using one or more of the above-mentioned various processors as hardware resources.
[1732] Furthermore, the hardware structure of these various processors can be, more specifically, an electric circuit that combines circuit elements such as semiconductor devices. The specific processing described above is merely an example. Therefore, it goes without saying that unnecessary steps may be deleted, new steps may be added, or the processing order may be rearranged, without departing from the spirit of the invention.
[1733] The above-described description and illustrations are a detailed explanation of the parts related to the technology of the present disclosure and are merely an example of the technology of the present disclosure. For example, the above description of the configuration, functions, actions, and effects is an explanation of an example of the configuration, functions, actions, and effects of the parts related to the technology of the present disclosure. Therefore, it goes without saying that unnecessary parts may be deleted, new elements may be added, or replacements may be made to the above-described description and illustrations within the scope of the gist of the technology of the present disclosure. Furthermore, to avoid confusion and facilitate understanding of the parts related to the technology of the present disclosure, the above-described description and illustrations omit explanations of common technical knowledge that do not require particular explanation to enable the implementation of the technology of the present disclosure.
[1734] All publications, patent applications, and technical standards mentioned in this specification are herein incorporated by reference to the same extent as if each individual publication, patent application, or technical standard was specifically and individually indicated to be incorporated by reference.
[1735] The following is further disclosed regarding the above embodiment.
[1736] (Claim 1)
[1737] a means for a user to input a database query in natural language;
[1738] means for utilizing generative AI to parse the natural language database query;
[1739] A means for generating a structured query language using the analysis results of the generation AI;
[1740] means for transmitting the structured query language to a database;
[1741] a means for returning results retrieved from the database to the user;
[1742] A system including:
[1743] (Claim 2)
[1744] 10. The system of claim 1, further comprising means for a user to input natural language queries for viewing historical data and performing statistical analysis.
[1745] (Claim 3)
[1746] 2. The system of claim 1, wherein the structured query language is SQL.
[1747] "Example 1"
[1748] (Claim 1)
[1749] a means for a user to input a database query in natural language;
[1750] means for receiving the natural language query at the terminal and transmitting it to a server;
[1751] means for the server to utilize a generative AI model to parse the natural language query;
[1752] A means for generating a structured query language using the analysis results of the generative AI model;
[1753] means for transmitting the structured query language to a database;
[1754] A means for the server to receive the results obtained from the database and return them to the user;
[1755] means for the terminal to display said results to a user;
[1756] A system including:
[1757] (Claim 2)
[1758] 10. The system of claim 1, further comprising means for a user to input natural language queries for viewing historical data and performing statistical analysis.
[1759] (Claim 3)
[1760] 2. The system of claim 1, wherein the structured query language is SQL.
[1761] "Application Example 1"
[1762] (Claim 1)
[1763] a means for a user to input a database query in natural language;
[1764] means for utilizing generative AI to parse the natural language database query;
[1765] A means for generating a structured query language using the analysis results of the generation AI;
[1766] means for transmitting the structured query language to a database;
[1767] a means for returning results retrieved from the database to the user;
[1768] A means for users to check inventory status in natural language at the logistics center;
[1769] a means for managing inventory using parsed natural language queries;
[1770] A system including:
[1771] (Claim 2)
[1772] 10. The system of claim 1, further comprising means for a user to input natural language queries for viewing historical data and performing statistical analysis.
[1773] (Claim 3)
[1774] 2. The system of claim 1, wherein the structured query language is SQL.
[1775] "Example 2: Combining Emotion Engines"
[1776] (Claim 1)
[1777] a means for a user to input a database query in natural language;
[1778] means for analyzing an input natural language query and a user's sentiment;
[1779] means for utilizing generative AI to parse the natural language database query;
[1780] A means for generating a structured query language using the analysis results of the generation AI;
[1781] means for transmitting the structured query language to a database;
[1782] means for adjusting the results retrieved from the database based on the user's emotions;
[1783] means for returning the adjusted results to the user;
[1784] A system including:
[1785] (Claim 2)
[1786] 10. The system of claim 1, further comprising means for a user to input natural language queries for viewing historical data and performing statistical analysis.
[1787] (Claim 3)
[1788] 2. The system of claim 1, wherein the structured query language is SQL.
[1789] "Application example 2 when combining emotion engines"
[1790] (Claim 1)
[1791] a means for a user to input a database query in natural language;
[1792] means for utilizing generative AI to parse the natural language database query;
[1793] A means for generating a structured query language using the analysis results of the generation AI;
[1794] means for transmitting the structured query language to a database;
[1795] a means for returning results retrieved from the database to the user;
[1796] means for adjusting a response of the system based on the emotion analyzed by the emotion engine;
[1797] A system including:
[1798] (Claim 2)
[1799] 10. The system of claim 1, further comprising means for a user to input natural language queries for viewing historical data and performing statistical analysis.
[1800] (Claim 3)
[1801] 2. The system of claim 1, wherein the structured query language is SQL.
[1802] (Claim 4)
[1803] 10. The system of claim 1, further comprising means for customers to input questions about products and inventory in natural language in a physical store.
[1804] (Claim 5)
[1805] The system according to claim 4, further comprising means for adjusting responses in a tone according to the customer's emotions based on the emotions analyzed by the emotion engine in the physical store. [Explanation of symbols]
[1806] 10, 210, 310, 410 Data Processing Systems 12 Data Processing Device 14 Smart Devices 214 Smart Glasses 314 Headset-type terminal 414 Robot< / url:> < / url:> < / url:> < / url:>
Claims
1. a means for a user to input a database query in natural language; means for utilizing generative AI to parse the natural language database query; A means for generating a structured query language using the analysis results of the generation AI; means for transmitting the structured query language to a database; a means for returning results retrieved from the database to the user; A system including:
2. 10. The system of claim 1, further comprising means for a user to input natural language queries to view historical data and perform statistical analysis.
3. The system of claim 1 , wherein the structured query language is SQL.
Citation Information
Patent Citations
Persona chatbot control method and system
JP2022180282A