A kind of acquisition methods of structural knowledge and its body based on the customization of intelligent masterplate
Technical field
A kind of acquisition methods of structural knowledge and its body based on the customization of intelligent masterplate of present invention design, that is, utilize one
The customizable masterplate of kind, the interface of structural knowledge submission is provided for knowledge provider.Realize different types of structural knowledge
Acquisition.Acquisition caused by so as to solve the problems, such as because multi-field structural knowledge species is various is cumbersome.Provide simultaneously
A kind of ontology acquisition method, the body quick obtaining of structural knowledge is realized, belongs to computer realm.
Background technology
Since 21 century, with the development of information technology, computer technology, Internet technology, knowledge plays more
The role for sending out important.In computer realm, data, information and knowledge are the emphasis and focus of research.Knowledge is to data and letter
The extraction and in-depth of breath, it is to the deeper understanding of things.Using the knowledge engineering that knowledge is research as by artificial intelligence
The science developed, the problems such as primary study representation of knowledge, knowledge acquisition and knowledge are applied.The purpose is to will be stored in text
Human knowledge in sheet, image, sound and thought etc., the form that computer can identify is extracted and be expressed as, is stored
Come.The corresponding processing software of exploitation, provides the user the knowledge of its needs exactly, or it is rational using knowledge make inferences come
Answer some problems.By means of the powerful computing capability of computer, the efficiency of user job is greatly enhanced.
Because the form of knowledge is varied, some knowledge are fuzzy or abstract, even human language also is difficult to
Description, it is just more difficult to be expressed as the form that computer can identify.Meanwhile the carrier of knowledge is also different, for some carriers
The extraction of interior knowledge is difficult to realize.So in knowledge engineering, knowledge acquisition is always research emphasis and difficult point.It is common at present
Knowledge acquisition mode is segmented into artificial acquisition, automatic acquisition and the class of semi-automatic acquisition three.Artificial obtain is by knowledge engineer
In a manner of reading or be exchanged with certain domain expert, the knowledge in the field is obtained, these knowledge are then written as computer
A kind of acquisition modes for the form that can be identified.The acquisition of this mode is less efficient.Automatic acquisition is the meter by writing
The mode that calculation machine program extracts knowledge in the carrier of knowledge automatically obtains knowledge, and this mode at present can only be in minimum special model
Enclose interior realization, or a kind of knowledge acquisition mode of more satisfactoryization.Current most common knowledge acquisition mode is semi-automatic to know
Know acquisition modes.Knowledge engineer obtains the determinant attribute of certain domain knowledge first and design knowledge obtains masterplate.The masterplate bag
Include human-computer interaction interface and corresponding relation database table.Knowledge provider fills in knowledge by human-computer interaction interface, and system is certainly
It is dynamic to be stored in database in designed table.This method is especially suitable for the acquisition of structural knowledge.With computer CPU
Exemplified by, underlying attribute has basic parameter, frequency, slot, kernel, caching, technical parameter etc., and knowledge provider can fill in these
Attribute, realize different type CPU knowledge acquisition.This is to use most wide knowledge acquisition method at present.But this method is most
Big problem is that the species of structural knowledge is too many, and the attribute of different things is different.Each masterplate will design one
Interactive interface and its corresponding database table.It is unpractical to make whole knowledge acquisition masterplates.Further, mould as making
Version needs the ability in terms of computer programming, and domain expert and knowledge provider not necessarily all possess such ability.Meanwhile know
Knowing representation has a lot.Wherein, body is particularly suitable for concept and its relation is a kind of as representation more popular at present
Expressing for knowledge.Current ontology acquisition often carries out manual compiling using software.Such as write using Prot é g é and generate body
The OWL files of expression.This method is less efficient on the ontology acquisition of structural knowledge.
The problem of species is various in being obtained for current structural knowledge and ontology acquisition is cumbersome, the present invention devises one kind
The structural knowledge acquisition methods of intelligent masterplate customization.This method can by domain expert's designed, designed knowledge acquisition masterplate, by
Human-computer interaction interface and corresponding database purchase table corresponding to designed masterplate generation, are submitted corresponding for knowledge provider
Knowledge simultaneously stores.The body OWL files of knowledge are generated simultaneously.
The object of the invention is:In the acquisition of structural knowledge, knowledge species is various, is all to design acquisition mould per a kind of knowledge
Version is unpractical.Simultaneously currently a popular ontology acquisition mode is relatively complicated, can not quickly and efficiently realize structural knowledge
Ontology representation.The present invention devises a kind of method of intelligent masterplate customization.With it, can by the field expert from
The acquisition masterplate of row design structure knowledge, and the knowledge as corresponding to the generation of these masterplates submits interface and database table, knowledge
Supplier submits knowledge by filling in these interfaces, and system is deposited into database, and can automatically generate these structurings
The ontology representation file of knowledge.
Acquisition for structural knowledge at present typically uses man-machine interaction acquisition modes.By taking CPU as an example, its important attribute
There are CPU model, basic parameter, frequency, slot, kernel, caching, technical parameter etc., specific object includes basic parameter and (is applicable
Type, generic series, Package size), frequency (dominant frequency, maximum farsighted frequency, outer frequency, frequency multiplication), slot (slot-type, pin number
Mesh), kernel (core code name, core amounts, Thread Count, manufacture craft, TDP), caching (delay by L2 cache, three-level
Deposit), technical parameter (instruction set, Memory Controller Hub, maximum support internal memory, Hyper-Threading, virtualization basis, processor digit)
Deng.CPU Description of Knowledge is a kind of typical structural knowledge, and the acquisition of knowledge here is usually according to above-mentioned information development
One personal-machine interaction page.The page contains these above-mentioned attributes, and the value for vacating attribute is filled in for knowledge provider.With
Family fill in these values and submits successively.System is stored to the good relational database of backstage designed in advance after getting these values
In.So it is achieved that CPU knowledge acquisition.
Many problems in this process be present.First, the uncertainty of knowledge acquisition masterplate, if do not had in system
CPU knowledge acquisition masterplate, then knowledge provider can not submit relevant knowledge.In addition, obtaining the flexibility deficiency of masterplate, then can
Cause knowledge acquisition inaccurate.If any CPU be subsidiary video card.If no corresponding attribute in above-mentioned masterplate, this
Partial knowledge can not obtain.Meanwhile this kind of non-structured knowledge type is too many, such as internal memory, gear, lathe, or even group
Knit information, corporate structure etc..It is unpractical that the knowledge of each type, which designs one and obtains masterplate,.Regardless of whether it is that design is gone back
It is that masterplate needs certain computer programming ability as modification, domain expert and knowledge provider are in no system engineer
With the help of can not realize.Have again be exactly this kind of knowledge ontology acquisition it is too cumbersome, conventional method is manually compiled using software
Write.If ontology representation file can be automatically generated, the ontology acquisition efficiency of structural knowledge can be greatly improved.
The content of the invention
The present invention is to solve the above problems, propose a kind of structural knowledge based on the customization of intelligent masterplate and its body
Acquisition methods.This method develops a masterplate Customization Tool first, and domain expert can establish or change knowledge using the instrument
Obtain masterplate.Establish or amended masterplate is stored in database.Then a masterplate Core Generator is developed, the instrument can be with
Parse the template information in database, human-computer interaction interface corresponding to generation and its database purchase table.Knowledge provider can be with
By filling in interface submission knowledge and being stored in database.After knowledge is submitted, system automatically generates OWL by Ontology learning instrument
The ontology file deposit system disk of form.
The technical solution adopted by the present invention is:A kind of acquisition of structural knowledge and its body based on the customization of intelligent masterplate
Method, this method include 3 steps:
Step 1), masterplate customization.
The masterplate Customization Tool can provide a personal-machine interactive interface for domain expert and be used for customizing masterplate.Domain expert
Can be that all kinds of structural knowledges design proprietary acquisition masterplate.
Step 2), human-computer interaction interface generation and knowledge are submitted.
The specifying information of masterplate is parsed, generates the human-computer interaction interface of such structural knowledge acquisition.Knowledge provider can
To submit knowledge according to the interface.
Step 3), Ontology learning.
The knowledge that user submits according to the information of such knowledge, can automatically generate the ontology describing file of OWL forms.
Further, step 1) proposes masterplate customization thought, and specific implementation is as follows:
By way of man-machine interaction, domain expert can customize such knowledge essential information and knowledge attribute and
Property value.System in the form of a table can be stored in these information in relational database after the completion of customization.One in whole process
Three class tables are shared, are template information table, masterplate attribute list and knowledge information table respectively.Each knowledge type is in template information table
In have a record, and corresponding one on it attribute and property value masterplate attribute list, and by knowledge attribute and attribute
It is worth the knowledge information table of generation.Template information and specific knowledge are stored in this three classes table.
Further, step 2) realizes that human-computer interaction interface generation and knowledge are submitted on the basis of step 1), specific real
Existing mode is as follows:
Knowledge provider selects the knowledge type to be provided, and system can find masterplate corresponding to the type knowledge, in relation
Record and its corresponding masterplate attribute list in template information table on the masterplate are parsed in database.Generate such knowledge
Man-machine interaction obtain interface.The attribute in need filled in can all show for filling in.Knowledge provider can be by filling out
Write the interface and submit knowledge.The knowledge that all interfaces generated by the masterplate are submitted can all be inserted into the knowledge of corresponding types
In information table.System can parse the content submitted and be checked for user.
Further, step 3) parses the knowledge of user's submission on the basis of step 2), to knowledge in a manner of body
Model and export OWL form ontology files, specific implementation is as follows:
The essential information of the knowledge and attribute information and category in masterplate attribute list described in system extraction knowledge information table
Property value information is parsed, and these information and correlation modeling primitive are corresponding, that is, is converted into class (Class) relation, data category
Property (Datatype Property) and attribute of a relation (Object Property).And then system is by Jena kits, with
OWL is that Ontology Modeling standard is modeled to knowledge, is stored in the form of ontology file.
The present invention compared with prior art the advantages of be:
1. flexibly and efficiently structural knowledge obtains.And in this method, can be according to knowledge type, at any time corresponding to design
Knowledge acquisition masterplate simultaneously generates human-computer interaction interface.The problem of knowledge type of structuring is more are solved.
2. rationally it make use of system space.It is as far as possible more for possible structural knowledge stencil plate in conventional method, can
The knowledge that can have has masterplate without knowledge.And in the present invention, only determine in system without corresponding knowledge acquisition
Can be new knowledge type stencil plate at once after masterplate.Which offers a saving system space.
3. the attribute of structural knowledge is changed at any time.In the present invention, acquisition interface can be made by changing knowledge masterplate
Changed with back-end data library structure, so as to realize the modification of existing knowledge type.
4. the ontology acquisition of structural knowledge rapidly and efficiently.The body text of knowledge can be automatically generated after knowledge submission
Part.
Brief description of the drawings
Fig. 1 is this method overall schematic;
Fig. 2 is masterplate Customization Tool example;
Fig. 3 is masterplate customization procedure example;
Fig. 4 is that masterplate stores relation table structure;
Fig. 5 is that the knowledge of generation submits examples of interfaces;
Fig. 6 is the corresponding relation that primitive is modeled in the body of example.
Embodiment
The present invention is described in further detail below in conjunction with the accompanying drawings.
The present invention is a kind of acquisition methods of the structural knowledge based on the customization of intelligent masterplate and its body, as shown in figure 1,
Mainly include three parts:Masterplate is customized, and human-computer interaction interface generation and knowledge are submitted, Ontology learning.
(1) masterplate customizes
Customization Tool provides the Custom Interface of a masterplate:
The title of knowledge can be filled in by the interface, and defines number of attributes, Property Name and the property value of knowledge.
The quantity of attribute is obtained by clicking on addition attribute extension every time.The title of attribute is by User Defined.Property value is by belonging to
Property value type and corresponding types content composition.The type of property value is good by system predefined, for example pure text of common type
This (fill substance), choice box (radio box or multiselect frame), drop-down menu (single choices of multiple types) etc..The content of corresponding types is determined
The scope that can be filled in the justice attribute Value Types, optional entry in such as drop-down menu.User's Selective type is simultaneously filled in
The content of the type.The attached filling explanation in masterplate explanation, the content filling method of different type property value is discussed in detail.The work
The specific example of tool is as shown in Figure 2.The example for specifically filling in process is as shown in Figure 3.
Masterplate customization procedure is typically implemented by domain expert.Because masterplate customization needs have profound level to the field
Solution.Can be by setting system actor to realize corresponding control of authority, to ensure the correctness of masterplate and availability.Domain expert
After the completion of filling in, click on and customize new masterplate.Corresponding masterplate title, masterplate ID (unique number), number of attributes, Property Name,
Property ID (unique number), property value etc., it is stored in the lump described in relational database in the tables of data of masterplate.A now structure
The masterplate customization for changing knowledge is completed.
Three class tables mainly are included in system, its structural relation is as shown in Figure 4.First kind table is template information table, in the table
The essential information of the masterplate of all submissions of system is stored, such as masterplate title, masterplate ID, stamp fabrication user etc., structure such as table 1
It is shown.The essential information of one knowledge templet of each record in the table.Second class table is masterplate attribute list, the structure such as institute of table 2
Show, the attribute and property value that the table is submitted according to domain expert automatically generate, and have recorded attribute and attribute that such knowledge has
Value.Specific example is as shown in table 3.3rd class table is knowledge information table, and its structure is as shown in table 4.The table is given birth to by the attribute list of table 2
Into wherein each attribute is the field of the table, property value is the definition of field.Each record represents some type of specific
The content of each knowledge, specific example are as shown in table 5.Furthermore it is possible to check that existing masterplate enters to existing masterplate by clicking on
Row modification, clicks on the relational database table that can change backstage after submitting automatically.One of the knowledge corresponding table 1 of each type
Record and a table 2 and a table 4.
The Template Information table of table 1
The template attributes table of table 2
The template attributes of table 3 represent example
Propertyid |
Propertyname |
Propertytype |
Propertycontent |
pid1 |
Name |
Text is shown |
|
pid2 |
Gende |
Option is shown (single choice) |
|
pid3 |
Age |
Option is shown (pulldown single choice) |
10~20 | 20~30 | 30~40 |>40 |
The knowledge information table of table 4
The knowledge information of table 5 represents example
Name |
Gender |
Age |
zhangsan |
Male |
20~30 |
lisi |
Male |
30~40 |
(2) human-computer interaction interface generation and knowledge are submitted
User selects the knowledge type to be submitted, and system parses the mould of the type knowledge in relational database according to selection
Version.By that record in table 1 on the knowledge, and the content of table 2 and table 4 corresponding to the record, knowledge acquisition is generated
Interactive interface, specific example is as shown in Figure 5.
In this process, system reads the record of this masterplate in template information table first.Inquire the name of the masterplate
Word, ID and subscriber.According to the ID of masterplate find to should masterplate masterplate attribute list.The attribute and property value inquired about in the table
Deng.According to the Query Result of two above, by presentation of information such as the name of masterplate, subscribers at the obvious place of masterplate.Attribute is to arrange
The mode of table is shown among the page.Per the title of display properties before a line, behind according to the type and its content of property value
Frame is filled in generation one.A text box is produced if text type, Selective type just produces choice box, and drop-down type produces one
Individual drop-down menu.Knowledge submitter fills in frame to submit knowledge by filling in these.After knowledge provider submits knowledge, it can incite somebody to action
Content is inserted into knowledge information table.At this moment the submission of structural knowledge is just completed.All boundaries generated by the masterplate
Face and the knowledge submitted are stored in this table.System can parse this table and check submitted knowledge for user.
(3) Ontology learning
For each knowledge for submission, system can be carried out by parsing knowledge content by Jena kits
Ontology knowledge models.
The modeling primitive of body includes:The inheritance of class, data type attribute (Datatype Property), pass
Set attribute (Object Property).The specific knowledge attribute value of system analysis and its type, by itself and Ontology Modeling primitive phase
It is corresponding, while Jena kits are borrowed, using OWL as body reference format, the Ontology Modeling of knowledge is completed, finally with ontology file
Form storage.
For example, certain flow class knowledge package is as shown in table 6 containing information
The information of certain the flow class knowledge of table 6
Process name |
NAME |
Field specialty |
Professional M |
Field purposes |
Purposes U |
Build people |
Build people X |
Core parameter |
Parameter P |
Attribute-name A |
Property value V |
The corresponding relation that primitive is modeled in its specifying information and OWL bodies is as shown in Figure 6:
According to this corresponding relation, detailed Ontology Modeling can be carried out to knowledge by Jena kits, with OWL forms text
Part preserves.
The content not being described in detail in description of the invention belongs to prior art known to professional and technical personnel in the field.