{
    "Node": {
        "$comment": "This node is like a box of chocolates - you never know what you're gonna get",
        "description": [
            "This node is part of the OmniGraph node writing examples.",
            "It is structured to include node and attribute information illustrating the .ogn format"
        ],
        "version": 1,
        "exclude": ["c++", "docs", "icon", "python", "template", "tests", "usd"],
        "language": "python",
        "memoryType": "cuda",
        "metadata": {
            "author": "Bertram P. Knowedrighter"
        },
        "tokens": "apple",
        "tags": "fruit,example,chocolate",
        "uiName": "OmniGraph Example Node",
        "$emptyAttributeLists": {
            "uiName": "OmniGraph Example Node",
            "inputs": {
            },
            "outputs": {
            },
            "state": {
            }
        },
        "inputs": {
            "numberOfLimbs": {
                "description": "The number of limbs present in the generated character",
                "type": "int",
                "default": 4,
                "optional": true,
                "memoryType": "cpu",
                "minimum": 2,
                "maximum": 8,
                "metadata": {
                    "disclaimer": "There is no distinction between 8-limbed spiders and 8-limbed Octopii"
                },
                "uiName": "Number Of Limbs"
            }
        },
        "outputs": {
        },
        "tests": [
            { "inputs:firstAddend": 1, "inputs:secondAddend" : 2, "outputs:sum": 3 },
            { "inputs:secondAddend": 5, "outputs:sum": 5 },
            {
                "inputs": {
                    "t0": 40320,
                    "t1": -109584,
                    "t2": 118124,
                    "t3": -67284,
                    "t4": 22449,
                    "t5": -4536,
                    "t6": 546,
                    "t7": -36,
                    "t8": 1
                },
                "outputs": { "roots": [1, 2, 3, 4, 5, 6, 7, 8] }
            },
            {
                "inputs:isGpu": true,
                "inputs:points": [[1.0, 2.0, 3.0], [2.0, 3.0, 4.0]],
                "inputs:multiplier": [2.0, 3.0, 4.0],
                "outputs:points": [[2.0, 6.0, 12.0], [4.0, 9.0, 16.0]],
                "gpu": ["outputs:points"]
            },
            {
                "inputs:multiplier": 2.0,
                "inputs:element": {"type": "float", "value": 6.0},
                "outputs:tuple": {"type:": "float[3]", "value": [12.0, 12.0, 12.0]}
            }
        ],
        "$tokenExamples": "Other types of token access, nested solely for documentation purposes",
        "$tokensWithArrayValue": {
            "metadata": {
                "author": "Bertram P. Knowedrighter"
            },
            "tokens": ["apple", "pear", "orange"],
            "uiName": "OmniGraph Example Node"
        },
        "$tokensWithNamedArrayValue": {
            "metadata": {
                "author": "Bertram P. Knowedrighter"
            },
            "tokens": { "apple": "Granny Smith", "pear": "Bosc Pear", "orange": "Florida Navel Orange"},
            "uiName": "OmniGraph Example Node"
        },
        "$iconPathOverride": {
            "exclude": ["c++", "docs", "icon", "python", "template", "tests", "usd"],
            "icon": "icons/CompanyLogo.svg",
            "language": "python"
        },
        "$iconPathWithColor": {
            "exclude": ["c++", "docs", "icon", "python", "template", "tests", "usd"],
            "icon": {
                "path": "icons/CompanyLogo.svg",
                "color": "#FF123456",
                "backgroundColor": [86, 52, 18, 255],
                "borderColor": "#FF3E3E3E"
            },
            "language": "python"
        },
        "$testsWithExtendedDataTypes": {
            "tests": [
                { "inputs:firstAddend": {"int": 1}, "inputs:secondAddend" : {"int": 2}, "outputs:sum": 3 },
                { "inputs:firstAddend": {"float": 1.5}, "inputs:secondAddend" : {"float": 2.5}, "outputs:sum": 4.0 }
            ]
        },
        "$singletonMetadata": {
            "language": "python",
            "singleton": true,
            "memoryType": "cuda"
        },
        "$testsThatGetAndSetStateVariables": {
            "tests": [
                { "state_set:counter": 9, "state_get:counter": 10 },
                { "state_set:counter": 5, "state:counter": 6 },
                {
                    "state_set": {
                        "counter": 9
                    },
                    "state_get": {
                        "counter": 10
                    }
                },
                {
                    "state_set": {
                        "counter": 5
                    },
                    "state": {
                        "counter": 6
                    }
                }
            ]
        },
        "$testsThatSetUpAGraph": {
            "tests": [
                {
                    "inputs": {
                        "firstAddend": 1
                    },
                    "outputs": {
                        "sum": 3
                    },
                    "setup": {
                        "create_nodes": [
                            ["TestNode", "omni.graph.examples.Node"]
                        ],
                        "create_prims": [
                            [["Prim1", {"attrInt": ["int", 2]}]]
                        ],
                        "connect": [
                            ["Prim1", "attrInt", "TestNode", "inputs:secondAddend"]
                        ]
                    }
                },
                {
                    "inputs:firstAddend": 10, "outputs:sum": 12
                }
            ]
        },
        "$optionalComputeAttribute": {
            "inputs": {
                "useInput1": {
                    "type": "bool",
                    "description": "If true then output the first input"
                },
                "firstInput": {
                    "type": "any",
                    "description": "First attribute to be checked",
                    "unvalidated": true
                },
                "secondInput": {
                    "type": "any",
                    "description": "Second attribute to be checked",
                    "unvalidated": true
                }
            }
        },
        "$schedulingHintsAsList": {
            "version": 1,
            "scheduling": ["global-write", "usd"],
            "language": "python"
        },
        "$schedulingHintsAsString": {
            "version": 1,
            "scheduling": "global-write,usd",
            "language": "python"
        },
        "$allowedTokens": {
            "inputs": {
                "operator": {
                    "type": "token",
                    "description": "The mathematical operator to apply",
                    "metadata": {
                        "allowedTokens": ["lt", "gt", "ne"]
                    }
                }
            }
        },
        "$allowedTokensSpecial": {
            "inputs": {
                "operator": {
                    "type": "token",
                    "description": "The mathematical operator to apply",
                    "metadata": {
                        "allowedTokens": {
                            "lt": "<",
                            "gt": ">",
                            "ne": "!="
                        }
                    }
                }
            }
        },
        "$outputOnly": {
            "inputs": {
                "defaultSpeed": {
                    "type": "double",
                    "description": [ "Default speed for interpolations. By connecting all 'Interpolate To' nodes to",
                                    "this the user can set it in just one place." ],
                    "metadata": {
                        "outputOnly": "1"
                    }
                }
            }
        },
        "$cudaPointers": {
            "metadata": {
                "author": "Bertram P. Knowedrighter"
            },
            "cudaPointers": "cpu",
            "uiName": "OmniGraph Example Node"
        },
        "$literalOnly": {
            "inputs": {
                "keyIn": {
                    "type": "token",
                    "description": "The key to trigger the downstream execution",
                    "metadata": {
                        "literalOnly": "1"
                    }
                }
            }
        },
        "$hidden": {
            "inputs": {
                "appearanceHint": {
                    "description": "Hint to shader writer of how the limbs should be colored.",
                    "type": "string",
                    "optional": true,
                    "metadata": {
                        "hidden": "true"
                    }
                }
            }
        },
        "$internal": {
            "inputs": {
                "debugFlags": {
                    "description": "Debugging flags. For internal use only.",
                    "type": "int",
                    "optional": true,
                    "metadata": {
                        "internal": "true"
                    }
                }
            }
        },
        "$deprecated": {
            "inputs": {
                "offset": {
                    "description": "Value to be added to the result, after 'scale' has been applied.",
                    "type": "float",
                    "default": 0.0,
                    "optional": true,
                    "deprecated": "Use 'minValue' instead."
                },
                "scale": {
                    "description": "Value to multiply the result by, before 'offset' has been applied.",
                    "type": "float",
                    "default": 1.0,
                    "optional": true,
                    "deprecated": [
                        "Use 'maxValue' instead.",
                        "To reproduce the same behavior as before, set 'maxValue' to 'scale' + 'offset'."
                    ]
                }
            }
        },
        "$uiType": {
            "description": "Holds a 3-component float constant displayed as a color.",
            "inputs": {
                "value": {
                    "type": "float[3]",
                    "description": "The constant value",
                    "metadata": {
                        "uiType": "color"
                    }
                }
            }
        },
        "$categories": {
            "description": "This is some kind of math array conversion node",
            "categories": "math:array,math:conversion"
        }
}
}