CN110097375A - A kind of Chinese medicine quality tracing modeling method that data granularity is gradable - Google Patents

A kind of Chinese medicine quality tracing modeling method that data granularity is gradable Download PDF

Info

Publication number
CN110097375A
CN110097375A CN201910226752.2A CN201910226752A CN110097375A CN 110097375 A CN110097375 A CN 110097375A CN 201910226752 A CN201910226752 A CN 201910226752A CN 110097375 A CN110097375 A CN 110097375A
Authority
CN
China
Prior art keywords
data
chinese medicine
tid
trace
algorithm
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910226752.2A
Other languages
Chinese (zh)
Inventor
俞磊
陶群山
王世好
杨勇
黄方亮
张璐瑶
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Anhui University of Traditional Chinese Medicine AHUTCM
Original Assignee
Anhui University of Traditional Chinese Medicine AHUTCM
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Anhui University of Traditional Chinese Medicine AHUTCM filed Critical Anhui University of Traditional Chinese Medicine AHUTCM
Priority to CN201910226752.2A priority Critical patent/CN110097375A/en
Publication of CN110097375A publication Critical patent/CN110097375A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/205Parsing
    • G06F40/211Syntactic parsing, e.g. based on context-free grammar [CFG] or unification grammars
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/018Certifying business or products

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • Finance (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Strategic Management (AREA)
  • Economics (AREA)
  • General Business, Economics & Management (AREA)
  • Development Economics (AREA)
  • Accounting & Taxation (AREA)
  • Marketing (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • Medical Treatment And Welfare Office Work (AREA)
  • Medical Preparation Storing Or Oral Administration Devices (AREA)

Abstract

The invention discloses a kind of Chinese medicine quality tracing modeling methods that data granularity is gradable, first on the basis of 12 kinds of pattern primitives of trace-back unit conversion process in design description Chinese medicine supply chain, it is based on its data store organisation of relational algebra Theoretical Design and data gathering algorithm;It is then based on syntax pattern distinguishment theory, on the basis of constructing the Chinese medicine product back-tracing data modeization description syntax, it constructs based on recursive sentence generation algorithm and is formed based on the grading specification method for improving pushdown automata, to establish the varying granularity model of Chinese medicine quality tracing data.The data granularity demand of the present invention can meet government regulation simultaneously person, the public and manufacturing enterprise, it is single to efficiently solve the problems, such as that traditional Chinese medicine quality tracing system trace back data granularity exports.

Description

A kind of Chinese medicine quality tracing modeling method that data granularity is gradable
Technical field
The present invention relates to Chinese medicine quality tracing modeling field more particularly to a kind of Chinese medicine materials that data granularity is gradable Amount retrospect modeling method.
Background technique
The essence of Chinese medicine quality tracing system is to improve Chinese medicine supply chain quality safety using means such as information technologies The service system of information asymmetry.Demand of the different user roles to system function is different: government and the public are mainly Specify the responsible party of Chinese medicine quality safety, it is desirable that the data granularity of output is thicker;And for Chinese medicine processing enterprise, retrospect System is a kind of internal resource management system, adapts to own service requirements of process, and this requires outputs should have fine number According to granularity.And in existing Chinese medicine material quality tracing system, since its flow modeling method is established in immutable rigid number According in modeling, this just determines that the output of system trace back data granularity is single, the person that can not meet government regulation simultaneously, the public and The data granularity demand of Producing medicinal herbs processing enterprise, receives the practicability of Chinese medicine quality tracing system and generalization sternly Recasting is about.
For this purpose, constructing a kind of Chinese medicine quality tracing modeling method that data granularity is gradable, herein to meet political affairs simultaneously The data granularity demand of mansion regulator, the public and manufacturing enterprise's demand.It is theoretical to be primarily based on configuration mode identification, in identification The pattern primitive of unit conversion can be traced in MED SUP chain, and design its data store organisation and data gathering algorithm;Then Based on syntax pattern distinguishment theory, construction describes method based on the Chinese medicine quality tracing data mode that pattern primitive models, And construct its sentence generation algorithm and grading specification method;Finally, verifying above-mentioned mould by taking certain Chinese medicine production as an example The feasibility and validity of type and algorithm.
Summary of the invention
The object of the invention is exactly single in order to make up the output of existing Chinese medicine material quality system trace back data granularity, can not be simultaneously This status of the data granularity demand of person, the public and Producing medicinal herbs processing enterprise that meets government regulation, constructs a kind of number According to the Chinese medicine quality tracing modeling method of granular scalability.
The present invention is achieved by the following technical solutions:
The gradable Chinese medicine quality tracing modeling method of data granularity, characterized by the following steps:
Step (1): 12 kinds of pattern primitives of trace-back unit conversion process in design description Chinese medicine supply chain;
Step (2): based on trace-back unit data store organisation and data in relational algebra Theoretical Design Chinese medicine supply chain Gathering algorithm;
Step (3):, the building Chinese medicine product back-tracing data modeization description syntax theoretical based on syntax pattern distinguishment;
Step (4): building is based on recursive sentence generation algorithm, is formed based on the grading rule for improving pushdown automata About method, to establish the varying granularity model of Chinese medicine quality tracing data.
The gradable Chinese medicine quality tracing modeling method of the data granularity, it is characterised in that: institute in step (1) 12 kinds of pattern primitives of trace-back unit conversion process in the design description Chinese medicine supply chain stated, the specific method is as follows: complete to GS1 Ball can be traced standard predicate set carry out local improvement, establish one group by receiving, sending, generate, destroy, construct, structure, according to The pattern primitive of attached, removing, modification, trimming, mobile and detection totally 12 predicates composition, so as to preferably centering quality of medicinal material Tracing information is described, and can illustrate in terms of Manufacture of medicinal slices of TCM, Chinese patent drug production two verifying respectively.
The gradable Chinese medicine quality tracing modeling method of the data granularity, it is characterised in that: institute in step (2) State based on trace-back unit data store organisation and data gathering algorithm in relational algebra Theoretical Design Chinese medicine supply chain, specifically Method is as follows:
(1) the Chinese medicine quality tracing data store organisation based on pattern primitive
It can be traced in standard in the whole world GS1, record personnel, place, time, object, five elements of event, i.e. pattern primitive Publicly-owned data attribute, be defined as
Rcommon=R (Eid, EName, Tid, Handler, Time, Location)
Wherein Eid is the unique instance mark of pattern primitive, and EName is the instance name of pattern primitive, and Tid is retrospect Unit marks, Handler are operator's marks, and Time is operation time of origin, and Location is operation scene;
The logic that trace-back unit converts in private data attribute characterization one kind Chinese medicine product supply chain of primitive in mode The storage organization of relationship, the traceable data of Chinese medicine quality tracing system is the nature of publicly-owned data attribute Yu private data attribute Connection;
(2) the trace back data gathering algorithm based on pattern primitive
12 quasi-mode primitives are shared, it is as follows that data general-purpose gathering algorithm process can be traced:
Step1: being distributed the instance identification Eid of certain mode by treaty rule, distributes the defeated of the mode by treaty rule Trace-back unit identifies Tid out;
Step2: 6 tuples are formed using the publicly-owned data attribute information of schema instance mark Eid and the schema instance { Eid, EName, Tid, Handler, Time, Location } is assigned to publicly-owned data attribute relationship Rcommon
Step3: schema instance mark Eid and output trace-back unit mark Tid in private data attribute form binary group { Eid, Tid } is assigned to the privately owned relation on attributes R of the modeprivate
Step4: publicly-owned data attribute relationship RcommonWith privately owned relation on attributes RprivateNature Link is established by Eid to close System.
The gradable Chinese medicine quality tracing modeling method of the data granularity, it is characterised in that: institute in step (3) That states is theoretical based on syntax pattern distinguishment, and the building Chinese medicine product back-tracing data modeization description syntax, the specific method is as follows:
The mapping of pattern primitive and grammatical terminal symbol is completed first, then on the basis of terminal symbol maps, to chase after forward For the process traced back, based on the transforming relationship of trace-back unit in all kinds of pattern primitives, the formalized description text of tracing process is established Method is specific as defined 1;
Define 1: in Chinese medicine product traceability system, the formalized description syntax of tracing process are G=(N, T, P, S), Wherein N={ S, M }, T={ a, b, c, d, e, f, g, h, i, j, k, l } and P:
(1)S→aM
(2)S→cM
(3)M→b
(4)M→d
(5)M→j
(6)M→gM
(7)M→hM
(8)M→eM
(9)M→kM
(10)M→lM
(11)M→iMM
(12)M→gMM
The retrospect process formalization for thereby establishing the Chinese medicine traceability system based on type 2 grammar describes method.
The gradable Chinese medicine quality tracing modeling method of the data granularity, it is characterised in that: institute in step (4) The building stated is based on recursive sentence generation algorithm, is formed based on the grading specification method for improving pushdown automata, thus The varying granularity model of Chinese medicine quality tracing data is established, the specific method is as follows:
(1) it is based on recursive sentence generation algorithm
Reading to each terminal symbol in the sentence in the formalized description syntax of the quality tracing process of step (4) foundation It takes, also just obtains the fine Chinese medicine product back-tracing data of granularity;The specific algorithm process of sentence generation is as follows:
Step1: according to Tid and Eid acquisition model primitive type, it is mapped to grammatical terminal symbol;
Step2: in the additional terminal symbol in sentence tail portion;
Step3: for structural model, since Tid is changed, to this algorithm of Tid recursive call;For destructing Mode, since Tid is changed, and deconstructing is multiple trace-back units, therefore indicates each of list Tid to new Tid This algorithm of recursive call;For depending on mode, since Tid and other trace-back units Tid establishes the relations of dependence, to Tid This algorithm of recursive call;For sending, destroying, separation mode, due to Tid as identified independent trace-back unit oneself pass through to Up to terminal, algorithm terminates, and returns to point of invocation;
Step4:Tid list is for example untreated to arrive tail end, then pointer is directed toward next Tid, returns to Step1, otherwise algorithm knot Beam returns to point of invocation;
(2) based on the traceable data granularity stage division for improving pushdown automata
It defines 2: in order to identify that the formalized description syntax of tracing process generate sentence, defining using original state as dual control heap The improvement pushdown automata of stack: A=(Q, Σ1,Γ,Γ',δ,q0,Z0,Z0', F), wherein Q={ q0,q1, Σ=a, c, b, d, J, g, h, e, k, l, i, f }, Γ={ S, M }, Z0=S,δ are as follows:
(1)δ(q0, a, S) and={ (q1,M,a)}
(2)δ(q0, c, S) and={ (q1,M,c)}
(3)δ(q1, b, M) and={ (q1,λ,b)}
(4)δ(q1, d, M) and={ (q1,λ,d)}
(5)δ(q1, j, M) and={ (q1,λ,j)}
(6) δ (q1, g, M)={ (q1,M,λ)}
(7)δ(q1, e, M) and={ (q1,M,λ)}
(8)δ(q1, h, M) and={ (q1,M,λ)}
(9)δ(q1, k, M) and={ (q1,M,λ)}
(10)δ(q1, l, M) and={ (q1,M,λ)}
(11)δ(q1, i, M) and={ (q1,MM,i)}
(12)δ(q1, f, M) and={ (q1,MM,f)}
Then the pushdown automata is from initial state q0With stack bottom symbols Z0Starting, successively reads in by preceding sentence generating algorithm The sentence of generation carries out formalization fusion to fine granulation data in the identification process to terminal symbol, and sentence is when processing terminate Coarseness data are obtained by structural information store storehouse, so that the Chinese medicine quality tracing process modeling of coarser particle size is completed, it is real The classification modeling of data granularity now can be traced.
The invention has the advantages that
The gradable Chinese medicine quality tracing modeling method of data granularity proposed by the present invention, can meet government regulation simultaneously The data granularity demand of person, the public and manufacturing enterprise efficiently solve traditional Chinese medicine quality tracing system trace back data Granularity exports single problem, has preferable application value.
Detailed description of the invention
Fig. 1 is the traceable data gathering algorithm flow chart of structural model.
Fig. 2 is sentence generation algorithm flow chart.
Fig. 3 is Chinese patent drug production business process map.
Fig. 4 is the Chinese medicine production and processing technology business process map based on pattern primitive.
Fig. 5 is the derivation tree of Chinese medicine production and processing technology operation flow.
Specific embodiment
The gradable Chinese medicine quality tracing modeling method of data granularity, includes the following steps:
Step (1): 12 kinds of pattern primitives of trace-back unit conversion process in design description Chinese medicine supply chain;
Step (2): based on trace-back unit data store organisation and data in relational algebra Theoretical Design Chinese medicine supply chain Gathering algorithm;
Step (3):, the building Chinese medicine product back-tracing data modeization description syntax theoretical based on syntax pattern distinguishment;
Step (4): building is based on recursive sentence generation algorithm, is formed based on the grading rule for improving pushdown automata About method, to establish the varying granularity model of Chinese medicine quality tracing data.
12 kinds of pattern primitives of trace-back unit conversion process in the Chinese medicine supply chain of design description described in step (1), The specific method is as follows:
It is a 7 predicate set that standard, which can be traced, in the general whole world GS1, be respectively receive, be mobile, conversion, storage, using, It destroys and sends, but since it cannot establish mapping relations with the trace-back unit conversion of inside retrospect, it cannot be with information system number Mapping relations are established according to the logical construction of storage, the predicate set that the whole world GS1 can be traced standard is needed to carry out local improvement thus (refinement and additions and deletions), establishes one group of pattern primitive being made of 12 predicates, be respectively receive, send, generating, destroying, constructing, Structure is depended on, removes, modifies, trims, moves and is detected, so that preferably centering quality of medicinal material tracing information is described.This 12 corresponding examples in Chinese medicine quality tracing of pattern primitive are specifically as shown in table 1, raw from Manufacture of medicinal slices of TCM, Chinese patent drug Produce two aspect citings.
Example of 1 12 pattern primitives of table in Chinese medicine quality tracing
Based on trace-back unit data store organisation in relational algebra Theoretical Design Chinese medicine supply chain described in step (2) With data gathering algorithm, the specific method is as follows:
(1) the Chinese medicine quality tracing data store organisation based on pattern primitive
It can be traced in standard in the whole world GS1, record personnel, place, time, object, five elements of event, i.e. pattern primitive Publicly-owned data attribute, be defined as
Rcommon=R (Eid, EName, Tid, Handler, Time, Location)
Wherein Eid is the unique instance mark of pattern primitive, and EName is the instance name of pattern primitive, and Tid is retrospect Unit marks, Handler are operator's marks, and Time is operation time of origin, and Location is operation scene;
Since each pattern primitive characterizes the logical relation of trace-back unit conversion in a kind of Chinese medicine product supply chain, Therefore in the Chinese medicine quality tracing data store organisation based on pattern primitive, the private data attribute characterization of primitive in mode This kind of logical relation.The private data attribute and the example of 12 quasi-mode primitives are as shown in table 2.
The private data attribute and example of 2 quasi-mode primitive of table
The storage organization that so data can be traced in Chinese medicine quality tracing system is publicly-owned data attribute and private data attribute Nature Link.By taking structural model as an example, the traceable data store organisation R of structural modelconstructIt is publicly-owned data attribute RcommonWith The private data attribute R of structural modelcommon_pvtNature Link, formal definition are as follows:
(2) the trace back data gathering algorithm based on pattern primitive
12 quasi-mode primitives are shared, it is as follows that data general-purpose gathering algorithm process can be traced:
Step1: being distributed the instance identification Eid of certain mode by treaty rule, distributes the defeated of the mode by treaty rule Trace-back unit identifies Tid out;
Step2: 6 tuples are formed using the publicly-owned data attribute information of schema instance mark Eid and the schema instance { Eid, EName, Tid, Handler, Time, Location } is assigned to publicly-owned data attribute relationship Rcommon
Step3: schema instance mark Eid and output trace-back unit mark Tid in private data attribute form binary group { Eid, Tid } is assigned to the privately owned relation on attributes R of the modeprivate
Step4: publicly-owned data attribute relationship RcommonWith privately owned relation on attributes RprivateNature Link relationship is established by Eid.
By taking " structural model " as an example, it is as follows that data gathering algorithm process can be traced:
Step1: being distributed the instance identification Eid of a structural model by treaty rule, distributes a construction by treaty rule The output trace-back unit of mode identifies Tid;
Step2: whether table is arrived to each of the input trace-back unit list for participating in structural model example trace-back unit Tail, if it does, Step6 is passed directly to, if no, into Step3;
Step3: schema instance identifies Eid, trace-back unit identifies TiThe publicly-owned data attribute of [Tid] and schema instance forms 6 tuples { Eid, EName, Tid, Handler, Time, Location } are assigned to publicly-owned data attribute relationship Rcommon
Step4: schema instance mark Eid, output trace-back unit mark Tid in private data attribute form binary group { Eid, Tid } is assigned to the privately owned relation on attributes R of structural modelconstruct_pvt
Step5: publicly-owned data attribute relationship RcommonWith privately owned relation on attributes Rconstruct_pvtNature is established by Eid to connect Connect relationship;
Step6: terminate.
The traceable data gathering algorithm flow chart of structural model is as shown in Figure 1.
Based on syntax pattern distinguishment theory, building Chinese medicine product back-tracing data modeization description described in step (3) The syntax, the specific method is as follows:
The mapping of pattern primitive and grammatical terminal symbol is completed first, and mapping relations are as shown in table 3.
The mapping relations of table 3 12 quasi-mode primitive and terminal symbol
On the basis of terminal symbol mapping, by taking the process traced forward as an example, based on trace-back unit in all kinds of pattern primitives Transforming relationship, establish the formalized description syntax of tracing process, it is specific as defined 1.
Define 1: in Chinese medicine product traceability system, the formalized description syntax of tracing process are G=(N, T, P, S), Wherein N={ S, M }, T={ a, b, c, d, e, f, g, h, i, j, k, l } and P:
(1)S→aM
(2)S→cM
(3)M→b
(4)M→d
(5)M→j
(6)M→gM
(7)M→hM
(8)M→eM
(9)M→kM
(10)M→lM
(11)M→iMM
(12)M→gMM
The syntax are type 2 grammar, thereby establish the retrospect Process flow of the Chinese medicine traceability system based on type 2 grammar Change description method.
Building described in step (4) is based on recursive sentence generation algorithm, is formed based on the grain for improving pushdown automata Degree classification specification method, to establish the varying granularity model of Chinese medicine quality tracing data, the specific method is as follows:
(1) it is based on recursive sentence generation algorithm
The formalized description syntax based on the quality tracing process that step (4) are established, are realized based on recursive grammatical sentence It generates, thus just completes the formalized description of the Chinese medicine product quality tracing information of fine granulation;To each end in sentence The reading for tying symbol, also just obtains the fine Chinese medicine product back-tracing data of granularity, the specific algorithm of sentence generation is given below:
Step1: according to Tid and Eid acquisition model primitive type, it is mapped to grammatical terminal symbol;
Step2: in the additional terminal symbol in sentence tail portion;
Step3: for structural model, since Tid is changed, to this algorithm of Tid recursive call;For destructing Mode, since Tid is changed, and deconstructing is multiple trace-back units, therefore indicates each of list Tid to new Tid This algorithm of recursive call;For depending on mode, since Tid and other trace-back units Tid establishes the relations of dependence, to Tid This algorithm of recursive call;For sending, destroying, separation mode, due to Tid as identified independent trace-back unit oneself pass through to Up to terminal, algorithm terminates, and returns to point of invocation;
Step4:Tid list is for example untreated to arrive tail end, then pointer is directed toward next Tid, returns to Step1, otherwise algorithm knot Beam returns to point of invocation.
Fig. 2 is algorithm specific flow chart.
(2) based on the traceable data granularity stage division for improving pushdown automata
It defines 2: in order to identify that the formalized description syntax of tracing process generate sentence, defining using original state as dual control heap The improvement pushdown automata of stack: A=(Q, Σ1,Γ,Γ',δ,q0,Z0,Z0', F), wherein Q={ q0,q1, Σ=a, c, b, d, J, g, h, e, k, l, i, f }, Γ={ S, M }, Z0=S,δ are as follows:
(1)δ(q0, a, S) and={ (q1,M,a)}
(2)δ(q0, c, S) and={ (q1,M,c)}
(3)δ(q1, b, M) and={ (q1,λ,b)}
(4)δ(q1, d, M) and={ (q1,λ,d)}
(5)δ(q1, j, M) and={ (q1,λ,j)}
(6) δ (q1, g, M)={ (q1,M,λ)}
(7)δ(q1, e, M) and={ (q1,M,λ)}
(8)δ(q1, h, M) and={ (q1,M,λ)}
(9)δ(q1, k, M) and={ (q1,M,λ)}
(10)δ(q1, l, M) and={ (q1,M,λ)}
(11)δ(q1, i, M) and={ (q1,MM,i)}
(12)δ(q1, f, M) and={ (q1,MM,f)}
Then the pushdown automata is from initial state q0With stack bottom symbols Z0Starting, successively reads in by preceding sentence generating algorithm The sentence of generation carries out formalization fusion to fine granulation data in the identification process to terminal symbol, and sentence is when processing terminate Coarseness data are obtained by structural information store storehouse, so that the Chinese medicine quality tracing process modeling of coarser particle size is completed, it is real The classification modeling of data granularity now can be traced.
So far, a kind of Chinese medicine quality tracing modeling method that data granularity is gradable is basically completed.Below by way of example Further illustrate effectiveness of the invention.
In the following, carrying out the Chinese medicine of schema object primitive with Liuwei Dihuang Wan (Chinese patent drug) production and processing for modeling object Product quality and safety retrospect modeling carries out formalized description to traceable data, and verifies traceable based on pushdown automata Data granularity stage division.Chinese patent drug production and processing technology operation flow is as shown in Figure 3.Analysis wherein the input of each process with it is defeated Trace-back unit relationship out is matched with aforementioned 12 kinds of pattern primitives, obtains the industry of the Chinese medicine production and processing technology based on pattern primitive Business process, as shown in Figure 4.The pattern primitive model of the operation flow is exported using the aforementioned syntax and sentence generation algorithm Tree export and sentence generation, sentence generated are ahhfbhfbhhhelekb, and grammatical derivation tree is shown in Fig. 5.
In the following, again respectively with " Liuwei Dihuang Wan " (Chinese patent drug), " ageratum oral liquid " (Chinese patent drug), " fructus lycii " (in Medicine medicine materical crude slice), for " dandelion " (prepared slices of Chinese crude drugs) this 4 kinds of Chinese medicine quality tracing processes, analysis data granularity classification specification Effect.Above-mentioned data are all from related Chinese medicine manufacturing enterprise.The effect of trace back data grading specification is as shown in table 5.As a result When showing algorithm using different supply chains, data staging specification intensity has a large amount of repeat between 48.4%~99.3% It operates, in the less plainly-packed Manufacture of medicinal slices of TCM process of supply-chain Structure information, hough transformation intensity highest.
Effect of the table 5 based on the trace back data grading specification for improving pushdown automata
In summary: the gradable Chinese medicine quality tracing modeling method of data granularity proposed by the present invention is practical to be had Effect, the data granularity demand of can meet government regulation simultaneously person, the public and manufacturing enterprise, has in Chinese medicine quality tracing There is preferable application value.

Claims (5)

1. the gradable Chinese medicine quality tracing modeling method of data granularity, characterized by the following steps:
Step (1): 12 kinds of pattern primitives of trace-back unit conversion process in design description Chinese medicine supply chain;
Step (2): based on trace-back unit data store organisation in relational algebra Theoretical Design Chinese medicine supply chain and data acquisition Algorithm;
Step (3):, the building Chinese medicine product back-tracing data modeization description syntax theoretical based on syntax pattern distinguishment;
Step (4): building is based on recursive sentence generation algorithm, is formed based on the grading specification side for improving pushdown automata Method, to establish the varying granularity model of Chinese medicine quality tracing data.
2. the gradable Chinese medicine quality tracing modeling method of data granularity according to claim 1, it is characterised in that: step Suddenly design described in (1) describes 12 kinds of pattern primitives of trace-back unit conversion process in Chinese medicine supply chain, and specific method is such as Under: to the whole world GS1 can be traced standard predicate set carry out local improvement, establish one group by receiving, sending, generate, destroy, structure It makes, structure, depend on, remove, modify, trim, move and detect the pattern primitive that totally 12 predicates form, so as to preferably centering Quality of medicinal material tracing information is described.
3. the gradable Chinese medicine quality tracing modeling method of data granularity according to claim 2, it is characterised in that: step Suddenly it is acquired described in (2) based on trace-back unit data store organisation in relational algebra Theoretical Design Chinese medicine supply chain and data Algorithm, the specific method is as follows:
(1) the Chinese medicine quality tracing data store organisation based on pattern primitive
It can be traced in standard in the whole world GS1, record personnel, place, time, object, five elements of event, the i.e. public affairs of pattern primitive There is data attribute, is defined as
Rcommon=R (Eid, EName, Tid, Handler, Time, Location)
Wherein Eid is the unique instance mark of pattern primitive, and EName is the instance name of pattern primitive, and Tid is trace-back unit mark Know, Handler is operator's mark, and Time is operation time of origin, and Location is operation scene;
The logical relation that trace-back unit converts in private data attribute characterization one kind Chinese medicine product supply chain of primitive in mode, The storage organization of the traceable data of Chinese medicine quality tracing system is the Nature Link of publicly-owned data attribute Yu private data attribute;
(2) the trace back data gathering algorithm based on pattern primitive
12 quasi-mode primitives are shared, it is as follows that data general-purpose gathering algorithm process can be traced:
Step1: being distributed the instance identification Eid of certain mode by treaty rule, is chased after by the output that treaty rule distributes the mode Trace back unit marks Tid;
Step2: using the schema instance mark Eid and the schema instance publicly-owned data attribute information form 6 tuples Eid, EName, Tid, Handler, Time, Location }, it is assigned to publicly-owned data attribute relationship Rcommon
Step3: in private data attribute schema instance mark Eid and output trace-back unit mark Tid composition binary group Eid, Tid }, it is assigned to the privately owned relation on attributes R of the modeprivate
Step4: publicly-owned data attribute relationship RcommonWith privately owned relation on attributes RprivateNature Link relationship is established by Eid.
4. the gradable Chinese medicine quality tracing modeling method of data granularity according to claim 2, it is characterised in that: step Suddenly based on syntax pattern distinguishment theory, the building Chinese medicine product back-tracing data modeization description syntax, specific side described in (3) Method is as follows:
The mapping of pattern primitive and grammatical terminal symbol is completed first, then on the basis of terminal symbol maps, with what is traced forward For process, based on the transforming relationship of trace-back unit in all kinds of pattern primitives, the formalized description syntax of tracing process, tool are established Body is as defined 1;
Define 1: in Chinese medicine product traceability system, the formalized description syntax of tracing process are G=(N, T, P, S), wherein N ={ S, M }, T={ a, b, c, d, e, f, g, h, i, j, k, l } and P:
(1)S→aM
(2)S→cM
(3)M→b
(4)M→d
(5)M→j
(6)M→gM
(7)M→hM
(8)M→eM
(9)M→kM
(10)M→lM
(11)M→iMM
(12)M→gMM
The retrospect process formalization for thereby establishing the Chinese medicine traceability system based on type 2 grammar describes method.
5. the gradable Chinese medicine quality tracing modeling method of data granularity according to claim 2, it is characterised in that: step Suddenly building described in (4) is based on recursive sentence generation algorithm, is formed based on the grading specification for improving pushdown automata Method, to establish the varying granularity model of Chinese medicine quality tracing data, the specific method is as follows:
(1) it is based on recursive sentence generation algorithm
Reading to each terminal symbol in the sentence in the formalized description syntax of the quality tracing process of step (4) foundation, Also the fine Chinese medicine product back-tracing data of granularity are just obtained;The specific algorithm process of sentence generation is as follows:
Step1: according to Tid and Eid acquisition model primitive type, it is mapped to grammatical terminal symbol;
Step2: in the additional terminal symbol in sentence tail portion;
Step3: for structural model, since Tid is changed, to this algorithm of Tid recursive call;For deconstructing mould Formula, since Tid is changed, and deconstructing is multiple trace-back units, therefore indicates that each of list Tid is passed to new Tid Return and calls this algorithm;For depending on mode, since Tid and other trace-back units Tid establishes the relations of dependence, Tid is passed Return and calls this algorithm;For sending, destroying, separation mode, due to Tid as identified independent trace-back unit oneself through reaching Terminal, algorithm terminate, and return to point of invocation;
Step4:Tid list is for example untreated to arrive tail end, then pointer is directed toward next Tid, returns to Step1, otherwise algorithm terminates, and returns Return to point of invocation;
(2) based on the traceable data granularity stage division for improving pushdown automata
It defines 2: in order to identify that the formalized description syntax of tracing process generate sentence, defining using original state as dual control storehouse Improve pushdown automata: A=(Q, Σ1,Γ,Γ',δ,q0,Z0,Z0', F), wherein Q={ q0,q1, Σ=a, c, b, d, j, g, H, e, k, l, i, f }, Γ={ S, M }, Z0=S,δ are as follows:
(1)δ(q0, a, S) and={ (q1,M,a)}
(2)δ(q0, c, S) and={ (q1,M,c)}
(3)δ(q1, b, M) and={ (q1,λ,b)}
(4)δ(q1, d, M) and={ (q1,λ,d)}
(5)δ(q1, j, M) and={ (q1,λ,j)}
(6) δ (q1, g, M)={ (q1,M,λ)}
(7)δ(q1, e, M) and={ (q1,M,λ)}
(8)δ(q1, h, M) and={ (q1,M,λ)}
(9)δ(q1, k, M) and={ (q1,M,λ)}
(10)δ(q1, l, M) and={ (q1,M,λ)}
(11)δ(q1, i, M) and={ (q1,MM,i)}
(12)δ(q1, f, M) and={ (q1,MM,f)}
Then the pushdown automata is from initial state q0With stack bottom symbols Z0Starting, successively reads in and is generated by preceding sentence generating algorithm Sentence formalization fusion carried out to fine granulation data in the identification process to terminal symbol, sentence processing terminate Shi Youjie Structure information store storehouse obtains coarseness data, to complete the Chinese medicine quality tracing process modeling of coarser particle size, realization can The classification of trace back data granularity models.
CN201910226752.2A 2019-03-25 2019-03-25 A kind of Chinese medicine quality tracing modeling method that data granularity is gradable Pending CN110097375A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910226752.2A CN110097375A (en) 2019-03-25 2019-03-25 A kind of Chinese medicine quality tracing modeling method that data granularity is gradable

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910226752.2A CN110097375A (en) 2019-03-25 2019-03-25 A kind of Chinese medicine quality tracing modeling method that data granularity is gradable

