A method, device and medium for generating product traceability information based on identification resolution
By generating product traceability identification code and determining the parsing interface, the problem that the existing technology cannot be applied to all user nodes is solved, and the full-chain traceability of the product is realized.
Patent Information
- Application Number
- CN202210087748.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-01-25
- Publication Date
- 2024-11-12
- Estimated Expiration
- 2042-01-25
AI Technical Summary
The prior art methods of generating product traceability information cannot be applied to all user nodes, resulting in the inability to trace the product.
By obtaining product traceability data, encoding and generating product traceability identification codes, determining enterprise analysis nodes and obtaining analysis interfaces, establishing product traceability information, and ensuring that all user nodes can parse product traceability identification codes.
The full-chain traceability of the product is realized, ensuring that all user nodes can parse the product traceability identification code through the analytical interface, and solving the difficulties that the existing technology cannot be applied to all user nodes.
Smart Images

Figure CN114493634B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a method, device and medium for generating product traceability information based on identification resolution. Background Art
[0002] Industrial Internet is the industry and application ecology formed by the all-round and deep integration of the Internet, new generation information technology and industrial systems. It is the key comprehensive information infrastructure for the development of industrial intelligence. In order to improve the competitiveness of enterprises themselves, improve the quality of service to users, and enhance the sense of participation of users in products, more and more attention is paid to the information of the whole life cycle of products.
[0003] When tracing products, most of them are generated by encoding enterprise data to generate product identification, but only the parsing node of the corresponding enterprise can parse the product identification. In the whole industrial chain of the product, the product traceability data includes a variety of data, such as production data and circulation data. Different data form different data identifications. When parsing the data identification, only the parsing node of the enterprise to which the data belongs can parse it. Therefore, the existing method of generating product traceability information cannot be applied to all user nodes, which brings difficulties to product traceability. Summary of the invention
[0004] One or more embodiments of the present specification provide a method, device and medium for generating product traceability information based on identity resolution, which are used to solve the following technical problem: the method of generating product traceability information in the prior art cannot be applied to all user nodes, resulting in the inability to trace the product.
[0005] One or more embodiments of this specification adopt the following technical solutions:
[0006] One or more embodiments of the present specification provide a method for generating product traceability information based on identification resolution, the method comprising: obtaining product traceability data of a current product, wherein the product traceability data comprises product data and an enterprise identification of the current product; encoding the product data according to a preset encoding rule to obtain a product data identification code of the current product; sorting the enterprise identification of the current product and the product data identification code of the current product according to a preset arrangement order to obtain a product traceability identification code of the current product; determining an enterprise resolution node corresponding to the product traceability identification code according to the product traceability identification code, and obtaining multiple resolution interfaces in the enterprise resolution node; and establishing product traceability information of the current product based on the corresponding relationship between the product traceability identification code of the current product and the multiple resolution interfaces.
[0007] Furthermore, the product traceability data includes product production data and product circulation data; the enterprise identification of the current product and the product data identification code of the current product are sorted according to a preset arrangement order to obtain the product traceability identification code of the current product, specifically including: determining multiple enterprise identifications of the current product through the raw material enterprise identification corresponding to the product production data, and the circulation enterprise identification corresponding to the product circulation data; generating a product raw material identification code of the current product according to the product production data, and generating a product circulation identification code of the current product according to the product circulation data; adding the raw material enterprise identification to the specified position of the product raw material identification code to obtain a first-stage identification code; adding the circulation enterprise identification to the specified position of the product circulation identification code to obtain a second-stage identification code; using the first-stage identification code and the second-stage identification code as the product traceability identification code of the current product.
[0008] Further, the product traceability information of the current product is established based on the product traceability identification code of the current product and the correspondence between the multiple parsing interfaces, specifically including: determining the raw material enterprise parsing node corresponding to the product raw material according to the raw material enterprise identifier in the product raw material identification code, and obtaining multiple raw material parsing interfaces in the raw material enterprise parsing node; determining the circulation enterprise parsing node corresponding to the product circulation according to the circulation enterprise identifier in the product circulation identification code, and obtaining multiple circulation parsing interfaces in the circulation enterprise parsing node; establishing the correspondence between the first-stage identification code and the second-stage identification code as the product stage correspondence; determining the correspondence between the first-stage identification code and the multiple raw material parsing interfaces, and determining the correspondence between the second-stage identification code and the multiple circulation parsing interfaces; establishing the full information table of the current product through the product stage correspondence, the correspondence between the first-stage identification code and the multiple raw material parsing interfaces, and the correspondence between the second-stage identification code and the multiple circulation parsing interfaces, and using the full information table of the current product as the product traceability information of the current product.
[0009] Furthermore, after establishing the product traceability information of the current product, the method also includes: when tracing the current product, obtaining the product traceability information of the current product; determining the product traceability identification code and multiple parsing interfaces of the current product in the product traceability information; splitting the product traceability identification code according to the preset arrangement order to obtain the product data identification code of the current product; determining a designated parsing interface from the multiple parsing interfaces, calling the designated parsing interface, parsing the product data identification code of the current product, and obtaining the product traceability data of the current product.
[0010] Further, determining a designated parsing interface from the multiple parsing interfaces specifically includes: obtaining interface information of the multiple parsing interfaces, wherein the interface information includes a historical parsing count, a parsing error count, and a total historical parsing time of the parsing interface; calculating a ratio of the total historical parsing time to the historical parsing count as a parsing efficiency of the parsing interface; calculating a ratio of the parsing error count to the historical parsing count as a parsing error rate of the parsing interface; sorting the multiple parsing interfaces in descending order of the parsing error rates of the multiple parsing interfaces to obtain a first sorting result of the multiple parsing interfaces; sorting the multiple parsing interfaces in descending order of the parsing efficiencies of the multiple parsing interfaces to obtain a second sorting result of the multiple parsing interfaces; and determining a designated parsing interface that meets the requirements from the multiple parsing interfaces based on the first sorting result and the second sorting result.
[0011] Furthermore, determining a specified parsing interface that meets the requirements from the multiple parsing interfaces based on the first sorting result and the second sorting result specifically includes: dividing the first sorting result into multiple parts in turn, and dividing the second sorting result into multiple parts in turn; establishing a correspondence between the specified part of the first sorting result and the specified part of the second sorting result; under the correspondence, determining the parsing interface that overlaps in the specified part of the first sorting result and the specified part of the second sorting result, and using the overlapping parsing interface as the specified parsing interface that meets the requirements.
[0012] Further, the enterprise resolution node corresponding to the product traceability identification code is determined according to the product traceability identification code, and multiple resolution interfaces are obtained in the enterprise resolution node, specifically including: obtaining the enterprise identification of the current product in the product traceability identification code; obtaining historical registration information of the corresponding enterprise according to the enterprise identification of the current product, wherein the historical registration information includes the enterprise resolution node corresponding to the enterprise and the identification type that can be resolved by the enterprise; obtaining all resolution interfaces corresponding to the enterprise according to the enterprise resolution node corresponding to the enterprise in the historical registration information; determining the identification type that can be resolved by each resolution interface through the identification type that can be resolved by the enterprise in the historical registration information; determining multiple resolution interfaces that meet the requirements according to the identification type that can be resolved by each resolution interface and the type of the product traceability identification code, wherein the identification type that can be resolved by the multiple resolution interfaces that meet the requirements is the same as the type of the product traceability identification code.
[0013] Furthermore, encoding the product data according to a preset coding rule to obtain a product data identification code for the current product specifically includes: dividing the product data of the current product into fields to obtain multiple product data fields; encoding the multiple product data fields according to preset coding rules for different fields to obtain multiple coding fields; arranging the multiple coding fields in a specified order to generate the current product data identification code.
[0014] One or more embodiments of this specification provide a device for generating product traceability information based on identity resolution, including:
[0015] at least one processor; and,
[0016] a memory communicatively connected to the at least one processor; wherein,
[0017] The memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to:
[0018] Obtain product traceability data of the current product, wherein the product traceability data includes product data and the enterprise identification of the current product; encode the product data according to a preset encoding rule to obtain a product data identification code of the current product; sort the enterprise identification of the current product and the product data identification code of the current product according to a preset arrangement order to obtain a product traceability identification code of the current product; determine the enterprise resolution node corresponding to the product traceability identification code according to the product traceability identification code, and obtain multiple resolution interfaces in the enterprise resolution node; establish product traceability information of the current product based on the product traceability identification code of the current product and the corresponding relationship between the multiple resolution interfaces.
[0019] One or more embodiments of this specification provide a non-volatile computer storage medium storing computer executable instructions, wherein the computer executable instructions are configured to:
[0020] Obtain product traceability data of the current product, wherein the product traceability data includes product data and the enterprise identification of the current product; encode the product data according to a preset encoding rule to obtain a product data identification code of the current product; sort the enterprise identification of the current product and the product data identification code of the current product according to a preset arrangement order to obtain a product traceability identification code of the current product; determine the enterprise resolution node corresponding to the product traceability identification code according to the product traceability identification code, and obtain multiple resolution interfaces in the enterprise resolution node; establish product traceability information of the current product based on the product traceability identification code of the current product and the corresponding relationship between the multiple resolution interfaces.
[0021] At least one of the above-mentioned technical solutions adopted in the embodiments of this specification can achieve the following beneficial effects: through the method provided in the embodiments of this specification, the product data is encoded and the enterprise identification of the product data is added to generate a product traceability identification code, and the enterprise resolution node that can resolve the product data identification code is determined according to the enterprise identification, and a corresponding relationship between the product traceability identification code and the resolution interface with resolution authority at the enterprise resolution node is established to generate product traceability information. The product traceability identification code and the corresponding resolution interface can be obtained through the product traceability information, thereby ensuring that all users can resolve the product traceability identification code through the resolution interface and realize product traceability. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] In order to more clearly illustrate the technical solutions in the embodiments of this specification or the prior art, the following briefly introduces the drawings required for use in the embodiments or the prior art description. Obviously, the drawings described below are only some embodiments recorded in this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative labor. In the drawings:
[0023] Figure 1 A schematic diagram of a method for generating product traceability information by identity resolution provided in an embodiment of this specification;
[0024] Figure 2 A schematic diagram of the structure of a device for generating product traceability information by identity resolution provided in an embodiment of this specification. DETAILED DESCRIPTION
[0025] In order to enable those skilled in the art to better understand the technical solutions in this specification, the technical solutions in the embodiments of this specification will be clearly and completely described below in conjunction with the drawings in the embodiments of this specification. Obviously, the described embodiments are only part of the embodiments of this specification, not all of the embodiments. Based on the embodiments of this specification, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this specification.
[0026] Industrial Internet is the industry and application ecology formed by the all-round and deep integration of the Internet, new generation information technology and industrial systems. It is the key comprehensive information infrastructure for the development of industrial intelligence. In order to improve the competitiveness of enterprises themselves, improve the quality of service to users, and enhance the sense of participation of users in products, more and more attention is paid to the information of the whole life cycle of products.
[0027] When tracing products, most of them are generated by encoding enterprise data, but only the parsing nodes of the corresponding enterprise can parse the product identification. In the whole industrial chain of the product, the product traceability data includes a variety of data, such as production data and circulation data. Different data form different data identifications. When parsing the data identification, only the parsing nodes of the enterprise to which the data belongs can parse it. Therefore, the existing method of generating product traceability information cannot be applied to all user nodes, resulting in the inability to trace the product.
[0028] The embodiment of this specification provides a method for generating product traceability information based on identification resolution. It should be noted that the execution subject in the embodiment of this specification can be a server or any device with data processing capabilities. Identification resolution technology connects all production factors such as equipment, machines and materials in industrial scenarios by establishing a unified identification system, and connects fragmented data and applications through the resolution system to achieve the mastery of information such as the source, flow process, and purpose of the data. Figure 1 A method for generating product traceability information based on identification resolution is provided in an embodiment of this specification, as shown in 1, and the method mainly includes the following steps:
[0029] Step S101, obtaining product traceability data of the current product.
[0030] In the actual application process, if you want to establish the traceability information of the product, you should first determine the product traceability data of the product. Product traceability data can be divided into production data and circulation data according to the different stages of the product. Production data is related to production materials and production processes, and is data related to the product in the production stage. Circulation data refers to data generated during the product circulation process. The production enterprise obtains all traceability information in the product production execution process through the enterprise production process execution system. Taking tea products as an example, the product traceability data of tea can include tea raw material data, tea sales data, etc.
[0031] In one embodiment of the present specification, product traceability data includes product data and the corporate identity of the current product. Product data refers to product-related data generated during the production process, circulation process, and various industrial chains. Since each type of data is generated by different entities, it is also necessary to obtain the corporate identity in the traceability data. By setting the corporate identity, the owner of the data can be indicated. For example, the corporate identity of tea raw material data can be the tea grower identity, and the circulation data can be the sales counter identity.
[0032] Step S102, encoding the product data according to a preset encoding rule to obtain a product data identification code of the current product.
[0033] Specifically, the product data is encoded according to preset encoding rules to obtain the product data identification code of the current product, which specifically includes: dividing the product data of the current product into fields to obtain multiple product data fields; encoding the product data fields according to preset encoding rules for different fields to obtain multiple encoding fields; arranging the multiple encoding fields in a specified order to generate the current product data identification code.
[0034] In one embodiment of the present specification, the coding rules of product traceability data are pre-set, and the coding rules here can be the coding rules of the enterprise to which the product traceability data belongs. The product data obtained in the product traceability data can be divided into structured data and unstructured data. Structured data is general numerical value and simplified text data, including data such as product batch number, production date, and production address. Unstructured data refers to pictures, videos, and large-capacity text data generated during the production process, such as incoming material inspection data, patch quality inspection data, purchase lists, operation logs, etc. The structured data in the product data is divided into fields to obtain multiple structured data fields. In addition, the unstructured data is formatted and converted into structured data, and the converted structured data is also divided into fields to obtain multiple converted data fields, and multiple structured data fields and multiple converted data fields are used as multiple product field data.
[0035] In one embodiment of the present specification, different encoding rules are set for different product data fields, and each product data field is encoded according to the corresponding encoding rules to obtain multiple encoding fields. After obtaining the multiple encoding fields, the multiple encoding fields are arranged in a specified order to obtain the current product data identification code. It should be noted that the specified order here can be a random order or can be sorted according to the generation time of each encoding field.
[0036] Step S103, sorting the enterprise identification of the current product and the product data identification code of the current product according to a preset arrangement order to obtain the product traceability identification code of the current product.
[0037] Specifically, the product traceability data includes product production data and product circulation data; the enterprise identification of the current product and the product data identification code of the current product are sorted in a preset order to obtain the product traceability identification code of the current product, specifically including: determining multiple enterprise identifications of the current product through the raw material enterprise identification corresponding to the product production data, and the circulation enterprise identification corresponding to the product circulation data; generating the product raw material identification code of the current product according to the product production data, and generating the product circulation identification code of the current product according to the product circulation data; adding the raw material enterprise identification to the specified position of the product raw material identification code to obtain the first-stage identification code; adding the circulation enterprise identification to the specified position of the product circulation identification code to obtain the second-stage identification code; using the first-stage identification code and the second-stage identification code as the product traceability identification code of the current product.
[0038] In one embodiment of this specification, product traceability data includes product production data and product circulation data, wherein the data source of product production data is the raw material production enterprise, therefore, the product production data corresponds to the raw material enterprise identification, and the source of product production data is determined by setting the raw material enterprise identification. Similarly, the data source of product circulation data is the circulation enterprise, therefore, the product circulation data corresponds to the operating circulation enterprise identification, and the raw material enterprise identification and the circulation enterprise identification are used as multiple enterprise identifications of the current product.
[0039] In one embodiment of the present specification, a product raw material identification code is generated based on production data, a product circulation identification code is generated based on circulation data, and the raw material enterprise identification is added to a specified position of the product raw material identification code to obtain a first-stage identification code. The specified position here can be in the identification prefix of the product raw material identification code, or it can be set in the identification suffix of the product raw material identification code. Similarly, the circulation enterprise identification is added to a specified position of the product circulation identification code to obtain a second-stage identification code; the specified position here can be in the identification prefix of the product raw material identification code, or it can be set in the identification suffix of the product raw material identification code. Since the current product includes a production stage and a circulation stage, a product traceability identification code for the current product is generated based on the first-stage identification code corresponding to the production stage and the second-stage identification code corresponding to the circulation stage.
[0040] Step S104: determining the enterprise resolution node corresponding to the product traceability identification code according to the product traceability identification code, and obtaining a plurality of resolution interfaces in the enterprise resolution node.
[0041] Specifically, according to the product traceability identification code, the enterprise resolution node corresponding to the product traceability identification code is determined, and multiple resolution interfaces are obtained in the enterprise resolution node, specifically including: obtaining the enterprise identification of the current product in the product traceability identification code; according to the enterprise identification of the current product, obtaining the historical registration information of the corresponding enterprise, wherein the historical registration information includes the enterprise resolution node corresponding to the enterprise and the identification type that can be resolved by the enterprise; according to the enterprise resolution node corresponding to the enterprise in the historical registration information, obtaining all resolution interfaces corresponding to the enterprise; through the identification type that can be resolved by the enterprise in the historical registration information, determining the identification type that can be resolved by each resolution interface; according to the identification type that can be resolved by each resolution interface and the type of the product traceability identification code, determining multiple resolution interfaces that meet the requirements, wherein the identification type that can be resolved by the multiple resolution interfaces that meet the requirements is the same as the type of the product traceability identification code.
[0042] In one embodiment of the present specification, the enterprise identification of the current product in the product traceability identification code is obtained, so that according to the enterprise identification of the current product, the historical registration information of the corresponding enterprise is obtained from multiple historical registration information, wherein the historical registration information includes the enterprise resolution node corresponding to the enterprise and the identification type that can be resolved by the enterprise. It should be noted that if the enterprise identification of the current product has multiple enterprises, the historical registration information of the multiple enterprises is obtained respectively.
[0043] In one embodiment of the present specification, according to the enterprise resolution node corresponding to the enterprise in the historical registration information, all resolution interfaces corresponding to the enterprise under the current enterprise resolution node are obtained, and the identification type that can be resolved by each resolution interface is determined through the identification type that can be resolved by the enterprise in the historical registration information. In other words, the resolution node of each enterprise can only resolve the identification code generated by the enterprise data of the corresponding enterprise, and each enterprise resolution node has multiple resolution interfaces, and the type of identification code resolved by each resolution interface is also different. According to the identification type that can be resolved by each resolution interface and the type of product traceability identification code, multiple resolution interfaces that meet the requirements are determined, wherein the identification type that can be resolved by the multiple resolution interfaces that meet the requirements is the same as the type of product traceability identification code.
[0044] Step S105: establishing product traceability information of the current product based on the product traceability identification code of the current product and the corresponding relationship between the multiple parsing interfaces.
[0045] In one embodiment of the present specification, based on the raw material enterprise identifier in the product raw material identification code, the raw material enterprise parsing node corresponding to the product raw material is determined, and multiple raw material parsing interfaces are obtained in the raw material enterprise parsing node; based on the circulation enterprise identifier in the product circulation identification code, the circulation enterprise parsing node corresponding to the product circulation is determined, and multiple circulation parsing interfaces are obtained in the circulation enterprise parsing node.
[0046] In one embodiment of the present specification, based on the first-stage identification code corresponding to the production data in the product production process and the second-stage identification code corresponding to the circulation data in the product circulation process, a correspondence between the first-stage identification code and the second-stage identification code is established as the product stage correspondence; the correspondence between the first-stage identification code and multiple raw material parsing interfaces is determined, and the correspondence between the second-stage identification code and the multiple circulation parsing interfaces is determined; through the product stage correspondence, the correspondence between the first-stage identification code and the multiple raw material parsing interfaces, and the correspondence between the second-stage identification code and the multiple circulation parsing interfaces, a full information table of the current product is established, and the full information table of the current product is used as the product traceability information of the current product.
[0047] In one embodiment of the present specification, when tracing the product of the current product, first obtain the product tracing information of the current product, that is, the full information table of the current product. Determine the product tracing identification code and multiple parsing interfaces of the current product in the product tracing information.
[0048] In one embodiment of the present specification, the product traceability identification code is split according to a preset arrangement order to obtain the product data identification code of the current product. It should be noted that the arrangement order here can be the arrangement order stored when the product traceability identification code is generated. A designated parsing interface is determined from multiple parsing interfaces, and the designated parsing interface is called to parse the product data identification code of the current product to obtain the product traceability data of the current product.
[0049] During the actual interface call, there are multiple parsing interfaces, and different parsing interfaces have different parsing capabilities. In order to further improve the accuracy of interface parsing, it is necessary to determine the designated parsing interface that meets the requirements from multiple parsing interfaces, parse the product data identification code of the current product, and obtain the product traceability data of the current product.
[0050] In one embodiment of the present specification, interface information of multiple parsing interfaces is obtained, where the interface information includes the historical parsing times, parsing error times, and the total historical parsing time of the parsing interface. The parsing efficiency of each parsing interface is determined by the historical parsing times and the total historical parsing time, and the ratio of the total historical parsing time to the historical parsing times is calculated, and the ratio result is used as the parsing efficiency of the parsing interface. The error rate of the parsing interface is determined by the parsing error times and the historical parsing coefficient, and the parsing error rate of the parsing interface is determined by calculating the ratio of the parsing error times to the historical parsing times.
[0051] In one embodiment of the present specification, multiple parsing interfaces are sorted in descending order of their parsing error rates to obtain a first sorting result of the multiple parsing interfaces. Multiple parsing interfaces are sorted in descending order of their parsing efficiencies to obtain a second sorting result of the multiple parsing interfaces. According to the first sorting result and the second sorting result, a specified parsing interface that meets the requirements is determined from the multiple parsing interfaces.
[0052] Wherein, according to the first sorting result and the second sorting result, determining the specified parsing interface that meets the requirements from the multiple parsing interfaces specifically includes: dividing the first sorting result into multiple parts in sequence, and dividing the second sorting result into multiple parts in sequence; for example, it can be divided into three parts, each of which includes the same number of parsing interfaces. Establishing a corresponding relationship between the specified part of the first sorting result and the specified part of the second sorting result, that is, the first sorting result is divided into three parts A, B and C in the order of parsing error rate from high to low, the error rate of all interfaces in part A is higher than that of all interfaces in part B, and the error rate of all interfaces in part B is higher than that of all interfaces in part C. The second sorting result is divided into three parts D, E and F in the order of parsing efficiency from high to low. Similarly, the parsing efficiency of all interfaces in part D is higher than that of all interfaces in part E, and the parsing efficiency of all interfaces in part E is higher than that of all interfaces in part F. In order to select the optimal parsing interface, it is necessary to establish a corresponding relationship between the specified part of the first sorting result and the specified part of the second sorting result, that is, the corresponding relationship between part C and part D, part B and part E, and part A and part F. Under the corresponding relationship, the overlapping parsing interfaces in the designated part of the first sorting result and the designated part of the second sorting result are determined, that is, the overlapping parsing interfaces in part C and part D are determined, and the overlapping parsing interfaces are used as the designated parsing interfaces that meet the requirements.
[0053] Through the method provided in the embodiments of this specification, the product data is encoded and the enterprise identification of the product data is added to generate a product traceability identification code. The enterprise resolution node that can resolve the product data identification code is determined according to the enterprise identification, and a correspondence between the product traceability identification code and the resolution interface with resolution authority at the enterprise resolution node is established to generate product traceability information. The product traceability identification code and the corresponding resolution interface can be obtained through the product traceability information, ensuring that all users can resolve the product traceability identification code through the resolution interface, thereby realizing product traceability.
[0054] The embodiment of this specification also provides a device for generating product traceability information based on identification resolution, such as Figure 2As shown, the device includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can: obtain product traceability data of the current product, wherein the product traceability data includes product data and the enterprise identification of the current product; encode the product data according to a preset encoding rule to obtain a product data identification code of the current product; sort the enterprise identification of the current product and the product data identification code of the current product according to a preset arrangement order to obtain a product traceability identification code of the current product; determine the enterprise resolution node corresponding to the product traceability identification code according to the product traceability identification code, and obtain multiple resolution interfaces in the enterprise resolution node; establish product traceability information of the current product based on the product traceability identification code of the current product and the correspondence between the multiple resolution interfaces.
[0055] The embodiment of this specification also provides a non-volatile computer storage medium, which stores computer executable instructions, and the computer executable instructions are set to: obtain product traceability data of the current product, wherein the product traceability data includes product data and the enterprise identification of the current product; encode the product data according to the preset coding rules to obtain the product data identification code of the current product; sort the enterprise identification of the current product and the product data identification code of the current product according to the preset arrangement order to obtain the product traceability identification code of the current product; determine the enterprise parsing node corresponding to the product traceability identification code according to the product traceability identification code, and obtain multiple parsing interfaces in the enterprise parsing node; based on the product traceability identification code of the current product and the corresponding relationship between the multiple parsing interfaces, establish the product traceability information of the current product. Each embodiment in this specification is described in a progressive manner, and the same and similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the embodiments of the device, equipment, and non-volatile computer storage medium, since they are basically similar to the method embodiments, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiments.
[0056] The above is a description of a specific embodiment of the specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0057] The above description is only one or more embodiments of this specification and is not intended to limit this specification. For those skilled in the art, one or more embodiments of this specification may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of one or more embodiments of this specification shall be included in the scope of the claims of this specification.
Claims
1. A method for generating product traceability information based on identification resolution, It is characterized in that The method comprises: Acquire product traceability data of the current product, wherein the product traceability data includes product data and the enterprise identification of the current product; Encode the product data according to a preset encoding rule to obtain a product data identification code of the current product; Sorting the enterprise identification of the current product and the product data identification code of the current product in a preset arrangement order to obtain a product traceability identification code of the current product; According to the product traceability identification code, determine the enterprise resolution node corresponding to the product traceability identification code, and obtain multiple resolution interfaces in the enterprise resolution node; Establishing product traceability information of the current product based on the product traceability identification code of the current product and the corresponding relationship between the multiple parsing interfaces; The product traceability data includes product production data and product circulation data; the product traceability identification code of the current product is obtained by sorting the enterprise identification of the current product and the product data identification code of the current product according to a preset arrangement order, specifically including: Determine multiple enterprise identifications of the current product through the raw material enterprise identification corresponding to the product production data and the circulation enterprise identification corresponding to the product circulation data; Generate a product raw material identification code of the current product according to the product production data, and generate a product circulation identification code of the current product according to the product circulation data; Add the raw material enterprise identification to the designated position of the product raw material identification code to obtain the first-stage identification code; Adding the circulation enterprise identification to the designated position of the product circulation identification code to obtain a second-stage identification code; Using the first-stage identification code and the second-stage identification code as the product traceability identification code of the current product; The establishing of the product traceability information of the current product based on the product traceability identification code of the current product and the correspondence between the multiple parsing interfaces specifically includes: According to the raw material enterprise identifier in the product raw material identification code, determine the raw material enterprise parsing node corresponding to the product raw material, and obtain multiple raw material parsing interfaces in the raw material enterprise parsing node; According to the circulation enterprise identification in the product circulation identification code, determining the circulation enterprise resolution node corresponding to the product circulation, and obtaining multiple circulation resolution interfaces in the circulation enterprise resolution node; Establishing a correspondence between the first-stage identification code and the second-stage identification code as a product stage correspondence; Determine the correspondence between the first-stage identification code and the plurality of raw material parsing interfaces, and determine the correspondence between the second-stage identification code and the plurality of circulation parsing interfaces; A full quantity information table of the current product is established through the corresponding relationship between the product stages, the corresponding relationship between the first stage identification code and the multiple raw material parsing interfaces, and the corresponding relationship between the second stage identification code and the multiple circulation parsing interfaces, and the full quantity information table of the current product is used as the product traceability information of the current product; After establishing the product traceability information of the current product, it also includes: When tracing the source of the current product, obtaining the product tracing information of the current product; Determining a product traceability identification code and a plurality of parsing interfaces of the current product in the product traceability information; According to the preset arrangement order, the product traceability identification code is split to obtain the product data identification code of the current product; Determining a designated parsing interface from the multiple parsing interfaces, calling the designated parsing interface, parsing the product data identification code of the current product, and obtaining product traceability data of the current product; The step of determining, according to the product traceability identification code, an enterprise resolution node corresponding to the product traceability identification code, and acquiring multiple resolution interfaces in the enterprise resolution node specifically includes: Obtaining the enterprise identification of the current product in the product traceability identification code; According to the enterprise identification of the current product, historical registration information of the corresponding enterprise is obtained, wherein the historical registration information includes the enterprise resolution node corresponding to the enterprise and the identification type that can be resolved by the enterprise; According to the enterprise resolution node corresponding to the enterprise in the historical registration information, all resolution interfaces corresponding to the enterprise are obtained; Determine the identification type that can be resolved by each resolution interface through the identification type that can be resolved by the enterprise in the historical registration information; According to the identification type that can be resolved by each resolution interface and the type of the product traceability identification code, multiple resolution interfaces that meet the requirements are determined, wherein the identification type that can be resolved by the multiple resolution interfaces that meet the requirements is the same as the type of the product traceability identification code.
2. According to the method for generating product traceability information based on identification resolution according to claim 1, It is characterized in that The step of determining a designated parsing interface from among the multiple parsing interfaces specifically includes: Obtaining interface information of the multiple parsing interfaces, wherein the interface information includes the number of historical parsing times, the number of parsing errors, and the total length of historical parsing time of the parsing interface; Calculate the ratio of the total historical analysis time to the number of historical analysis times as the analysis efficiency of the analysis interface; Calculate the ratio of the number of parsing errors to the number of historical parsing times as the parsing error rate of the parsing interface; Sorting the multiple parsing interfaces in descending order of parsing error rates of the multiple parsing interfaces to obtain a first sorting result of the multiple parsing interfaces; Sorting the multiple parsing interfaces in descending order of parsing efficiency of the multiple parsing interfaces to obtain a second sorting result of the multiple parsing interfaces; According to the first sorting result and the second sorting result, a designated parsing interface that meets the requirements is determined from the multiple parsing interfaces.
3. According to claim 2, a method for generating product traceability information based on identification resolution, It is characterized in that The determining, according to the first sorting result and the second sorting result, a specified parsing interface that meets the requirements from the multiple parsing interfaces specifically includes: Divide the first sorting result into multiple equal parts in sequence, and divide the second sorting result into multiple equal parts in sequence; Establishing a correspondence between a specified portion of the first sorting result and a specified portion of the second sorting result; Under the corresponding relationship, the overlapping parsing interfaces in the designated part of the first sorting result and the designated part of the second sorting result are determined, and the overlapping parsing interfaces are used as the designated parsing interfaces that meet the requirements.
4. According to claim 1, a method for generating product traceability information based on identification resolution, It is characterized in that The step of encoding the product data according to a preset encoding rule to obtain a product data identification code of the current product specifically includes: Dividing the product data of the current product into fields to obtain a plurality of product data fields; Encoding the multiple product data fields according to preset encoding rules for different fields to obtain multiple encoding fields; Arrange the multiple coding fields in a specified order to generate the current product data identification code.
5. A device for generating product traceability information based on identification resolution, It is characterized in that The device comprises: at least one processor; and, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to: Acquire product traceability data of the current product, wherein the product traceability data includes product data and the enterprise identification of the current product; Encode the product data according to a preset encoding rule to obtain a product data identification code of the current product; Sorting the enterprise identification of the current product and the product data identification code of the current product in a preset arrangement order to obtain a product traceability identification code of the current product; According to the product traceability identification code, determine the enterprise resolution node corresponding to the product traceability identification code, and obtain multiple resolution interfaces in the enterprise resolution node; Establishing product traceability information of the current product based on the product traceability identification code of the current product and the corresponding relationship between the multiple parsing interfaces; The product traceability data includes product production data and product circulation data; the product traceability identification code of the current product is obtained by sorting the enterprise identification of the current product and the product data identification code of the current product according to a preset arrangement order, specifically including: Determine multiple enterprise identifications of the current product through the raw material enterprise identification corresponding to the product production data and the circulation enterprise identification corresponding to the product circulation data; Generate a product raw material identification code of the current product according to the product production data, and generate a product circulation identification code of the current product according to the product circulation data; Add the raw material enterprise identification to the designated position of the product raw material identification code to obtain the first-stage identification code; Adding the circulation enterprise identification to the designated position of the product circulation identification code to obtain a second-stage identification code; Using the first-stage identification code and the second-stage identification code as the product traceability identification code of the current product; The establishing of the product traceability information of the current product based on the product traceability identification code of the current product and the correspondence between the multiple parsing interfaces specifically includes: According to the raw material enterprise identifier in the product raw material identification code, determine the raw material enterprise parsing node corresponding to the product raw material, and obtain multiple raw material parsing interfaces in the raw material enterprise parsing node; According to the circulation enterprise identification in the product circulation identification code, determining the circulation enterprise resolution node corresponding to the product circulation, and obtaining multiple circulation resolution interfaces in the circulation enterprise resolution node; Establishing a correspondence between the first-stage identification code and the second-stage identification code as a product stage correspondence; Determine the correspondence between the first-stage identification code and the plurality of raw material parsing interfaces, and determine the correspondence between the second-stage identification code and the plurality of circulation parsing interfaces; A full quantity information table of the current product is established through the corresponding relationship between the product stages, the corresponding relationship between the first stage identification code and the multiple raw material parsing interfaces, and the corresponding relationship between the second stage identification code and the multiple circulation parsing interfaces, and the full quantity information table of the current product is used as the product traceability information of the current product; After establishing the product traceability information of the current product, it also includes: When tracing the source of the current product, obtaining the product tracing information of the current product; Determining a product traceability identification code and a plurality of parsing interfaces of the current product in the product traceability information; According to the preset arrangement order, the product traceability identification code is split to obtain the product data identification code of the current product; Determining a designated parsing interface from the multiple parsing interfaces, calling the designated parsing interface, parsing the product data identification code of the current product, and obtaining product traceability data of the current product; The step of determining, according to the product traceability identification code, an enterprise resolution node corresponding to the product traceability identification code, and acquiring multiple resolution interfaces in the enterprise resolution node specifically includes: Obtaining the enterprise identification of the current product in the product traceability identification code; According to the enterprise identification of the current product, historical registration information of the corresponding enterprise is obtained, wherein the historical registration information includes the enterprise resolution node corresponding to the enterprise and the identification type that can be resolved by the enterprise; According to the enterprise resolution node corresponding to the enterprise in the historical registration information, all resolution interfaces corresponding to the enterprise are obtained; Determine the identification type that can be resolved by each resolution interface through the identification type that can be resolved by the enterprise in the historical registration information; According to the identification type that can be resolved by each resolution interface and the type of the product traceability identification code, multiple resolution interfaces that meet the requirements are determined, wherein the identification type that can be resolved by the multiple resolution interfaces that meet the requirements is the same as the type of the product traceability identification code.
6. A non-volatile computer storage medium storing computer executable instructions, wherein the computer executable instructions are configured to: Get the product traceability data of the current product, in, The product traceability data includes product data and the enterprise identification of the current product; Encode the product data according to a preset encoding rule to obtain a product data identification code of the current product; Sorting the enterprise identification of the current product and the product data identification code of the current product in a preset arrangement order to obtain a product traceability identification code of the current product; According to the product traceability identification code, determine the enterprise resolution node corresponding to the product traceability identification code, and obtain multiple resolution interfaces in the enterprise resolution node; Establishing product traceability information of the current product based on the product traceability identification code of the current product and the corresponding relationship between the multiple parsing interfaces; The product traceability data includes product production data and product circulation data; the product traceability identification code of the current product is obtained by sorting the enterprise identification of the current product and the product data identification code of the current product according to a preset arrangement order, specifically including: Determine multiple enterprise identifications of the current product through the raw material enterprise identification corresponding to the product production data and the circulation enterprise identification corresponding to the product circulation data; Generate a product raw material identification code of the current product according to the product production data, and generate a product circulation identification code of the current product according to the product circulation data; Add the raw material enterprise identification to the designated position of the product raw material identification code to obtain the first-stage identification code; Adding the circulation enterprise identification to the designated position of the product circulation identification code to obtain a second-stage identification code; Using the first-stage identification code and the second-stage identification code as the product traceability identification code of the current product; The establishing of the product traceability information of the current product based on the product traceability identification code of the current product and the correspondence between the multiple parsing interfaces specifically includes: According to the raw material enterprise identifier in the product raw material identification code, determine the raw material enterprise parsing node corresponding to the product raw material, and obtain multiple raw material parsing interfaces in the raw material enterprise parsing node; According to the circulation enterprise identification in the product circulation identification code, determining the circulation enterprise resolution node corresponding to the product circulation, and obtaining multiple circulation resolution interfaces in the circulation enterprise resolution node; Establishing a correspondence between the first-stage identification code and the second-stage identification code as a product stage correspondence; Determine the correspondence between the first-stage identification code and the plurality of raw material parsing interfaces, and determine the correspondence between the second-stage identification code and the plurality of circulation parsing interfaces; A full quantity information table of the current product is established through the corresponding relationship between the product stages, the corresponding relationship between the first stage identification code and the multiple raw material parsing interfaces, and the corresponding relationship between the second stage identification code and the multiple circulation parsing interfaces, and the full quantity information table of the current product is used as the product traceability information of the current product; After establishing the product traceability information of the current product, it also includes: When tracing the source of the current product, obtaining the product tracing information of the current product; Determining a product traceability identification code and a plurality of parsing interfaces of the current product in the product traceability information; According to the preset arrangement order, the product traceability identification code is split to obtain the product data identification code of the current product; Determining a designated parsing interface from the multiple parsing interfaces, calling the designated parsing interface, parsing the product data identification code of the current product, and obtaining product traceability data of the current product; The step of determining, according to the product traceability identification code, an enterprise resolution node corresponding to the product traceability identification code, and acquiring multiple resolution interfaces in the enterprise resolution node specifically includes: Obtaining the enterprise identification of the current product in the product traceability identification code; According to the enterprise identification of the current product, historical registration information of the corresponding enterprise is obtained, wherein the historical registration information includes the enterprise resolution node corresponding to the enterprise and the identification type that can be resolved by the enterprise; According to the enterprise resolution node corresponding to the enterprise in the historical registration information, all resolution interfaces corresponding to the enterprise are obtained; Determine the identification type that can be resolved by each resolution interface through the identification type that can be resolved by the enterprise in the historical registration information; According to the identification type that can be resolved by each resolution interface and the type of the product traceability identification code, multiple resolution interfaces that meet the requirements are determined, wherein the identification type that can be resolved by the multiple resolution interfaces that meet the requirements is the same as the type of the product traceability identification code.
Citation Information
Patent Citations
Anti-fake traceablility system and method based on label reading
CN106022805A
Method for realizing source tracing and interconnection of industry chain upstream and downstream enterprises
CN106548359A
Data traceability system
CN111507709A
Big data decision analysis system and method based on industrial Internet identifier analysis
CN112165391A
Heterogeneous medical device identifier analysis method and system and storage medium
CN113128592A
