Documentation Index
Fetch the complete documentation index at: https://dev.docs.inworld.ai/llms.txt
Use this file to discover all available pages before exploring further.
Overview > Inworld Graph Asset
Class: UInworldGraphAsset | Inherits from: UObject
Asset representation of an Inworld graph for serialization and storage. This class serves as the asset representation of an Inworld graph, containing all nodes, edges, and configuration data necessary to create and execute runtime graphs. It provides functionality for graph validation, configuration generation, and runtime graph instance creation.
Methods
Reference
GetGraphConfig
Retrieves the graph configuration as a string.
Examples
const FString& GetGraphConfig()
Returns
Type: const FString&
Description: The graph configuration string.
GetGraphInstance
Creates and returns a compiled graph instance asynchronously.
Examples
void GetGraphInstance(FOnGraphCompiled Callback)
Parameters
| Parameter | Type | Description |
|---|
| Callback | FOnGraphCompiled | Delegate called when the graph instance is ready. |
GetGraphInstance
Examples
GetLevelNum
Gets the number of levels in the graph hierarchy.
Examples
Returns
Type: int
Description: The number of levels in the graph.
GetNodesByLevel
Retrieves all nodes at a specific level in the graph hierarchy.
Examples
void GetNodesByLevel(
int Level,
TArray<UInworldNodeAsset*>& Nodes
)
Parameters
| Parameter | Type | Description |
|---|
| Level | int | The level to query for nodes. |
| Nodes | TArray<UInworldNodeAsset*>& | Output array of nodes at the specified level. |
IsValidAsSubgraph
Checks if this graph asset is valid for use as a subgraph.
Examples
Returns
Type: bool
Description: True if the graph can be used as a subgraph, false otherwise.
Print
Prints debug information about the graph.
Examples
void Print(
bool ToConsole,
bool ToScreen
)
Parameters
| Parameter | Type | Description |
|---|
| ToConsole | bool | If true, prints to console output. |
| ToScreen | bool | If true, prints to screen overlay. |