Skip to content

Commit

Permalink
✨ (openai) Add create speech OpenAI action
Browse files Browse the repository at this point in the history
Closes #1025
  • Loading branch information
baptisteArno committed Nov 20, 2023
1 parent f6ac389 commit 1a44bf4
Show file tree
Hide file tree
Showing 23 changed files with 1,772 additions and 74 deletions.
2 changes: 1 addition & 1 deletion apps/builder/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
"nextjs-cors": "2.1.2",
"nodemailer": "6.9.3",
"nprogress": "0.2.0",
"openai": "4.11.1",
"openai": "4.19.0",
"papaparse": "5.4.1",
"posthog-js": "1.77.1",
"posthog-node": "3.1.1",
Expand Down
206 changes: 206 additions & 0 deletions apps/builder/public/templates/audio-chat-gpt.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,206 @@
{
"version": "6",
"id": "clp6onbn200011ab379x5gnea",
"name": "Audio ChatGPT",
"icon": "🔈",
"events": [
{
"id": "ewnfbo0exlu7ihfu2lu2lusm",
"outgoingEdgeId": "knz1ln1so0dfyth76qjkjn1p",
"graphCoordinates": { "x": -228.25, "y": -123.31 },
"type": "start"
}
],
"groups": [
{
"id": "qfrz5nwm63g12dajsjxothb5",
"title": "User input",
"graphCoordinates": { "x": 105.17, "y": -56.29 },
"blocks": [
{
"id": "ovgk70u0kfxrbtz9dy4e040o",
"type": "text input",
"options": { "variableId": "vudksu3zyrat6s1bq6qne0rx3" }
},
{
"id": "m4jadtknjb3za3gvxj1xdn1k",
"outgoingEdgeId": "fpj0xacppqd1s5slyljzhzc9",
"type": "Set variable",
"options": {
"variableId": "vabkycu0qqff5d6ar2ama16pf",
"type": "Append value(s)",
"item": "{{User Message}}"
}
}
]
},
{
"id": "a6ymhjwtkqwp8t127plz8qmk",
"title": "ChatGPT reply",
"graphCoordinates": { "x": 445.12, "y": -56.2 },
"blocks": [
{
"id": "xikptnw1lp1qxdqo10qhmwy1",
"type": "OpenAI",
"options": {
"task": "Create chat completion",
"model": "gpt-3.5-turbo",
"messages": [
{
"id": "wsdxha9db58gk2v9n1j10m7c",
"role": "Dialogue",
"dialogueVariableId": "vabkycu0qqff5d6ar2ama16pf",
"startsBy": "user"
}
],
"responseMapping": [
{
"id": "p8ksqi2jhyzid2od3dikv299",
"valueToExtract": "Message content",
"variableId": "vni6kwbch8zlq92dclgcivzyr"
}
],
"credentialsId": "clp6ooc3700031ab30yof27jm"
}
},
{
"id": "yblc864bzipaqfja7b2o3oo0",
"type": "Set variable",
"options": {
"variableId": "vabkycu0qqff5d6ar2ama16pf",
"type": "Append value(s)",
"item": "{{Assistant Message}}"
}
},
{
"id": "prsimdxdol42ty2parzgx8am",
"type": "OpenAI",
"options": {
"credentialsId": "clp6ooc3700031ab30yof27jm",
"task": "Create speech",
"model": "tts-1",
"input": "{{Assistant Message}}",
"voice": "alloy",
"saveUrlInVariableId": "vgr0iwg95npp7pztkmdyn89m1"
}
},
{
"id": "f6onszqys2tx7pw3tshb2vcy",
"outgoingEdgeId": "dw9jclv60i040saiikj3a386",
"type": "audio",
"content": { "url": "{{Assistant audio message}}" }
}
]
},
{
"id": "c5f00f3oclwi1srcz10jjt9u",
"title": "Intro",
"graphCoordinates": { "x": -222.61, "y": -54.39 },
"blocks": [
{
"id": "dp5gx25j73fgmcj9582ydik9",
"type": "OpenAI",
"options": {
"credentialsId": "clp6ooc3700031ab30yof27jm",
"task": "Create speech",
"model": "tts-1",
"input": "Hi there! How can I help?",
"voice": "alloy",
"saveUrlInVariableId": "vxw4quja426402hvhtm33tsp3"
}
},
{
"id": "dmab8kc35uh84vvw1a53xbjn",
"outgoingEdgeId": "xnao10ucc1hbynv3pmk1t4by",
"type": "audio",
"content": { "url": "{{Welcome audio}}" }
}
]
},
{
"id": "yswu9fml4zflxaqlujb94ir8",
"title": "",
"graphCoordinates": { "x": 19.51, "y": -338.93 },
"blocks": [
{
"id": "okm2zz32zn8b60u1vkfrv9ca",
"type": "text",
"content": {
"richText": [
{
"type": "p",
"children": [
{
"text": "You need to add your OpenAI credentials to make this bot work. 🪄"
}
]
}
]
}
},
{
"id": "m5a1d0vhsrpyvvvyj89awxzc",
"type": "text",
"content": {
"richText": [
{
"type": "p",
"children": [
{
"text": "Once it's done, delete this group and connect the "
},
{ "text": "Start", "bold": true },
{ "text": " event with " },
{ "text": "Intro", "bold": true },
{ "text": " 🚀\n" }
]
}
]
}
}
]
}
],
"edges": [
{
"id": "fpj0xacppqd1s5slyljzhzc9",
"from": { "blockId": "m4jadtknjb3za3gvxj1xdn1k" },
"to": { "groupId": "a6ymhjwtkqwp8t127plz8qmk" }
},
{
"id": "xnao10ucc1hbynv3pmk1t4by",
"from": { "blockId": "dmab8kc35uh84vvw1a53xbjn" },
"to": { "groupId": "qfrz5nwm63g12dajsjxothb5" }
},
{
"id": "dw9jclv60i040saiikj3a386",
"from": { "blockId": "f6onszqys2tx7pw3tshb2vcy" },
"to": { "groupId": "qfrz5nwm63g12dajsjxothb5" }
},
{
"from": { "eventId": "ewnfbo0exlu7ihfu2lu2lusm" },
"to": { "groupId": "yswu9fml4zflxaqlujb94ir8" },
"id": "knz1ln1so0dfyth76qjkjn1p"
}
],
"variables": [
{ "id": "vni6kwbch8zlq92dclgcivzyr", "name": "Assistant Message" },
{ "id": "vudksu3zyrat6s1bq6qne0rx3", "name": "User Message" },
{ "id": "vabkycu0qqff5d6ar2ama16pf", "name": "Chat history" },
{ "id": "vxw4quja426402hvhtm33tsp3", "name": "Welcome audio" },
{ "id": "vgr0iwg95npp7pztkmdyn89m1", "name": "Assistant audio message" }
],
"theme": {},
"selectedThemeTemplateId": null,
"settings": {},
"createdAt": "2023-11-20T09:06:40.430Z",
"updatedAt": "2023-11-20T09:20:01.662Z",
"folderId": null,
"publicId": null,
"customDomain": null,
"workspaceId": "freeWorkspace",
"resultsTablePreferences": null,
"isArchived": false,
"isClosed": false,
"whatsAppCredentialsId": null
}
Loading

