Semantic parsing method and device based on rules and learning and electronic equipment
A semantic analysis and rule technology, applied in semantic analysis, machine learning, natural language translation, etc., can solve problems such as weak generalization ability, change, and difficulty in post-maintenance, to expand the scope of analysis, strong scalability, and solve limitations. sexual effect
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0042] Such as figure 1 As shown, the embodiment of the present invention provides a semantic analysis method based on rules and learning, including:
[0043] S101, identifying natural language sentences based on the original rules in the rule set, and generating structured sentences;
[0044] S102, judging whether the structured sentence can completely express the semantics of the natural language sentence, if not, obtaining the difference text between the natural language sentence and the structured sentence;
[0045] S103, inputting the difference text into a pre-trained learning model to generate new rules;
[0046] S104. Update the rule set by using the new rule.
[0047] In step S101, a large number of pre-written original rules are stored in the rule set, and the expression form of the original rules can be a self-defined context-free grammar rule. A syntax example might look like this:
[0048] =
[0049] |
[0050] |
[0051] |
[0052] |
[0053] |
...
Embodiment 2
[0104] Such as figure 2 As shown, another aspect of the present invention also includes a functional module architecture completely corresponding to the aforementioned method flow, that is, an embodiment of the present invention also provides a semantic analysis device based on rules and learning, including:
[0105] The rule parsing module 201 is used to identify natural language sentences based on the original rules in the rule set and generate structured sentences;
[0106] A judging module 202, configured to judge whether the structured sentence can completely express the semantics of the natural language sentence; if not, obtain the difference text between the natural language sentence and the structured sentence;
[0107] The new rule generating module 203 is used to input the difference text into the pre-trained learning model to generate new rules;
[0108] An update module 204, configured to update the rule set with the new rule.
[0109] The judgment ...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


