A multi-stage intelligent negotiation method and system based on a large language model

CN122986992APending Publication Date: 2026-10-27BEIJING RUI KELUN INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611090219.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-22
Publication Date
2026-10-27

AI Technical Summary

Technical Problem

对此,现有技术缺乏稳定可靠的解决方案

Benefits of technology

通过指令校验层对结构化驱动指令执行双重校验,确保意图标识的合法性和状态转移的匹配性。该校验机制能够识别并拦截不符合预设逻辑的指令,在校验不通过时生成纠偏指令并注入意图解析模块的对话上下文,驱动其重新生成合规指令。此过程保持了当前状态指针不变,提升协商过程中状态流转的确定性与指令处理的准确性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122986992A_ABST
    Figure CN122986992A_ABST
Patent Text Reader

Abstract

The application discloses a kind of multi-stage intelligent negotiation method and system based on large language model, and the application relates to human-computer interaction technical field. Including message interface module, intention analysis module, multi-processing state machine, confirmation module. The application is double-verified to driving instruction by instruction verification layer, generates rectification instruction when failing and constraint decoding forced compliance, keeps state pointer unchanged, continuously fails to reach upper limit manual intervention, improves accuracy and robustness. Parameter isolation execution area encrypts storage boundary constraint factor, only safe interface returns Boolean result, internal monotonic convergence algorithm is used to generate adjustment factor, so that adjustment sequence is monotonically approximated to boundary and does not leak numerical value, to ensure safety. First sub-state machine processes resource parameter negotiation, and second sub-state machine calculates stage quantity in segments and generates execution plan. Two-stage confirmation passes through preparation and submission atomic process, confirms complete issue voucher, timeout rollback state, to ensure transaction consistency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of human-computer interaction technology, specifically to a multi-stage intelligent negotiation method and system based on a large language model. Background Technology

[0002] In resource negotiation scenarios based on human-computer dialogue, large language models (LLMs) are often used as interaction agents to parse user natural language input and generate negotiation solutions.

[0003] However, in real-world scenarios of automated business negotiation or resource scheduling, existing negotiation schemes based on large language models generally suffer from several technical problems.

[0004] First, the generative nature of large language models inherently leads to uncontrollable outputs. In complex multi-stage negotiation processes, the model may generate intent commands that deviate from the preset state transition path, causing chaotic state machine transitions and preventing the negotiation process from proceeding according to the established strategy, or even leading to an infinite loop or illegal state. Existing engineering practices lack efficient and accurate mechanisms for verifying and correcting the intent identifiers output by the model, making it difficult to guarantee the reliability and determinism of negotiation state transitions.

[0005] Secondly, negotiation systems typically need to adhere to the service provider's pre-defined business bottom-line constraints, such as minimum acceptable resource allocation thresholds or price boundaries. Existing solutions usually store these bottom-line constraint parameters in plaintext at the application layer, placing them in the same trust domain as the large language model. This architecture poses a serious security risk. Attackers can indirectly obtain these parameters using methods such as prompt injection, model illusion manipulation, or context leakage, ultimately leading to a reversal of negotiating power and damage to the service provider's interests.

[0006] Ensuring the model can access necessary negotiation information while simultaneously achieving strict security isolation and preventing leakage of core bottom-line parameters is a pressing technical challenge. Currently, existing technologies lack stable and reliable solutions to this problem. Summary of the Invention

[0007] To address the shortcomings of existing technologies, this invention provides a multi-stage intelligent negotiation method and system based on a large language model, which solves the problems mentioned in the background.

[0008] To solve the above-mentioned technical problems, the technical solution of the present invention is as follows: Firstly, a multi-stage intelligent negotiation system based on a large language model includes: The message interface module is used to receive session messages sent by the user client; The intent parsing module is used to generate structured driving instructions based on session messages. The structured driving instructions include intent identifiers and processing path selection parameters. A multi-processing state machine that communicates with the intent parsing module; The multiprocessing state machine includes a first sub-state machine and a second sub-state machine, and is configured with an instruction verification layer and an event generator; The instruction verification layer is used to obtain structured driver instructions and perform double verification on them. Verify whether the intent identifier belongs to the preset set of valid intent identifier enumeration values, and whether the transition relationship between the target sub-state machine indicated by the intent identifier and the current sub-state machine pointed to by the current state pointer of the multiprocessor state machine matches the valid state transition mapping table. If the double verification fails, the instruction verification layer generates a structured correction instruction and injects the correction instruction as a context constraint message into the current dialogue context of the intent parsing module to drive the regeneration of the structured driving instruction while keeping the current state pointer unchanged. If the structured driver instruction regenerated by the intent parsing module based on the correction instruction passes the double verification, the instruction verification layer will switch the current state pointer to the first sub-state machine or the second sub-state machine according to the intent identifier in the newly generated instruction.

