Document specification reference checking method and system based on WPS loading item and electronic equipment
By using preset wildcards and dynamic databases in WPS add-ons, quickly filtering and checking the correctness of standard names and numbers in documents, solving the problem of time-consuming and labor-intensive and difficult to guarantee accuracy in manual review, and achieving efficient and accurate standard reference inspection.
Patent Information
- Application Number
- CN202510543624.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-28
- Publication Date
- 2025-05-30
AI Technical Summary
The prior art checks the specification names and numbers cited in documents through manual review, which is time-consuming and labor-intensive and difficult to ensure accuracy.
The document specification reference check method based on WPS add-ons is used to filter out the specification name and number in the document through preset wildcards, and match it with the current specification in the preset database, generate an error list and output it.
It realizes rapid search and correctness check of standardized names and numbers in documents, improves efficiency and accuracy, and reduces the time spent on review.
Smart Images

Figure CN120067242A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and more particularly to a document specification reference checking method, system and electronic device based on a WPS add-in. Background Art
[0002] In technical reports, it is necessary to cite multiple specification names and numbers. For example, in the process of architectural design or other professional design, it is necessary to follow national or industry technical specifications, and in the text of technical reports such as engineering feasibility studies, preliminary designs, and construction drawings, the names and numbers of the current technical specifications must be indicated. The format for citing specifications is usually "Specification Name" (Specification Number)". For example, if a specification for the water transport industry is called "Seaport General Design Specification" and the specification number is "JTS 165-2013" ("JTS" indicates mandatory specifications for the water transport industry, "165" indicates that the specification is serial number 165, and "2013" indicates the year the specification was issued), then it should be cited in the report text as "Seaport General Design Specification" (JTS 165-2013).
[0003] With the changes in the external environment such as technological advancement, changes in safety standards, and the application of new materials, specifications will be invalidated or revised and updated, and specification numbers will also be updated irregularly, so it is easy to have errors in specification names or specification numbers. In a technical report, there are often more than a hundred standards that need to be cited, and they are distributed in different chapters of the report. After the new version of the specification is implemented, the report text should delete the reference to the obsolete version of the specification and quote the new version of the specification name and number. However, at present, manual review is mainly used to check and modify the standard names and numbers in the report text. This method is not only time-consuming and labor-intensive, but also prone to omissions. Therefore, there is an urgent need for a method that can quickly review all specification names and numbers in a document to ensure the correctness of the specification references in the report text and reduce the time spent on review. Summary of the Invention
[0004] The purpose of the present invention is to provide a document specification reference checking method, system and electronic device based on WPS add-in, so as to solve the problems faced by the existing technology of checking the names and numbers of specifications referenced in documents through manual review, which is time-consuming and labor-intensive, and difficult to ensure accuracy.
[0005] In a first aspect, the present invention provides a document specification reference checking method based on a WPS add-in, comprising: Get a preset wildcard, which is a structured expression "[!《》]@preset keyword" for matching the name of a specification enclosed in quotation marks. The preset keywords include: specification, guideline, rule, standard, requirement, notice, and announcement. Based on the preset wildcard, a target specification name is filtered out through the search interface of WPS, where the target specification name is the specification name contained in the document to be checked; Based on the target specification name, the target specification number contained in the document to be checked is screened out, where the target specification number is a specification number corresponding to the target specification name; Based on whether there is a current specification matching the target specification name and the target specification number in the preset database, the referenced specifications in the document to be checked are checked. The preset database stores the name of the current specification, the corresponding specification number, the release date and the valid status field, and is dynamically updated.
[0006] In a preferred solution, filtering out the target specification name through the WPS search interface based on the preset wildcard includes: Based on the preset wildcard, preselected specification names are filtered out through the search interface of WPS; Regular expressions are used to filter out characters other than Chinese characters in the preselected standard name to obtain the target standard name.
[0007] In a preferred embodiment, the step of filtering out the target specification number contained in the document to be checked based on the target specification name includes: Based on the position where the target specification name appears in the document to be checked, obtaining a character string of a preset length following the target specification name in the document to be checked; Using a regular expression to filter out characters other than English letters in the character string to obtain a preselected standard number; The English letters in the preselected specification number are converted into uppercase to obtain the target specification number.
[0008] In a preferred embodiment, the checking of the referenced specification in the document to be checked based on whether there is an existing specification matching the target specification name and the target specification number in the preset database includes: Determining whether a first target current specification exists in the preset database, where the first target current specification is a current specification whose name matches the name of the target specification; If the first target current specification exists, determining whether the specification number of the first target current specification matches the target specification number; If the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output.
[0009] In a preferred embodiment, if the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, including: If the first target current specification does not exist in the preset database, searching the preset database for a second target current specification and specification number, the second target current specification being the current specification with the highest similarity to the target specification; Generate and output an error list based on the target specification name, the target specification number, and the name and specification number of the second target current specification; If the specification number of the first target current specification does not match the target specification number, an error list is generated and output based on the target specification name, the target specification number, the name of the first target current specification and the specification number of the target specification.
[0010] In a preferred embodiment, if the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, then generating and outputting an error list further includes: Obtaining location information of the target specification name in the document to be checked; The position information is added to the error list so that when the target specification name in the error list is clicked, the position where the target specification name appears in the document to be checked is located.
[0011] In a preferred embodiment, if the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, then generating and outputting an error list further includes: If the first target current specification does not exist in the preset database, generating a character string "Specification Name Error" and adding it to the error list; If the specification number of the first target current specification does not match the target specification number, a character string "Specification number error" is generated and added to the error list.
[0012] In a preferred embodiment, if the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, then generating and outputting an error list further includes: Generate a virtual modification key and add it to the error list; Among them, the virtual modification button associates the target specification name and the target specification number with the name and specification number of the second target current specification respectively, and associates the target specification number with the specification number of the first target current specification, and when triggered, replaces the target specification name and the target specification number in the document to be checked with the name and specification number of the second target current specification respectively, or replaces the target specification number with the specification number of the first target current specification.
[0013] In a second aspect, the present invention provides a document specification reference checking system based on a WPS add-in, comprising: A collection unit is configured to obtain a preset wildcard, wherein the preset wildcard is a structured expression "[!《》]@preset keyword", which is used to match the specification name enclosed in quotation marks. The preset keyword may include: specification, guideline, rule, standard, requirement, notice, and announcement; A first screening unit is configured to screen out target specification names through a search interface of the WPS based on a preset wildcard, where the target specification names are specification names contained in the document to be checked; A second screening unit is configured to screen out a target specification number contained in the document to be checked based on the target specification name, where the target specification number is a specification number corresponding to the target specification name; The checking unit is used to check the referenced specifications in the document to be checked based on whether there is a current specification matching the target specification name and the target specification number in the preset database. The preset database stores the name of the current specification, the corresponding specification number, the release date and the valid status field, and is dynamically updated.
[0014] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and runnable on the processor, wherein when the processor executes the program, the document specification reference checking method based on the WPS add-in as described above is implemented.
[0015] To achieve the above-mentioned objectives, the present invention provides a document specification reference checking method, system, and electronic device based on a WPS add-in. After obtaining a preset wildcard, the system uses the preset wildcard to filter out the specification name contained in the document to be checked as the target specification name through the WPS search interface. Then, based on the target specification name, the system filters out the specification number corresponding to the target specification name contained in the document to be checked as the target specification number. Finally, based on whether there is an existing specification matching the target specification name and target specification number in a preset database storing the names and corresponding specification numbers of existing specifications, the system checks the referenced specifications in the document to be checked. The preset wildcard is a structured expression "[!《》]@preset keyword," which is used to match the specification name enclosed in quotation marks. The preset keywords include: specification, guideline, rule, standard, requirement, notice, and announcement. That is, by developing a WPS add-in to quickly find all specification names and numbers in a document and compare them with the built-in database, a rapid check of the correctness of the referenced specifications in the document to be checked is achieved, effectively improving efficiency and ensuring accuracy compared to manual review, and reducing review time. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] Figure 1 A flowchart of a document specification reference checking method based on a WPS add-in is provided for the implementation of the present invention.
[0017] Figure 2 A diagram illustrating the meaning of a preset wildcard instance provided in an embodiment of the present invention.
[0018] Figure 3 The present invention provides a specific flow chart for checking and modifying a report document reference specification using the WPS add-in-based document reference checking method provided in an embodiment of the present invention.
[0019] Figure 4 The software initial interface diagram is an example of applying the document specification reference checking method based on WPS add-in provided by an embodiment of the present invention.
[0020] Figure 5 For click Figure 4 After clicking the Start Search button, the error list interface generated for the instance document is shown.
[0021] Figure 6 For click Figure 5 After the second line shown, select the interface image corresponding to the instance document.
[0022] Figure 7 For click Figure 5 The interface diagram of the instance document displayed after the corresponding position of the instance document is modified after clicking the "One-click modification" button on the second row shown.
[0023] Figure 8 A structural diagram of a document specification reference checking system based on a WPS add-in provided in an embodiment of the present invention.
[0024] Figure 9 A schematic structural diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0025] The present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.
[0026] It is understandable that in a technical report, there are often more than a hundred standards that need to be cited, and they are distributed in different chapters of the report. The currently commonly used manual review method is used to check the specifications cited in the report. It is necessary to read the report from beginning to end, list all the specification names and numbers cited in the report, and then check one by one to see if the cited specifications are current. This method is very inefficient and prone to omissions and errors.
[0027] Based on this, an embodiment of the present invention provides a document specification reference checking method based on a WPS add-in to achieve rapid retrieval and acquisition of all specification names and numbers in a document, and by comparing with a preset database, check the correctness of the referenced specification names and numbers in the document to be checked, thereby solving the problem of time-consuming and labor-intensive manual review and checking of document specification references, and the inability to guarantee accuracy.
[0028] The document specification reference checking method based on WPS add-in provided by the present invention is executed on an electronic device, which can be an intelligent terminal device such as a laptop, a personal computer, and a tablet computer. Of course, in some cases, it can also be a server on the network side.
[0029] like Figure 1 As shown, the document specification reference checking method based on the WPS add-in provided in an embodiment of the present invention mainly includes the following steps: 110. Get the preset wildcard.
[0030] Among them, the preset wildcard is the structured expression "[!《》]@preset keyword", which is used to match the standard name wrapped in quotation marks. The preset keywords include: standard, guide, rule, standard, requirement, notice and announcement.
[0031] 120. Based on the preset wildcard, filter out the target specification name through the WPS search interface.
[0032] Wherein, the target specification name is the specification name contained in the document to be checked; 130. Based on the target specification name, filter out the target specification number contained in the document to be checked.
[0033] Among them, the target specification number is the specification number corresponding to the target specification name.
[0034] 140. Checking the cited specifications in the to-be-checked document based on whether there is a current specification matching the target specification name and the target specification number in the preset database.
[0035] Among them, the preset database stores the name, corresponding specification number, release date and effective status field of the current specification, and is dynamically updated.
[0036] Specifically, the current specification refers to the effective version specification that is newly released and has not been replaced or repealed.
[0037] In some possible embodiments, when applying the method for checking the citation of document specifications based on the WPS add-in provided in the above embodiments to check the cited specifications and numbers in the to-be-checked document, the user only needs to determine the preset wildcard and then open the document to be checked for errors, that is, the to-be-checked document, in the WPS software, and then click the "Start Search" button of the program, so that the electronic device can call the search interface Application.Selection.Find() of the WPS software, use the preset wildcard as the search keyword, and use the wildcard method to search all the cited specification names in the to-be-checked document. After obtaining all the cited specification names in the to-be-checked document, further obtain the corresponding specification numbers based on the specification names. Finally, by comparing the obtained specification names and numbers with the preset database storing the names and corresponding numbers of the current specifications one by one, the automatic search and check of the cited specifications in the to-be-checked document are realized.
[0038] It can be understood that the current specifications are usually named as "XX Specification", "XX Guide", etc., and the common format for citation is "《Specification Name》(Specification Number)". Therefore, by setting the preset wildcard as the structured expression 《[!《》]@Preset Keyword》, and the keywords include: specification, guide, rule, standard, requirement, notice and announcement. All the specification names wrapped in angle brackets in the to-be-checked document can be comprehensively matched.
[0039] In some possible embodiments, taking the preset keyword as "specification" as an example, the meaning of the preset wildcard "《[!《》]@Specification》" is specifically described. That is: such as Figure 2As shown, the first character "《" indicates that the character to be searched should start with a left book title mark, the square brackets " [] " indicate matching any single character within the brackets, and the exclamation mark "!" within the square brackets indicates "exclusion" or "not", that is, matching any character not within the square brackets. Therefore, "!《》" means excluding the characters "《" and "》", that is, [!《》] means that the string to be searched cannot include duplicate book title marks. The "@" is one of the wildcards, indicating that the previous pattern can match one or more characters. The final "规范》" means that the character should end with the two characters "规范" plus the right half of the book title mark. Therefore, based on the preset wildcard "《[!《》]@规范》", all strings containing "《……规范》" in the document to be checked can be screened out through the search interface of WPS, that is, the specification names cited in the document to be checked.
[0040] Furthermore, by setting that the preset database can be dynamically updated, it can adapt to the continuous changes of the current specification names and versions.
[0041] Specifically, in some possible embodiments, taking the fields included in the preset database as an example, including specification name, specification number, release date, and valid status fields, the storage form of a certain specification in the preset database can be as shown in Table 1: Table 1 Instance table structure of the preset database
[0042] In an optional embodiment, based on the preset wildcard, the target specification names are screened out through the search interface of WPS, including: Based on the preset wildcard, the preselected specification names are screened out through the search interface of WPS; Using regular expressions to filter out other characters except Chinese characters in the preselected specification names to obtain the target specification names.
[0043] In this embodiment, by filtering out other characters except Chinese characters in the string found based on the preset wildcard "《[!《》]@preset keyword》", and then taking the remaining part as the target specification name, the accuracy of the screened target specification name is improved.
[0044] It can be understood that, as mentioned above, the format of the specification citation is usually "《Specification Name》 (Specification Number)". Based on this, in an optional embodiment, based on the target specification name, the target specification numbers included in the document to be checked are screened out, including: Based on the position where the target specification name appears in the document to be checked, obtain the string with a preset length after the target specification name in the document to be checked; Using regular expressions to filter out other characters except English letters in the string to obtain the preselected specification numbers; Convert the English letters in the pre-selected specification number into uppercase to obtain the target specification number.
[0045] Specifically, because the specification number follows the specification name, after obtaining the target specification name, a character string of a preset length following the target specification name in the document to be checked is obtained based on its position in the document to be checked. This character string will contain the specification number. By converting the English letters in the pre-selected specification number to uppercase, false positives caused by the case of English letters in the specification number can be avoided.
[0046] Furthermore, by using regular expressions to filter out characters other than English in the string and then converting English into uppercase, the target specification number can be obtained.
[0047] It is understandable that the preset length can be set according to the length of the specification number of the current specification in the field of use, ensuring that the preset length is set greater than the maximum length of the specification number in the current specification in the application field.
[0048] It should be noted that a specification reference includes two parts: the specification name and the specification number. Therefore, the check of the specification reference in the document must also include these two parts. Based on this, in an optional embodiment, based on whether there is an existing specification matching the target specification name and target specification number in the preset database, the check of the specification reference in the document to be checked includes: Determine whether the first target current specification exists in the preset database.
[0049] The first target current specification is the current specification whose name matches the target specification name; If a first target current specification exists, determining whether the specification number of the first target current specification matches the target specification number; If the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output.
[0050] In this embodiment, when checking the referenced specifications in the document to be checked based on whether there is a current specification matching the target specification name and the target specification number in the preset database, it is first determined whether there is a current specification matching the target specification name, i.e., the first target current specification, in the preset database. Then, after determining that the first target current specification exists in the preset database, it is further determined whether the specification number of the first target current specification matches the target specification number. Otherwise, an error list is directly generated and output, thereby improving the efficiency of checking document specification references.
[0051] It should be noted that the preset database is pre-set and, in some possible embodiments, can be generated by obtaining the names and numbers of all currently valid versions of the specification and then storing them in the database. Specifically, the preset database includes at least two columns, "Specification Name" and "Specification Number," which correspond one to one.
[0052] Furthermore, when it is determined that the first target current specification does not exist in the preset database, it means that the specification referenced by the document to be checked is not the current valid version of the specification. When it is determined that the specification number of the first target current specification does not match the target specification number, it means that although the specification name referenced by the document to be checked is the current valid version of the specification, the specification number is not valid. Therefore, the corresponding specifications referenced in the document to be checked need to be modified, that is, an error list is generated and output.
[0053] Furthermore, by refining the error list, users can more accurately understand and correct reference errors in the document to be checked. In one optional embodiment, if the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, including: If the first target current specification does not exist in the preset database, the second target current specification and specification number are searched in the preset database.
[0054] Among them, the second target current specification is the current specification whose name is most similar to the target specification name.
[0055] Specifically, the similarity calculation may adopt the Bitap algorithm.
[0056] Generate and output an error list based on the target specification name, target specification number, name and specification number of the second target current specification; If the specification number of the first target current specification does not match the target specification number, an error list is generated and output based on the target specification name, the target specification number, the name of the first target current specification, and the specification number of the target specification.
[0057] In this embodiment, when it is determined that the first target current specification does not exist in the preset database, the current specification and specification number with the highest similarity between the name and the target specification name is searched in the preset database as the second target current specification, and then an error list is generated and output based on the target specification name, target specification number, and the name and specification number of the second target current specification. When it is determined that the target specification name referenced in the document to be checked is not the current specification, the second target current specification can be provided to the user as a reference to facilitate the user to confirm whether the erroneous specification referenced in the document to be checked should be the second target current specification.
[0058] By generating and outputting an error list based on the target specification name, target specification number, the name of the first target current specification and the specification number of the target specification when it is determined that the specification number of the first target current specification does not match the target specification number, the correct specification number can be provided to the user, making it easier for the user to confirm and modify.
[0059] It is understandable that when it is determined that the name or number of the specification referenced in the document to be checked is incorrect, if the location of the erroneous specification can be quickly located, it can further facilitate the user to check and modify it, thereby improving the inspection efficiency.
[0060] Based on this, in an optional embodiment, if the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, further comprising: Get the location information of the target specification name in the document to be checked; Adds location information to the error list so that when you click the target specification name in the error list, you can locate the location where the target specification name appears in the document to be checked.
[0061] In this embodiment, by adding the location information of the target specification name in the document to be checked to the error list, when the user clicks the error list, he can jump to the location where the target specification name appears in the document to be checked, thereby facilitating the user's verification and modification.
[0062] Furthermore, the error type can be clarified for the user, which can also improve the user's modification efficiency. Based on this, in an optional embodiment, if the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, which also includes: If the first target current specification does not exist in the preset database, a character string "Specification Name Error" is generated and added to the error list; If the specification number of the first target current specification does not match the target specification number, a string "Specification Number Error" is generated and added to the error list.
[0063] Furthermore, if the user can directly replace the incorrect specification name and / or specification number with the correct specification name and / or specification number when determining that the specification reference is incorrect, the modification efficiency can be effectively improved and the labor can be reduced. Based on this, in an optional embodiment, if the first target current specification does not exist or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, which also includes: Generate virtual modification buttons and add them to the error list; Among them, the virtual modification button associates the target specification name and the target specification number with the name and the specification number of the second target current specification respectively, associates the target specification number with the specification number of the first target current specification, and when triggered, replaces the target specification name and the target specification number in the document to be inspected with the name and the specification number of the second target current specification respectively, or replaces the target specification number with the specification number of the first target current specification.
[0064] Specifically, by setting a virtual modification button that associates the target specification name and the target specification number with the name and the specification number of the second target current specification respectively, and associates the target specification number with the specification number of the first target current specification, when the virtual modification button is clicked, it is possible to achieve one-click modification of the cited specifications in the document to be inspected.
[0065] In some possible embodiments, the replacement is achieved through the text replacement interface Range.Text.Replace() of the WPS software to achieve in-situ replacement and retain the original format.
[0066] The following uses a specific example to illustrate the specific process of checking and modifying the cited specifications of a report document by using the document specification citation checking method based on the WPS add-in provided in the above embodiments.
[0067] As Figure 3 shown, it specifically includes the following processes: Data preparation: Obtain the names and numbers of all currently valid version specifications, store them in a database, and form a preset database. Among them, it contains two columns, "specification name" and "specification number", and they correspond one by one.
[0068] Obtain the specification name string in the report document: The user opens the document to be checked in the WPS software. After clicking the "Start Search" button of the program, use the search interface Application.Selection.Find() of the WPS software and start searching using the wildcard method. The search keyword is set to "《[!《》]@Specification》".
[0069] Obtain the specification number string in the original document: After successfully obtaining the specification name string, obtain the string with a length of 20 characters after this string, filter out the characters other than numbers and English letters, and then convert all English letters to uppercase as the specification number, string 2.
[0070] Check whether the specification name matches the database: Search for string 1 in the "specification name" column of the database: 1. If string 1 is not found in the query, use Application.Selection.Range.Start to obtain the position of the original document corresponding to string 1, and search for the value with the highest similarity to string 1 in the "Specification Name" column of the database in a fuzzy matching manner. Return the corresponding "Specification Name" in the database as string 3, and the corresponding "Specification Number" in the database as string 4. Set "Specification Name Error" as string 5. Then skip the next process and directly proceed to the next-next process.
[0071] 2. If string 1 is found in the query, proceed to the next process.
[0072] Check whether the specification number matches the database: Search for string 2 in the "Specification Number" column of the database: 3. If string 2 is not found in the query, use Application.Selection.Range.Start to obtain the position of the original document corresponding to string 1, return the "Specification Name" in the database that matches string 1 as string 3, and the corresponding "Specification Number" in the database as string 4. Set "Specification Number Error" as string 5. Then proceed to the next process.
[0073] 4. If string 2 is found in the query, it means that both the obtained specification name and specification number are correct. Skip to the next-next process.
[0074] Add string 1 to the "Specification Name in Original Document" column in the display list, which is the error list, add string 2 to the "Specification Number in Original Document" column in the display list, add string 3 to the "Specification Name in Database" column in the display list, add string 4 to the "Specification Number in Database" column in the display list, and add string 5 to the "Error Type" column in the display list.
[0075] Continue to obtain the next search result of the search keyword "《[!《》]@Specification》", start repeating from obtaining the specification name string in the report document by repeating the above process until the search of the entire document is completed, and then proceed to the next process.
[0076] Display the display list on the page. When the user double-clicks a list row, set Application.ActiveDocument.Range(start, start + 10).Select(), where start is the original document position corresponding to string 1. This selects string 1 in the original document, allowing the user to jump to the corresponding position in the original document. The user can directly click the "One-click Modify" button to replace the incorrect specification name (string 1) and incorrect specification number (string 2) in the original document with the specification name (string 3) and specification number (string 4) in the database.
[0077] The software interface example when used is as follows: Figures 4 to 7 As shown. Among them, Figure 4 This is the initial interface of the software. After clicking the "Start Search" button, the following information will be displayed on the page: Figure 5 Double-click the corresponding row (e.g. row 2) in the list of possible incorrect specification results, and the corresponding position of the original document (e.g. Figure 6 As shown), if you click the "One-click Modify" button corresponding to the item, a confirmation dialog box will pop up. After the user clicks confirm, the original document will be automatically modified according to the correct value in the database to prevent misoperation. The result after modification is as follows: Figure 7 .Depend on Figure 7 It can be seen that the incorrect specification number "JTJ144-1-2010" has been changed to the correct specification number "JTS 144-1-2010" In summary, the document specification reference checking method based on the WPS add-in provided by the above embodiment, on the one hand, by adopting the wildcard method, can efficiently obtain the names and numbers of all referenced specifications in the report, thereby avoiding the omission problem that is easy to occur when searching for all referenced specifications in the report through manual review; on the other hand, after obtaining all referenced specifications in the report, by batch comparison with a preset database (containing the names and numbers of all currently valid specifications), all items not included in the database are automatically detected and listed as suspected error items, thereby avoiding the need to search and compare one by one through manual review, which makes the process cumbersome and inefficient; on the other hand, by adding location information and generating a virtual modification button, on the error summary page, double-clicking any error item can directly jump to the corresponding position in the document, and when it is determined that modification is required, the incorrect specification name and / or specification number can be automatically corrected by clicking the button, thereby avoiding the problem of manual modification after discovering specification reference errors in the report through manual review, which is inefficient. In other words, a convenient, easy-to-use, and accurate method for checking specification names and numbers in documents is provided. The synergy of a WPS add-in, structured wildcards, and a dynamic database addresses the pain points of manual review of specification validity. Experiments comparing manual review (taking an average of one hour per document) with this method (completed within five minutes) have increased the error detection rate from 60% to 95%.
[0078] The following is an introduction to the document specification reference checking system based on the WPS add-in provided in an embodiment of the present invention. The document specification reference checking system based on the WPS add-in described below can be considered as a module architecture for implementing the document specification reference checking method based on the WPS add-in provided in an embodiment of the present invention; the content described below can be cross-referenced with the above.
[0079] Optional, see Figure 8 , Figure 8 This is a structural block diagram of a document specification reference checking system based on a WPS add-in provided by an embodiment of the present invention. The system may include: The collection unit 10 is used to obtain a preset wildcard, which is a structured expression "[!《》]@preset keyword" for matching the name of the specification enclosed in quotation marks. The preset keywords include: specification, guideline, rule, standard, requirement, notice, and announcement; The first screening unit 20 is configured to screen out target specification names through a search interface of the WPS based on a preset wildcard, where the target specification names are specification names contained in the document to be checked; The second screening unit 30 is used to screen out the target specification number contained in the document to be checked based on the target specification name, where the target specification number is the specification number corresponding to the target specification name; The checking unit 40 is used to check the referenced specifications in the document to be checked based on whether there is an existing specification matching the target specification name and target specification number in the preset database. The preset database stores the name of the existing specification, the corresponding specification number, the release date and the valid status field, and is dynamically updated.
[0080] Optionally, the first screening unit 20 is specifically configured to: Based on the preset wildcard, pre-selected specification names are filtered through the WPS search interface; Regular expressions are used to filter out characters other than Chinese characters in the pre-selected standard names to obtain the target standard names.
[0081] Optionally, the second screening unit 30 is specifically configured to: Based on the position where the target specification name appears in the document to be checked, obtaining a character string of a preset length following the target specification name in the document to be checked; Use regular expressions to filter out characters other than English letters in the string to obtain the preselected standard number; Convert the English letters in the pre-selected specification number into uppercase to obtain the target specification number.
[0082] Optionally, the inspection unit 40 is specifically configured to: Determining whether a first target current specification exists in a preset database, the first target current specification being a current specification whose name matches the target specification name; If a first target current specification exists, determining whether the specification number of the first target current specification matches the target specification number; If the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output.
[0083] Optionally, the inspection unit 40 is more specifically configured to: If the first target current specification does not exist in the preset database, then the second target current specification and specification number are searched in the preset database. The second target current specification is the current specification with the highest similarity to the target specification name. Generate and output an error list based on the target specification name, target specification number, name and specification number of the second target current specification; If the specification number of the first target current specification does not match the target specification number, an error list is generated and output based on the target specification name, the target specification number, the name of the first target current specification, and the specification number of the target specification.
[0084] Optionally, the inspection unit 40 is further configured to: Get the location information of the target specification name in the document to be checked; Adds location information to the error list so that when you click the target specification name in the error list, you can locate the location where the target specification name appears in the document to be checked.
[0085] Optionally, the inspection unit 40 is further configured to: If the first target current specification does not exist in the preset database, a character string "Specification Name Error" is generated and added to the error list; If the specification number of the first target current specification does not match the target specification number, a string "Specification Number Error" is generated and added to the error list.
[0086] Optionally, the inspection unit 40 is further configured to: Generate virtual modification buttons and add them to the error list; Among them, the virtual modification button associates the target specification name and target specification number with the name and specification number of the second target current specification respectively, and associates the target specification number with the specification number of the first target current specification, and when triggered, replaces the target specification name and target specification number in the document to be checked with the name and specification number of the second target current specification respectively, or replaces the target specification number with the specification number of the first target current specification.
[0087] Below, reference Figure 9 To describe the electronic device provided by the embodiment of the present application, the electronic device provided by the embodiment may include: at least one processor 100, at least one communication interface 200, at least one memory 300 and at least one communication bus 400; In the embodiment of the present invention, the number of the processor 100, the communication interface 200, the memory 300, and the communication bus 400 is at least one, and the processor 100, the communication interface 200, and the memory 300 communicate with each other through the communication bus 400; obviously, Figure 9 The communication connections shown for the processor 100, communication interface 200, memory 300, and communication bus 400 are merely optional; Optionally, the communication interface 200 may be an interface of a communication module, such as an interface of a GSM module; the processor 100 may be a central processing unit (CPU), or an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement an embodiment of the present invention.
[0088] The memory 300 may include a high-speed RAM memory, and may also include a non-volatile memory (non-volatile memory), such as at least one disk memory.
[0089] The processor 100 is specifically configured to execute an application program in the memory to implement the steps of the above-mentioned WPS add-in-based document specification reference checking method.
[0090] In addition, an embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the document specification reference checking method based on the WPS add-in provided by the above methods is implemented.
[0091] The above embodiments are provided for illustrative purposes only and are not intended to limit the scope of implementation. Those skilled in the art will readily appreciate that other variations or modifications based on the above descriptions are possible. It is not necessary and impossible to provide an exhaustive list of all implementations. Obvious variations or modifications arising therefrom remain within the scope of protection of the present invention.
Claims
1. A document specification reference checking method based on WPS add-in, characterized in that: include: Get a preset wildcard, which is a structured expression "[!《》]@preset keyword", used to match the specification name wrapped in book title quotation marks, and the preset keywords include: specification, guideline, rule, standard, requirement, notice and announcement; Based on the preset wildcard, a target specification name is screened out through a search interface of WPS, where the target specification name is a specification name contained in the document to be checked; Based on the target specification name, filter out the target specification number contained in the document to be checked, the target specification number being the specification number corresponding to the target specification name; Based on whether there is a current specification matching the target specification name and the target specification number in the preset database, the referenced specification in the document to be checked is checked. The preset database stores the name of the current specification, the corresponding specification number, the release date and the effective status field, and is dynamically updated.
2. The document specification reference checking method based on WPS add-in according to claim 1 is characterized in that: The method of filtering out the target specification name based on the preset wildcard through the search interface of WPS includes: Based on the preset wildcard, pre-selected specification names are filtered out through the search interface of WPS; Regular expressions are used to filter out characters other than Chinese characters in the pre-selected standard name to obtain the target standard name.
3. The document specification reference checking method based on WPS add-in according to claim 1 is characterized in that: The step of filtering out the target specification number contained in the document to be checked based on the target specification name includes: Based on the position where the target specification name appears in the document to be checked, obtaining a character string of a preset length after the target specification name in the document to be checked; Using regular expressions to filter out characters other than English letters in the string to obtain a pre-selected standard number; The English letters in the pre-selected specification number are converted into uppercase to obtain the target specification number.
4. The document specification reference checking method based on WPS add-in according to claim 1 is characterized in that: The checking of the referenced specification in the document to be checked based on whether there is an existing specification matching the target specification name and the target specification number in the preset database includes: Determining whether there is a first target current specification in the preset database, the first target current specification being a current specification whose name matches the name of the target specification; If the first target current specification exists, determining whether the specification number of the first target current specification matches the target specification number; If the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output.
5. The document specification reference checking method based on WPS add-in according to claim 4 is characterized in that: If the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, including: If the first target current specification does not exist in the preset database, searching the preset database for a second target current specification and specification number, the second target current specification being the current specification with the highest similarity to the target specification; Based on the target specification name, the target specification number, the name and specification number of the second target current specification, an error list is generated and outputted; If the specification number of the first target current specification does not match the target specification number, an error list is generated and output based on the target specification name, the target specification number, the name of the first target current specification and the specification number of the target specification.
6. The document specification reference checking method based on WPS add-in according to claim 5 is characterized in that: If the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, and further includes: Obtaining the location information of the target specification name in the document to be checked; The position information is added to the error list so that when the target specification name in the error list is clicked, the position where the target specification name appears in the document to be checked is located.
7. The document specification reference checking method based on WPS add-in according to claim 6 is characterized in that: If the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, and further includes: If the first target current specification does not exist in the preset database, a character string "Specification Name Error" is generated and added to the error list; If the specification number of the first target current specification does not match the target specification number, a character string "Specification number error" is generated and added to the error list.
8. The document specification reference checking method based on WPS add-in according to claim 7 is characterized in that: If the first target current specification does not exist, or the specification number of the first target current specification does not match the target specification number, an error list is generated and output, and further includes: Generate a virtual modification key and add it to the error list; Among them, the virtual modification button associates the target specification name and the target specification number with the name and specification number of the second target current specification respectively, and associates the target specification number with the specification number of the first target current specification, and when triggered, replaces the target specification name and the target specification number in the document to be checked with the name and specification number of the second target current specification respectively, or replaces the target specification number with the specification number of the first target current specification.
9. A document specification reference checking system based on WPS add-in, characterized in that: include: A collection unit, used to obtain a preset wildcard, wherein the preset wildcard is a structured expression "[!《》]@preset keyword", which is used to match the specification name wrapped in book title quotation marks, and the preset keywords include: specification, guideline, rule, standard, requirement, notice and announcement; A first screening unit, configured to screen out a target specification name through a search interface of the WPS based on a preset wildcard, wherein the target specification name is a specification name contained in the document to be checked; A second screening unit, configured to screen out a target specification number contained in the document to be checked based on the target specification name, wherein the target specification number is a specification number corresponding to the target specification name; The checking unit is used to check the referenced specifications in the document to be checked based on whether there is a current specification matching the target specification name and the target specification number in the preset database. The preset database stores the name of the current specification, the corresponding specification number, the release date and the effective status field, and is dynamically updated.
10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the document specification reference checking method based on the WPS add-in as described in any one of claims 1 to 8 is implemented.
Citation Information
Patent Citations
International standardization organization file issuing management system and method
CN119250432A
Cited By
Engineering design document compliance inspection method, electronic equipment and storage medium
CN120509388A