4 comments on commit 1a44bf4

@vercel
Copy link

@vercel vercel bot commented on 1a44bf4 Nov 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vercel
Copy link

@vercel vercel bot commented on 1a44bf4 Nov 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

docs – ./apps/docs

docs-typebot-io.vercel.app
docs-git-main-typebot-io.vercel.app
docs.typebot.io

@vercel
Copy link

@vercel vercel bot commented on 1a44bf4 Nov 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

builder-v2 – ./apps/builder

builder-v2-git-main-typebot-io.vercel.app
builder-v2-typebot-io.vercel.app
app.typebot.io

@vercel
Copy link

@vercel vercel bot commented on 1a44bf4 Nov 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

viewer-v2 – ./apps/viewer

apr.nigerias.io
aso.nigerias.io
baohanh.qmap.vn
blackcan.cr8.ai
blackvip.online
bot.4display.nl
bot.a6t-you.com
bot.artiweb.app
bot.devitus.com
bot.neobank.fun
bot.reeplai.com
bot.scayver.com
bot.tc-mail.com
carspecs.lam.ee
chat.borang.net
chat.lalmon.com
chat.sureb4.com
conversawpp.com
eventhub.com.au
feiraododia.com
fitness.riku.ai
games.klujo.com
iludogaming.com
ironcitygym.com
localove.online
marksteward.org
mikestuward.org
projektelco.com
proscale.com.br
ren.hartawan.my
sellmycarbr.com
sniperclass.com
svhmapp.mprs.in
tanjakoil.store
typebot.aloe.do
web.ofilipi.com
acordo-certo.com
app-liberado.pro
ask.pemantau.org
batepapo.digital
bot.contakit.com
bot.imovfast.com
bot.lafabri.link
bot.neobank.tech
bot.piccinato.co
bot.synclab.help
chat.sifucrm.com
chat.syncwin.com
chatonlineja.com
bot.thegymgame.it
bot.uluhub.com.br
cares.urlabout.me
chat.ezbooking.ai
chat.gaswadern.de
chat.gniorder.com
chat.leadmagic.io
viewer-v2-typebot-io.vercel.app
mdb.assessoria.girotto.progenbr.com
mdb.assessoria.marinho.progenbr.com
mdb.assessoria.rodrigo.progenbr.com
register.thailandmicespecialist.com
mdb.assessoria.desideri.progenbr.com
mdb.assessoria.fernanda.progenbr.com
mdb.assessoria.jbatista.progenbr.com
mdb.assessoria.mauricio.progenbr.com
mdb.evento.autocadastro.progenbr.com
form.shopmercedesbenzsouthorlando.com
mdb.evento.equipeinterna.progenbr.com
bot.studiotecnicoimmobiliaremerelli.it
mdb.assessoria.boaventura.progenbr.com
mdb.assessoria.jtrebesqui.progenbr.com
pesquisa.escolamodacomproposito.com.br
anamnese.clinicaramosodontologia.com.br
gabinete.baleia.formulario.progenbr.com
mdb.assessoria.carreirinha.progenbr.com
chrome-os-inquiry-system.itschromeos.com
mdb.assessoria.paulomarques.progenbr.com
viewer-v2-git-main-typebot-io.vercel.app
main-menu-for-itschromeos.itschromeos.com
mdb.assessoria.qrcode.ademir.progenbr.com
mdb.assessoria.qrcode.arthur.progenbr.com
mdb.assessoria.qrcode.danilo.progenbr.com
mdb.assessoria.qrcode.marcao.progenbr.com
mdb.assessoria.qrcode.marcio.progenbr.com
mdb.assessoria.qrcode.aloisio.progenbr.com
mdb.assessoria.qrcode.girotto.progenbr.com
mdb.assessoria.qrcode.marinho.progenbr.com
mdb.assessoria.qrcode.rodrigo.progenbr.com
mdb.assessoria.carlosalexandre.progenbr.com
mdb.assessoria.qrcode.desideri.progenbr.com
mdb.assessoria.qrcode.fernanda.progenbr.com
mdb.assessoria.qrcode.jbatista.progenbr.com
mdb.assessoria.qrcode.mauricio.progenbr.com
mdb.assessoria.fernanda.regional.progenbr.com
mdb.assessoria.qrcode.boaventura.progenbr.com
mdb.assessoria.qrcode.jtrebesqui.progenbr.com
mdb.assessoria.qrcode.carreirinha.progenbr.com
mdb.assessoria.qrcode.paulomarques.progenbr.com
mdb.assessoria.qrcode.carlosalexandre.progenbr.com
mdb.assessoria.qrcode.fernanda.regional.progenbr.com

Please sign in to comment.