Decision Tree

Decision Tree

The Decision Tree model in Scorport allows for powerful conditional decision-making through a visual, logic-driven framework. Designed with scalability and flexibility in mind, decision trees can handle complex scenarios with real-time input data and calculated variables.

Note: Creation of Decision Trees begins directly in the Strategy Designer, where users can integrate their decision logic into broader workflows. This ensures a seamless transition from decision-making to execution.


What Is a Decision Tree?

A Decision Tree is a branching logic framework that allows users to define outcomes based on multiple conditions. With Scorport, users can visually build and customize decision trees using If, Else logic. Decision trees dynamically evaluate input data, calculated variables, or external inputs to guide decisions.


Key Features

  1. Dynamic Conditions:

    • Use logical statements such as If, Else, or Else If to define decision pathways.
    • Combine conditions based on input data and calculated variables.
  2. Scalable Depth:

    • Build deeply nested trees with no limitations on the number of branches or conditions.
  3. Pre-Built Formulas:

    • Leverage Scorport’s library of user-friendly formulas (e.g., Age between (30–45], Income > 50,000).
    • These formulas simplify the creation of complex conditions.
  4. Seamless Integration:

    • Decision Trees are created directly within the Strategy Designer, enabling integration with workflows and other modules.
  5. Automated Execution:

    • The logic is processed in real time, ensuring fast and accurate decision-making.

How to Create a Decision Tree

Step 1: Start in the Strategy Designer

  • Navigate to the Strategy Designer module.
  • Build Decision Tree as part of your strategy workflow.
  • Add input Json file (Applicant data) to the Input

Applicant Data 

{
  "applicant": {
    "gender": "Male",
    "age": 35,
    "income": 60000,
    "credit_score": 750
  }
}

 

Step 2: Define the Root Condition

  • The root condition serves as the entry point for the decision tree.
  • Specify the first logical condition (e.g., If Applicant is Male).

Step 3: Add Subsequent Conditions

  • Define additional branches based on the outcomes of the root condition. For each branch, specify:
    • The condition to evaluate.
    • The logic for the outcome (Yes, No, Else).

Step 4: Assign Outcomes

  • At the end of each branch, define the desired outcome (e.g., Approve, Deny, Further Review).
  • Outcomes can trigger actions in other modules or external systems.

Step 5: Fine-Tune and Test

  • Use Scorport’s formula library to refine conditions.
  • Test the decision tree with sample inputs to ensure the logic behaves as expected.

Example: Loan Approval Decision Tree

This decision tree evaluates loan applications based on gender, age, income, and credit score.

image.png

Decision Tree Flow:

Root Condition: If Applicant is Male:
  • Yes → Proceed to check age.
  • No → If Applicant is Female:
    • Continue with a different tree for female applicants (e.g., evaluate additional criteria).
Next Condition: If Age is between (30–45]:
  • Yes → Check income.
  • No → Deny loan (Outcome: No).
Next Condition: If Income > $50,000:
  • Yes → Approve loan (Outcome: Yes).
  • No → Further review (Outcome: Maybe).
Final Condition: If Credit Score > 700:
  • Yes → Approve premium loan (Outcome: Yes).
  • No → Approve standard loan (Outcome: Yes).

Example Breakdown:

  1. Applicant A:

    • Gender: Male → Yes.
    • Age: 35 → Yes.
    • Income: $60,000 → Yes.
    • Credit Score: 750 → Premium Loan Approved.
  2. Applicant B:

    • Gender: Female → New tree logic applies.
    • Age: 28 → Denied in new tree.
    • Income: $40,000 → No further processing.

Benefits of Decision Trees

  1. Scalability:

    • Handle increasingly complex decision logic without limitations.
  2. Customizable:

    • Easily adjust conditions, logic, and outcomes to match evolving business needs.
  3. Visual Simplicity:

    • Drag-and-drop functionality makes it easy to design and manage even intricate workflows.
  4. Real-Time Automation:

    • Integrated execution ensures decisions are made accurately and efficiently.

The Decision Tree model in Scorport is an indispensable tool for managing conditional decision-making. By designing logic directly within the Strategy Designer, users can create intelligent and dynamic workflows tailored to their unique business requirements.