Publications (1)

Publication Number Publication Date
CN110097375A true CN110097375A (en) 2019-08-06

Family

ID=67443881

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910226752.2A Pending CN110097375A (en) 2019-03-25 2019-03-25 A kind of Chinese medicine quality tracing modeling method that data granularity is gradable

Country Status (1)

Country Link
CN (1) CN110097375A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102708410A (en) * 2012-03-14 2012-10-03 山东省射频识别应用工程技术研究中心有限公司 Network tracing system and network tracing method for non-staple food industrial chain
US20140258172A1 (en) * 2012-04-16 2014-09-11 Terence Malcolm Roach Method and system for the discovery and description of business endeavours
CN104850399A (en) * 2015-04-30 2015-08-19 昆明理工大学 Retrospective analysis method and retrospective analysis system capable of generating mapping table between component interface and component implementation

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102708410A (en) * 2012-03-14 2012-10-03 山东省射频识别应用工程技术研究中心有限公司 Network tracing system and network tracing method for non-staple food industrial chain
US20140258172A1 (en) * 2012-04-16 2014-09-11 Terence Malcolm Roach Method and system for the discovery and description of business endeavours
CN104850399A (en) * 2015-04-30 2015-08-19 昆明理工大学 Retrospective analysis method and retrospective analysis system capable of generating mapping table between component interface and component implementation

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
齐林: "面向可追溯的物联网数据采集与建模方法研究", 《中国优秀博士论文全文数据库》 *

