This is a Discord bot that allows you to lookup flea market prices with your voice. Small demo.
The bot listens and transcribes all text spoken by any user who starts the bot command. Then that transcribed text is processed in the bot and matched against some pattern, like price check <item>
. Then <item>
is looked up on Tarkov-Market and the bot spits out some useful information from there. Along with a shorter TTS message played in the channel.
This is what makes this work. There's a file support/transcribe_vocab.txt
that contains all the mappings for Amazon Transcribe. The vocab name is hardcoded to tarkov
for now, you should update yours accordingly.
There's a helper script you can run to push updates to AWS.
npm run update-vocab
Make sure you check the status afterwords to see if there are any parsing failures. It needs to follow these guidelines.
If you plan to contribute to this list, please reach out to me and I can give you access to a master spreadsheet with items catagorized by sheets. There's an export script that generates support/transcribe_vocab.txt
.
You first need to !deploy the bot. Only the owner of the app can deploy it. It will try to auto-deploy if you have the guild id configured.
-
/join
to join your voice channel. -
/start
to tell the bot to start recording you. It's opt-in. -
/stop
stop listening -
/leave
leave the voice channel -
/check
do a text-based lookup
- Basic knowledge of
- Node
- TypeScript
- AWS
- AWS Account (this will cost based on usage)
- Amazon Transcribe
- Amazon Polly - TTS
- S3: for storing/loading vocab model for Transcribe
- Your own Discord App ID
Currently two sources available. By default it will use tarkov.dev. But it also has support for Tarkov-Market, but you need to have an API key to use Tarkov-Market, which costs $5/mo.
Runs with .env.dev
vars. Has ability to auto-join and start recording a preset user in a preset guild, outputing to a preset channel based on the environment variables.
This wll build and run the service.
npm run dev
Just runs with node in prod environmment with .env
loaded. Doesn't build.
npm run prod
I am trying fly.io to host this right now. You can deploy with:
npm run deploy
All secrets will be stored in .env
/.env.dev
file.
For development the .env.dev
file is used instead. For full reference of all the variables check out src/config.env.ts
.
- Finish adding item voice models!
- Session persistence (for seamless redeploys?)