Skip to content
Proud to collaborate with Microsoft for Startups

dgi.synapse.map_capabilities ​

Map operations to library_ids, identify missing params

Map decomposed operations to real workflow library_ids.

The third synapse (runs parallel with check_auth). Takes operations from decompose and maps each to a registered workflow type, identifying which parameters are available and which are missing.

Inputs:

  • operations: list of operation dicts from dgi.synapse.decompose (required)
  • parameter_flow: dict from decompose (required)
  • understanding: dict from dgi.synapse.understand (required)
  • workflow_catalog: list of workflow descriptors with schemas (required)

Outputs (terminal state_data):

  • mappings: list of mapping dicts with library_id, param_mapping, missing_params
  • unmapped_operations: list of operation IDs that couldn't be mapped
  • all_missing_params: consolidated list of params the user needs to provide
  • input_tokens: int
  • output_tokens: int

Plugin required: context.get_plugin("ai")

Overview ​

PropertyValue
Workflow typeAtomic
LibraryApp-dgi
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
connection_uuiduuidNo—Explicit AI CloudConnection UUID — threaded to ai.chat.complete so synapse uses the org's resolved connection (org-context-free)
modelstringNo—Optional model override threaded to ai.chat.complete
operationsjsonYes—Operations from decompose
parameter_flowjsonYes—Parameter flow from decompose
understandingjsonYes—Understanding from understand
workflow_catalogjsonYes—Workflow descriptors with schemas

Output Schema ​

FieldTypeRequiredDefaultDescription
all_missing_paramslistNo——
input_tokensintegerNo——
mappingslistNo——
output_tokensintegerNo——
unmapped_operationslistNo——
connection_uuiduuidNo——
modelstringNo——
operationsjsonNo——
parameter_flowjsonNo——
understandingjsonNo——
workflow_catalogjsonNo——
failure_reasonstringNo——
failure_typestringNo——
failed_actionstringNo——
failed_at_statestringNo——
failed_stepstringNo——
failed_layerstringNo——
errorstringNo——
error_typestringNo——

States ​

StateInitialTerminalSuccessAuto-advanceDescription
pendingYesNo—execute—
completedNoYesYes——
failedNoYesNo——

State Diagram ​

Transitions ​

FromActionToDescription
pendingexecutecompleted—
* (any state)failfailed—

API Usage ​

bash
POST /api/workflows/start
Content-Type: application/json

{
  "workflow_type": "dgi.synapse.map_capabilities",
  "initial_data": {
    "operations": "value",
    "parameter_flow": "value",
    "understanding": "value",
    "workflow_catalog": "value"
  }
}