motivate-mcp
An MCP server that returns motivational quotes matched to the task you're working on, with tools to list topics and explain matches. It also includes a hook for receiving a quote on every prompt submission.
README
motivate-mcp
An MCP server that returns a motivational quote matched to the task you are actually working on.
Most quote generators pick at random, which is why they stop landing after a day. This one reads a short description of what you are doing, scores it against a keyword map, and returns something relevant. Say you are debugging and you get Kernighan. Say you are stuck and you get Mandela. Say you are avoiding shipping and you get told to ship.
> "When you have eliminated the impossible, whatever remains, however improbable,
> must be the truth."
> — Arthur Conan Doyle
72 quotes across 57 topics. No API key, no network calls, no telemetry.
Install
git clone https://github.com/lazyturtle22/motivate-mcp.git
cd motivate-mcp
npm install
Use it as an MCP server
Add it to your MCP client config. For Claude Code, ~/.claude.json:
{
"mcpServers": {
"motivate": {
"command": "node",
"args": ["/absolute/path/to/motivate-mcp/src/index.js"]
}
}
}
Restart the client and three tools appear.
Tools
| Tool | What it does |
|---|---|
motivate |
Returns a quote matched to a task description. Takes task (string) and optional avoid_repeats (boolean, default true) |
list_topics |
Lists every topic and how many quotes sit under it |
explain_match |
Shows which topics a description matches, without returning a quote. Useful when tuning the keyword map |
Repeats are tracked per session, so a long session will not serve you the same line twice until it runs out of relevant ones.
Getting a quote on every message
An MCP tool only fires when the model decides to call it, so it will not reliably hit every message. If you want one every time, use the included hook instead. It runs on every prompt you submit, reads what you typed, and prints a matched quote into the context.
Add to ~/.claude/settings.json:
{
"hooks": {
"UserPromptSubmit": [
{
"hooks": [
{
"type": "command",
"command": "node /absolute/path/to/motivate-mcp/hook/motivate-hook.js"
}
]
}
]
}
}
Set MOTIVATE_QUIET=1 to silence it without unwiring it. The hook fails silently by
design: a broken quote generator should never be able to break your prompt.
The two can run together. The hook gives you the every-message drip, the MCP tool lets the model ask for one deliberately when it thinks you need it.
How the matching works
src/match.js holds a map of topic to signal words. A task description is scanned for
those words, topics are scored (multi-word phrases count double, since they are stronger
evidence), and quotes are ranked by how well their topics overlap the top matches.
Signals match at a word start, not anywhere in the string. This matters if you add
your own. A plain substring check looks fine until you notice ui fires on "built"
and "guide", try fires on "country", and lead fires on "misleading" — so
you ask about building something and get a quote about design.
There is deliberately no boundary on the end of a signal, so stems still work:
optimis matches "optimising", frustrat matches "frustrated". When adding a short
signal (three characters or fewer), check it against a few real sentences first.
The final pick is randomised across everything within 70% of the best score, so the same input does not always produce the same line.
If nothing matches, it falls back to the whole database rather than returning nothing.
Check what a description matches before adding new signal words:
node -e "import('./src/match.js').then(m => console.log(m.scoreTopics('your text here')))"
Adding quotes
Edit src/quotes.js. Each entry is:
{
text: "The quote itself.",
by: "Who said it",
topics: ["debugging", "persistence"],
}
Attribution rules, please keep to them:
- Where a line is widely repeated but the original wording or source is disputed,
bystarts withattributed to. Do not strip that prefix to make it look tidier. - Proverbs and genuinely anonymous lines are credited as
ProverborAnonymous.
Use topics that already exist where you can, so quotes cluster rather than scatter. Run
npm test afterwards, which checks for duplicates, missing authors and orphan topics.
Tests
npm test
Nine tests using the built-in node:test runner. No framework, no build step.
Licence
MIT. See LICENSE.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。