Clay's personal life-ops Slack bot, powered by Claude and Clay-Mate.
Hermie is a conversational AI agent that lives in Slack. It knows your life context through Clay-Mate (tasks, projects, thoughts, contacts) and can:
- Answer questions about your tasks, projects, and schedule
- Add, complete, and update tasks
- Save thoughts and reminders
- Search across your entire Clay-Mate history
- Actually be helpful without being a corporate robot
- Runtime: Node.js
- Slack: Slack Bolt SDK with Socket Mode
- AI: Claude Sonnet (claude-sonnet-4-20250514)
- Memory: Clay-Mate MCP server (Supabase-backed)
- Deployment: Railway
- Go to api.slack.com/apps
- Click Create New App
- Choose From scratch
- Name it
Hermie(or whatever you want) - Select your workspace
- Click Create App
- In your app settings, go to OAuth & Permissions (left sidebar)
- Scroll to Scopes → Bot Token Scopes
- Add these scopes:
app_mentions:read- So Hermie can see when it's @mentionedchannels:history- To read messages in public channels (when mentioned)chat:write- To send messagesgroups:history- To read messages in private channels (when mentioned)im:history- To read DM historyim:read- To access DM metadataim:write- To send DMsmpim:history- To read group DM historyreactions:read- To see reactions (optional but nice)reactions:write- To add the "thinking" reactionusers:read- To get user info
- Go to Socket Mode (left sidebar)
- Toggle Enable Socket Mode to ON
- You'll be prompted to create an App-Level Token
- Name it
hermie-socket(or whatever) - Add the scope:
connections:write - Click Generate
- Copy this token (starts with
xapp-) — this is yourSLACK_APP_TOKEN
- Go to Event Subscriptions (left sidebar)
- Toggle Enable Events to ON
- Under Subscribe to bot events, add:
app_mention- When someone @mentions Hermiemessage.im- When someone DMs Hermie
- Click Save Changes
- Go to Install App (left sidebar)
- Click Install to Workspace
- Authorize the permissions
- Copy the Bot User OAuth Token (starts with
xoxb-) — this is yourSLACK_BOT_TOKEN
- Go to App Home (left sidebar)
- Scroll to Show Tabs
- Toggle Messages Tab to ON
- Check Allow users to send Slash commands and messages from the messages tab
- Create a new GitHub repo for Hermie
- Push this code to it:
cd hermie
git init
git add .
git commit -m "Initial Hermie setup"
git remote add origin https://github.com/YOUR_USERNAME/hermie.git
git push -u origin main- Go to railway.app and sign in
- Click New Project
- Choose Deploy from GitHub repo
- Select your
hermierepo - Railway will detect it's a Node.js app
- In your Railway project, click on the service
- Go to Variables tab
- Add these variables (click Raw Editor to paste them all):
SLACK_BOT_TOKEN=xoxb-your-bot-token
SLACK_APP_TOKEN=xapp-your-app-token
ANTHROPIC_API_KEY=sk-ant-your-key
CLAY_MATE_MCP_URL=https://bnmupvkjtghnzczkmpxj.supabase.co/functions/v1/clay-mate
CLAY_MATE_MCP_KEY=your-clay-mate-key
- Railway will automatically redeploy with the new variables
- Check the Deployments tab for build logs
- Look for:
Hermie is running on port 3000andSocket Mode: connected - Open Slack and DM Hermie: "hey, what's on my plate today?"
- Clone the repo
- Copy
.env.exampleto.envand fill in your values - Install dependencies:
npm install- Run with hot reloading:
npm run dev- Or run normally:
npm startRailway's free tier (and Render, etc.) can spin down after inactivity. To prevent this:
- Set up Uptime Robot (free tier works)
- Create a new HTTP(s) monitor
- Point it at:
https://your-railway-url.up.railway.app/health - Set interval to 5 minutes
The /health endpoint returns {"status": "ok", "timestamp": "...", "service": "hermie"}.
Hermie doesn't pull all of Clay-Mate on every message. That would be slow.
Session boot (first message after 2+ hours):
- Pulls daily briefing, open tasks, active projects, agent state
- Bundles into system prompt context
Mid-conversation:
- Uses rolling window of last 20 messages
- Relies on booted context + conversation history
After writes:
- Any write operation (add task, complete task, etc.) invalidates context
- Next message triggers a fresh boot pull
Deep lookup:
- When you ask about something specific, Hermie uses
global_search - Only pulls what's needed, not everything
index.js— Main Slack app, Claude integration, message handlingclay-mate.js— Clay-Mate MCP API wrappermemory.js— Session management, context loadinghermie-prompt.js— System prompt builder, tool definitions
"Hermie isn't responding to DMs"
- Make sure Messages Tab is enabled in App Home settings
- Check that
message.imevent subscription is added
"Hermie isn't responding to @mentions"
- Make sure
app_mentionevent subscription is added - Make sure the bot is invited to the channel
"Socket Mode won't connect"
- Verify your
SLACK_APP_TOKENstarts withxapp- - Make sure Socket Mode is enabled in app settings
"Claude API errors"
- Check your
ANTHROPIC_API_KEYis valid - Check you have API credits
"Clay-Mate calls failing"
- Verify
CLAY_MATE_MCP_URLandCLAY_MATE_MCP_KEYare correct - Check the Supabase function logs