Skip to content

DecisionsDev/Decision-Automation-Interchange-Format

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

Decision Automation Interchange Format

Purpose

A structured, portable JSON format for describing a complete decision automation project—including data models, decision logic, dependencies, and metadata.
The aim is to facilitate the creation of automation projects in IBM ODM by using a canonical abstraction format hiding the details of the persistence and implementation of such a project. You can use this format to create new projects manually or through any programmatic tools including AI.

Overview

The Decision Automation Interchange Format enables the specification and exchange of decision services using a platform-agnostic, human-readable JSON schema. It supports:

  • Project metadata for cataloging and governance
  • Structured data models (Business Object Model classes)
  • Task Model (aka RuleFlow) orchestrating the flow of evaluation of tasks nodes and transitions, including explicit dependencies and execution policies
  • Rule Packages to structure the rules
  • Rule-based artifacts with near natural-language logic

Document Structure

{
  "kind": "DecisionService",
  "metadata": { ... },
  "datamodel": { ... },
  "operation": { ... },
  "taskmodel": { ... }
}

Metadata

Overview

The datamodel section defines all the data classes used by the decision logic.

Field Type Description
name string Internal ID or key name
display_name string Human-readable title
description string Long description (optional)
summary string Short summary (optional)
locale string Language and region code (e.g. en-US)
publisher string Author or organization (optional)

Example

"metadata": {
    "display_name": "Fuselage Inspection",
    "name": "FuselageInspection"
  }

Data Model

Overview

The datamodel section defines all the data classes used by the decision logic.

"datamodel": {
  "classes": [ ... ]
}

Class Definition

Each class includes:

  • name (string): Canonical class name
  • jsonname (string): JSON-serializable name
  • description (string): Class description
  • Fields (array):
    • name: Field name
    • type: Primitive (string, boolean, integer, date) or reference to another class
    • collection: Whether it's a list (optional)
    • description: Explanation
    • templates (optional): Verbalization templates (e.g., getter, setter)

Example

"datamodel": {
    "name": "Fuselage dataModel",
    "classes": [
      {
        "name": "InspectionDetails",
        "jsonname": "InspectionDetails",
        "description": "Inspection details",
        "Fields": [
          {
            "name": "aircraft",
            "type": "Aircraft",
            "description": "the aircraft to check"
          },
          {
            "name": "check date",
            "type": "date",
            "description": "the date of the Airworthiness Status"
          }
        ]
      },
      {
        "name": "Aircraft",
        "jsonname": "Aircraft",
        "description": "The Aircraft",
        "Fields": [
          {
            "name": "series",
            "type": "string",
            "description": "the model series"
          },
          {
            "name": "flight cycles",
            "type": "integer",
            "description": "the number of flight cycles"
          }
        ]
      }

Operation

Overview

Defines the interface of the decision service.

"operation": {
  "name": "OperationName",
  "parameters": [ ... ]
}

Example

"operation": {
    "name": "Fuselage operation",
    "parameters": [
      {
        "name": "InspectionDetails",
        "type": "InspectionDetails",
        "verbalization": "the inspection details",
        "description": "Details of the fuselage inspection",
        "direction": "in"
      },
      {
        "name": "AirworthinessStatus",
        "type": "AirworthinessStatus",
        "verbalization": "the airworthiness status",
        "description": "The result of the inspection",
        "direction": "out"
      }
    ]
  },

Task Model

Overview

Defines decision logic packages and the rule execution flow.

"taskmodel": {
    "packages": [ ...],
    "ruleFlow": {
      "name": "myRuleFlow",
      "ruleTasks": [ ... ]
    }

Rule Packages

Structures the logic into folders.

Rule Flow

Defines the execution sequence and dependency between tasks.

Example

  "taskmodel": {
    "packages": [
      {
        "name": "Initialization",
        "artifacts": [
          {
            "type": "rule",
            "name": "Default rule",
            "bal": "then set 'the airworthiness status' to a new airworthiness status where eligible is false, compliant is true;"
          }
        ]
      },
      {
        "name": "Eligibility",
        "artifacts": [
          {
            "type": "rule",
            "name": "Applicability rule",
            "bal": "if the series of the aircraft of 'the inspection details' is one of { \"A390-100\", \"A390-250\" } then make it true that 'the airworthiness status' is eligible;"
          },
          {
            "type": "rule",
            "name": "MSN rule",
            "bal": "if the MSN of the aircraft of 'the inspection details' is at most 0201 and the MSN of the aircraft of 'the inspection details' is not 010 then make it true that 'the airworthiness status' is eligible;"
          }
        ]
      },
      {
        "name": "Compliance",
        "artifacts": [
          {
            "type": "rule",
            "name": "Eligibility rule",
            "bal": "if it is not true that 'the airworthiness status' is eligible then set compliance of 'the airworthiness status' to false;"
          },
          {
            "type": "rule",
            "name": "Effective date rule",
            "bal": "if the check date of 'the inspection details' is after 4/1/2010 then set compliance of 'the airworthiness status' to false;"
          },
        ]
      }
    ],
    "ruleFlow": {
      "name": "myRuleFlow",
      "ruleTasks": [
        {
          "name": "initialization",
          "algorithm": "default",
          "select": [
            "Initialization"
          ],
          "requirements": []
        },
        {
          "name": "eligibility",
          "algorithm": "default",
          "exitCriteria": "ruleinstance",
          "ordering": "literal",
          "select": [
            "Eligibility"
          ],
          "requirements": [
            {
              "from": "initialization"
            }
          ]
        },
        {
          "name": "compliance",
          "algorithm": "default",
          "exitCriteria": "ruleinstance",
          "ordering": "literal",
          "select": [
            "Compliance"
          ],
          "requirements": [
            {
              "from": "eligibility",
              "condition": "it is not true that 'the airworthiness status' is compliant"
            }
          ]
        }
      ]
    }
  }

About

Decision Automation Interchange Format

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published