{"_id":"@caleblawson/voice-cloudflare","name":"@caleblawson/voice-cloudflare","dist-tags":{"latest":"0.10.3"},"versions":{"0.10.3":{"name":"@caleblawson/voice-cloudflare","version":"0.10.3","description":"Mastra Sarvam AI voice integration","type":"module","main":"dist/index.js","types":"dist/index.d.ts","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./package.json":"./package.json"},"license":"Elastic-2.0","dependencies":{"cloudflare":"^4.3.0","zod":"^3.25.57"},"devDependencies":{"@cloudflare/workers-types":"^4.20250610.0","@microsoft/api-extractor":"^7.52.8","@types/node":"^20.19.0","eslint":"^9.28.0","tsup":"^8.5.0","typescript":"^5.8.3","vitest":"^2.1.9","@internal/lint":"0.0.13","@mastra/core":"npm:@caleblawson/core@0.10.7-alpha.0"},"keywords":["mastra","cloudflare","tts","stt","open-source","speech-to-text","text-to-speech","speech-recognition"],"peerDependencies":{"@mastra/core":"^0.10.0-alpha.0"},"scripts":{"build":"tsup src/index.ts --format esm,cjs --experimental-dts --clean --treeshake=smallest --splitting","build:watch":"pnpm build --watch","test":"vitest run","test:watch":"vitest watch","lint":"eslint ."},"gitHead":"c31e90130a5c9765c23f688ecea70adc6164543d","_id":"@caleblawson/voice-cloudflare@0.10.3","_integrity":"sha512-a7f2RQjItrFhU8blM0ca92BDhy/mHTmEZU86C9yV96myCes01ehAC0oPtvs23KsJBpq3aVyOWGD4ZiJuxXrYdw==","_resolved":"C:\\Users\\caleb\\AppData\\Local\\Temp\\5e6274d187171eb2ae7acc43ffa172f8\\caleblawson-voice-cloudflare-0.10.3.tgz","_from":"file:caleblawson-voice-cloudflare-0.10.3.tgz","_nodeVersion":"21.2.0","_npmVersion":"10.2.3","dist":{"integrity":"sha512-a7f2RQjItrFhU8blM0ca92BDhy/mHTmEZU86C9yV96myCes01ehAC0oPtvs23KsJBpq3aVyOWGD4ZiJuxXrYdw==","shasum":"5097c59aa6cc8c089cad3a3f4b3e98b6e429fd66","tarball":"https://registry.npmjs.org/@caleblawson/voice-cloudflare/-/voice-cloudflare-0.10.3.tgz","fileCount":9,"unpackedSize":13882,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIECzP2oiQ351ikbPyMcJ2ahG7sqTp8qoJuEGH6KTdnY7AiB+iehFori1gWLVGmex1JmBObc4Xb1fgw70/WeYgv+shQ=="}]},"_npmUser":{"name":"caleblawson","email":"caleb.lawson@dynapt.com","actor":{"name":"caleblawson","email":"caleb.lawson@dynapt.com","type":"user"}},"directories":{},"maintainers":[{"name":"caleblawson","email":"caleb.lawson@dynapt.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/voice-cloudflare_0.10.3_1750741036465_0.5855163603651989"},"_hasShrinkwrap":false}},"time":{"created":"2025-06-24T04:57:16.384Z","0.10.3":"2025-06-24T04:57:16.655Z","modified":"2025-06-24T04:57:16.906Z"},"maintainers":[{"name":"caleblawson","email":"caleb.lawson@dynapt.com"}],"description":"Mastra Sarvam AI voice integration","keywords":["mastra","cloudflare","tts","stt","open-source","speech-to-text","text-to-speech","speech-recognition"],"license":"Elastic-2.0","readme":"# @mastra/voice-cloudflare\r\n\r\nCloudflare Voice integration for Mastra, providing Text-to-Speech (TTS) capabilities using open source speech models.\r\n\r\n## Installation\r\n\r\n```bash\r\nnpm install @mastra/voice-cloudflare\r\n```\r\n\r\n## Configuration\r\n\r\nThe module requires the following environment variables:\r\n\r\nIf using Cloudflare Native Bindings:\r\n\r\n`./wrangler.jsonc`\r\n\r\n```json\r\n\"ai\": {\r\n    \"binding\": \"AI\",\r\n  },\r\n```\r\n\r\nIf using Cloudflare REST API:\r\n\r\n```bash\r\nCLOUDFLARE_AI_API_KEY=your_api_key\r\nCLOUDFLARE_ACCOUNT_ID=your_account_id\r\n```\r\n\r\n## Usage\r\n\r\n```typescript\r\nimport { CloudflareVoice } from '@mastra/voice-cloudflare';\r\n\r\n// Native Bindings\r\nconst voice = new CloudflareVoice({\r\n  binding: env.AI,\r\n  listeningModel: {\r\n    model: '@cf/openai/whisper-large-v3-turbo',\r\n  },\r\n});\r\n\r\n// REST API\r\nconst voice = new CloudflareVoice({\r\n  listeningModel: {\r\n    apiKey: 'YOUR_API_KEY',\r\n    model: '@cf/openai/whisper-large-v3-turbo',\r\n    account_id: 'YOUR_ACC_ID',\r\n  },\r\n});\r\n\r\n// Generate Text from an audio stream\r\nconst text = await voice.listen(audioStream);\r\n```\r\n\r\n## Features\r\n\r\n- Open source models\r\n\r\n## Available Models\r\n\r\n### Speech Models\r\n\r\nThe following speech-to-text models are available:\r\n\r\n| Model                               | Description                    |\r\n| ----------------------------------- | ------------------------------ |\r\n| `@cf/openai/whisper-tiny-en`        | Lightweight English-only model |\r\n| `@cf/openai/whisper`                | Standard multilingual model    |\r\n| `@cf/openai/whisper-large-v3-turbo` | High-accuracy turbo model      |\r\n","readmeFilename":"README.md","_rev":"1-2e1ef1d3464589815c3b25c5215a3411"}