{
  "name": "Mario Speaker",
  "nodes": [
    {
      "parameters": {
        "resource": "audio",
        "operation": "transcribe",
        "binaryPropertyName": "file0",
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "typeVersion": 1.8,
      "position": [
        320,
        -176
      ],
      "id": "97d65a7e-2eab-4c5c-9520-8fb264fffc9e",
      "name": "OpenAI",
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "a897cbf4-f60a-493f-814d-75093074c478",
              "name": "conversation",
              "value": "={{ $json.output }}",
              "type": "string"
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        1024,
        -64
      ],
      "id": "08341bc6-6156-40ba-a1da-bee76e1bf8e2",
      "name": "formatToLLM1"
    },
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "948e960f-5467-4126-9bf2-3d9e8b8e26a7",
        "responseMode": "responseNode",
        "options": {
          "binaryPropertyName": "file"
        }
      },
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2.1,
      "position": [
        -320,
        -176
      ],
      "id": "0627547f-5b88-4e86-9d84-1b666ca16c3e",
      "name": "Webhook"
    },
    {
      "parameters": {
        "respondWith": "allIncomingItems",
        "options": {}
      },
      "type": "n8n-nodes-base.respondToWebhook",
      "typeVersion": 1.4,
      "position": [
        1280,
        -176
      ],
      "id": "14b2822e-fa29-49cd-a05f-0d4a5f5d6005",
      "name": "Respond to Webhook"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "={{ $json.text }}",
        "options": {
          "systemMessage": "Voc\u00ea \u00e9 o Mario Bros, fale como ele e quero respostas muito curtas e sem emojis ou caracteres especiais, mas pode usar pontua\u00e7\u00e3o para dar emo\u00e7\u00e3o na fala. Lembra que vou ler em voz alta pro humano. "
        }
      },
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 2.2,
      "position": [
        640,
        -192
      ],
      "id": "bd960657-0c1d-4e52-9edd-df0e70ac29fd",
      "name": "AI Agent"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "gpt-4o-mini",
          "mode": "list",
          "cachedResultName": "gpt-4o-mini"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        640,
        32
      ],
      "id": "ffae52be-9d3b-49f0-93cb-b7079d9bd1b6",
      "name": "OpenAI Chat Model",
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "sessionIdType": "customKey",
        "sessionKey": "1"
      },
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "typeVersion": 1.3,
      "position": [
        816,
        176
      ],
      "id": "73c1764c-af27-4fe2-b183-7dacebb7f0bd",
      "name": "Simple Memory"
    }
  ],
  "connections": {
    "OpenAI": {
      "main": [
        [
          {
            "node": "AI Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Webhook": {
      "main": [
        [
          {
            "node": "OpenAI",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "formatToLLM1": {
      "main": [
        [
          {
            "node": "Respond to Webhook",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Simple Memory": {
      "ai_memory": [
        [
          {
            "node": "AI Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent": {
      "main": [
        [
          {
            "node": "formatToLLM1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": true,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "c9ab0c3b-c504-48c7-9231-bc5ff543253c",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "id": "fbEihV5aq7GIzJdt",
  "tags": []
}