Intelligent office form processing method, system and equipment based on large model
By parsing user intent using a large language model and combining it with a knowledge base to generate form fill content, the problem of cumbersome form processing in office automation systems is solved, enabling personalized and intelligent form filling, and improving operational efficiency and user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- XIAMEN INTRETECH
- Filing Date
- 2025-12-16
- Publication Date
- 2026-05-01
AI Technical Summary
In existing office automation systems, form processing is cumbersome, lacks intelligence, and is devoid of personalized interaction, resulting in poor user efficiency and experience.
An intelligent office form processing method based on a large language model is adopted. It parses user intent through natural language commands, combines a pre-set knowledge base and MCP tools to generate form fill content, and updates the knowledge base after submission.
It enables personalized form processing and context-aware intelligent filling, simplifies user operations, improves filling accuracy and interactive experience, and enhances the system's scalability and maintainability.
Smart Images

Figure CN121960673A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of artificial intelligence technology, and in particular to an intelligent office form processing method, system and device based on a large model. Background Technology
[0002] In modern enterprise digital operations, Office Automation (OA) systems and Enterprise Resource Planning (ERP) systems are critical infrastructures that support core business processes. They are deeply integrated into the daily operations of various organizations, handling a large volume of routine administrative, human resources, financial, and business operations through electronic forms. These systems typically standardize and connect workflows using numerous predefined electronic forms (such as employee expense reports, leave applications, procurement approvals, and project reports). Employees usually need to access the system interface, manually locate the target form in a complex menu hierarchy, and fill in all required fields to initiate the process. Current solutions primarily rely on a fixed graphical user interface (GUI) and predefined form templates for interaction. The form processing logic is relatively static, with each submission treated as an independent event. As enterprises grow and processes become more refined, the types and number of forms accumulated within the system increase dramatically. Users need to complete tedious searches and highly repetitive data entry tasks among massive amounts of forms. Simultaneously, traditional architectures struggle to effectively utilize users' historical behavioral data to provide contextual support for the current task and fail to achieve intelligent, personalized interaction centered on natural language, resulting in room for improvement in overall operational efficiency and user experience. Summary of the Invention
[0003] In view of this, the purpose of this invention is to propose an intelligent office form processing method, system and device based on a large model, which aims to solve the problems of cumbersome operation, low level of intelligence, lack of personalization and poor interactive experience in the existing office form processing methods.
[0004] To achieve the above objectives, the present invention provides an intelligent office form processing method based on a large model, the method comprising: Receive natural language instructions input by the user, parse the natural language instructions using a large language model, and obtain the user's intent and key information entities; Based on the user's intent, the corresponding MCP tool is invoked to obtain the structured information of the corresponding form; Based on the user's user identifier and the key information entities, a search is performed in a preset knowledge base to obtain the user's static information and the user's historical behavior information. The user's static information, user's historical behavior information, structured information, and key information entities are used as context inputs into the large language model to generate the fill content for the corresponding fields of the form; The target form containing the entered content is pushed to the user for confirmation, and the confirmed target form is submitted to the backend office system.
[0005] Preferably, the step of invoking the corresponding MCP tool according to the user's intent to obtain the structured information of the corresponding form includes: The form type is determined based on the user's intent, and a tool identifier is generated based on the form type; The corresponding MCP tool is invoked based on the tool identifier, and the structured information returned by the MCP tool for defining form fields and attributes is obtained.
[0006] Preferably, the preset knowledge base includes a relational database and a vector database; the step of retrieving user static information and user historical behavior information from the preset knowledge base based on the user's user identifier and the key information entities includes: Based on the user identifier, a query is performed in the relational database to obtain the user's static information, including user identifier, name, department, and position. The key information entity is converted into a query vector, and the query vector is then mixed with the corresponding historical form records in the vector database to obtain the user's historical behavior information.
[0007] Preferably, the step of converting the key information entity into a query vector, and then performing a mixed retrieval of the query vector with the corresponding historical form records in the vector database to obtain the user's historical behavior information includes: Calculate the cosine similarity between the query vector and the semantic embedding vector of the corresponding historical form record to obtain the vector recall score; Historical form records are matched based on a preset attribute filtering method. The scores of the successfully matched attributes are summed to obtain the attribute filtering score. The attribute filtering method includes form type matching and key entity matching. The BM25 algorithm is used to calculate the keyword matching score by comparing the keywords in the key information entity with the metadata of historical form records. The vector recall score, attribute filtering score, and keyword matching score are weighted and summed to obtain the hybrid retrieval score. Calculate the time decay factor for each historical form record, and calculate the final search score for each historical form record based on the time decay factor and the mixed search score. The historical form records are sorted according to the final retrieval score, and a preset number of historical form records are selected as the user's historical behavior information.
[0008] Preferably, the step of inputting the user's static information, user historical behavior information, structured information, and key information entities as context into the large language model to generate the fill content for the corresponding fields of the form includes: Based on the structured information, the form fields are divided into basic fields, system fields, and descriptive fields, wherein... For basic fields, the corresponding fields are populated using the aforementioned user static information; For system fields, the corresponding fields are formatted and filled based on the current system time or the time entity extracted from the key information entity; For descriptive fields, the corresponding content is obtained by reasoning based on the key information entities and the user's historical behavior information using a large language model.
[0009] Preferably, the method further includes: After the target form is successfully submitted, the preset knowledge base is updated based on the form data corresponding to the target form.
[0010] Preferably, updating the preset knowledge base based on the form data corresponding to the target form includes: The form data, including form type, submission time, and key-value pairs of each field, is stored as a new structured record in the relational database; The free text field content is extracted from the form data, converted into a semantic embedding vector, and stored in the vector database along with the corresponding metadata. The historical form records in the vector database are then managed.
[0011] Preferably, the management of historical form records in the vector database includes: Regularly perform semantic clustering analysis on multiple historical form records of the same user identifier under the same form type. When the number of historical form records in a cluster exceeds a preset threshold, generate a general summary based on the free text field of the historical form records in the corresponding cluster by calling a large language model. The summary is vectorized to generate an aggregated memory item, which is stored in the vector database and associated with the record identifiers of all historical form records within the corresponding cluster.
[0012] To achieve the above objectives, the present invention also provides an intelligent office form processing system based on a large model, the system comprising: The natural language interaction module is used to receive natural language commands input by the user; The intent recognition and task planning module is used to parse the natural language instructions through the embedded large language model to obtain the user intent and key information entities; The MCP toolset module is used to call the corresponding MCP tool according to the user's intent and provide the structured information of the corresponding form; The long-term memory module includes a relational database and a vector database, which is used to retrieve user static information and user historical behavior information based on the user's user identifier and the key information entities. The intelligent content generation and filling module is used to integrate the structured information, key information entities, user static information and user historical behavior information, and call the large language model to generate the filling content of the corresponding fields of the form; The form presentation and confirmation module is used to push the target form with the entered content to the user for confirmation, and submit the confirmed target form to the backend office system.
[0013] To achieve the above objectives, the present invention also proposes an intelligent office form processing device based on a large model, comprising a processor, a memory, and a computer program stored in the memory, wherein the computer program is executed by the processor to implement the steps of an intelligent office form processing method based on a large model as described in the above embodiments.
[0014] To achieve the above objectives, the present invention also proposes a computer-readable storage medium storing a computer program that is executed by a processor to implement the steps of an intelligent office form processing method based on a large model as described in the above embodiments.
[0015] To achieve the above objectives, the present invention also proposes a computer program product, including a computer program / instructions, which, when executed by a processor, implement the steps of an intelligent office form processing method based on a large model as described in the above embodiments.
[0016] Beneficial effects: The above solution fundamentally transforms office form processing by constructing an intelligent workflow that uses natural language commands as input and a large language model as the core processing engine. It shifts the traditional passive "human-finds-forms" model to an intention-driven proactive service model. Users no longer need to concern themselves with the specific location or field structure of the form; they only need to describe their needs in natural language to trigger the subsequent automated processing chain. Based on the intention, the system automatically invokes the corresponding form tool and combines static information and historical behavior data retrieved from a pre-set knowledge base to provide rich context for the large language model. This automatically generates the fill-in content for each field of the form, fills in the information, and submits it, greatly simplifying the user's operation path and improving office efficiency. It also enables personalized form content and context-aware intelligent filling, significantly improving the accuracy of form completion and the user's interactive experience.
[0017] By defining tool identifiers based on form types, the accuracy and reliability of tool calls are ensured, avoiding mis-calls due to intent recognition bias. This allows the system to flexibly and accurately connect to different form resources, laying the foundation for handling diverse office form scenarios. By introducing a Model Context Protocol (MCP) toolset, each specific office form (such as leave applications and expense reports) is encapsulated as an independent, callable tool, decoupling business logic (form structure) from the core intelligent engine (large language model). When new form types need support, only the corresponding MCP tool needs to be developed and registered, without modifying the large language model or the system's core framework code. This greatly improves the system's scalability and maintainability, enabling it to quickly adapt to changes in enterprise business processes and iterative form updates.
[0018] By employing a hybrid knowledge base architecture combining relational and vector databases, and implementing a hybrid retrieval strategy encompassing vector recall, attribute filtering, and keyword matching, the system can simultaneously address the precise retrieval of static user information and the semantic similarity retrieval of unstructured text from historical behavior. Specifically, the hybrid retrieval integrates multi-dimensional matching based on semantics, form type, and key entities, and introduces a time decay mechanism to correct the retrieval result scores, ensuring that the system prioritizes recent and relevant historical user behavior when making recommendations. This retrieval mechanism significantly improves the accuracy and timeliness of locating effective reference information from users' vast historical data, guarantees the semantic relevance of retrieval results, provides high-quality, personalized contextual information for subsequent intelligent filling, and effectively enhances the targeting of recommended content.
[0019] By intelligently categorizing fields into basic, system, and descriptive fields based on the structured information in the form, and employing differentiated filling strategies for each type, the form filling process is optimized and made more intelligent. Basic identity information is filled directly, while system information such as dates is automatically formatted and filled, ensuring efficiency and accuracy. For complex fields such as reasons and descriptions, the reasoning capabilities of a large language model are utilized, combined with user commands and retrieved historical records, to generate the form, ensuring its naturalness and contextual relevance. This categorized filling mechanism balances automation and the quality of generated content, significantly improving the overall accuracy and usability of the filled content, resulting in a final form that is both complete and accurate, and conforms to the specific business context.
[0020] By asynchronously storing the structured data and vectorized representations of the text content in a relational database and a vector database respectively after successful form submission, the system achieves continuous accumulation and self-growth of long-term memory. This allows the system to become increasingly intelligent with use, and the user's usage history continuously enriches its personalized knowledge base. Furthermore, through periodic semantic clustering analysis and summary generation (aggregating memory items), massive historical records on the same topic can be compressed and refined, effectively managing the size of the knowledge base, preventing data bloat, and extracting more representative user behavior patterns. This provides more accurate and concise contextual information for future retrievals, demonstrating the system's long-term sustainability and intelligent management level. Attached Figure Description
[0021] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0022] Figure 1 This is a flowchart illustrating an intelligent office form processing method based on a large model, as provided in an embodiment of the present invention.
[0023] Figure 2 This is a schematic diagram of the structure of an intelligent office form processing system provided in an embodiment of the present invention.
[0024] The realization of the invention's objective, its functional characteristics, and advantages will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0025] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention. Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to represent selected embodiments of the invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0026] The present invention will be described in detail below with reference to the embodiments.
[0027] Reference Figure 1 The diagram shown is a flowchart illustrating an intelligent office form processing method based on a large model, according to an embodiment of the present invention.
[0028] In this embodiment, the method is implemented based on an intelligent office form processing system. (Refer to...) Figure 2 As shown, the system includes a natural language interaction module, an intent recognition and task planning module, an MCP toolset module, a long-term memory module, an intelligent content generation and filling module, and a form presentation and confirmation module; among them, The natural language interaction module is used to receive natural language commands input by the user; The intent recognition and task planning module is used to parse the natural language instructions through the embedded large language model to obtain the user intent and key information entities; The MCP toolset module is used to call the corresponding MCP tool according to the user's intent and provide the structured information of the corresponding form; The long-term memory module includes a relational database and a vector database, which is used to retrieve user static information and user historical behavior information based on the user's user identifier and the key information entities. The intelligent content generation and filling module is used to integrate the structured information, key information entities, user static information and user historical behavior information, and call the large language model to generate the filling content of the corresponding fields of the form; The form presentation and confirmation module is used to push the target form with the entered content to the user for confirmation, and submit the confirmed target form to the backend office system.
[0029] In this embodiment, the system is deployed in an enterprise intranet environment. When a user sends a natural language command through a chat window integrated into the enterprise communication software, such as "I need reimbursement for the taxi fare for visiting client B yesterday afternoon, totaling 58 yuan," and the receipt has been uploaded, the natural language interaction module captures this text information and transmits it to the backend system. Subsequently, the large language model embedded in the intent recognition and task planning module parses the command, identifies the core user intent as "reimbursement," and extracts key information entities, such as time: yesterday afternoon, reason: visiting client B, expense type: taxi fare, and amount: 58 yuan. Based on the identified "reimbursement" intent, this module plans to call the MCP tool corresponding to the "travel expense reimbursement form." Then, the MCP toolset module responds to this call, returning the JSON Schema structured information of the "travel expense reimbursement form," specifying all the fields and formats required for the form. Meanwhile, the long-term memory module, based on the user ID and key entities such as "Customer B" and "taxi fare," queries a relational database (such as PostgreSQL) to retrieve the user's department, employee number, and other static information. It then uses a mixed search in a vector database (such as Milvus or ChromaDB) to match the user's frequently used note templates from past "taxi fare" reimbursements. The intelligent content generation and filling module gathers all this information and again calls the large language model to automatically generate the content for each field: filling in the applicant and department fields with the user's static information, converting "yesterday afternoon" to the system date format, and generating a standard expense description by combining the reason and historical templates. Finally, the form presentation and confirmation module renders the intelligently filled expense form as a clear card message and returns it to the user. After the user reviews it and confirms, the module submits the form data to the backend financial OA system, completing the entire process.
[0030] Specifically, the method includes: S11: Receive natural language instructions input by the user, parse the natural language instructions using a large language model, and obtain the user's intent and key information entities.
[0031] In this embodiment, the user inputs a natural language text command through the chatbot interface integrated into the enterprise instant messaging tool: "I need to visit Client A from 2 PM to 5 PM today, mainly for project coordination, and I need an outing application form." The front-end interaction layer captures this text command and encapsulates it as a request, sending it to the large language model processing layer in the system backend. Upon receiving the command, the large language model, built into the intent recognition and task planning module, first performs deep semantic understanding and contextual analysis. The large language model (LLM) can use open-source pre-trained models (such as the Qwen series and DeepSeek series) fine-tuned on internal enterprise data, or it can be an API call to a commercial closed-source model (such as GPT5). The large language model accurately identifies the core requirement of the command: initiating an "outing application" process. Simultaneously, it precisely extracts several key information fragments from the statement: the time entities "2 PM today" and "5 PM" correspond to the start and end times of the outing, respectively; the object entity "Client A" clarifies the visit recipient; and the reason entity "project coordination" describes the purpose of the outing. Furthermore, the model implicitly understands that the intent to "apply for travel" is inherently linked to subsequent fields such as "applicant," "department," and "destination." The large language model structures the recognition and extraction results, outputting a clear JSON object, for example: {"intent": "application for travel", "start_time": "today 14:00","end_time": "today 17:00", "partner": "Client A", "reason": "project coordination"}. This completes the transformation from unstructured natural language to a machine-understandable structured task description, providing a clear execution basis for subsequent steps.
[0032] User intent refers to the type of core office business operation that a user wants to complete through natural language commands. Intent is usually directly bound to specific office form types, such as: "leave" (corresponding to leave application form), "reimbursement" (corresponding to expense reimbursement form), "outing" (corresponding to outing application form), "purchasing" (corresponding to purchase application form), "submit weekly report" (corresponding to project weekly report), etc. The system determines the MCP tools to be called and the approval process to be processed in the backend by accurately identifying intent. Key information entities refer to structured data items extracted from user natural language commands and used to populate specific fields in a form. These entities are the basic elements constituting the form content and typically include, but are not limited to: time entities (e.g., 2 PM to 5 PM today), used to populate fields such as start time, end time, and application date; location / object entities (e.g., "Client A" or "XX Project Site"), used to populate fields such as destination, visited object, and project name; reason / description entities (e.g., "Project Matching" or "Attending a Technology Summit"), which are the main source of content for descriptive fields (e.g., reason details or expense description); numerical entities (e.g., "Amount 500 yuan" or "3 days"), used to populate fields such as expense amount and number of days of leave; and related entities (e.g., "Project A" extracted from "Purchasing for Project A"), which can be used to populate the "Related Projects" field in the form.
[0033] S12, based on the user's intent, call the corresponding MCP tool to obtain the structured information of the corresponding form.
[0034] Furthermore, in step S12, the step of invoking the corresponding MCP tool according to the user's intent to obtain the structured information of the corresponding form includes: S12-1, Determine the form type based on the user intent, and generate a tool identifier based on the form type; S12-2, Invoke the corresponding MCP tool according to the tool identifier, and obtain the structured information returned by the MCP tool for defining form fields and attributes.
[0035] In this embodiment, based on the results obtained from the above analysis, the module plans the following task: It needs to call a dedicated tool for handling outbound business to obtain the form. First, based on this intent, the target form type is determined to be an "Outbound Application Form," and a unique corresponding tool identifier (e.g., outbound_application_tool) is generated accordingly. Then, based on this identifier, a precise call request is initiated to the MCP toolset module. The called "Outbound Application Form" MCP tool responds to the request, returning a structured information conforming to the JSON Schema specification. This structured information clearly defines all the fields that the "Outbound Application Form" must contain, such as: applicant, department, date, reason_details, destination, schedule, etc., and their attributes. This form structure definition provides an accurate field mapping target and content generation framework for subsequent intelligent filling.
[0036] S13, based on the user's user identifier and the key information entity, a search is performed in the preset knowledge base to obtain the user's static information and the user's historical behavior information.
[0037] Furthermore, in step S13, the preset knowledge base includes a relational database and a vector database; the step of retrieving user static information and user historical behavior information from the preset knowledge base based on the user's user identifier and the key information entities includes: S13-1, Based on the user identifier, query the relational database to obtain the user's static information, including user identifier, name, department, and position; S13-2, the key information entity is converted into a query vector, and the query vector is mixed with the corresponding historical form records in the vector database to obtain the user's historical behavior information.
[0038] Furthermore, in step S13-2, the key information entity is converted into a query vector, and the query vector is mixed with the corresponding historical form records in the vector database to obtain the user's historical behavior information, including: S13-2-1, Calculate the cosine similarity between the query vector and the semantic embedding vector of the corresponding historical form record to obtain the vector recall score; S13-2-2, Based on a preset attribute filtering method, historical form records are matched, and the scores of successfully matched attributes are summed to obtain an attribute filtering score. The attribute filtering method includes form type matching and key entity matching. S13-2-3, BM25 is used to calculate the keyword matching score by comparing the keywords in the key information entity with the metadata of the historical form records; S13-2-4, The vector recall score, attribute filtering score and keyword matching score are weighted and summed to obtain the hybrid retrieval score; S13-2-5, Calculate the time decay factor for each historical form record, and calculate the final search score for each historical form record based on the time decay factor and the mixed search score. S13-2-6, Sort the historical form records according to the final search score, and select a preset number of historical form records as the user's historical behavior information.
[0039] In this embodiment, based on the current user's unique identifier (user ID), a precise query is performed in the "User Static Information Table" of the relational database to instantly retrieve the user's name (e.g., "Zhang San"), department (e.g., "Marketing Department"), position, and other essentially unchanged static user information. This information will be used to directly populate the basic fields in the form. Simultaneously, the extracted key information entities (e.g., "Client A," "Project Coordination") are converted into high-dimensional query vectors using a pre-trained text embedding model. Subsequently, in the vector database, a multi-dimensional hybrid retrieval is performed based on this query vector, including: (1) Calculate the vector recall score: Calculate the cosine similarity between the query vector and the historical data vectors in the database as the vector recall score S. vector S vector = cos(V query V history ) = (V query ·V history ) / (|V query |×|V history |); (2) Calculate the attribute filtering score: Boolean matching is performed based on preset rules, and a fixed score is accumulated for each successful match. The specific preset rules are as follows: if the form type in the history records exactly matches the current task requirement ("Outbound Application Form"), the score is +C1; if the content of commonly used key fields in the history records (such as "Destination") exactly matches the key entity extracted in the instruction (such as "Customer A"), the score is +C2; where C1 and C2 are preset fixed bonus values; the scores of all successfully matched structured attributes are summed to obtain the attribute filtering score S. attr ; (3) Calculate the keyword matching score: The BM25 algorithm is used to calculate the degree of matching between the keywords in the instruction and the historical metadata, and the keyword matching score S is obtained. key ; (4) Calculate the mixed search score: The above three scores are weighted and summed according to the preset weight coefficients. The calculation formula is S Hybrid = ω vector ×S vector + ω attr ×S attr + ω key ×S key In the formula, the weighting coefficient ω vector ω attr ω key Satisfy ω vector +ω attr +ω key = 1.
[0040] (5) Furthermore, by applying time decay and calculating the final retrieval score: calculate the time decay factor for each relevant historical record, the formula of which is as follows: Where λ is a configurable decay rate parameter greater than zero (controlling the decay speed; the larger λ is, the faster the memory decays, and the more the system tends to recommend recent behavioral habits), t days The number of days between the time the historical record was generated and the current time is calculated; then, the composite retrieval score for each record is multiplied by a decay factor to obtain the final retrieval score: S. final = S Hybrid × Decay. This mechanism ensures that recent and relevant records receive higher weight. According to S... final All candidate historical records are sorted in descending order, and the top one or more records are selected as the user's historical behavior information retrieved in this search. For example, a record might be retrieved showing that the user visited customer A several months ago, which includes the customer's specific address.
[0041] S14, the user static information, user historical behavior information, structured information, and key information entities are input into the large language model as context to generate the fill content of the corresponding fields of the form.
[0042] Furthermore, in step S14, the step of inputting the user static information, user historical behavior information, structured information, and key information entities as context into the large language model to generate the fill content for the corresponding fields of the form includes: Based on the structured information, the form fields are divided into basic fields, system fields, and descriptive fields, wherein... For basic fields, the corresponding fields are populated using the aforementioned user static information; For system fields, the corresponding fields are formatted and filled based on the current system time or the time entity extracted from the key information entity; For descriptive fields, the corresponding content is obtained by reasoning based on the key information entities and the user's historical behavior information using a large language model.
[0043] S15, the target form with the input content is pushed to the user for confirmation, and the confirmed target form is submitted to the backend office system.
[0044] In this embodiment, all the aforementioned information is aggregated into the intelligent content generation and filling module. The input received by this module includes: structured information (i.e., field definitions) from the "Outing Application Form" returned by the MCP tool; key information entities (such as time, customer, and reason) parsed from natural language instructions; user static information (name, department) retrieved from a relational database; and user historical behavior information (such as address records of past visits to customer A) obtained through hybrid retrieval from a vector database. Based on the structured information of the form, the fields to be filled are intelligently divided into three categories and filled accordingly: Basic field population: For basic fields such as "Applicant" and "Department", the static user information "Zhang San" and "Marketing Department" obtained from the relational database are directly used for population; System field population: For the "Application Date" field, it is automatically formatted and populated based on the current system date to generate a standard date format; Descriptive field reasoning generation: For complex descriptive fields such as "reason for travel", "destination", and "itinerary", the system calls the large language model, taking the key information entities ("Client A", "project coordination") and the retrieved historical behavior information (Client A's historical address) as context input. The large language model performs reasoning and content generation. For example, "reason for travel" is filled in to be more complete as "to have a project coordination meeting with Client A"; "destination" is filled in as "Client A's company (No. XX, XX Road, XX District, XX City)" based on the historical address; and "itinerary" is intelligently generated as "depart from the company at 2 pm to Company A, and return to the company at 5 pm".
[0045] All fields in the form have been intelligently filled in. The form presentation and confirmation module renders the completed form data into a clearly structured, field-defined card message, which is then pushed to the user's chat interface. The card clearly displays all the filled content and provides two interactive buttons: "Confirm Submission" and "Modify." After the user reviews the data and finds it correct, they click "Confirm Submission." The system backend then converts the data in the card into a format that conforms to the enterprise OA system API requirements and submits it to the OA system to initiate the approval process. If the user needs to make adjustments, they can click the "Modify" button or directly enter supplementary instructions such as "Change the destination to Customer A's factory." The system will repeat the relevant steps to update the form and refresh the card based on the new instructions until the user finally confirms and submits.
[0046] Furthermore, in another embodiment, the method further includes: S16, After the target form is successfully submitted, the preset knowledge base is updated according to the form data corresponding to the target form.
[0047] Furthermore, in step S16, updating the preset knowledge base based on the form data corresponding to the target form includes: S16-1, Store the form data, including form type, submission time, and key-value pairs of each field, as a new structured record in the relational database; S16-2, Extract the content of free text fields from the form data, convert the content of free text fields into semantic embedding vectors, and store them together with the corresponding metadata in the vector database, and manage the historical form records in the vector database.
[0048] Furthermore, in step S16-2, the management of historical form records in the vector database includes: S16-2-1, Periodically perform semantic clustering analysis on multiple historical form records of the same user identifier under the same form type. When the number of historical form records in a cluster exceeds a preset threshold, a general summary is generated based on the free text field of the historical form records in the corresponding cluster by calling the large language model. S16-2-2, the general summary is vectorized to generate an aggregated memory item, which is stored in the vector database and associated with the record identifiers of all historical form records within the corresponding cluster.
[0049] In this embodiment, after the user confirms and successfully submits the form to the OA system, the system triggers an asynchronous task to update the long-term memory module. The submitted form data, including form type, submission time, user ID, and key-value pairs of each field, is stored as a new structured record in the "Structured Form History Table" of the relational database. Simultaneously, the free text fields in the form (such as "reason for travel") are extracted, converted into semantic embedding vectors using a text embedding model, and stored along with relevant metadata in a vector database for future semantic retrieval.
[0050] In addition, the system periodically performs memory optimization management. For example, the backend service periodically performs semantic clustering analysis on similar historical form records of the same user. When the number of records in a cluster exceeds a preset threshold (e.g., 10 records), a general summary is generated based on the free text of these records by calling a large language model. This summary is then vectorized and stored as an "aggregate memory item" in the vector database, while being associated with the record IDs of all original historical records. The original detailed record vectors can be marked or cleaned up, thereby optimizing storage efficiency and retrieval performance while preserving core semantic information.
[0051] This invention also provides an intelligent office form processing device, which includes the intelligent office form processing system based on a large model as described above. The intelligent office form processing system can employ... Figure 2 The structure of the embodiment, correspondingly, can be executed Figure 1 The technical solutions of the method embodiments shown are similar in implementation principle and technical effect. For details, please refer to the relevant records in the above embodiments, which will not be repeated here.
[0052] The device includes: a mobile phone, digital camera, or tablet computer, or other device with a camera function; or a device with an image processing function; or a device with an image display function. The device may include components such as a memory, processor, input unit, display unit, and power supply.
[0053] The memory can be used to store software programs and modules. The processor executes various functional applications and data processing by running the software programs and modules stored in the memory. The memory can mainly include a program storage area and a data storage area. The program storage area can store the operating system, application programs required for at least one function (such as image playback function), etc.; the data storage area can store data created according to the use of the device. In addition, the memory can include high-speed random access memory, and can also include non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device. Accordingly, the memory can also include a memory controller to provide access to the memory for the processor and input units.
[0054] The input unit can be used to receive input numerical, character, or image information, and to generate keyboard, mouse, joystick, optical, or trackball signal inputs related to user settings and function control. Specifically, in addition to a camera, the input unit of this embodiment may also include a touch-sensitive surface (e.g., a touch screen) and other input devices.
[0055] The display unit can be used to display information input by the user or information provided to the user, as well as various graphical user interfaces of the device. These graphical user interfaces can be composed of graphics, text, icons, video, and any combination thereof. The display unit may include a display panel, optionally configured as an LCD (Liquid Crystal Display), OLED (Organic Light-Emitting Diode), or other similar display panel. Furthermore, a touch-sensitive surface may cover the display panel. When the touch-sensitive surface detects a touch operation on or near it, it transmits the information to the processor to determine the type of touch event. Subsequently, the processor provides corresponding visual output on the display panel based on the type of touch event.
[0056] This invention also provides a computer-readable storage medium, which may be a computer-readable storage medium included in the memory described in the above embodiments; or it may be a standalone computer-readable storage medium not assembled into a device. The computer-readable storage medium stores at least one instruction, which is loaded and executed by a processor to implement... Figure 1 The method shown is an intelligent office form processing method based on a large model. The computer-readable storage medium can be a read-only memory, a disk, or an optical disk, etc.
[0057] This invention also provides a computer program product, including a computer program / instructions, which are loaded and executed by a processor to achieve [the desired result]. Figure 1 This illustrates an intelligent office form processing method based on a large model.
[0058] It should be noted that the various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For system embodiments, device embodiments, and storage medium embodiments, since they are basically similar to the method embodiments, the descriptions are relatively simple, and relevant parts can be referred to the descriptions in the method embodiments.
[0059] Furthermore, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0060] The foregoing description illustrates and describes preferred embodiments of the present invention. It should be understood that the present invention is not limited to the forms disclosed herein and should not be construed as excluding other embodiments. It can be used in various other combinations, modifications, and environments, and can be altered within the scope of the inventive concept by means of the foregoing teachings or techniques or knowledge in related fields. Any modifications and variations made by those skilled in the art that do not depart from the spirit and scope of the present invention should be within the protection scope of the appended claims.
Claims
1. A method for intelligent office form processing based on a large model, characterized in that, The method includes: Receive natural language instructions input by the user, parse the natural language instructions using a large language model, and obtain the user's intent and key information entities; Based on the user's intent, the corresponding MCP tool is invoked to obtain the structured information of the corresponding form; Based on the user's user identifier and the key information entities, a search is performed in a preset knowledge base to obtain the user's static information and the user's historical behavior information. The user's static information, user's historical behavior information, structured information, and key information entities are used as context inputs into the large language model to generate the fill content for the corresponding fields of the form; The target form containing the entered content is pushed to the user for confirmation, and the confirmed target form is submitted to the backend office system.
2. The intelligent office form processing method based on a large model according to claim 1, characterized in that, The step of invoking the corresponding MCP tool based on the user's intent to obtain the structured information of the corresponding form includes: The form type is determined based on the user's intent, and a tool identifier is generated based on the form type; The corresponding MCP tool is invoked based on the tool identifier, and the structured information returned by the MCP tool for defining form fields and attributes is obtained.
3. The intelligent office form processing method based on a large model according to claim 1, characterized in that, The preset knowledge base includes a relational database and a vector database; the step of retrieving user static information and user historical behavior information from the preset knowledge base based on the user's user identifier and the key information entities includes: Based on the user identifier, a query is performed in the relational database to obtain the user's static information, including user identifier, name, department, and position. The key information entity is converted into a query vector, and the query vector is then mixed with the corresponding historical form records in the vector database to obtain the user's historical behavior information.
4. The intelligent office form processing method based on a large model according to claim 3, characterized in that, The process of converting the key information entity into a query vector, and then performing a mixed retrieval of the query vector with the corresponding historical form records in the vector database to obtain the user's historical behavior information includes: Calculate the cosine similarity between the query vector and the semantic embedding vector of the corresponding historical form record to obtain the vector recall score; Historical form records are matched based on a preset attribute filtering method. The scores of the successfully matched attributes are summed to obtain the attribute filtering score. The attribute filtering method includes form type matching and key entity matching. The BM25 algorithm is used to calculate the keyword matching score by comparing the keywords in the key information entity with the metadata of historical form records. The vector recall score, attribute filtering score, and keyword matching score are weighted and summed to obtain the hybrid retrieval score. Calculate the time decay factor for each historical form record, and calculate the final search score for each historical form record based on the time decay factor and the mixed search score. The historical form records are sorted according to the final retrieval score, and a preset number of historical form records are selected as the user's historical behavior information.
5. The intelligent office form processing method based on a large model according to claim 1, characterized in that, The step of inputting the user's static information, historical behavior information, structured information, and key information entities as context into the large language model to generate the fill content for the corresponding fields of the form includes: Based on the structured information, the form fields are divided into basic fields, system fields, and descriptive fields, wherein... For basic fields, the corresponding fields are populated using the aforementioned user static information; For system fields, the corresponding fields are formatted and filled based on the current system time or the time entity extracted from the key information entity; For descriptive fields, the corresponding content is obtained by reasoning based on the key information entities and the user's historical behavior information using a large language model.
6. The intelligent office form processing method based on a large model according to claim 1, characterized in that, The method further includes: After the target form is successfully submitted, the preset knowledge base is updated based on the form data corresponding to the target form.
7. The intelligent office form processing method based on a large model according to claim 6, characterized in that, The step of updating the preset knowledge base based on the form data corresponding to the target form includes: The form data, including form type, submission time, and key-value pairs of each field, is stored as a new structured record in the relational database; The free text field content is extracted from the form data, converted into a semantic embedding vector, and stored in the vector database along with the corresponding metadata. The historical form records in the vector database are then managed.
8. The intelligent office form processing method based on a large model according to claim 7, characterized in that, The management of historical form records in the vector database includes: Regularly perform semantic clustering analysis on multiple historical form records of the same user identifier under the same form type. When the number of historical form records in a cluster exceeds a preset threshold, generate a general summary based on the free text field of the historical form records in the corresponding cluster by calling a large language model. The summary is vectorized to generate an aggregated memory item, which is stored in the vector database and associated with the record identifiers of all historical form records within the corresponding cluster.
9. An intelligent office form processing system, characterized in that, The system includes: The natural language interaction module is used to receive natural language commands input by the user; The intent recognition and task planning module is used to parse the natural language instructions through the embedded large language model to obtain the user intent and key information entities; The MCP toolset module is used to call the corresponding MCP tool according to the user's intent and provide the structured information of the corresponding form; The long-term memory module includes a relational database and a vector database, which is used to retrieve user static information and user historical behavior information based on the user's user identifier and the key information entities. The intelligent content generation and filling module is used to integrate the structured information, key information entities, user static information and user historical behavior information, and call the large language model to generate the filling content of the corresponding fields of the form; The form presentation and confirmation module is used to push the target form with the entered content to the user for confirmation, and submit the confirmed target form to the backend office system.
10. An intelligent office form processing device based on a large model, characterized in that, The method includes a processor, a memory, and a computer program stored in the memory, the computer program being executed by the processor to implement the steps of a large-model-based intelligent office form processing method as described in any one of claims 1 to 8.