[0009] The first sub-state machine is used to insert the processing level into the processing level sequence when entering the first sub-state, using a preset starting adjustment factor as the adjustment factor associated with the first processing level, and providing the processing level sequence to the user terminal. Among them, the adjustment factor is a numerical parameter related to system resource allocation, including bandwidth quota, computing resource amount, storage capacity or parallel execution limit. The initial adjustment factor is determined based on the user's historical resource usage records or the request parameter field in the structured driver instruction. The system also includes a parameter isolation execution area, which is used to store the lowest acceptable adjustment factor as a boundary constraint factor in encrypted form in a parameter isolation execution area that is pre-configured independently of the intent parsing module. The parameter isolation execution area exposes parameter adjustment call interface and security status query interface. The parameter isolation execution area is configured to reject the intent parsing module's direct read request for the boundary constraint factor. The safety status query interface is used to receive the adjustment factor to be compared as input, decrypt the boundary constraint factor in the parameter isolation execution area, compare the adjustment factor to be compared with the boundary constraint factor numerically, and return a Boolean result indicating whether the boundary constraint factor has been reached or exceeded. The instruction verification layer is also used to generate a trigger event and send the trigger event to the first sub-state machine when the verification passes and the intent identifier is recognized as indicating that the user rejects the current processing level. When the first sub-state machine receives a trigger event, it passes the adjustment factor associated with the current processing level to the parameter isolation execution area through the parameter adjustment call interface, and calls the strategy adjustment logic in the parameter isolation execution area. The strategy adjustment logic decrypts the boundary constraint factor within the parameter isolation execution area, and generates a new adjustment factor based on the input adjustment factor and the decrypted boundary constraint factor through a monotonically convergent algorithm. This makes the adjustment factor sequence, consisting of the initial adjustment factor and the subsequently generated new adjustment factors in the order of generation, monotonically approximate the boundary constraint factor in numerical terms. The new adjustment factor is returned to the first sub-state machine via the parameter adjustment call interface; the first sub-state machine uses the new adjustment factor as the adjustment factor associated with the new processing level, inserts the new processing level into the processing level sequence, and continues to provide it to the user. The first sub-state machine is also used to stop generating new processing levels and trigger the upgrade process to manual processing nodes when the preset level termination conditions are met. The upgrade process includes encapsulating the current processing level sequence, the current adjustment factor, and the boundary touch state returned by the security status query interface based on the current adjustment factor into a context snapshot, and passing it to the manual processing node; The second sub-state machine stores the standard execution mode parameter set and the segmented execution mode parameter set, which are used to select parameters according to the processing path in the structured driving instructions, select the corresponding parameter set, combine the request parameters of the external execution computing interface, and obtain the execution plan. The event generator is used to generate a processing completion event when the first sub-state machine or the second sub-state machine receives a structured driving instruction indicating that the user terminal accepts the current scheme, and then passes the processing completion event to the confirmation module. The confirmation module is used to execute an atomic confirmation process after receiving a processing completion event; The atomic confirmation process includes: sending a preliminary confirmation request to the user terminal and waiting for a first confirmation signal; after receiving the first confirmation signal, sending a submission confirmation request to the user terminal and waiting for a second confirmation signal; triggering the issuance of electronic credentials when the first and second confirmation signals are received successively within a preset time window; if the first and second confirmation signals are not received by the end of the preset time window, triggering a timeout compensation action, which includes sending a rollback instruction to the multiprocessing state machine to roll back the negotiation state to the state before the processing completion event was received.

[0010] As a further aspect of the present invention, the parameter isolation execution area is implemented by a hardware-based trusted execution environment, and the runtime memory space of the intent parsing module is physically isolated from the memory space of the parameter isolation execution area. The security status query interface enters the trusted execution environment via security monitoring calls, and the comparison and return of Boolean results are both completed within the trusted execution environment.

[0011] As a further embodiment of the present invention, the monotonically convergent algorithm is one of the following: Bisector compromise Or the proportional decrease method ,in, k is a preset attenuation coefficient and 0 < k < 1.

[0012] As a further aspect of the present invention, the segmented execution mode parameter set includes an initial processing volume ratio parameter r, a transition period segment number n, and a transition period processing volume adjustment coefficient. And the number of normal segments m; when the second sub-state machine receives the structured driving instruction indicating the segmented execution mode, it processes the total processing volume A carried in the structured driving instruction, through... Calculate the initial processing volume; through Calculate the remaining processing capacity; through Calculate the reference unit quantity; through Calculate the unit quantity of the transition section; through Calculate the normal segment unit quantity, and use this to construct the request body for calling the external execution calculation interface. , The combination of , n, and m constitutes the request parameters.

