Tips for Polishing Your OPA Policy Model - Oracle Policy Automation (March 2019) Jasmine Lee Oracle Policy Automation Specialist Last updated: ...
←
→
Page content transcription
If your browser does not render page correctly, please read the page content below
Tips for Polishing Your OPA Policy Model Oracle Policy Automation (March 2019) Jasmine Lee Oracle Policy Automation Specialist Last updated: March 2019 Copyright © 2019, Oracle and/or its affiliates. All rights reserved. |
Introduction • Audience – People who work with OPA policy models. It is assumed the reader has already had OPA training and is familiar with using OPA. • Purpose – Provide ideas and suggestions for polishing your policy models, and direct you to relevant articles in the OPA Documentation Library. • Software version – Deck prepared for Oracle Policy Modeling (19A). • Acronyms –OPA – Oracle Policy Automation Tip: Latest version of the OPA Documentation Library can be –OPM – Oracle Policy Modeling found via the question mark button in OPM and on OPA OTN Copyright © 2019, Oracle and/or its affiliates. All rights reserved. |
Example Projects • OPM includes Example Policy Models that demonstrate features discussed in this deck Filter examples by Industry and Feature Example projects available from the Project tab Example projects available from the Project tab Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 3
Tips for Polishing Your Policy Model • Screen Configuration • Substitution and Sentence Generation • Improving the Explanation – Labels on Interview Screens – Name Substitution – Intermediate Attributes – Interview Stages – Gender Pronoun Substitution – Rule Tags – Navigation Strip – Second Person Sentence Generation – Trimming Explanations – Attributes – Containers – Substituting Names in Labels – Trimming Explanations – Relationships – Entity Collect Screen • User Input – Adding Images to Interview Screens – Default Values • Enhancing Interviews – Value Lists – Look and Feel of Interviews – Hint Text – Document Generation using BI – Validating User Input – Event rules Publisher – Validating User Input – Data tab – Capture the User’s Location – Input Masks – Configuring Attribute Value Formats • Language Support – Configuring Standard Message Strings – Adding a Verb to the Default Verb List – Adding a Translation Layer – Writing Rules in Other Languages Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 4
Labels on Interview Screens Documentation Library • Labels can: • Add text to screens – be added to provide context and additional info • Add a label control – be used as additional headings and subheadings • Specify the type of label – include raw text, as well as HTML • Hide and show screen – have conditional visibility controls – contain substitution • Show attribute values on screens • Show attribute values in other screen text Example labels • Use embedded HTML in an interview Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 6
Interview Stages Documentation Library • Group related interview screens together in a folder • Organize an interview • Folder becomes a stage in the interview into stages OPM (design time) Interview (runtime) Interview stage Interview stage Interview screen Interview screen Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 7
Navigation Strip Documentation Library • Configure the appearance of the interview • Configure the Train stops navigation strip Left menu • Navigation strip may be displayed at the top or left of the page • Many configuration Ribbon Thermometer options available, e.g. text color, text size, background color Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 8
Containers Documentation Library • Containers may be used to lay out screen controls side-by-side • Change control layout • Containers allow for responsive design in interviews, e.g. two for a screen columns which collapse to a single column in a small browser • Example project: myBenefits • Labels and images may also be put in containers Screen controls laid out in two columns. Efficient use of space on a larger screen Screen controls automatically collapse to one column in a narrow browser window. More readable on a small screen. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 9
Entity Collect Screen Documentation Library • Entity collection layout can be ‘portrait’ or ‘tabular’ style • Collect entity instances • Tabular will usually make more efficient use of screen space • Example project: myBenefits • Containers can also be used inside the entity collect space to control layout Entity collect screen with tabular layout Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 10
Adding Images to Interview Screens Documentation Library • Add images to interview screens as useful visual aids • Add images to screens • Many configuration options available for images, e.g. • Use embedded HTML in horizontal alignment (left, center, right), image size, an interview conditional visibility, clickable link • Refer to images using HTML tags • Images may be placed in • Change control layout containers for further for a screen layout control • Edit a container control (including • Use text substitution to placing other insert different images controls within a depending on the value container) of a substituted attribute • Example project: Energy Saver Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 11
Enhancing Interviews Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 12
Look and Feel of Interviews Documentation Library • Many aspects of the interview look and feel can be set in the • Configure the appearance Styles section of the Interview tab, e.g. color scheme, banner of the interview graphic, heading styles, button location, footer and header • Change the appearance of interview items Interview and the Debugger Styles section in OPM Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 13
Document Generation using BI Publisher Documentation Library • Generate documents from interviews, e.g. letters, forms, etc. • Forms OPM supports creation of RTF, PDF, HTML, XML & Excel forms • Create, update or delete a form • Forms may include text, images, charts, explanations, signatures • Overview of designing a • Note: Requires installation of BI Publisher Desktop. This is a form separate product. It is not part of Oracle Policy Modeling. • Design an RTF template or a PDF template for a form • Add forms to screens • Insert a signature into a form • BI Publisher code for Policy Modeling • Download BI Publisher • Troubleshooting guide for forms • Example: Healthy Eating Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 14
Capture the User’s Location Documentation Library • User’s location (latitude and longitude) may be captured • Capture the user’s during the interview using standard browser location support location • Latitude and longitude may be used in rules, e.g. • Example projects: My Store App, Emergency Generate map URL to Response add to interview screen Compare distance between locations Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 15
Configuring Attribute Value Formats Documentation Library • Default attribute value formats are based on the project • Change the formatting region (for non-Boolean attributes) and the project language of attribute values in an (for Boolean attributes) interview • E.g. If project language = ‘English (American)’ and region = ‘United States (English)’ then: – Default currency symbol: $ – Default date out format: MM/dd/yyyy – Default Boolean values: Yes/No • Default attribute value formats can be modified in: Project > Language > Formatting • Generally will not need to edit default formats, but configuration options are there if needed Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 16
Configuring Standard Message Strings Documentation Library • Default message strings and labels (e.g. standard error text, • Change the text of alt-text, button labels, etc.) can be modified in Interview > buttons, messages and Styles > Strings other built-in interview items • Generally will not need to edit default message strings, but configuration options are there if needed • Note: Button labels (e.g. Next, Back, Submit, Add New Instance, Remove) can also be modified on a per-button basis • To change all occurrences of a message string → modify the default string, e.g. to use ‘Continue’ instead of ‘Next’ as the standard label on a Next button • To change one occurrence of a button label → make the change on the individual screen Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 17
Substitution and Sentence Generation Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 18
Name Substitution Documentation Library • Personalizes the interview for a more user-friendly experience • Personalize attribute • Collect the person’s name early in the interview, then text substitute the name in later questions, e.g. “Does the person • Enable substitution in Policy Modeling have insurance?” becomes “Does John have insurance?” • Understand text • Particularly important when using entities, e.g. “Is the child a substitution full-time student?” becomes “Is Emma a full-time student?”, principles “Is Joshua a full-time student?”, etc. • Combine multiple text strings into a single text • Substituted name automatically appears in attribute text on attribute interview screens and in explanations • If first and last name collected separately, use concatenation to combine if full name needed for substitution in attributes Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 19
Gender Pronoun Substitution Documentation Library • May be used in combination, or in isolation, with name • Personalize attribute substitution to personalize the interview for a more user- text friendly experience, and to provide more natural language text • Enable substitution in Policy Modeling • Gender pronoun substitution requires collecting gender • Substitute a pronoun for a text In combination with name substitution, “Has the attribute applicant submitted the applicant’s tax return?” • Understand text Original rule becomes “Has Christopher submitted his tax return?” generically refers substitution to “the applicant” principles • Collect the gender of a person Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 20
Second Person Sentence Generation Documentation Library • Similar concept to name substitution, but sentences/questions • Display interview text in generated in second person rather than third person second person form • Requires name substitution to be set up first • Also see the articles for Name Substitution • Works with gender pronoun substitution if it has been set up Example: Instead of “Has the Example: Instead of “Does the applicant submitted the applicant’s applicant have health tax return?” it displays “Have you insurance?” it displays “Do submitted your tax return?” you have health insurance?” Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 21
Substituting Names in Labels Documentation Library • Variable values (e.g. person’s name, age, etc.) can be • Personalize attribute substituted into labels on interview screens text • Requires name substitution to be set up first • Enable substitution in Policy Modeling • Understand text Example: The person’s name and age substitution were collected on a previous screen, principles and those values have been substituted into label text on the School screen • Show attribute values on screens • Show attribute • Tip: For substitution in labels, make sure the substitution values in other screen text values will always be known in advance of the screen being displayed, otherwise “unknown” will appear in place of the • View text substitution substitution value examples Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 22
User Input Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 23
Default Values Documentation Library • Can set default values for inputs on interview screens • Provide answer values – Defaults can be specific values, or can be dynamically determined • Specify a default for based on previously collected data, or inferred from rules an input • Reduces the typing/clicking required to complete an interview All currency values have been defaulted to $0. User only needs to edit the fields for which they have income. Reduces manual data entry. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 24
Value Lists Documentation Library • A value list is a way of managing lists of values for attributes • Overview of value lists • A single value list can be attached to multiple attributes, e.g. • Set up a value list in a the person’s home address, the person’s work address project • Associate a value list • Value lists can be created manually, imported from another with an attribute OPM project, or loaded in from a Service Cloud connection or collected on a screen web service connection. • Hide and show individual items in a value list • Value lists can be Value list displayed as • Choose how data is image buttons displayed as lists, collected radio buttons, • Button types text buttons, • List types images, sliders • Example projects: Loan Advisor, myBenefits Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 25
Hint Text Documentation Library • Can supply hint text for inputs on interview screens • Provide answer values – Hint text appears until the user clicks into the input field • Specify hint text • Tip: Always add hint text when the format of the input is important, for example: – Date fields – Any sort of ID number like SSN, TFN, NINO, PHN Hint text showing the required date format Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 26
Validating User Input – Event Rules Documentation Library • Error event and Warning event rules may be used where • Validate user input there is conditional logic associated with the validation, e.g. • Use rules to show – Display the message “Please check the dates of birth. You have errors and warnings indicated that your date of birth is after your child’s date of birth.” if the applicant’s date of birth > the child’s date of birth • Error event: Error message is displayed and the user is prevented from continuing until the situation that triggered the event is no longer present. • Warning event: Warning message is displayed, but the user is able to click past and continue the interview. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 27
Validating User Input – Data Tab Documentation Library • Validation with regular expressions and min/max can be done • Validate user input on the attribute in the Data tab • Specify validations – Error text may be configured on a per attribute basis on individual inputs • Use min/max values if there is no conditional logic for Other info triggering the error, e.g. • http://en.wikipedia.org/ – ‘the person’s age’ field could have a minimum allowable value of wiki/Regular_expression 0 and a maximum of 120 • Use regular expressions to validate the format of an input such as an email address, an SSN, a TFN, a NINO or a PHN, e.g. – ^[0-9]{3}-?[0-9]{2}-?[0-9]{4}$ is a basic SSN validation – allows for NNN-NN-NNNN and NNNNNNNNN Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 28
Input Masks Documentation Library • Masked input text boxes may be used to auto-format data • Choose how data is entered into text fields, e.g. phone numbers, social security collected numbers, product codes, etc. • Text box types – Masked input text Uses the input mask: boxes (999) 999 9999 Uses the input mask: A*999AA* • Input masks can effectively act as a type of validation since the input field won’t allow the user to type offending characters, e.g. an input mask containing only numbers will not allow letters to be entered. • Masked input text boxes can only be used with text attributes. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 29
Language Support Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 30
Adding a Verb to the Default Verb List Documentation Library • Default verb list for the policy model is based on the Rule • Configure the list of Language selected when creating the project recognized verbs • Occasionally you may need a new verb • If a Boolean won’t parse properly, it’s This statement won’t parse as intended as the operative verb (love) a sign the statement’s operative is not in the default verb list. verb may not be in the verb list • Options are to re-word the attribute to use a different operative verb, or add the new verb to the list for the project Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 31
Adding a Translation Layer Documentation Library • Create one or more translation layers, e.g. policy model in • Translate policy models English, interview in choice of English, Spanish or French into other languages • Even a partial translation layer is sufficient to demo the • Create a form in a different language concept. Google Translate can be used for basic demos. Use a • Example project: (human) translation expert for real implementations Travel Compensation • Generated forms can also be created in different languages English … with Spanish … and Chinese policy model translation layer translation layer Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 32
Writing Rules in Other Languages Documentation Library • Many languages available out-of-the-box for rule authoring • Write rules in other – For additional languages, create a custom language parser languages • Change the user interface • Function Reference is available in out-of-the-box languages language for Policy • When creating a new project, select the desired Rule Modeling Language and Rule Region • Change the language of the Policy Automation • Rule Language: Hub – Language in which rule documents are written • Custom language support • Function references in • Rule Region: different languages – Affects currency, numeric and date formatting of data entered and displayed – Affects parsing of currency and number constants in rule docs Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 33
Improving the Explanation Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 34
Intermediate Attributes Documentation Library • Intermediate attributes can be added to make the • Design an explanation Explanation* more meaningful • Add more information – These two examples have identical core logic, but Example 2 to an explanation has a more meaningful Explanation* due to the inclusion of • Add intermediate intermediate attributes rules • Improve the wording of Example 1 Example 2 a rule • Replace grouping operators with new attributes * Explanations previously called Decision Reports Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 35
Rule Tags Documentation Library • Structural elements in legislation (e.g. section, paragraph, • Tag rules with article) and policy (e.g. chapter, guideline) can be captured in references to source rules and displayed in explanations in an interview material • Add more information to an explanation Rule tags in an explanation • Show reference tags in an interview in an explanation • Example project: Travel Compensation Rule with rule tags * Rule Tags previously called Structural Elements. Explanations previously called Decision Reports. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 36
Trimming Explanations – Attributes Documentation Library • Explanations* automatically generated based on the logic, • Hide information in an language and structure of the rules can be extremely verbose explanation • Can trim Explanations using Silent and Invisible settings on the • Hide all attributes in the explanation attribute in the Data tab below a particular – Silent: Hide all logic nested below a particular attribute attribute – Invisible: Hide the attribute only • Hide a particular attribute in the Options for Booleans Options for non-Booleans explanation • Cut off an explanation above a particular attribute * Explanations previously called Decision Reports Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 37
Trimming Explanations – Relationships Documentation Library • Silent and Invisible can be applied to relationships • Hide information in an – See examples below with a containment relationship (the explanation household members) and an inferred relationship (the children) • Hide a relationship in the explanation Invisible set on No trimming Invisible set on both relationships the containment relationship Invisible on containment Invisible on relationship containment Silent and relationship Invisible on Silent on inferred inferred relationship relationship * Explanations previously called Decision Reports Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 38
Documentation and Further Information Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 39
Oracle Technology Network Oracle Policy Automation on the Oracle Technology Network – OPA Documentation Library – Best Practice Documentation – Tutorials, whitepapers, datasheets Ask questions about OPA on the OPA Forum or OPA Cloud Connect Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 40
OPA Social Media OPA on Twitter OPA Discussion Forum OPA on LinkedIn OPA on YouTube OPA Cloud Connect OPA Blog Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 41
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. | 42
You can also read