A method, apparatus and related equipment for handling document collaboration conflicts
By performing semantic analysis and type identification on conflicts in document collaboration using a multimodal large model, the problem of poor conflict handling in existing technologies is solved, and more accurate and efficient document collaboration conflict handling is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- CHINA MOBILE FINANCIAL TECHNOLOGY CO LTD
- Filing Date
- 2026-02-04
- Publication Date
- 2026-05-26
AI Technical Summary
Existing document collaboration conflict resolution methods mainly focus on the data layer's write order and storage state convergence, resulting in poor conflict resolution performance.
Using a multimodal large model, semantic analysis is performed on collaborative documents, operation instructions, and change data to determine conflict types and content, and appropriate processing methods are selected based on the conflict type, including specific processing methods for text, image, and table conflicts.
Semantic analysis improves the accuracy and adaptability of conflict handling, enhancing the effectiveness of conflict resolution in document collaboration.
Smart Images

Figure CN122086848A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of information technology, and in particular to a method, apparatus and related equipment for handling document collaboration conflicts. Background Technology
[0002] Document collaboration is a technology that allows multiple users to work collaboratively on the same core document. When conflicts arise during document collaboration, current conflict resolution methods (such as Conflict-Free Replicated Data Type (CRDT) technology) only focus on the data-level write order and storage state convergence, resulting in poor conflict handling in document collaboration. Summary of the Invention
[0003] This application provides a document collaboration conflict handling method, apparatus, and related equipment, which can solve the technical problem of poor conflict handling effect in document collaboration.
[0004] In a first aspect, embodiments of this application provide a method for handling document collaboration conflicts, the method comprising:
[0005] The system acquires multiple operation instructions executed by multiple user terminals on the collaborative document, as well as multiple change data generated after executing the multiple operation instructions.
[0006] A multimodal large model is used to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data to obtain semantic analysis results. Based on the semantic analysis results, the conflict types of the multiple operation instructions and the conflict content of the multiple change data are determined.
[0007] Based on the conflict type, determine the conflict handling method corresponding to the conflict content, and adjust the conflict content according to the conflict handling method to obtain the first document.
[0008] Optionally, determining the conflict handling method corresponding to the conflict content based on the conflict type, and adjusting the conflict content according to the conflict handling method, includes at least one of the following:
[0009] In cases where the conflict type includes textual conflict, the conflict content is adjusted based on the syntax tree structure and the semantic analysis results.
[0010] When the conflict type includes image conflict, the overlapping area in the conflict content is identified by region mask contrast detection, and prompt information is added to the overlapping area.
[0011] In the case where the conflict type includes table conflict, a table version matrix is determined based on the conflict content and the change data, and the conflict content is adjusted according to the table version matrix.
[0012] Optionally, the step of acquiring multiple operation instructions executed by multiple user terminals on the collaborative document includes:
[0013] Within a preset time range, acquire multiple sets of operation instructions executed by multiple user terminals on collaborative documents, and acquire a preset number of the multiple operation instructions from the multiple sets of operation instructions in the form of a sliding window.
[0014] Optionally, the plurality of operation instructions may be multiple operation instructions obtained by merging similar instructions.
[0015] Optionally, the method further includes:
[0016] The network latency of the multiple user terminals and the number of multiple operation commands are obtained respectively;
[0017] If the network latency is less than a preset first threshold and the number of instructions is greater than a preset second threshold, the first document is sent to the plurality of user terminals respectively.
[0018] If the network latency is greater than or equal to a preset first threshold and the number of instructions is greater than a preset second threshold, the multiple operation instructions are adjusted according to the conflict content to obtain serialized operation instructions, and the serialized operation instructions are sent to the multiple user terminals respectively.
[0019] Optionally, the method further includes:
[0020] The collaborative document is divided into multiple fragmented documents according to a predetermined order based on the semantic structure of the collaborative document and the device types of the multiple user terminals.
[0021] The document conflict handling method is executed in parallel on the multiple fragmented documents to obtain the first document corresponding to each of the multiple fragmented documents;
[0022] The first documents corresponding to each of the multiple fragmented documents are integrated in the predetermined order to obtain the second document.
[0023] Secondly, embodiments of this application provide a personalized service content recommendation device, the device comprising:
[0024] The acquisition module is used to acquire multiple operation instructions executed by multiple user terminals on the collaborative document, as well as multiple change data generated after the execution of the multiple operation instructions;
[0025] The first processing module is used to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data using a multimodal large model to obtain semantic analysis results, and to determine the conflict type of the multiple operation instructions and the conflict content of the multiple change data based on the semantic analysis results.
[0026] The second processing module is used to determine the conflict handling method corresponding to the conflict content according to the conflict type, and adjust the conflict content according to the conflict handling method to obtain the first document.
[0027] Thirdly, embodiments of this application provide an electronic device, including: a processor, a memory, and a program stored in the memory and executable on the processor, wherein when the program is executed by the processor, it implements the steps of the document collaboration conflict handling method as described in the first aspect.
[0028] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the document collaboration conflict resolution method as described in the first aspect.
[0029] Fifthly, embodiments of this application provide a computer program product including computer instructions that, when executed by a processor, implement the steps of the document collaboration conflict resolution method as described in the first aspect.
[0030] In this embodiment, by using a multimodal large model to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data, the conflict type and conflict content can be determined at the semantic level, providing accurate data support for conflict handling and thus improving the conflict handling effect in document collaboration. In addition, by selecting and adjusting the conflict handling method according to the conflict type, the conflict handling method and the conflict content can be better adapted, which can further improve the conflict handling effect in document collaboration. Attached Figure Description
[0031] To more clearly illustrate the technical solutions of the embodiments of this application, 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 this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0032] Figure 1 This is a flowchart of a document collaboration conflict resolution method provided in an embodiment of this application;
[0033] Figure 2 This is a schematic diagram of conflict points in the conflict resolution of a contract document provided in an embodiment of this application;
[0034] Figure 3 This is a schematic diagram of the structure of a document collaboration conflict handling device provided in an embodiment of this application;
[0035] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0036] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0037] The terms "first," "second," etc., used in this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such terms can be used interchangeably where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first" and "second" are generally of the same class, not limited in number; for example, the first object can be one or more. Furthermore, "and / or" in this application indicates at least one of the connected objects. For example, the scope of protection of "A and / or B" covers at least three scenarios: Scenario 1: including A but not B; Scenario 2: including B but not A; Scenario 3: including both A and B. Additionally, the character " / " generally indicates that the preceding and following objects are in an "or" relationship.
[0038] See Figure 1 , Figure 1 This is a flowchart of a document collaboration conflict resolution method provided in an embodiment of this application, such as... Figure 1 As shown, the method includes the following steps:
[0039] Step 101: Obtain multiple operation instructions executed by multiple user terminals on the collaborative document, and multiple change data generated after executing the multiple operation instructions;
[0040] The plurality of user terminals may include, but are not limited to, mobile terminals (such as mobile phones), desktop terminals (such as personal computers) and embedded terminals;
[0041] In this application, a desktop terminal may also be referred to as a desktop client, and a mobile terminal may also be referred to as a mobile client;
[0042] The collaborative document can be a document that supports collaborative operations among the multiple user terminals; the collaborative document can include unimodal data or multimodal data; for example, the collaborative document can include one or more of conventional modal data such as images, text, and tables, and can also include one or more of extended modal data such as audio data, video data, and model data.
[0043] The multiple operation instructions may include one or more of the following: adding, deleting, modifying, querying, annotating, setting permissions, copying, moving, merging, and splitting the collaborative document; the multiple operation instructions can be obtained by capturing them through a browser plugin set on the user's end.
[0044] The multiple operation instructions can be multiple instructions obtained through preprocessing. Taking any user-side operation instruction as an example, the user-side operation instruction can be preprocessed through the Operational Transformation (OT) algorithm and local pre-submission can be performed. Then, according to the document data format and operation specifications specified in the ISO / IEC 20802 standard, the preprocessed operation instruction can be encapsulated into a standardized operation package form adapted to the CRDT mechanism.
[0045] In this step, multiple operation instructions executed by multiple user terminals on collaborative documents are obtained, as well as multiple change data generated after the execution of the multiple operation instructions, providing a data foundation for handling document collaboration conflicts.
[0046] Step 102: Use a multimodal large model to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data to obtain semantic analysis results. Based on the semantic analysis results, determine the conflict type of the multiple operation instructions and the conflict content of the multiple change data.
[0047] The multimodal large model can be an attention-based multimodal large model, such as a large-scale pre-trained model built on the Transformer architecture based on the attention mechanism; the multimodal large model can perform semantic analysis, feature fusion, cross-modal reasoning, document content understanding and generation on multimodal data such as text, images, audio, and tables.
[0048] The multimodal large model may include at least one of the following: a bidirectional encoder representation from transformers (BERT) model, a graph neural network (GNN) model, and a contrastive language-image pre-training (CLIP) model; the BERT model, GNN model, and CLIP model can serve as the core components of the multimodal large model to construct the multimodal large model.
[0049] Among them, the BERT model can be used to analyze the syntax and semantics of text manipulation instructions; the GNN model can maintain cell relationships through table manipulation instructions; and the CLIP model can align visual image semantics and text semantics for image manipulation instructions.
[0050] Determining the conflict type and content based on the semantic analysis results can be achieved by recognizing the semantic relationships between operation commands (e.g., determining whether the paragraph deleted by user A is referenced by user B).
[0051] In this step, a multimodal large model is used to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data. On the one hand, it can analyze the semantic contradictions in the collaborative document, the multiple operation instructions, and the multiple change data from a semantic level and obtain semantic analysis results, which can more accurately determine the conflict type and conflict content, providing a more accurate data foundation for obtaining the first document. On the other hand, the multimodal large model can handle cross-modal data, and identify the semantic correlation between change data of different modalities through semantic analysis, which can expand the applicability of the document collaboration conflict handling method and achieve better conflict handling results in document collaboration.
[0052] Step 103: Determine the conflict handling method corresponding to the conflict content according to the conflict type, adjust the conflict content according to the conflict handling method, and obtain the first document.
[0053] The first document may be a document obtained by adjusting the conflicting content to resolve the conflict.
[0054] In this step, selecting the appropriate conflict resolution method based on the conflict type will enable the conflict resolution method to adjust the conflict content more effectively, thereby improving the conflict resolution effect in document collaboration.
[0055] In this embodiment, by using a multimodal large model to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data, the conflict type and conflict content can be determined at the semantic level, providing accurate data support for conflict handling and thus improving the conflict handling effect in document collaboration. In addition, by selecting and adjusting the conflict handling method according to the conflict type, the conflict handling method and the conflict content can be better adapted, which can further improve the conflict handling effect in document collaboration.
[0056] In some implementations, since the collaborative document can be multimodal data, the change data and the conflicting content can also be multimodal data; the method may further include: using the multimodal big model to perform cross-semantic alignment on the collaborative document, the multiple change data and the conflicting content.
[0057] Specifically, determining the conflicting content of the multiple changed data based on the semantic analysis results may include:
[0058] The semantic analysis results are obtained by performing cross-semantic alignment on the multiple changed data using the multimodal large model.
[0059] Based on the semantic analysis results, the relevance scores of the multimodal data among the multiple change data are determined;
[0060] If the relevance score is less than a preset value, it is determined that there is no conflicting content among the multiple changed data.
[0061] If the correlation score is greater than or equal to a preset value, the conflicting content of the multiple changed data is determined.
[0062] In this embodiment, the correlation score of multimodal data is obtained based on the multimodal large model, thereby determining whether there is conflict content in the multiple changed data. This can not only improve the ability of conflict handling to be extended to multimodal data, but also help to determine the conflict content through the correlation score, thus obtaining a better conflict handling effect.
[0063] For example, the multiple changed data may include text data and image data; the relevance score between text data and image data (such as whether the image region annotated by user A matches the text description modified by user B) can be calculated through the cross-modal attention mechanism of a multimodal large model;
[0064] Specifically, a cross-modal attention mechanism can be implemented using the CrossModalAttention class to calculate the relevance score between two different modalities of data: text and image. See the following Python code for details:
[0065] class CrossModalAttention(nn.Module):
[0066] def __init__(self):
[0067] super().__init__()
[0068] self.text_proj = nn.Linear(768, 512)
[0069] self.image_proj = nn.Conv2d(3, 512, kernel_size=1)
[0070] def forward(self, text_emb, image_emb):
[0071] # Calculate cross-modal attention score
[0072] attn_scores = torch.matmul(
[0073] self.text_proj(text_emb),
[0074] self.image_proj(image_emb).flatten(2) )
[0076] return attn_scores
[0077] In some implementations, adjusting the conflict content according to the conflict handling method may include: determining the adjustment priority of the conflict content through a preset multi-dimensional evaluation matrix, and adjusting the conflict content according to the conflict handling method and the adjustment priority; since the adjustment priority is considered in the process of adjusting the conflict content, the pertinence and efficiency of conflict handling can be improved, and the effect of conflict handling can be further improved.
[0078] Specifically, the preset multi-dimensional evaluation matrix may include a time priority dimension, a user terminal permission dimension, a semantic integrity dimension, and a network quality dimension, as well as the weights corresponding to each of the time priority dimension, user terminal permission dimension, semantic integrity dimension, and network quality dimension; see Table 1 below for details:
[0079] Table 1:
[0080]
[0081] More specifically, the conflicting content can be weighted and summed according to preset weights in the dimensions of time priority, user permissions, semantic integrity, and network quality to obtain a priority score for the conflicting content; the adjustment priority of the conflicting content can be determined based on the priority score.
[0082] In some implementations, determining the conflict handling method corresponding to the conflict content based on the conflict type, and adjusting the conflict content according to the conflict handling method, includes at least one of the following:
[0083] In cases where the conflict type includes textual conflict, the conflict content is adjusted based on the syntax tree structure and the semantic analysis results.
[0084] When the conflict type includes image conflict, the overlapping area in the conflict content is identified by region mask contrast detection, and prompt information is added to the overlapping area.
[0085] In the case where the conflict type includes table conflict, a table version matrix is determined based on the conflict content and the change data, and the conflict content is adjusted according to the table version matrix.
[0086] Specifically, the BERT model can be used to analyze the syntax and semantics of text manipulation instructions to determine the type of text conflict, and the conflict content can be adjusted based on the semantic analysis results and syntax tree analysis to ensure that the adjusted (e.g., modified) document structure is legal; the conflict content in text conflicts can also be adjusted based on the BERT model.
[0087] Adding prompts to the overlapping area can be done by marking the overlapping area with visual prompts; specific implementation methods can include: using special colors such as bright yellow and warning red to mark the overlapping area; it can also be combined with text prompts to indicate the location of the conflict and handling guidance; specifically, prompts can be added to the overlapping area in image conflicts based on the CLIP model;
[0088] The table version matrix may include data such as version number, operation instructions for each version, change data and conflict content, as well as data such as the time of execution of operation instructions, user terminal information of the user terminal executing the operation and the user terminal's operation permissions, and priority adjustment information for conflict content and preset conflict handling rules; specifically, the conflict content in the table conflict can be adjusted based on the GNN model.
[0089] Adjusting the conflicting content according to the version matrix in the table can be done by taking the target version content as the adjusted conflicting content based on the user's operating permissions or preset conflict handling rules; alternatively, it can also retain the conflicting content generated by each version, form a conflict record, and archive it.
[0090] In this embodiment, since each of the text conflict, image conflict, and table conflict uses its own corresponding conflict handling method, the conflict handling method can be better adapted to the conflict content; by adjusting the conflict content through the corresponding conflict handling method, a better conflict handling effect can be achieved.
[0091] In some implementations, the step of acquiring multiple operation instructions executed by multiple user terminals on a collaborative document includes:
[0092] Within a preset time range, acquire multiple sets of operation instructions executed by multiple user terminals on collaborative documents, and acquire a preset number of the multiple operation instructions from the multiple sets of operation instructions in the form of a sliding window.
[0093] The preset quantity can be set as needed by those skilled in the art; for example, the preset quantity can be 5.
[0094] In this embodiment, a preset number of operation instructions from the multiple operation instruction sets are obtained in the form of a sliding window, avoiding full calculation to reduce computational overhead, improve the efficiency of computing resource utilization and conflict handling, and achieve better conflict handling results.
[0095] In some implementations, the method may further include managing high-frequency operation instructions using a differential caching strategy and / or a Least Recently Used (LRU) cache eviction mechanism to reduce redundant analysis and computational overhead, and improve computational resource utilization efficiency and conflict handling efficiency.
[0096] In some implementations, the multiple operation instructions are multiple operation instructions obtained by merging similar instructions. By merging similar instructions, the number of operation instructions and computational overhead can be reduced, the efficiency of computing resource utilization and conflict handling can be improved, and a better conflict handling effect can be achieved.
[0097] In some embodiments, the method further includes:
[0098] The network latency of the multiple user terminals and the number of multiple operation commands are obtained respectively;
[0099] If the network latency is less than a preset first threshold and the number of instructions is greater than a preset second threshold, the first document is sent to the plurality of user terminals respectively.
[0100] If the network latency is greater than or equal to a preset first threshold and the number of instructions is greater than a preset second threshold, the multiple operation instructions are adjusted according to the conflict content to obtain serialized operation instructions, and the serialized operation instructions are sent to the multiple user terminals respectively.
[0101] The preset first threshold and the preset second threshold can be set as needed by those skilled in the art; specifically, the preset first threshold can be 50 milliseconds; the preset second threshold can be 100.
[0102] In this embodiment, under low-latency network conditions and with a large number of instructions, the first document is directly sent to the multiple user terminals respectively, which can quickly achieve multi-terminal document state alignment and synchronization, meeting the efficiency requirements of multi-user terminal document collaboration; under high-latency network conditions and with a small number of instructions, the serialization operation instructions are directly sent to the multiple user terminals respectively, reducing the risk of transmission timeout and failure, and achieving better document collaboration effect.
[0103] For example, when the network latency is less than 50ms, the number of instructions exceeds 100, and the user terminal is a mobile terminal, the first document is directly sent to the user terminal to complete the state synchronization; this method is suitable for high bandwidth and low latency environments (such as local area networks) where complete states are directly exchanged.
[0104] When the network latency is greater than or equal to 50ms, the number of instructions is less than or equal to 100, and the user terminal is a desktop, the serialized operation instructions are sent to the user terminal to indicate that the operation synchronization has been completed. This method is suitable for both low-latency and high-latency network conditions, and can broadcast operation logs and execute them in sequence.
[0105] In some embodiments, the method may further include:
[0106] Under high load conditions (e.g., system load exceeds a preset third threshold), the first document can be synchronized to the multiple user terminals using a stateful CRDT method to improve document collaboration.
[0107] Under low load conditions (e.g., system load is less than or equal to a preset third threshold), the first document can be synchronized to the multiple user terminals via an operational CRDT to save memory and improve document collaboration efficiency.
[0108] In some embodiments, the method further includes:
[0109] The collaborative document is divided into multiple fragmented documents according to a predetermined order based on the semantic structure of the collaborative document and the device types of the multiple user terminals.
[0110] The document conflict handling method is executed in parallel on the multiple fragmented documents to obtain the first document corresponding to each of the multiple fragmented documents;
[0111] The first documents corresponding to each of the multiple fragmented documents are integrated in the predetermined order to obtain the second document.
[0112] In this embodiment, since the document conflict handling method is executed in parallel on the multiple fragmented documents, this parallel execution method can shorten the conflict handling time, improve the utilization efficiency of computing resources, and further improve the conflict handling effect in document collaboration.
[0113] For example, the above parallel execution methods may also include operation card splitting strategies and graphics processing unit (GPU) acceleration schemes;
[0114] Specifically, when the collaborative document includes text data, it can be sharded by text paragraphs (e.g., sharding key Sharekey = paragraph identifier (Identifier, ID)) and user device type (e.g., mobile or desktop) through the operation of the card sharding strategy; since it supports parallel computing of multiple computing nodes under the parallel processing framework, the time spent on conflict handling can be shortened;
[0115] The GPU acceleration solution can optimize the above-mentioned multimodal large model inference and semantic analysis process through the Compute Unified Device Architecture (CUDA) kernel function; the GPU acceleration solution can also be implemented through a batch processing mechanism (e.g., a batch size of 32).
[0116] In some implementations, the method further includes signing the operation corresponding to the parallel execution to verify the integrity of the operation; optionally, the operation integrity can be verified by signing with a private key using a 256-bit Secure Hash Algorithm (SHA-256) and a Rivest-Shamir-Adleman Algorithm (RSA).
[0117] In some implementations, the method further includes constructing a zero-knowledge verification protocol to prove the legality of parallel execution operations, thereby achieving conflict verification under privacy protection; optionally, the legality of operations can be proved by cryptographic techniques such as zero-knowledge succinct non-interactive argument of knowledge (zk-SNARKs).
[0118] It should be noted that the document collaboration conflict handling method disclosed above can be executed by an electronic device, that is, all steps included in the above method are executed by the electronic device, which can be a server, computer, cloud computing node, cloud service node or mobile phone or other electronic devices.
[0119] This application also provides a document collaboration conflict resolution system, including: a client proxy layer, an edge computing layer, and a cloud coordination layer;
[0120] The client agent layer is used to obtain multiple operation instructions from the multiple user terminals for the collaborative document. Optionally, this operation can be implemented based on browser event listening and operation queue management. Specifically, the key technologies of the client agent layer may include: first, differential capture technology, which only records incremental changes in the Document Object Model (DOM) to reduce data transmission; second, operation compression algorithm, which merges continuous keystroke operation instructions into higher-level operations (e.g., merging 100 keyboard events into "insert paragraph A"). The data structure of this layer is recorded as follows: each operation contains a unique ID (e.g., UUIDv7), a user ID (e.g., CMCC-UID-2023), a timestamp, and a semantic tag (e.g., "delete paragraph X").
[0121] The edge computing layer may include: a semantic analysis engine and a hybrid CRDT module;
[0122] The semantic analysis engine may include a multimodal large model; utilizing the natural language understanding submodule of the multimodal large model, a lightweight BERT model is used to classify the intents of the multiple operation commands, such as "merge paragraphs" and "delete table rows"; secondly, context association is performed, maintaining an operation history graph and analyzing the semantic relationship between the current operation command and the context, for example, when user A deletes a paragraph, it checks whether there is a conflict with the modifications of other users; finally, there is an intent label generator part, where users output structured labels, such as: {"action":"merge","source":"para1","target":"para2"}), for use in subsequent conflict decision-making;
[0123] In this example, "action":"merge" indicates a merge operation; "source":"para1" indicates that the source object is paragraph 1; "target":"para2" indicates that the target object of the operation is paragraph 2; the structured data in the example shows that the user intends to merge the content of "paragraph 1" (para1) into "paragraph 2" (para2), and after the merge, para1 may be deleted or the content of the two may be integrated.
[0124] The hybrid CRDT module may include a state-based CRDT module and an operational CRDT module;
[0125] The state-based CRDT module can be used for add / delete operations (such as inserting / deleting text), and can also mark the latest state based on a timestamp;
[0126] The operational CRDT module can be used for formatting or moving operations (such as font modification and paragraph movement), and can also achieve synchronization through broadcast operation logs;
[0127] The cloud coordination layer may include a conflict decision-maker;
[0128] The conflict decision-maker can detect conflicts based on an operation dependency graph, which can be generated based on the aforementioned multiple operation instructions and the collaboration document; the conflict decision-maker can also determine the priority score of the conflict content based on the aforementioned multi-dimensional evaluation matrix and produce the final operation sequence.
[0129] The operation dependency graph can be a directed acyclic graph (DAG), which can be used to represent the logical dependencies between multiple operation instructions in a document collaboration conflict resolution system. Each node in the graph represents a user operation instruction (such as insert, delete, or merge), and the edges in the graph represent the dependencies or temporal relationships between operation instructions.
[0130] The purpose of an operation dependency graph is to explicitly show the causal relationship between operation instructions (such as operation instruction B depending on the result of operation instruction A) and to identify conflicting operations that cannot coexist (such as deleting and modifying the same paragraph at the same time). The construction of an operation dependency graph includes the generation of nodes (each operation instruction is transformed into a node in the graph) and the establishment of edge dependencies (such as data dependency, where operation B directly modifies the output result of operation A; or control dependency, where operation B needs to be executed after operation A is completed).
[0131] Conflict detection can detect when two operation instructions modify the same content, or when an object read by operation instruction A is modified by operation instruction B, etc.; then, priority scores are calculated based on a multi-dimensional evaluation matrix to generate the final operation.
[0132] For example, taking the conflict resolution of contract documents by the multiple user terminals as an example, the multiple user terminals include mobile terminals (e.g., mobile phone terminals or tablet terminals), desktop terminals (e.g., computer terminals) and hybrid terminals (alternating between mobile terminals and computer terminals).
[0133] Specifically, the multiple user terminals include: ① legal counsel (computer terminal), who uses a Windows computer to modify the terms of the contract; ② business manager (mobile terminal), who merges contract paragraphs through a mobile terminal; ③ auditor (hybrid terminal), who alternates between annotating the contract on their mobile phone and reviewing it on their computer.
[0134] At this time, the computer is in a low-latency enterprise WiFi network environment (e.g., network latency of 20ms); the mobile device is in a network environment of hybrid fourth-generation mobile communication technology (4G) / fifth-generation mobile communication technology (5G) (e.g., network latency of 50-150ms).
[0135] Multiple user actions and semantic tags (data changes) were captured: ① On the computer (legal counsel), the "Breach of Contract" clause (Article 12) was modified; the system automatically generated semantic tags: "Operation type: Clause modification; Target location: Article 12; Modification content: The penalty ratio is adjusted from 5% to 7%; Permission level: High (legal counsel exclusive permission)"; ② On the mobile (business manager), the "Dispute Resolution" clause (Article 15) was dragged and merged into the "Applicable Law" clause (Article 16); the system automatically generated semantic tags: "Operation type: Clause merging; Source clause: Article 15; Target clause: Article 16; Intent confidence level: 92% (can be obtained through mobile lightweight model analysis)"; ③ The auditor (cross-device) first annotated "Requires board approval" for Article 12 of the contract on the mobile device, then adjusted the format of Article 16 on the computer and established cross-device operation associations.
[0136] Intelligent preprocessing can be performed using the edge computing layer: ① Computer-side operation processing: In low-latency environments, state-based CRDTs are used directly to synchronize the 12th complete state (including modification records) to edge nodes (such as the edge computing layer mentioned above); ② Mobile-side operation processing: In high-latency environments, operation-based CRDTs are used, uploading only the merge command and operation logs, and edge nodes pre-generate merge previews; ③ Cross-device (special processing): Auditor's annotation operations are marked as "cross-device related operations", and the system automatically establishes a semantic link between the 12th modification and the annotation.
[0137] To detect and identify conflicts in the above operation instructions and changes, please refer to [link / reference]. Figure 2 , Figure 2 This is a schematic diagram of conflict points in contract document conflict handling provided in an embodiment of this application, such as... Figure 2As shown, there are three points of conflict (conflict content): First, "Article 12 modified on the computer" and "Article 12 in the auditor's comments"; Second, "Article 15 merged on the mobile device" and "Article 16 format adjusted by the auditor"; Third, the merging operation may cause other clauses referencing Article 15 to become invalid.
[0138] Key conflicts were identified as follows: First, conflicts between modification and annotation (direct object conflicts); second, conflicts between merging and formatting adjustments (indirect dependency conflicts). Subsequently, semantic features were annotated, and the conflict level of each operation was recorded: the conflict type for modification was content coverage, affecting a single clause, with high semantic intensity; the conflict type for merging was structural disruption, affecting multiple clauses, with medium semantic intensity; the conflict type for annotation was metadata conflict, affecting the annotation itself, with low semantic intensity.
[0139] By constructing a decision matrix to conduct a multi-dimensional evaluation of the conflicting content, scores were obtained for each of the four dimensions: timeliness (time priority), user permissions, semantic integrity, and network quality. See Table 2 below for details.
[0140] Table 2:
[0141]
[0142] The sources of the score values for each dimension in Table 2 above can be found in Table 3 below:
[0143] Table 3:
[0144]
[0145] The basic weights of the above four dimensions can be determined based on the scenario (for example, the basic weights for a contract editing scenario could be: timeliness 40%, permission weight 30%, semantic integrity 20%, and network quality 10%); they can also be adaptively adjusted according to the actual situation. For example, when high concurrency conflicts are detected, the timeliness weight can be temporarily increased (+15%), and when the operation involves legal clauses, the permission weight can be automatically increased to 50%.
[0146] The following is an example of how priority scores are calculated:
[0147] Modification operation number 12: Priority score = 90 × 0.4 + 80 × 0.3 + 95 × 0.2 + 90 × 0.1 = 88;
[0148] Merge operation #15: Priority score = 85 × 0.4 + 70 × 0.3 + 92 × 0.2 + 60 × 0.1 = 79.4;
[0149] Conflict resolution strategies: ① Conflict in Article 12: Retain the legal counsel's modifications, convert the auditor's comments to floating comment boxes, and add a marker indicating "Requires board approval"; ② Conflict in Articles 15-16: Perform the merger operation but retain the original version number of Article 15. The format adjustment will only apply to the new clauses after the merger, and all references to Article 15 will be automatically updated.
[0150] Multi-user consistency synchronization: ① PC: Instantly displays the 12th revised item, with a sidebar prompt "Mobile merge operation has been adapted," and the document structure tree is automatically refreshed; ② Mobile: Step-by-step synchronization, first quickly confirming that the merge operation has been received, loading the revision details in batches (adapting to network fluctuations), and then displaying the merged new clause, while the original 15th item is displayed as the historical version; ③ Auditing: Mobile phones and computers automatically synchronize the final state, annotations are automatically located in the revised clauses, and formatting adjustments are consistent across devices.
[0151] See Figure 3 , Figure 3 This is a schematic diagram of the structure of a document collaboration conflict resolution device provided in an embodiment of this application, as shown below. Figure 3 As shown, the document collaboration conflict resolution device 300 includes:
[0152] The acquisition module 301 is used to acquire multiple operation instructions executed by multiple user terminals on the collaborative document, as well as multiple change data generated after the execution of the multiple operation instructions;
[0153] The first processing module 302 is used to perform semantic analysis on the collaborative document, the multiple operation instructions and the multiple change data using a multimodal large model to obtain semantic analysis results, and to determine the conflict type of the multiple operation instructions and the conflict content of the multiple change data based on the semantic analysis results;
[0154] The second processing module 303 is used to determine the conflict handling method corresponding to the conflict content according to the conflict type, and adjust the conflict content according to the conflict handling method to obtain the first document.
[0155] Optionally, determining the conflict handling method corresponding to the conflict content based on the conflict type, and adjusting the conflict content according to the conflict handling method, includes at least one of the following:
[0156] In cases where the conflict type includes textual conflict, the conflict content is adjusted based on the syntax tree structure and the semantic analysis results.
[0157] When the conflict type includes image conflict, the overlapping area in the conflict content is identified by region mask contrast detection, and prompt information is added to the overlapping area.
[0158] In the case where the conflict type includes table conflict, a table version matrix is determined based on the conflict content and the change data, and the conflict content is adjusted according to the table version matrix.
[0159] Optionally, the step of acquiring multiple operation instructions executed by multiple user terminals on the collaborative document includes:
[0160] Within a preset time range, acquire multiple sets of operation instructions executed by multiple user terminals on collaborative documents, and acquire a preset number of the multiple operation instructions from the multiple sets of operation instructions in the form of a sliding window.
[0161] Optionally, the plurality of operation instructions may be multiple operation instructions obtained by merging similar instructions.
[0162] Optionally, the document collaboration conflict resolution device 300 may also include: a third processing module;
[0163] The third processing module is used to obtain the network latency of the multiple user terminals and the number of multiple operation commands, respectively.
[0164] If the network latency is less than a preset first threshold and the number of instructions is greater than a preset second threshold, the first document is sent to the plurality of user terminals respectively.
[0165] If the network latency is greater than or equal to a preset first threshold and the number of instructions is greater than a preset second threshold, the multiple operation instructions are adjusted according to the conflict content to obtain serialized operation instructions, and the serialized operation instructions are sent to the multiple user terminals respectively.
[0166] Optionally, the document collaboration conflict resolution device 300 may also include: a fourth processing module;
[0167] The fourth processing module is used to segment the collaborative document according to the semantic structure of the collaborative document and the device types of the multiple user terminals in a predetermined order to obtain multiple segmented documents.
[0168] The document conflict handling method is executed in parallel on the multiple fragmented documents to obtain the first document corresponding to each of the multiple fragmented documents;
[0169] The first documents corresponding to each of the multiple fragmented documents are integrated in the predetermined order to obtain the second document.
[0170] The document collaboration conflict resolution device 300 is designed to implement the various processes described above in the embodiments of the document collaboration conflict resolution method. The technical features are one-to-one and can achieve the same technical effect. To avoid repetition, it will not be described again here.
[0171] This application also provides an electronic device, including: a processor, a memory, and a program stored in the memory and executable on the processor. When the program is executed by the processor, it implements the various processes of the above-described document collaboration conflict handling method embodiments and achieves the same technical effect. To avoid repetition, it will not be described again here.
[0172] For details, see Figure 4 This application also provides an electronic device, including a bus 401, a transceiver 402, an antenna 403, a bus interface 404, a processor 405, and a memory 406.
[0173] The transceiver 402 is used to acquire multiple operation instructions executed by multiple user terminals on the collaborative document, as well as multiple change data generated after executing the multiple operation instructions;
[0174] The processor 405 is configured to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data using a multimodal large model to obtain semantic analysis results, and determine the conflict type of the multiple operation instructions and the conflict content of the multiple change data based on the semantic analysis results;
[0175] Based on the conflict type, determine the conflict handling method corresponding to the conflict content, and adjust the conflict content according to the conflict handling method to obtain the first document;
[0176] Optionally, determining the conflict handling method corresponding to the conflict content based on the conflict type, and adjusting the conflict content according to the conflict handling method, includes at least one of the following:
[0177] In cases where the conflict type includes textual conflict, the conflict content is adjusted based on the syntax tree structure and the semantic analysis results.
[0178] When the conflict type includes image conflict, the overlapping area in the conflict content is identified by region mask contrast detection, and prompt information is added to the overlapping area.
[0179] In the case where the conflict type includes table conflict, a table version matrix is determined based on the conflict content and the change data, and the conflict content is adjusted according to the table version matrix.
[0180] Optionally, the step of acquiring multiple operation instructions executed by multiple user terminals on the collaborative document includes:
[0181] Within a preset time range, acquire multiple sets of operation instructions executed by multiple user terminals on collaborative documents, and acquire a preset number of the multiple operation instructions from the multiple sets of operation instructions in the form of a sliding window.
[0182] Optionally, the plurality of operation instructions may be multiple operation instructions obtained by merging similar instructions.
[0183] Optionally, the processor 405 is further configured to acquire the network latency of the plurality of user terminals and the number of instructions of the plurality of operation instructions, respectively;
[0184] If the network latency is less than a preset first threshold and the number of instructions is greater than a preset second threshold, the first document is sent to the plurality of user terminals respectively.
[0185] If the network latency is greater than or equal to a preset first threshold and the number of instructions is greater than a preset second threshold, the multiple operation instructions are adjusted according to the conflict content to obtain serialized operation instructions, and the serialized operation instructions are sent to the multiple user terminals respectively.
[0186] Optionally, the processor 405 is further configured to segment the collaborative document in a predetermined order according to the semantic structure of the collaborative document and the device types of the multiple user terminals, resulting in multiple segmented documents;
[0187] The document conflict handling method is executed in parallel on the multiple fragmented documents to obtain the first document corresponding to each of the multiple fragmented documents;
[0188] The first documents corresponding to each of the multiple fragmented documents are integrated in the predetermined order to obtain the second document.
[0189] exist Figure 4 In this context, a bus architecture (represented by bus 401) is used. Bus 401 can include any number of interconnected buses and bridges, linking various circuits including one or more processors represented by processor 405 and memory represented by memory 406. Bus 401 can also link various other circuits such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and therefore will not be described further herein. Bus interface 404 provides an interface between bus 401 and transceiver 402. Transceiver 402 can be a single element or multiple elements, such as multiple receivers and transmitters, providing a unit for communicating with various other devices over a transmission medium. Data processed by processor 405 is transmitted over a wireless medium via antenna 403, which further receives data and transmits data to processor 405.
[0190] Processor 405 is responsible for managing bus 401 and general processing, and can also provide various functions, including timing, peripheral interface, voltage regulation, power management, and other control functions. Memory 406 can be used to store data used by processor 405 during operation.
[0191] Optionally, the processor 405 may be a central processing unit (CPU), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or a complex programmable logic device (CPLD).
[0192] This application also provides a computer-readable storage medium storing a computer program. When executed by a processor, this computer program implements the various processes of the above-described document collaboration conflict handling method embodiments and achieves the same technical effects. To avoid repetition, it will not be described again here. The computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, etc.
[0193] This application also provides a computer program product, including computer instructions. When executed by a processor, the computer instructions implement the various processes of the above-described document collaboration conflict handling method embodiments and achieve the same technical effects. To avoid repetition, they will not be described again here.
[0194] It should be noted that, 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 limitations, 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 that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.
[0195] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0196] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.
Claims
1. A method for handling document collaboration conflicts, characterized in that, The method includes: The system acquires multiple operation instructions executed by multiple user terminals on the collaborative document, as well as multiple change data generated after executing the multiple operation instructions. A multimodal large model is used to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data to obtain semantic analysis results. Based on the semantic analysis results, the conflict types of the multiple operation instructions and the conflict content of the multiple change data are determined. Based on the conflict type, determine the conflict handling method corresponding to the conflict content, and adjust the conflict content according to the conflict handling method to obtain the first document.
2. The method according to claim 1, characterized in that, The step of determining the conflict handling method corresponding to the conflict content based on the conflict type, and adjusting the conflict content according to the conflict handling method, includes at least one of the following: In cases where the conflict type includes textual conflict, the conflict content is adjusted based on the syntax tree structure and the semantic analysis results. When the conflict type includes image conflict, the overlapping area in the conflict content is identified by region mask contrast detection, and prompt information is added to the overlapping area. In the case where the conflict type includes table conflict, a table version matrix is determined based on the conflict content and the change data, and the conflict content is adjusted according to the table version matrix.
3. The method according to claim 1 or 2, characterized in that, The step of acquiring multiple operation instructions executed by multiple user terminals on collaborative documents includes: Within a preset time range, acquire multiple sets of operation instructions executed by multiple user terminals on collaborative documents, and acquire a preset number of the multiple operation instructions from the multiple sets of operation instructions in the form of a sliding window.
4. The method according to claim 1 or 2, characterized in that, The multiple operation instructions are multiple operation instructions obtained by merging similar instructions.
5. The method according to claim 1 or 2, characterized in that, The method further includes: The network latency of the multiple user terminals and the number of multiple operation commands are obtained respectively; If the network latency is less than a preset first threshold and the number of instructions is greater than a preset second threshold, the first document is sent to the plurality of user terminals respectively. If the network latency is greater than or equal to a preset first threshold and the number of instructions is greater than a preset second threshold, the multiple operation instructions are adjusted according to the conflict content to obtain serialized operation instructions, and the serialized operation instructions are sent to the multiple user terminals respectively.
6. The method according to claim 1, characterized in that, The method further includes: The collaborative document is divided into multiple fragmented documents according to a predetermined order based on the semantic structure of the collaborative document and the device types of the multiple user terminals. The document conflict handling method is executed in parallel on the multiple fragmented documents to obtain the first document corresponding to each of the multiple fragmented documents; The first documents corresponding to each of the multiple fragmented documents are integrated in the predetermined order to obtain the second document.
7. A document collaboration conflict resolution device, characterized in that, The device includes: The acquisition module is used to acquire multiple operation instructions executed by multiple user terminals on the collaborative document, as well as multiple change data generated after the execution of the multiple operation instructions; The first processing module is used to perform semantic analysis on the collaborative document, the multiple operation instructions, and the multiple change data using a multimodal large model to obtain semantic analysis results, and to determine the conflict type of the multiple operation instructions and the conflict content of the multiple change data based on the semantic analysis results. The second processing module is used to determine the conflict handling method corresponding to the conflict content according to the conflict type, and adjust the conflict content according to the conflict handling method to obtain the first document.
8. An electronic device, characterized in that, include: A processor, a memory, and a program stored in the memory and executable on the processor, wherein the program, when executed by the processor, implements the steps of the method as described in any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the method as described in any one of claims 1 to 6.
10. A computer program product, characterized in that, Includes computer instructions that, when executed by a processor, implement the steps of the method as described in any one of claims 1 to 6.