FocusRoom MCP Server
FocusRoom | 生产力代理
一个使用 Python、Streamlit、Groq、SQLite 和 MCP 构建的个人生产力工作区。它将任务管理、每日规划、持久记忆、多代理监督器和可选的电子邮件提醒整合在一个项目中。
功能
Streamlit 生产力仪表板
创建、列出、筛选和完成任务
任务优先级、截止日期、项目和状态
在
productivity.db中进行持久化 SQLite 存储每日计划和生产力报告
保存和搜索个人记忆
由 Groq 驱动的生产力助手
用于任务、记忆和规划请求的多代理监督器
为外部客户端提供 HTTP 工具的 MCP 服务器
可选的自动电子邮件提醒
Related MCP server: Task API MCP
要求
Python 3.10 或更高版本
用于 AI 功能的 Groq API 密钥
用于电子邮件提醒的 Gmail SMTP 凭据或其他 SMTP 提供商
设置
1. 创建虚拟环境
PowerShell:
python -m venv .venv
.\.venv\Scripts\Activate.ps1如果 PowerShell 阻止当前会话的脚本执行:
Set-ExecutionPolicy -Scope Process -ExecutionPolicy RemoteSigned
.\.venv\Scripts\Activate.ps12. 安装依赖
python -m pip install -r requirements.txt3. 配置环境变量
将 .env.example 复制为 .env 并填写相应值:
Copy-Item .env.example .envGroq 支持的代理所需:
GROQ_API_KEY=your_groq_api_key
GROQ_MODEL=openai/gpt-oss-120b可选的 MCP 配置:
MCP_HOST=127.0.0.1
MCP_PORT=8000
MCP_API_KEY=local_or_remote_api_key用于电子邮件提醒:
EMAIL_SENDER=your_email@gmail.com
EMAIL_RECIPIENT=recipient@example.com
EMAIL_PASSWORD=your_smtp_or_app_password
SMTP_SERVER=smtp.gmail.com
SMTP_PORT=587不要提交 .env 或 API 凭据。它们已被 .gitignore 排除。
运行 Streamlit 应用
streamlit run streamlit_app.py该应用提供以下部分:
概览 - 任务指标、进行中的工作、每日快照和完成进度
任务 - 创建和筛选任务,然后将任务标记为完成
计划 - 查看当前每日计划和生产力报告
记忆 - 保存和搜索持久上下文
助手 - 向生产力监督器发送自然语言请求
运行 MCP 服务器
使用以下命令启动 Streamable HTTP MCP 服务器:
python -m orchestrator.mcp_server默认情况下,它运行在 http://127.0.0.1:8000/mcp。
该服务器暴露以下工具:
productivity_assistantcreate_tasklist_tasksupdate_taskcomplete_taskdelete_tasksave_memorysearch_memorydaily_planproductivity_report
将 MCP 服务器绑定到非本地主机时,请设置 MCP_API_KEY。远程请求必须使用 bearer 令牌:
Authorization: Bearer <MCP_API_KEY>运行提醒
提醒工作进程会检查即将到来的任务并发送已配置的电子邮件通知:
python reminder_worker.py提醒计划在工作进程中配置,支持在任务到期前 24 小时、1 小时和 15 分钟发送提醒。电子邮件提醒需要在 .env 中提供有效的 SMTP 设置。
运行测试
使用项目虚拟环境,以便 pytest 可用:
.\.venv\Scripts\python -m pytest -q要运行特定的测试文件:
.\.venv\Scripts\python -m pytest -q test_multi_agent.py要在不启动应用的情况下检查 Python 语法:
.\.venv\Scripts\python -m compileall streamlit_app.py orchestrator项目结构
Productivity_Agent/
|-- streamlit_app.py # Streamlit user interface
|-- requirements.txt # Python dependencies
|-- .env.example # Environment variable template
|-- productivity.db # Local SQLite database, generated locally
|-- reminder_service.py # Reminder service implementation
|-- reminder_worker.py # Continuous reminder worker
|-- orchestrator/
| |-- agent.py # Core task, memory, plan, and report logic
| |-- database.py # SQLite persistence layer
| |-- orchestrator.py # Multi-agent supervisor
| |-- mcp_server.py # MCP HTTP server and tools
| |-- memory_agent.py # Memory agent adapter
| |-- planning_agent.py # Planning agent adapter
| |-- task_agent.py # Task agent adapter
|-- test_*.py # Project tests数据与安全说明
任务和记忆存储在本地 SQLite 中。
.env包含机密信息,必须保持私密。对于 Gmail,请在需要时使用应用专用密码,而不是您的主账户密码。
当服务器暴露在 localhost 之外时,需要 MCP API 密钥。
如果本地任务和记忆历史很重要,请备份
productivity.db。
故障排除
无法识别 pytest
通过虚拟环境运行 pytest:
.\.venv\Scripts\python -m pytest -q应用启动但助手不可用
检查 .env 是否存在并包含有效的 GROQ_API_KEY,然后重启 Streamlit。
Streamlit 报告 missing ScriptRunContext
当直接使用 python -c 导入 Streamlit 模块时会出现此警告。请使用 streamlit run streamlit_app.py 启动应用程序以正常操作。
编译正常但测试在收集阶段失败
收集错误意味着 pytest 无法完成测试导入。请先阅读报告的第一个异常,并修复该依赖项或构造函数不匹配的问题,然后再评估其余测试。
This server cannot be deployed
Maintenance
Related MCP Connectors
ADHD-friendly tasks, notes & projects for LucidNest - 18 tools, scoped tokens, Streamable HTTP.
Nifty's MCP server — exposes tasks, projects, messages, and files as tools for AI agents.
Manage tasks, Focus Zone, notes, projects, and task history from compatible AI assistants.
ADHD system of record for agents: tasks, goals, loops, calendar, focus stats.
Related MCP Servers
- AlicenseBqualityBmaintenanceExposes the Deferno task-manager backend to AI agents, enabling them to read, create, update, and manage tasks, habits, chores, events, and daily plans.81MIT
- AlicenseBqualityDmaintenanceEnables AI clients to create and manage tasks via a local REST API by converting natural language into HTTP requests through the Model Context Protocol.1MIT
- AlicenseNot gradedqualityBmaintenanceEnables authenticated MCP clients to manage projects, tasks, habits, and daily capacity through tool calls.1 npmISC

Nexxupp MCP Serverofficial
AlicenseBqualityCmaintenanceEnables AI agents to store and search private memory, explore and edit workspace stations, databases, tasks, and charts, and schedule calendar events through natural language. Supports local stdio and hosted HTTP modes with per-user OAuth scoping of tools.22MIT