[0013] As a further aspect of the present invention, the correction instruction includes an error type code for verification failure and a list of valid intent identifier enumeration values. The intent parsing module uses constraint decoding technology to restrict the output intent identifier to a list of valid intent identifier enumeration values, so that the regenerated structured driver instructions pass double verification.

[0014] As a further aspect of the present invention, the hierarchical termination condition includes at least one of the following: The difference between the newly adjusted factor and the boundary constraint factor is less than the preset difference threshold; and / or the number of generated processing layers reaches the preset maximum number of iterations; and / or the instruction verification layer detects that the number of times the intent parsing module continuously regenerates structured driving instructions reaches the preset retry limit.

[0015] Secondly, a multi-stage intelligent negotiation method based on a large language model is provided. This method is implemented through a multi-stage intelligent negotiation system based on a large language model and includes the following steps: S1. The message interface module receives session messages; S2, The intent parsing module generates structured driver instructions; S3, the instruction verification layer performs dual verification on structured driver instructions; S4. The first sub-state machine generates the first processing level with the initial adjustment factor; when the instruction verification layer recognizes the rejection intention, it generates a trigger event; after receiving the trigger event, the first sub-state machine calls the monotonic convergence algorithm through the security interface to generate a new adjustment factor and insert it into the processing level; in response to the achievement of the processing level sequence, the second sub-state machine selects the standard execution mode parameter set or the segmented execution mode parameter set according to the processing path selection parameters. In the segmented execution mode, the initial processing volume ratio parameter, the number of transition periods, the transition period processing volume adjustment coefficient and the number of normal periods in the segmented execution mode parameter set are used to calculate the request parameters, and the external interface is called to obtain the execution plan; S5: When the first sub-state machine or the second sub-state machine receives confirmation from the instruction verification layer that the user has accepted the current scheme, the event generator creates a processing completion event and notifies the confirmation module. S6: The confirmation module executes the atomic confirmation process.

[0016] Thirdly, a computing device, comprising: One or more processors; A storage device for storing one or more programs, which, when executed by one or more processors, enable the one or more processors to implement a multi-stage intelligent negotiation method based on a large language model.

[0017] Fourthly, a computer-readable storage medium storing a program that, when executed by a processor, implements a multi-stage intelligent negotiation method based on a large language model.

[0018] This invention provides a multi-stage intelligent negotiation method and system based on a large language model. Compared with existing technologies, it has the following advantages: A dual verification layer performs checks on structured driver commands to ensure the legitimacy of intent identifiers and the matching of state transitions. This verification mechanism can identify and block commands that do not conform to preset logic. When verification fails, a corrective command is generated and injected into the dialog context of the intent parsing module, driving it to regenerate a compliant command. This process keeps the current state pointer unchanged, improving the determinism of state transitions and the accuracy of command processing during negotiation.

[0019] By establishing a parameter isolation execution zone and storing boundary constraint factors in encrypted form, the system isolates the intent parsing module from direct access to sensitive values. The security status query interface only decrypts and compares values ​​within the isolation zone before returning a Boolean result, preventing the boundary constraint factors themselves from being leaked. When the user rejects the current solution, the policy adjustment logic generates a new adjustment factor within this security zone using a monotonically convergent algorithm, ensuring that the adjustment sequence is reliable and monotonically approaches the bottom line, thus enhancing the security of core parameters during the negotiation process.

[0020] The multi-processing state machine distinguishes between a first sub-state machine and a second sub-state machine, which are used to handle parameter negotiation and execution plan planning, respectively. Upon receiving a rejection intent, the first sub-state machine uses a security interface to call an algorithm to generate a processing layer with associated new adjustment factors, achieving multi-round negotiation. This divide-and-conquer state machine design decouples the negotiation logic from the execution planning logic, with the instruction verification layer uniformly managing state transitions, enabling the system to flow orderly between different processing modes based on user intent.

[0021] The second sub-state machine introduces a segmented execution mode parameter set, which can automatically calculate the number of processing units in each stage based on the total processing volume and preset parameters. This method generates request parameters for the processing tasks according to a stage sequence based on parameters such as the initial processing volume ratio, the number of transition periods, and adjustment coefficients. These parameters are then used to call external computing interfaces and obtain execution plans. This provides structured scheme planning support for the refined and personalized execution of processing tasks, transforming abstract negotiation results into operable batch execution sequences.

