Intelligent invoicing method and system based on AI large model
By integrating ASR, OCR and LLM models on the Dify intelligent body platform, the intelligent invoice is built, which solves the problem of cumbersome traditional invoice process and achieves efficient and convenient invoice operation.
Patent Information
- Application Number
- CN202510940201.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-09
- Publication Date
- 2025-08-08
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The traditional invoice is cumbersome, the invoice business is complex and the efficiency and accuracy are low.
Using the intelligent invoice method of AI big model, the open source ASR speech recognition model, OCR text recognition model and LLM large language model are integrated through the Dify agent platform to build a speech recognition agent, a file content recognition agent and an invoice filling agent to realize the processing of natural language text and the extraction of invoice field information.
The operation process of invoice is simplified, the invoice processing efficiency is improved, labor costs are reduced, and efficient and convenient invoice service capabilities are provided.
Smart Images

Figure CN120450796A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of artificial intelligence and invoice issuance technology, and in particular to an intelligent invoicing method and system based on an AI big model. Background Art
[0002] With the rapid development of digitalization and artificial intelligence, traditional invoicing processes in corporate finance and tax management often face numerous challenges. The complex information required to fill in, select, and confirm invoicing can lead to increased operational complexity, cumbersome processes, and low efficiency and accuracy.
[0003] Therefore, it is necessary to provide an intelligent invoicing method and system based on AI big model to solve the above technical problems. Summary of the Invention
[0004] In order to solve the above technical problems, the present invention provides an intelligent invoicing method and system based on an AI large model, which is used to solve the problems in the existing technology of high complexity of invoicing business operations, cumbersome invoicing process, and low invoicing efficiency and accuracy.
[0005] The present invention provides an intelligent invoicing method based on an AI large model, wherein the intelligent invoicing system includes: Install the Dify agent platform and privately deploy the open-source ASR speech recognition model, open-source OCR text recognition model, and open-source LLM large language model; On the Dify agent platform, a speech recognition agent is constructed that integrates the open source ASR speech recognition model, obtains the speech file stream through the API and converts it into natural language text; On the Dify agent platform, a file content recognition agent is built that integrates the open source OCR text recognition model, obtains text file streams through the API and converts them into natural language text; On the Dify agent platform, an order invoicing agent is constructed that integrates the open source LLM large language model and extracts order field information from the natural language text through prompt word engineering; On the Dify agent platform, an invoice filling agent is constructed that integrates the open source LLM large language model, and extracts invoice field information from the natural language text through prompt word engineering.
[0006] Preferably, the Dify agent platform is used to provide a development and operating environment for AI agents, and to combine and call AI models through a workflow mode, wherein the AI agents include speech recognition agents, file content recognition agents, order invoicing agents and invoice filling agents; the AI models include open source ASR speech recognition models, open source OCR text recognition models and open source LLM large language models.
[0007] Preferably, the open source ASR speech recognition model is used to provide the function of ASR automatic speech recognition; the open source OCR file recognition model is used to provide the function of OCR recognition and extraction of text information; and the open source LLM large language model is used to provide the function of natural language semantic understanding and reasoning generation.
[0008] Preferably, the order invoicing agent is configured with an order API calling interface for receiving the order processing type and order auxiliary information, as well as the order invoicing dialogue text corresponding to the natural language text; Order processing types include order information extraction and order item selection; when the order processing type is order information extraction, the order field information is extracted from the order invoicing dialogue text through the prompt word engineering and returned in JSON format text, and the order field information includes customer name, customer tax number, order number, order date and order amount; when the order processing type is order item selection, multiple candidate orders are retrieved and matched based on the extracted order field information, a candidate order is selected from the multiple candidate orders and passed into the candidate order list through the order auxiliary information parameter, and the index number of the selected candidate order is identified from the order invoicing dialogue text through the prompt word engineering and returned in Arabic numerals.
[0009] Preferably, the invoice filling agent is configured with an invoicing API call interface for receiving the invoicing processing type and invoicing auxiliary information, as well as the invoicing dialogue text corresponding to the natural language text; Invoicing processing types include invoicing information extraction, invoicing item selection, and invoicing information supplementation. When the invoicing processing type is invoicing information extraction, the invoicing field information is extracted from the invoicing dialog text through the prompt word process and returned as JSON text. The invoicing field information includes customer name, sales product or service name, invoicing amount, and invoice remarks. When the invoicing processing type is invoicing item selection, multiple candidate customers or candidate products are retrieved and matched based on the extracted invoicing field information. A candidate customer is selected from the multiple candidate customers and passed into the candidate customer list through the invoicing auxiliary information parameter. Alternatively, a candidate product is selected from the multiple candidate products and passed into the candidate product list through the invoicing auxiliary information parameter. The index number of the selected candidate customer or candidate product is identified from the invoicing dialog text through the prompt word process and returned in Arabic numerals. When the invoicing processing type is invoicing information supplementation, the supplementary field information needs to be passed into the invoicing auxiliary information parameter and referenced in the prompt word. The content corresponding to the supplementary field information is extracted from the invoicing dialog text and returned as a string.
[0010] An intelligent invoicing system based on an AI large model, the intelligent invoicing system comprising: The user interaction layer includes the order invoicing page and the invoice filling page. A dialog window is provided on each page. When the user enters the order or invoice description text in the dialog window and clicks the send button, the intelligent order invoicing or invoice filling function of the AI capability layer is invoked. The AI capability layer is used to centrally manage and dispatch voice recognition agents, file content recognition agents, order invoicing agents, and invoice filling agents; The business logic layer is used to assemble invoice data, issue invoice codes, generate invoice format files, store invoices, deliver invoices, and transmit invoices in accordance with preset tax requirements; The data persistence layer is used to store orders and invoices using a relational database, and to store and manage invoice format files using a distributed file repository.
[0011] Preferably, a file upload icon button is provided near the send button of the dialog window, and the file upload icon button supports the user end to upload files of various formats and then call the OCR file recognition function of the AI capability layer; There is also a microphone icon button near the send button in the conversational window to invoke voice input. After the user clicks the microphone icon button, he starts speaking, invoking the voice collection and automatic recognition capabilities of the AI capability layer.
[0012] Preferably, when the user terminal clicks the mouse button and continues to hold down the microphone icon button, voice collection begins; when the user terminal releases the mouse button, the voice collection operation is automatically ended and a voice file stream in wav format is generated.
[0013] Preferably, a preview interface of the invoice face style is provided below the dialogue window, i.e., the invoice filling page. The invoice filling page is used to display the invoice field information extracted by the invoice filling agent in real time, and provide invoice management and query functions, wherein the invoice management function includes customer management, commodity management, invoice amount management, and pre-coding management functions.
[0014] Compared with related technologies, the intelligent invoicing method and system based on AI big model provided by the present invention has the following beneficial effects: The present invention integrates an open source ASR speech recognition model through a speech recognition intelligent body, realizing online speech collection that does not rely on third-party devices or components. Then, recording clips can be obtained through simple mouse events, and the speech stream can be sent to the ASR model for processing and conversion into natural language text. This effectively solves the problem that traditional speech collection systems need to rely on external devices, and that devices such as intelligent speech recognition mice need to rely on external network ASR cloud services, which in turn causes the unavailability of the enterprise office intranet.
[0015] The present invention integrates an open source OCR text recognition model through a file content recognition agent to achieve the ability to recognize and extract file content.
[0016] This invention integrates the open-source Large Language Model (LLM) into the order invoicing agent, enabling it to extract order information from natural language text. Furthermore, leveraging the LLM's powerful learning and semantic understanding capabilities, fine-tuning training allows it to understand and process user requests in complex scenarios, significantly streamlining the invoicing process.
[0017] This invention integrates the open-source LLM large language model into the invoice filling agent, extracting invoicing element information from natural language text and supporting the supplementary extraction of specific field information. Furthermore, leveraging the LLM large language model's powerful learning and semantic understanding capabilities, fine-tuning training can be used to understand and process user invoicing requests in complex scenarios, helping to reduce the complexity of invoice filling and simplifying the invoicing process.
[0018] The intelligent invoicing system of the present invention can provide a natural conversational interactive invoicing mode by integrating multiple AI intelligent entities, effectively reducing the learning cost of system use, significantly simplifying the invoicing business operation process, improving invoicing processing efficiency, reducing labor costs, and bringing users a better invoicing experience. It provides enterprises with efficient, convenient, and intelligent invoicing service capabilities, which helps to achieve the intelligent leap of corporate invoicing business. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 This is a flow chart of an intelligent invoicing method based on an AI large model of the present invention; Figure 2 This is a system block diagram of an intelligent invoicing system based on an AI large model of the present invention; Figure 3 This is a layered architecture diagram of an intelligent invoicing system based on an AI big model of the present invention. DETAILED DESCRIPTION
[0020] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0021] Example 1
[0022] like Figure 1 As shown, an intelligent invoicing method based on an AI large model, the intelligent invoicing system includes: S1: Install the Dify agent platform and privately deploy the open-source ASR speech recognition model, open-source OCR text recognition model, and open-source LLM large language model. It is understandable that the Dify intelligent agent platform, LLM large language model, ASR speech recognition model, and OCR text recognition model can be integrated into the AI infrastructure layer.
[0023] Among them, you can install and deploy the Dify intelligent agent platform, which provides the development and operation environment of AI intelligent agents, as well as the combined call of multiple AI models through workflow mode. Then, you can privately deploy an open source ASR speech recognition model, such as OpenAI-Whisper, DeepSpeech, etc., to provide ASR automatic speech recognition capabilities; privately deploy an open source OCR file recognition model, such as PaddleOCR, Tesseract OCR, EasyOCR, TrOCR, etc., to provide OCR recognition and text information extraction capabilities; privately deploy one or more open source LLM large language models, such as DeepSeek, Qwen, etc., to provide natural language semantic understanding and reasoning generation capabilities.
[0024] It should be noted that in an intelligent workflow, the LLM large language model of appropriate specifications can be selected based on the complexity of the semantic environment of the invoicing business processing steps. A small-scale model with a small number of parameters can achieve a faster response speed, while a large-scale model with a large number of parameters can provide better understanding and generation capabilities.
[0025] S2, building a speech recognition agent on the Dify agent platform that integrates the open source ASR speech recognition model, obtaining the speech file stream through the API and converting it into natural language text; Through the Dify agent platform, you can build a speech recognition agent, call the privately deployed ASR speech recognition model, and provide an API interface to receive voice file streams and return converted natural language text.
[0026] S3, building a file content recognition agent on the Dify agent platform that integrates the open source OCR text recognition model, obtains text file streams through the API and converts them into natural language text; Through the Dify agent platform, you can build a file content recognition agent, call a privately deployed OCR model, and provide an API interface to receive files in formats such as images and PDFs, and return the text recognized from the files.
[0027] S4, building an order invoicing agent on the Dify agent platform that integrates the open source LLM large language model, and extracting order field information from the natural language text through prompt word engineering; Based on the workflow model in the Dify agent platform, an order invoicing agent can be built to call the privately deployed LLM large language model and receive processing type, auxiliary information, and dialogue text through the API call interface.
[0028] Processing types include information extraction and project selection. When the processing type is information extraction, the ability to extract order query fields is provided. Prompt word engineering extracts the field information supported by order queries, namely customer name, customer tax ID, order number, order date, and order amount, from the conversation text and returns it as JSON text. When the processing type is project selection, the ability to select a candidate order from multiple candidate orders is provided. The selected candidate order is passed to the candidate order list via auxiliary information parameters, and the index number of the selected candidate order is identified from the conversation text through prompt word engineering and returned as Arabic numerals.
[0029] It should be noted that for information extraction processing types, it is usually necessary to use an LLM large language model with a medium number of parameters, while for project selection processing types, only an LLM large language model with a smaller number of parameters is needed.
[0030] S5, on the Dify agent platform, build an invoice filling agent that integrates the open source LLM large language model, and extract the invoice field information from the natural language text through prompt word engineering.
[0031] Based on the workflow model in the Dify agent platform, an invoice filling agent can be built to call the privately deployed LLM large language model and receive processing type, auxiliary information, and dialogue text through the API call interface.
[0032] Processing types include information extraction, project selection, and information supplement. When the processing type is information extraction, the prompt word project can be used to extract the invoicing element field information, namely, customer name, sales product or service name, invoice amount, and ticket notes, from the conversation text and return it in JSON format text. When the processing type is project selection, a candidate customer or product can be selected from multiple candidate customer or product lists, and then the candidate customer or product list can be passed in through the auxiliary information parameter. The index number of the selected item can be identified from the conversation text through the prompt word project and returned in Arabic numerals. When the processing type is information supplement, the auxiliary information parameter needs to be passed in specific supplementary fields, such as customer name, sales product or service name, invoice amount, etc., and the auxiliary information parameter is referenced in the prompt word. Finally, the field content that needs to be supplemented is extracted from the conversation text and returned as a string.
[0033] It should be noted that the item selection processing type is used for scenarios where multiple matching candidates are retrieved based on the extracted customer name, product, or service name. A further conversation is required to select a single option. Because the invoicing elements extracted from a single conversation are incomplete, multiple rounds of information supplementation are required to repeatedly extract the complete invoicing element information.
[0034] During the specific implementation process, the Dify agent platform is used to provide a development and operating environment for AI agents, as well as to combine and call AI models through workflow modes. Among them, AI agents include speech recognition agents, file content recognition agents, order invoicing agents, and invoice filling agents; AI models include open source ASR speech recognition models, open source OCR text recognition models, and open source LLM large language models.
[0035] The open source ASR speech recognition model is used to provide the function of ASR automatic speech recognition; the open source OCR file recognition model is used to provide the function of OCR recognition and extraction of text information; the open source LLM large language model is used to provide the function of natural language semantic understanding and reasoning generation.
[0036] The intelligent invoicing system of the present invention adopts a layered architecture design and uses JavaWeb technology to achieve the collaborative operation of multimodal models. First, the system can use the browser's built-in Web Speech API to achieve online voice acquisition. Then, a speech recognition agent can be built, integrating the open source ASR speech recognition model to recognize voice fragments and convert them into text information. Furthermore, a file content recognition agent can be built, integrating the open source OCR file recognition model to achieve text content recognition of files in formats such as images and PDFs. An invoice filling agent can be built, integrating the LLM large language model, and using the prompt word engineering to extract invoicing element information from natural language text information, and implement the agent call on the invoice filling page. Finally, an order invoicing agent can be built, integrating the LLM large language model, using the prompt word engineering to extract order-related information from natural language text information, and implement the agent call on the order invoicing page.
[0037] The order invoicing agent is configured with an order API calling interface for receiving the order processing type and order auxiliary information, as well as the order invoicing dialogue text corresponding to the natural language text; Order processing types include order information extraction and order item selection; when the order processing type is order information extraction, the order field information is extracted from the order invoicing dialogue text through the prompt word engineering and returned in JSON format text, and the order field information includes customer name, customer tax number, order number, order date and order amount; when the order processing type is order item selection, multiple candidate orders are retrieved and matched based on the extracted order field information, a candidate order is selected from the multiple candidate orders and passed into the candidate order list through the order auxiliary information parameter, and the index number of the selected candidate order is identified from the order invoicing dialogue text through the prompt word engineering and returned in Arabic numerals.
[0038] The invoice filling agent is configured with an invoicing API call interface for receiving the invoicing processing type and invoicing auxiliary information, as well as the invoicing processing type, invoicing auxiliary information and invoicing dialogue text corresponding to the natural language text; Invoicing processing types include invoicing information extraction, invoicing item selection, and invoicing information supplementation. When the invoicing processing type is invoicing information extraction, the invoicing field information is extracted from the invoicing dialog text through the prompt word process and returned as JSON text. The invoicing field information includes customer name, sales product or service name, invoicing amount, and invoice remarks. When the invoicing processing type is invoicing item selection, multiple candidate customers or candidate products are retrieved and matched based on the extracted invoicing field information. A candidate customer is selected from the multiple candidate customers and passed into the candidate customer list through the invoicing auxiliary information parameter. Alternatively, a candidate product is selected from the multiple candidate products and passed into the candidate product list through the invoicing auxiliary information parameter. The index number of the selected candidate customer or candidate product is identified from the invoicing dialog text through the prompt word process and returned in Arabic numerals. When the invoicing processing type is invoicing information supplementation, the supplementary field information needs to be passed into the invoicing auxiliary information parameter and referenced in the prompt word. The content corresponding to the supplementary field information is extracted from the invoicing dialog text and returned as a string.
[0039] Example 2
[0040] like Figure 2 As shown, an intelligent invoicing system based on an AI large model includes: The user interaction layer includes the order invoicing page and the invoice filling page. A dialog window is provided on each page. When the user enters the order or invoice description text in the dialog window and clicks the send button, the intelligent order invoicing or invoice filling function of the AI capability layer is invoked. The AI capability layer is used to centrally manage and dispatch voice recognition agents, file content recognition agents, order invoicing agents, and invoice filling agents; The business logic layer is used to assemble invoice data, issue invoice codes, generate invoice format files, store invoices, deliver invoices, and transmit invoices in accordance with preset tax requirements; The data persistence layer is used to store orders and invoices using a relational database, and to store and manage invoice format files using a distributed file repository.
[0041] A file upload icon button is provided near the send button of the dialog window. The file upload icon button supports the user end to upload files of various formats and then call the OCR file recognition function of the AI capability layer; There is also a microphone icon button near the send button in the conversational window to invoke voice input. After the user clicks the microphone icon button, he starts speaking, invoking the voice collection and automatic recognition capabilities of the AI capability layer.
[0042] When the user clicks the mouse button and keeps pressing the microphone icon button, voice collection begins; when the user releases the mouse button, the voice collection operation ends automatically and a voice file stream in wav format is generated.
[0043] A preview interface of the invoice face style is provided below the dialogue window, namely the invoice filling page. The invoice filling page is used to display the invoice field information extracted by the invoice filling agent in real time, and provide invoice management and query functions, wherein the invoice management function includes customer management, commodity management, invoice amount management, and pre-coding management functions.
[0044] The intelligent invoicing system of the present invention can integrate all the above-mentioned AI agents, provide conversational interactive interface functions such as order invoicing and invoice filling, and realize the generation of invoice format files, storage, delivery, query and other functions of invoices. In addition, invoice data can also be transmitted to the tax system.
[0045] like Figure 3 As shown, the intelligent invoicing system of the present invention adopts a layered architecture design, including a user interaction layer, an AI capability layer, a business logic layer and a data persistence layer.
[0046] Among them, the user interaction layer focuses on implementing two pages: order invoicing and invoice filling. A dialogue window is provided on each interface. Users can directly enter the invoicing content description text and click the send button, which corresponds to calling the AI capability layer's intelligent order invoicing or intelligent invoice filling capabilities.
[0047] For the order invoicing page, an order query list page is provided below the dialog window, allowing real-time search for matching orders based on the order field information extracted by the order invoicing agent. For the invoice filling page, a preview interface for the invoice face is provided below the dialog window, displaying the invoice element information extracted by the invoice filling agent in real time and visually presenting the invoice content and style to the user. Finally, after clicking the Confirm Invoice button and issuing the invoicing instruction, the user can invoke the invoicing-to-delivery function to complete the entire invoicing process.
[0048] Next to the Send button in the dialog window, a file upload icon button is provided, which supports uploading files in various formats such as PDF and pictures. After the user uploads the file, the OCR file recognition capability of the AI capability layer can be called.
[0049] Next to the send button in the conversation window, there is a microphone icon button that invokes voice input. Users can start speaking after clicking the button, and then call upon the voice collection and automatic recognition capabilities of the AI capability layer.
[0050] The invoice filling page, located below the dialog window, provides a preview of the invoice's appearance. It displays the invoice element information extracted by the invoice filling agent in real time, and intuitively presents the invoice's content and appearance to the user. Additionally, this page offers basic management functions such as customer management, product management, invoice quota management, and pre-coding management, as well as query functions such as order and invoice inquiries.
[0051] The AI capability layer can centrally manage and dispatch all AI agents, providing core capabilities such as voice collection and automatic recognition, OCR file recognition, intelligent order invoicing, and intelligent invoice filling.
[0052] The business logic layer can implement functions such as invoice data assembly, invoice coding and issuance, invoice format file generation, invoice storage, and invoice delivery in accordance with actual tax requirements, and transmit invoice data to the tax system. JavaMail can be used to implement invoice delivery via email.
[0053] The data persistence layer uses a relational database, such as PostgreSQL, to store structured data such as orders and invoices, and a distributed file storage system, such as MinIO and FastDFS, to store and manage invoice format files, including OFD, XML, PDF and other formats.
[0054] In the order invoicing interaction process, a file is uploaded, and the file content recognition agent is invoked to identify the text in the file. Speech input is then invoked, and the speech recognition agent is invoked to convert the speech into natural language text. All the recognized text, the natural language text converted from speech, and the text entered by the user on the keyboard are sent to the order invoicing agent. The LLM large language model in the order invoicing agent extracts the field information supported by order queries. Based on this extracted field information, the order query capability of the business logic layer is invoked to retrieve and match order data. Finally, based on the order data, the order invoicing handler of the business logic layer is invoked to complete the invoicing process.
[0055] In an invoicing conversation, there's no guarantee that all the necessary information for the invoice will be fully extracted, or that the extracted information won't be able to retrieve unique matching invoicing data. In this case, a system dialog can be automatically sent to prompt the user to supplement the information or select an item. For example, in an order invoicing conversation, when multiple matching orders are retrieved, the system will prompt "Please select the order you want to invoice this time" in the dialog window. The user can fully enter or speak the uniquely identified order number, or simply say "Select the first one." The system will then return the index number through the order invoicing agent and select the corresponding order data.
[0056] In the interactive process of invoice filling, first upload the file, call the file content recognition agent to identify the text content in the file; then input the voice, call the voice recognition agent, and convert the voice into natural language text. Whether it is the text content recognized in the file, the natural language text converted by the voice, or the text entered by the user on the keyboard, it will be sent to the invoice filling agent. The LLM large language model in the invoice filling agent extracts the invoice field information. Then, based on the extracted customer name, the customer query capability of the business logic layer is called to retrieve the matching unique customer data and assemble the invoice purchaser information. Alternatively, based on the extracted sales product or service name, the product query capability of the business logic layer is called to retrieve the matching unique product data. The tax rate in the product data and the extracted invoice amount are used to calculate the tax-free amount and tax amount. The invoice item information is assembled, and finally the complete and structured invoice data is obtained. Then, the invoice filling processing program of the business logic layer is called to complete the invoice issuance process.
[0057] In the invoice filling dialogue, the user says "Help Company A to issue a special VAT invoice of 500 yuan", the system will automatically call the invoice filling agent, extract the invoice element information in JSON format with the content of "{customer name: Company A, invoice type: special invoice, invoice amount: 500}". At the same time, the system will automatically check and determine the missing invoice item information, and prompt the user in the dialogue window "What is the sales product or service of this invoice?" The user can directly answer "b service charge", and then call the invoice filling agent again to extract "b service".
[0058] It's important to note that because the microphone icon button uses JavaScript to capture the mousedown event, when the user clicks and holds the microphone icon, voice recording can be performed using the browser's built-in Web Speech API. When the user releases the mouse button, JavaScript captures the mouseup event, automatically ending recording and generating a WAV file stream. Furthermore, production use of the browser's built-in Web Speech API requires the application system to deploy the HTTPS protocol.
[0059] To sum up, through the voice recognition intelligent agent, the ability to receive voice input is realized; through the file content recognition intelligent agent, the ability to receive and recognize text information in files in formats such as pictures and PDFs is realized; through the order invoicing intelligent agent, the ability to extract order information and select orders through natural conversational interaction is realized; through the order invoicing intelligent agent, the ability to extract invoicing element information and select items through natural conversational interaction is realized. By integrating multiple AI intelligent agents, a natural conversational interactive invoicing mode is provided, which effectively reduces the system usage learning cost, improves invoicing efficiency, brings users a more friendly invoicing experience, and provides enterprises with efficient, convenient and intelligent invoicing service capabilities, significantly simplifies invoicing business operations, effectively improves invoicing processing efficiency, reduces labor costs, and helps to achieve the intelligent leap of enterprise invoicing business.
[0060] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0061] Those skilled in the art will appreciate that all or part of the steps in the various methods of the above embodiments can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium, including a read-only memory (ROM), a random access memory (RAM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), a one-time programmable read-only memory (OTPROM), an electronically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, magnetic disk storage, magnetic tape storage, or any other computer-readable medium capable of carrying or storing data.
[0062] It should also be noted that the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, commodity, or apparatus that includes a series of elements includes not only those elements but also other elements not explicitly listed, or includes elements inherent to such process, method, commodity, or apparatus. In the absence of further limitations, an element defined by the phrase "comprises a ..." does not exclude the presence of other identical elements in the process, method, commodity, or apparatus that includes the element.
Claims
1. An intelligent invoicing method based on AI big model, characterized by: include: Install the Dify agent platform and privately deploy the open-source ASR speech recognition model, open-source OCR text recognition model, and open-source LLM large language model; On the Dify agent platform, a speech recognition agent is constructed that integrates the open source ASR speech recognition model, obtains the speech file stream through the API and converts it into natural language text; On the Dify agent platform, a file content recognition agent is built that integrates the open source OCR text recognition model, obtains text file streams through the API and converts them into natural language text; On the Dify agent platform, an order invoicing agent is constructed that integrates the open source LLM large language model and extracts order field information from the natural language text through prompt word engineering; On the Dify agent platform, an invoice filling agent is constructed that integrates the open source LLM large language model, and extracts invoice field information from the natural language text through prompt word engineering.
2. According to claim 1, an intelligent invoicing method based on an AI large model is characterized in that: The Dify agent platform is used to provide a development and operating environment for AI agents, as well as to combine and call AI models through workflow modes. Among them, AI agents include speech recognition agents, file content recognition agents, order invoicing agents, and invoice filling agents; AI models include open source ASR speech recognition models, open source OCR text recognition models, and open source LLM large language models.
3. According to claim 1, an intelligent invoicing method based on an AI large model is characterized in that: The open source ASR speech recognition model is used to provide the function of ASR automatic speech recognition; the open source OCR file recognition model is used to provide the function of OCR recognition and extraction of text information; the open source LLM large language model is used to provide the function of natural language semantic understanding and reasoning generation.
4. According to claim 1, an intelligent invoicing method based on an AI large model is characterized in that: The order invoicing agent is configured with an order API calling interface for receiving the order processing type and order auxiliary information, as well as the order invoicing dialogue text corresponding to the natural language text; Order processing types include order information extraction and order item selection. When the order processing type is order information extraction, the prompt word project extracts order field information from the order invoicing dialog text and returns it in JSON format. The order field information includes customer name, customer tax ID, order number, order date, and order amount. When the order processing type is order item selection, multiple candidate orders are retrieved and matched based on the extracted order field information. One candidate order is selected from the multiple candidate orders and passed into the candidate order list through the order auxiliary information parameter. The index number of the selected candidate order is identified from the order invoicing dialogue text through the prompt word project and returned in Arabic numerals.
5. According to claim 1, an intelligent invoicing method based on an AI large model is characterized in that: The invoice filling agent is configured with an invoicing API call interface for receiving the invoicing processing type and invoicing auxiliary information, as well as the invoicing dialogue text corresponding to the natural language text; Invoicing processing types include invoicing information extraction, invoicing item selection, and invoicing information supplementation. When the invoicing processing type is invoicing information extraction, the invoicing field information is extracted from the invoicing dialog text through the prompt word process and returned as JSON text. The invoicing field information includes customer name, sales product or service name, invoicing amount, and invoice remarks. When the invoicing processing type is invoicing item selection, multiple candidate customers or candidate products are retrieved and matched based on the extracted invoicing field information. A candidate customer is selected from the multiple candidate customers and passed into the candidate customer list through the invoicing auxiliary information parameter. Alternatively, a candidate product is selected from the multiple candidate products and passed into the candidate product list through the invoicing auxiliary information parameter. The index number of the selected candidate customer or candidate product is identified from the invoicing dialog text through the prompt word process and returned in Arabic numerals. When the invoicing processing type is invoicing information supplementation, the supplementary field information needs to be passed into the invoicing auxiliary information parameter and referenced in the prompt word. The content corresponding to the supplementary field information is extracted from the invoicing dialog text and returned as a string.
6. An intelligent invoicing system based on AI big model, characterized by: The intelligent invoicing system includes: The user interaction layer includes the order invoicing page and the invoice filling page. A dialog window is provided on each page. When the user enters the order or invoice description text in the dialog window and clicks the send button, the intelligent order invoicing or invoice filling function of the AI capability layer is invoked. The AI capability layer is used to centrally manage and dispatch voice recognition agents, file content recognition agents, order invoicing agents, and invoice filling agents; The business logic layer is used to assemble invoice data, assign invoice codes, generate invoice format files, store invoices, deliver invoices, and transmit invoices in accordance with preset tax requirements; The data persistence layer is used to store orders and invoices using a relational database, and to store and manage invoice format files using a distributed file repository.
7. An intelligent invoicing system based on an AI big model according to claim 6, characterized in that: A file upload icon button is provided near the send button of the dialog window. The file upload icon button supports the user end to upload files of various formats and then call the OCR file recognition function of the AI capability layer; There is also a microphone icon button near the send button in the conversational window to invoke voice input. After the user clicks the microphone icon button, he starts speaking, invoking the voice collection and automatic recognition capabilities of the AI capability layer.
8. An intelligent invoicing system based on an AI big model according to claim 7, characterized in that: When the user clicks the mouse button and keeps pressing the microphone icon button, voice collection begins; when the user releases the mouse button, the voice collection operation ends automatically and a voice file stream in wav format is generated.
9. According to claim 6, an intelligent invoicing system based on an AI big model is characterized in that: A preview interface of the invoice face style is provided below the dialogue window, namely the invoice filling page. The invoice filling page is used to display the invoice field information extracted by the invoice filling agent in real time, and provide invoice management and query functions, wherein the invoice management function includes customer management, commodity management, invoice amount management, and pre-coding management functions.
Citation Information
Patent Citations
Billing information processing method and device based on large language model, and electronic equipment
CN118552269A
Bill information extraction method and system and storage medium
CN119495109A
Business performance anomaly detection and disposal method based on AI intelligent agent
CN119831132A
Intelligent network invoice issuing method, device and system based on AI large model
CN119963275A
Intelligent invoicing method and system based on finance and tax industry large model
CN119963276A
Cited By
Prompt prompt template automatic construction method for intelligent reimbursement system
CN120832371A