Answer Server 12.12

# Generate a Question Equivalence Rule

You can use the `GetResources` action to suggest a question equivalence rule, based on a set of questions. You can use this to automatically generate an initial question equivalence rule, which you can modify to optimize the rule for your question equivalence class.

For example:

    http://localhost:12000?Action=GetResources&SystemName=MyAnswerbank&Type=rule_suggestion&IDs=9706856188043740111,8129920660480699726,3067998369792637739

This example generates a rule that matches the questions with the IDs `9706856188043740111`, `8129920660480699726`, and `3067998369792637739`.

You can also optionally add additional questions in a text filter, for example to specify the reference question for the question equivalence class that you want to create, or to include questions that do not currently exist in the Answer Bank index.

For example:

    http://localhost:12000?Action=GetResources&SystemName=MyAnswerbank&Type=rule_suggestion&IDs=9706856188043740111,8129920660480699726,3067998369792637739&Filter=%7B%20%22rule_suggestion_text%22%20%3A%20%5B%22How%20do%20I%A0get%20regular%20updates%20about%20MyCompany%3F%22%5D%20%7D

The `Filter` parameter takes a percent-encoded JSON object, which contains the filters to apply. In this case, the unencoded JSON object is:

    { "rule_suggestion_text" : ["How do I get regular updates about MyCompany?"] }

TIP: You can also use `GetResources` to find question equivalence classes that do not have an associated rule, by setting the `Type` parameter to question_equivalence_class, and using the `Filter` parameter to search for the `incoming` state (which is for classes that do not have rules). For example:

    Action=GetResources&SystemName=MyAnswerbank&Type=question_equivalence_class&Filter=%7B%20%22state%22%3A%20%22incoming%22%20%7D

This corresponds to the following filter:

    { "state" : "incoming" }

You can modify the question equivalence rule as required, and add it to the question equivalence class by using the `ManageResources` action. See Update a Question Equivalence Class.

You can also test that the question equivalence rule matches all the rules that you want to add to the question class by using the `GetResources` action. See Test Your Question Equivalence Rule.

© Copyright 2015-2022 Micro Focus or one of its affiliates
Version 12.12 | Last updated June 2022

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to swpdl.idoldocsfeedback@microfocus.com.

We appreciate your feedback!

Product: IDOL Answer Server 12.12

Topic Title: Generate a Question Equivalence Rule