[0022] After processing is completed, the confirmation module executes an atomic confirmation process that includes a pre-confirmation request and a submission confirmation request. This process requires that both confirmation signals be received within a preset time window before the electronic certificate is issued; otherwise, a rollback command is sent to revert the negotiation state to the state before completion. If both confirmation signals are not received by the end of the preset time window, the confirmation module sends a rollback command to the multi-processing state machine, reverting the negotiation state from the pending submission state to the state before processing was completed, thereby ensuring the consistency of the system state in the event of a timeout. Attached Figure Description

[0023] Figure 1 This is a system block diagram of the system of the present invention.

[0024] Figure 2 This is a flowchart illustrating the method of the present invention.

[0025] Figure 3 This is a flowchart illustrating the dual verification process of structured driver instructions in this invention. Detailed Implementation

[0026] 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 some embodiments of the present invention, and not all embodiments. 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.

[0027] Please see Figures 1 to 3 As shown, the embodiments of the present invention provide the following technical solutions: As an embodiment of the present invention: This invention relates to a multi-stage intelligent negotiation method and system based on a large language model, comprising the following steps: The message interface module is used to receive session messages sent by the user client.

[0028] The conversation messages include text, speech-to-text transcription, etc., which are converted into conversation messages in a unified format by the message interface module.

[0029] The intent parsing module is used to generate structured driver instructions based on session messages; A structured instruction is a data structure with predefined fields and formats used to drive downstream functional modules to perform specific operations. This instruction can at least include an operation type field, a target module identifier field, and a parameter payload field. Its format can be structured, such as JSON or XML, to ensure unambiguous parsing and execution between different modules.

[0030] The intent parsing module loads a pre-trained large language model and uses function call or constraint decoding techniques to extract structured intent identifiers and processing path selection parameters from the conversation messages.

[0031] Constraint decoding technology refers to the process of text generation in a large language model where the output range is restricted to a predefined set of tags that conform to the syntax of structured instruction-driven instructions. This forces the model to generate instructions in a legal format, such as only outputting specific key names or specific enumeration values, thus avoiding syntax errors or illegal instructions. In this embodiment, the constraint decoding technology is implemented as follows: at the vocabulary output layer of the large language model, a preset mask matrix is ​​applied to set the output probability of illegitimate intent identifiers to negative infinity, thereby forcing the model to select outputs only from the list of legal intent identifier enumeration values ​​to ensure the structural legality of the generated instructions.

[0032] The intent identifier is an enumerated value that the intent parsing module can output, such as "ADJUST" (request parameter adjustment) or "EXECUTE" (request execution plan).

[0033] The processing path selection parameter further specifies the sub-paths within the same intent category.

[0034] A multiprocessing state machine internally stores a current state pointer, state transition rules, and includes a first sub-state machine, a second sub-state machine, an instruction verification layer, and an event generator. The state transition rules define the legal transition relationships between the sub-state machines.

[0035] The instruction verification layer is used to obtain structured driver instructions and perform double verification on each structured driver instruction. The first layer of verification: determining whether the intent identifier belongs to the preset set of valid intent identifier enumeration values; in this embodiment, the set of valid intent identifier enumeration values ​​can be pre-configured, such as including: {query intent, set intent, interrupt intent, confirm intent, deny intent}, etc., which can be configured according to business needs.

[0036] The second layer of verification: Determine whether the transition relationship between the target sub-state machine pointed to by the intent identifier and the current sub-state machine pointed to by the current state pointer of the multiprocessing state machine matches the valid state transition mapping table; If the double verification fails, the instruction verification layer generates a structured correction instruction and injects it as a context constraint message into the current dialogue context of the intent parsing module. The correction instruction includes the error type code for the verification failure and a list of valid intent identifier enumeration values.

[0037] The intent parsing module uses constraint decoding technology to restrict the output intent identifier to a list of valid intent identifier enumeration values ​​in order to regenerate structured driver instructions and ensure that the regenerated structured driver instructions pass double verification; at the same time, the current state pointer remains unchanged.

[0038] If the number of consecutive double verifications reaches the preset retry limit, an exception handling signal is triggered, and the process is directly transferred to manual handling. In this embodiment, the instruction verification layer is configured with a retry counter, which is used to count the number of consecutive double verifications.

[0039] If the double verification passes, the instruction verification layer switches the current state pointer to either the first sub-state machine or the second sub-state machine based on the intent identifier. When switching to the first sub-state machine, a multi-level parameter negotiation process is initiated. The first sub-state machine enters the first sub-state, uses a preset starting adjustment factor as the adjustment factor associated with the first processing level, inserts this processing level into the processing level sequence, and provides the processing level sequence to the user terminal.