Similar Documents

Publication Publication Date Title
CN104123374B (en) The method and device of aggregate query in distributed data base
CN103729460B (en) Graphical data model managing method and system based on metadata
CN105260403B (en) General integration across database access method
CN104965735B (en) Device for generating upgrading SQL scripts
CN107943452B (en) Multi-user collaborative development system structure design platform
CN105138326B (en) A kind of method and system for realizing sql dynamic configuration based on ibatis
CN103177068A (en) Systems and methods for merging source records in accordance with survivorship rules
CN104572895A (en) MPP (Massively Parallel Processor) database and Hadoop cluster data intercommunication method, tool and realization method
CN103559025A (en) Software refactoring method through clustering
CN104111998A (en) Method and device for sorting coding and integrated exchange and management of heterogeneous data of enterprise
CN109446221A (en) A kind of interactive data method for surveying based on semantic analysis
CN107491476B (en) Data model conversion and query analysis method suitable for various big data management systems
Li et al. Challenges and trends of big data analytics
CN112231417A (en) Data classification method and device, electronic equipment and storage medium
CN110276390A (en) A kind of third party's food inspection synthesis of mechanism information processing system and method
CN106919697A (en) A kind of method that data are imported multiple Hadoop components simultaneously
CN110097375A (en) A kind of Chinese medicine quality tracing modeling method that data granularity is gradable
CN113821538A (en) Streaming data processing system based on metadata
CN103593182A (en) Method for reconfiguring software by using clustering mode
CN108846003A (en) A kind of unstructured machine data processing method and processing device
CN101334800B (en) Method for describing function model by applying specific gene coding
KR102054756B1 (en) Method for designing optimizationally 3D model library to International standard standard product in Shipbuilding Marine
CN111984826A (en) XML-based data automatic storage method, system, device and storage medium
CN109726204A (en) A kind of data information management method and device based on self-defining data table
CN104573916A (en) Technical index instance generation method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination