116 lines
2.5 KiB
Markdown

# OpenClaw Meeting Notes
A Discord bot that automatically joins voice channels and transcribes meetings when specific users are present together. Integrates with OpenClaw for post-meeting actions.
## Features
- Auto-joins VC when configured users are together
- Per-speaker transcription using onnx-asr (hyprwhspr backend)
- Timestamped transcript saved to JSON
- Prompts via OpenClaw for post-meeting actions
- Self-contained - easy to share and deploy
## Requirements
- Node.js 18+ or Bun
- ffmpeg (for audio conversion)
- hyprwhspr with onnx-asr backend (for transcription)
- A Discord bot token
## Setup
1. Clone and install dependencies:
```bash
git clone https://git.nicholai.work/Nicholai/openclaw-meeting-notes.git
cd openclaw-meeting-notes
bun install
```
2. Copy the example env and configure:
```bash
cp .env.example .env
```
Edit `.env`:
```env
discordToken=YOUR_BOT_TOKEN
targetUsers=USER_ID_1,USER_ID_2
transcriptsDir=~/.agents/meeting-transcripts
openclawGatewayUrl=http://localhost:3850
guildId=YOUR_GUILD_ID
```
3. Build and run:
```bash
bun run build
bun run start
```
## Configuration
| Env Var | Description |
|---------|-------------|
| `discordToken` | Discord bot token |
| `targetUsers` | Comma-separated user IDs to watch for |
| `transcriptsDir` | Where to save meeting transcripts |
| `openclawGatewayUrl` | OpenClaw gateway URL for prompts |
| `guildId` | Discord guild ID to monitor |
## Bot Permissions
The bot needs these permissions in your server:
- View Channels
- Connect (to voice channels)
- Speak (muted, but needed to join)
## How It Works
1. Bot monitors voice channels for target users
2. When all target users are in the same VC, bot joins (muted)
3. Captures audio streams per speaker
4. Converts PCM → WAV → text via onnx-asr
5. When users leave, saves transcript JSON
6. Prompts via OpenClaw for follow-up actions
## Output Format
Transcripts are saved as JSON:
```json
{
"channel": "General",
"startTime": "2026-02-27T00:00:00.000Z",
"endTime": "2026-02-27T00:30:00.000Z",
"duration": "30m 0s",
"participants": {
"123456789": "username1",
"987654321": "username2"
},
"transcript": [
{
"speakerId": "123456789",
"speakerName": "username1",
"timestamp": 1708992000000,
"text": "Hey, let's talk about the project..."
}
]
}
```
## Systemd Service
To run as a background service:
```bash
cp meeting-notes.service ~/.config/systemd/user/
systemctl --user enable --now meeting-notes
```
## License
MIT