[0040] Here, the first sub-state refers to the first sub-state machine used to be activated and enter the initial negotiation state. The initial adjustment factor is determined based on the user's historical resource usage records or the request parameter field in the structured driver instruction. Each processing level is associated with an adjustment factor. In this embodiment, the adjustment factor is a numerical parameter directly related to system resource allocation, including but not limited to bandwidth quota, computing resource amount, storage capacity, or parallel execution limit.

[0041] The minimum acceptable adjustment factor is used as a boundary constraint factor and stored in encrypted form in the parameter isolation execution area. The parameter isolation execution area is independent of the intent parsing module and exposes two secure interfaces: a parameter adjustment call interface and a security status query interface.

[0042] The parameter is configured to isolate the execution zone and deny the intent parsing module direct read requests for boundary constraint factors, i.e., to block arbitrary memory reads using hardware and software forced access control.

[0043] The safety status query interface is used to receive the adjustment factor to be compared as input. The parameter isolation execution area decrypts the boundary constraint factor internally, compares the adjustment factor to be compared with the boundary constraint factor numerically, and returns a boolean result indicating whether the input adjustment factor has reached or exceeded the boundary constraint factor.

[0044] During the interaction, when the user rejects the current processing level, the instruction verification layer generates a trigger event and sends the trigger event to the first sub-state machine when the verification passes and the intent identifier indicates that the user rejects the current processing level.

[0045] The triggering event contains fields such as the current processing level number and the adjustment factor for rejection, and is sent to the first sub-state machine to ensure the determinism of state transition.

[0046] After receiving the trigger event, the first sub-state machine passes the adjustment factor of the current processing level to the parameter isolation execution area through the parameter adjustment call interface, and calls the internal strategy adjustment logic.

[0047] In this embodiment, the parameter adjustment call interface is implemented as a secure remote procedure call channel to receive input parameters. This safety passage will The trusted execution environment is input and the policy adjustment logic is executed to calculate the new adjustment factor. Then, the result is returned to the first sub-state machine. Throughout the entire call process, the boundary constraint factor... The plaintext value is always calculated within the trusted execution environment and is never transmitted through the interface.

[0048] The strategy adjustment logic decrypts the boundary constraint factor within the parameter isolation execution area, and generates a new adjustment factor based on the input adjustment factor and the boundary constraint factor through a monotonically convergent algorithm, so that the adjustment factor sequence monotonically approximates the boundary constraint factor.

[0049] In this embodiment, the monotonically convergent algorithm uses the bisection compromise method, and the formula is as follows: In the formula, This indicates that the new adjustment factor generated by the strategy adjustment logic within the parameter isolation execution area will be returned to the first sub-state machine as the adjustment factor associated with the next processing level. This indicates the adjustment factor associated with the current processing level passed in by the first sub-state machine when the policy adjustment is triggered, i.e., the adjustment factor corresponding to the processing level rejected by the user. This represents the boundary constraint factor, i.e. the minimum acceptable adjustment factor. It participates in the calculation in the form of a decrypted value within the parameter isolation execution area, and the plaintext cache is cleared immediately after the calculation is completed.

[0050] The new adjustment factor is returned to the first sub-state machine via the parameter adjustment call interface; the first sub-state machine uses the new adjustment factor as the adjustment factor associated with the new processing level, inserts the new processing level into the processing level sequence, and continues to provide it to the user. The first sub-state machine has preset hierarchical termination conditions, which include: the difference between the new adjustment factor and the boundary constraint factor is less than a preset difference threshold, or the number of generated hierarchies has reached the preset maximum number of iterations, or the instruction verification layer detects that the number of times the intent parsing module continuously regenerates structured driving instructions has reached the preset retry limit.

[0051] When the termination condition of a new processing level is met, the generation of new processing levels will stop, and the upgrade process to manual processing nodes will be triggered.

[0052] The upgrade process encapsulates the current processing level sequence, the current adjustment factor, and the boundary touch state returned by the security status query interface based on the current adjustment factor into a structured context snapshot, and passes it to the manual processing node to ensure that the manual processing node fully obtains the negotiation context.

[0053] When switching to the second sub-state machine, execution plan planning begins. The second sub-state machine stores the standard execution mode parameter set and the segmented execution mode parameter set. Based on the processing path selection parameters in the structured driver instruction, one of the standard execution mode parameter set or the segmented execution mode parameter set is selected.

[0054] The segmented execution mode parameter set includes the initial processing volume ratio parameter r, the number of transition segments n, and the transition processing volume adjustment coefficient. And the normal segment number m.

