# Create Decision Table

When you are on the rules list, you can access the Decision Table Architect within the AI Assistant. It lets you generate a custom Decision Table from written, human-readable instructions.

Instead of manually building a rule row by row, you can simply describe your business case, and the assistant will generate a ready-to-use decision table for you. This feature aims to simplify rule creation, especially for users who are new to the platform or working with repetitive decision logic.

<figure><img src="/files/T7c31wAAKzj0Eeb6Rtdn" alt=""><figcaption></figcaption></figure>

## How the Prompt Works

Inside the prompt window, enter your business case and provide some basic information:

* **Your case description** – be as specific and clear as possible, include all important conditions and expected outcomes
* **Input Properties** – the attributes the rule will evaluate (e.g. `age`, `amount`, `status`)
* **Output Properties** – the attributes of the output model (e.g. `approvalStatus`, `interestRate`)

Once this information is provided, the assistant begins building the rule. When the rule is ready, you will see a message confirming it is complete. Click the confirmation button to finalize the creation – then you will be redirected directly to the new rule for review or editing.

## Prompt Examples

{% hint style="info" %}
AI Assistant is limited to generating decision tables with a maximum of **10 rows**. If your described case results in more scenarios, consider simplifying the logic.
{% endhint %}

1. Simple Loan Application Evaluation:

> *I want to evaluate a loan application based on the applicant's age and credit score.*\
> \&#xNAN;*If the age is under 21, the application should be declined.*\
> \&#xNAN;*If the credit score is below 600, also decline.*\
> \&#xNAN;*Otherwise, approve.*\
> \&#xNAN;*Input model properties: `age`, `creditScore`*\
> \&#xNAN;*Output model properties: `approvalStatus`*

2. Fraud Risk Evaluation:

> *I want to assess the fraud risk of a transaction based on payment method, transaction amount, country, and customer verification status.*
>
> * *If payment is "Crypto", amount > 5000, and not verified → High risk*
> * *If payment is "Card", country is in "High-Risk List", and not verified → High risk*
> * *If payment is "BankTransfer", amount > 10000 → Medium risk*
> * *If verified and amount < 1000 → Low risk*
> * *If payment is "Card" or "BankTransfer", country is "Trusted", verified → Low risk*
> * *If payment is "Crypto" and amount < 1000 → Medium risk*
> * *If not verified and country is not known → High risk*
> * *If payment is "Card", amount > 2000, and not verified → Medium risk*
> * *Else → Low risk*
>
> *Input model properties: `paymentMethod`, `amount`, `country`, `isVerified`*\
> \&#xNAN;*Output model properties: `riskLevel`*

If the AI Assistant cannot generate the Decision Table based on your prompt, try to simplify it or re-formulate it. You may also try to change the mode (from Fast to Precise or vice versa).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.decisionrules.io/doc/ai-assistant/ai-assistant-features/create-decision-table.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
