i
Create with AI
Deyel can use artificial intelligence to generate Java code for an advanced rule based on a request, simply by providing a text with the rule definition.
The option in the top toolbar enables the automatic generation of Java code for a rule, using artificial intelligence, speeding up development and reducing the possibility of coding errors.
Preliminary Considerations
To use rule generation with artificial intelligence, the following must be previously defined:
•The related objects in the “Advanced” tab of the rule properties.
•The parameters - input and output - of the rule.
AI Rules Generation Wizard
Clicking on the icon opens the AI Rule Generation Wizard as a panel on the right side of the screen where the prompt can be entered.
Prompt Specification
The prompt must contain the request for what the Java code of the rule must execute. The clearer and more detailed it is, the better the response generated by AI.
Rule Code Generation
By clicking on the “New” button within the AI rule generation wizard, the Java code that meets the prompt's requirement is automatically generated in the rule's code section.
Example
In this example, a read requirement for an instance of the “Account” entity is defined in the prompt according to the “pidAccount” input parameter, and the "qyAnualRev" field is assigned to the "pvalue" output parameter. With this requirement, Java code is automatically generated in the modeling area.