[0055] If the segmented execution mode is selected, the calculation is performed based on the total processing volume A carried in the structured driver instructions, as follows: The unit of measurement for the total processing volume A is consistent with the requirements of the execution computing interface, such as the number of data entries, the number of processing tasks, the total bandwidth, or the total computing core time. pass Calculate the initial processing volume, that is, the processing volume allocated in the first batch; pass Calculate the remaining processing volume, which is the total amount to be allocated in segments after deducting the initial processing volume; pass The baseline unit quantity is calculated, which represents the average value of the remaining processing quantity under the weighted average of the number of transition periods and the number of normal periods. This value serves as the basis for calculating the unit quantities of the transition period and the normal period. pass Calculate the unit quantity of the transition section, that is, the processing quantity allocated to each transition section; pass Calculate the number of normal segment units, that is, the processing amount allocated to each normal segment.

[0056] In the above formula, all operations are performed in floating-point or integer mode within the computer. The specific precision can be set according to actual needs. The number of transitional segments, n, represents the number of processing segments required before entering normal segmentation; the number of normal segments, m, represents the number of processing segments allocated on average according to the baseline unit quantity; the initial processing volume ratio parameter r represents the proportion of the initial processing volume allocated in the segmented execution mode to the total processing volume, with a value ranging from 0 to 1; and the transitional processing volume adjustment coefficient... Used to amplify or reduce the proportion of each segment during the transition period relative to the reference unit; Will , The combination of , n, and m serves as the request parameters, which call the external execution calculation interface to obtain the execution plan and send it back to the user.

[0057] In this embodiment, the segmented computation can be applied to a variety of scenarios, such as batch delivery of cloud resources, segmented execution of distributed tasks according to priority, and gray-scale release of traffic. As a result, a request body that meets the requirements of the external interface can be automatically constructed based on the segmentation parameters.

[0058] The event generator is responsible for generating a processing achievement event when a negotiation or plan is reached. Specifically, when the first or second sub-state machine receives confirmation from the instruction verification layer that the user has accepted the current plan, the event generator immediately creates a processing achievement event and passes it to the confirmation module.

[0059] The confirmation module is used to execute an atomic confirmation process after receiving a processing completion event. The atomic confirmation process is as follows: L1. Send a preliminary confirmation request to the user terminal and start a timer to wait for the first confirmation signal; L2. After receiving the first confirmation signal, persist the current protocol snapshot, then send a submission confirmation request to the user terminal, and wait for the second confirmation signal; L3. If the first confirmation signal and the second confirmation signal are received successively within the preset time window, the external voucher generation interface will be called to issue the electronic voucher. L4. If the first and second confirmation signals are not received by the time window expires, the timeout compensation action will be triggered. The confirmation module sends a rollback command to the multiprocessing state machine. The multiprocessing state machine rolls back the negotiated state to the processing level before the processing was achieved, clears the persistent temporary snapshot, and can notify the client to reconfirm.

[0060] As a second embodiment of the present invention: In specific implementation, compared with Embodiment 1, the only difference between the technical solution of this embodiment and Embodiment 1 is that this embodiment also proposes: The parameter-isolated execution zone is implemented based on a hardware-based trusted execution environment, such as Intel SGX or ARM TrustZone.

[0061] The runtime memory space of the intent parsing module is physically isolated from the memory space of the parameter isolation execution area; Both the parameter adjustment call interface and the security status query interface are invoked into the trusted execution environment through security monitoring.

[0062] Within the security status query interface, the legitimacy of the call source is verified, the boundary constraint factor is decrypted, numerical comparison is performed, and only the Boolean value of the comparison result is returned via a secure channel.

[0063] As an embodiment of the present invention: In its specific implementation, compared to Embodiment 1 and Embodiment 2, the technical solution of this embodiment differs from that of Embodiment 1 and Embodiment 2 only in that: in this embodiment, the strategy adjustment logic within the parameter isolation execution area still adopts the proportional decrease method as a monotonically convergent algorithm, and its formula is as follows: ,in Δ represents the adjustment step size calculated in this round, that is, the amount of reduction in the difference between the current adjustment factor and the boundary constraint factor; k is a preset decay coefficient, with a value range greater than 0 and less than 1, used to control the speed at which the boundary constraint factor is approached in each iteration. The larger the value of k, the faster the contraction.

[0064] The algorithm directly calculates a new adjustment factor based on the current gap, which leads to monotonically convergent, and the step size of each iteration decreases proportionally to the current gap.

[0065] Those skilled in the art can choose between the two algorithms according to actual needs, or adopt other forms such as All monotonically gradual formulas are within the scope of protection of this invention.

[0066] As an embodiment of the present invention: This embodiment provides a multi-stage intelligent negotiation method based on a large language model. This method is implemented through a multi-stage intelligent negotiation system based on a large language model and includes the following steps: S1, the message interface module receives session messages.

[0067] S2, The intent parsing module generates structured driver instructions.

[0068] S3, the instruction verification layer performs dual verification on structured driver instructions.

[0069] S4. The first sub-state machine generates the first processing level with the initial adjustment factor; when the instruction verification layer recognizes the rejection intention, it generates a trigger event; after receiving the trigger event, the first sub-state machine calls the monotonic convergence algorithm through the security interface to generate a new adjustment factor and insert it into the processing level.

[0070] The second sub-state machine selects either the standard execution mode parameter set or the segmented execution mode parameter set according to the processing path. In the segmented execution mode, it calculates the request parameters using the initial processing volume ratio parameter, the number of transition periods, the transition period processing volume adjustment coefficient, and the number of normal periods from the segmented execution mode parameter set, and calls the external interface to obtain the execution plan.

[0071] S5: When the first sub-state machine or the second sub-state machine receives confirmation from the instruction verification layer that the user has accepted the current scheme, the event generator creates a processing completion event and notifies the confirmation module.

[0072] S6: The confirmation module executes the atomic confirmation process.

[0073] Furthermore, any content not described in detail in this specification is existing technology known to those skilled in the art.

[0074] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, 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 process, method, article, or apparatus.

[0075] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

[0076] The various embodiments of this application have been described above. These descriptions are exemplary and not exhaustive, nor are they limited to the disclosed embodiments. Many modifications and variations will be apparent to those skilled in the art without departing from the scope and spirit of the described embodiments. The terminology used herein is chosen to best explain the principles, practical application, or improvement of the technology in the market, or to enable others skilled in the art to understand the embodiments disclosed herein.

Claims

1. A multi-stage intelligent negotiation system based on a large language model, characterized in that, include: The message interface module is used to receive session messages sent by the user client; The intent parsing module is used to generate structured driving instructions based on session messages. The structured driving instructions include intent identifiers and processing path selection parameters. A multi-processing state machine is connected to the intent parsing module. The multi-processing state machine includes a first sub-state machine and a second sub-state machine, and is configured with an instruction verification layer and an event generator. The instruction verification layer is used to obtain structured driving instructions and perform double verification on the structured driving instructions. The first sub-state machine is used to insert the processing level into the processing level sequence when entering the first sub-state, using a preset starting adjustment factor as the adjustment factor associated with the first processing level, and providing the processing level sequence to the user terminal. Among them, the adjustment factor is a numerical parameter related to system resource allocation, including bandwidth quota, computing resource amount, storage capacity or parallel execution limit. The initial adjustment factor is determined based on the user's historical resource usage records or the request parameter field in the structured driver instruction. The second sub-state machine stores the standard execution mode parameter set and the segmented execution mode parameter set, which are used to select parameters according to the processing path in the structured driving instructions, select the corresponding parameter set, combine the request parameters of the external execution computing interface, and obtain the execution plan. The event generator is used to generate a processing completion event when the first sub-state machine or the second sub-state machine receives a structured driving instruction indicating that the user terminal accepts the current scheme, and then passes the processing completion event to the confirmation module. The confirmation module is used to execute an atomic confirmation process after receiving a processing completion event.

2. The multi-stage intelligent negotiation system based on a large language model according to claim 1, characterized in that, The dual verification is as follows: verifying whether the intent identifier belongs to the preset set of legal intent identifier enumeration values, and whether the transition relationship between the target sub-state machine indicated by the intent identifier and the current sub-state machine pointed to by the current state pointer of the multiprocessor state machine matches the legal state transition mapping table. If the double verification fails, the instruction verification layer generates a structured correction instruction and injects the correction instruction as a context constraint message into the current dialogue context of the intent parsing module to drive the regeneration of the structured driving instruction while keeping the current state pointer unchanged. If the double verification passes, the instruction verification layer switches the current state pointer to the first sub-state machine or the second sub-state machine according to the intent identifier.

3. The multi-stage intelligent negotiation system based on a large language model according to claim 1, characterized in that, The system also includes a parameter isolation execution area, which is used to store the lowest acceptable adjustment factor as a boundary constraint factor in encrypted form in a parameter isolation execution area that is pre-configured independently of the intent parsing module. The parameter isolation execution area is configured to reject the intent parsing module's direct read request for the boundary constraint factor. The parameter isolation execution area exposes parameter adjustment call interface and security status query interface to the outside world. The safety status query interface is used to receive the adjustment factor to be compared as input, decrypt the boundary constraint factor in the parameter isolation execution area, compare the adjustment factor to be compared with the boundary constraint factor numerically, and return a Boolean result indicating whether the boundary constraint factor has been reached or exceeded.

4. The multi-stage intelligent negotiation system based on a large language model according to claim 3, characterized in that, The parameter isolation execution area is implemented by a hardware-based trusted execution environment, and the runtime memory space of the intent parsing module is physically isolated from the memory space of the parameter isolation execution area; The security status query interface enters the trusted execution environment via security monitoring calls, and the comparison and return of Boolean results are both completed within the trusted execution environment.

5. A multi-stage intelligent negotiation system based on a large language model according to claim 3, characterized in that, The instruction verification layer is also used to generate a trigger event and send the trigger event to the first sub-state machine when the verification passes and the intent identifier is recognized as indicating that the user rejects the current processing level. When the first sub-state machine receives a trigger event, it passes the adjustment factor associated with the current processing level to the parameter isolation execution area through the parameter adjustment call interface, and calls the strategy adjustment logic in the parameter isolation execution area. The strategy adjustment logic decrypts the boundary constraint factor within the parameter isolation execution area, and generates a new adjustment factor based on the input adjustment factor and the decrypted boundary constraint factor through a binary compromise algorithm or a proportional decrease algorithm. This makes the adjustment factor sequence, composed of the initial adjustment factor and the subsequently generated new adjustment factors in the order of generation, monotonically approximate the boundary constraint factor in numerical terms. The new adjustment factor is returned to the first sub-state machine via the parameter adjustment call interface; the first sub-state machine uses the new adjustment factor as the adjustment factor associated with the new processing level, inserts the new processing level into the processing level sequence, and continues to provide it to the user.

6. A multi-stage intelligent negotiation system based on a large language model according to claim 3, characterized in that, The first sub-state machine is also used to stop generating new processing levels and trigger the upgrade process to manual processing nodes when the preset level termination conditions are met. The upgrade process includes encapsulating the current processing level sequence, the current adjustment factor, and the boundary touch state returned by the security status query interface based on the current adjustment factor into a context snapshot, and then passing it to the manual processing node.

7. A multi-stage intelligent negotiation system based on a large language model according to claim 2, characterized in that, The correction instruction includes the error type code for the failed verification and a list of valid intent identifier enumeration values; The intent parsing module uses constraint decoding technology to restrict the output intent identifier to a list of valid intent identifier enumeration values, so that the regenerated structured driver instructions pass double verification.

8. A multi-stage intelligent negotiation system based on a large language model according to claim 6, characterized in that, The hierarchical termination condition includes at least one of the following: The difference between the newly adjusted factor and the boundary constraint factor is less than the preset difference threshold; The number of processing layers generated has reached the preset maximum number of iterations; The instruction verification layer detected that the number of times the intent parsing module continuously regenerated the structured driver instruction had reached the preset retry limit.

9. A multi-stage intelligent negotiation system based on a large language model according to claim 1, characterized in that, The atomic confirmation process includes: sending a preliminary confirmation request to the user terminal and waiting for a first confirmation signal; after receiving the first confirmation signal, sending a submission confirmation request to the user terminal and waiting for a second confirmation signal; triggering the issuance of electronic credentials when the first and second confirmation signals are received successively within a preset time window; if the first and second confirmation signals are not received by the end of the preset time window, triggering a timeout compensation action, which includes sending a rollback instruction to the multiprocessing state machine to roll back the negotiation state to the state before the processing completion event was received.

10. A multi-stage intelligent negotiation method based on a large language model, wherein the method is implemented by a multi-stage intelligent negotiation system based on a large language model as described in any one of claims 1-9, characterized in that, The method includes the following steps: S1. The message interface module receives session messages; S2, The intent parsing module generates structured driver instructions; S3, the instruction verification layer performs dual verification on structured driver instructions; S4. The first sub-state machine generates the first processing level with the initial adjustment factor; when the instruction verification layer recognizes the rejection intention, it generates a trigger event; after receiving the trigger event, the first sub-state machine generates a new adjustment factor and inserts it into the processing level through a binary compromise algorithm or a proportional decrease algorithm; in response to the achievement of the processing level sequence, the second sub-state machine selects the standard execution mode parameter set or the segmented execution mode parameter set according to the processing path selection parameters. In the segmented execution mode, the initial processing volume ratio parameter, the number of transition periods, the transition period processing volume adjustment coefficient, and the number of normal periods in the segmented execution mode parameter set are used to calculate the request parameters, and the external interface is called to obtain the execution plan; S5: When the first sub-state machine or the second sub-state machine receives confirmation from the instruction verification layer that the user has accepted the current scheme, the event generator creates a processing completion event and notifies the confirmation module. S6: The confirmation module executes the atomic confirmation process.