From srp-allstaff
Generate weekly work report from GitHub, Linear, and Lark data (周报生成 - 从 GitHub、Linear 和飞书数据自动生成周报)
npx claudepluginhub serendipityoneinc/srp-claude-code-marketplaceThis skill uses the workspace's default tool permissions.
自动从 GitHub 提交记录、Linear 任务和飞书文档生成周报。
Drafts structured weekly software development reports from git logs, Obsidian work logs, YAML schedules, GitHub PRs, 云效 tasks, and calendars. Use for 周报 or end-of-week summaries.
Generates daily standup reports aggregating 24h GitHub activity (PRs, commits, reviews) and Linear issues by status (In Progress, Todo, blockers). Ideal for morning prep or activity summaries.
Conducts structured weekly retrospectives: scans git repos for commits, checks GitHub issues/projects, interviews user on business topics, creates verified issues, updates canonical files.
Share bugs, ideas, or general feedback.
自动从 GitHub 提交记录、Linear 任务和飞书文档生成周报。
Automatically generate weekly work reports from GitHub commits/PRs, Linear issues, and Lark documents.
帮我生成上周的周报
Generate my weekly report for last week
帮我总结过去一周的工作
Collect PRs, issues, and commits authored by user:
Available MCP Tools:
mcp__plugin_github_github__search_pull_requests - Search PRs by authormcp__plugin_srp-developer_github__search_issues - Search issues by authormcp__plugin_github_github__list_commits - List commits in reposSearch Query Format:
author:<username> [org:<organization>] created:>=<start_date>
Collect documents the user participated in:
Available MCP Tools:
mcp__plugin_srp-allstaff_lark__docx_builtin_search - Search cloud documentsmcp__plugin_srp-allstaff_lark__docx_v1_document_rawContent - Get document contentKey Parameters:
useUAT: true - Use user access tokensearch_key - Keywords to searchcount - Number of results (max 50)owner_ids - Filter by document owner (optional)IMPORTANT: Multi-Strategy Search (重要:多策略搜索)
飞书文档的 owner 可能不是用户本人(如智能纪要由会议系统自动生成),因此需要使用多种搜索策略:
Strategy 1: Search by user name (按用户名搜索)
{
"search_key": "智能纪要 <用户中文名>",
"count": 50
}
This captures meeting notes where the user was a presenter or key participant.
Strategy 2: Search by owner_id (按文档所有者搜索)
{
"search_key": "",
"owner_ids": ["<user_open_id>"],
"count": 50
}
This captures documents created by the user directly.
Strategy 3: Search by date keywords (按日期关键词搜索)
{
"search_key": "2026年1月 会议 培训",
"count": 50
}
Combined with manual filtering by date range.
Documents to look for (需要关注的文档类型):
Search Strategy (搜索策略):
IMPORTANT: Must perform multiple searches to capture all meeting-related documents:
User-hosted meetings/trainings (用户主讲的会议/培训):
智能纪要 {用户中文名} (e.g., "智能纪要 朱广彬")AI notes {用户中文名} (e.g., "AI notes 朱广彬")Regular team meetings (常规团队会议):
双周会 会议 - Biweekly meetings周会 会议纪要 - Weekly meetingsOther work documents (其他工作文档):
培训 分享 - Training and sharing sessionsDate Filtering:
Collect issues the user worked on:
Available MCP Tools (via Rube):
LINEAR_GET_CURRENT_USER - Get current user IDLINEAR_LIST_LINEAR_ISSUES - List issues by assignee/statusLINEAR_RUN_QUERY_OR_MUTATION - GraphQL for complex queriesThree queries to run:
Status mapping:
Generate structured weekly report and publish to Lark document.
Available MCP Tools:
mcp__plugin_srp-allstaff_lark__docx_builtin_import - Import markdown as Lark documentUsage:
{
"useUAT": true,
"data": {
"file_name": "周报_<中文名>_MMDD-MMDD",
"markdown": "<markdown content>"
}
}
Response contains:
url - Direct link to the created Lark documenttoken - Document ID for future reference1. Clarify Parameters (确认参数)
- Time range: Monday to Sunday of previous week
- GitHub username
- GitHub organization (if applicable)
- User's Chinese name (用户中文名) - for searching Lark meeting notes
2. Collect GitHub Data (收集 GitHub 数据)
- Search PRs: author:<username> created:>=<start_date>
- Extract: date, repo, PR number, title, summary
2.5 Collect Linear Issues (收集 Linear 任务)
- Get current user ID via LINEAR_GET_CURRENT_USER
- Query completed issues in date range (state.type = "completed", completedAt within range)
- Query in-progress issues assigned to user (state.type in ["started", "unstarted"])
- Query issues created by user in date range (GraphQL with creator filter)
- Deduplicate and group by status for display
3. Collect Lark Documents (收集飞书文档) - IMPORTANT: Multiple searches required!
a. Search user-hosted meetings: "智能纪要 {用户中文名}"
b. Search user-hosted meetings: "AI notes {用户中文名}"
c. Search user-hosted trainings: "培训 {用户中文名}"
d. Search team meetings: "双周会 会议", "周会 会议纪要"
e. Search with owner_ids for user-created documents
f. Filter documents by date in title matching report period
g. Read document content for relevant meetings
h. Extract key information (topics, participants, action items)
4. Generate Report (生成报告)
- Format as structured markdown
- Separate sections for: 主讲的培训/分享, 参与的会议
- Present to user for review
5. Publish to Lark (发布到飞书)
- Use `mcp__plugin_srp-allstaff_lark__docx_builtin_import` to create Lark document
- File name format: "周报_<中文名>_MMDD-MMDD" (飞书限制文件名最多27字符)
- Return the Lark document URL to user
6. Iterate (迭代)
- Adjust based on user feedback
## 周报 (YYYY-MM-DD ~ YYYY-MM-DD)
### 一、代码开发工作
| 日期 | 仓库 | PR | 内容摘要 |
|------|------|-----|----------|
| MM-DD | repo-name | #N | Brief description |
### 二、项目任务 (Linear)
**本周完成:**
- [Done] Issue title
**进行中:**
- [In Progress] Issue title
**本周新建:**
- [Backlog] Issue title
### 三、培训/会议工作
#### 主讲的培训/分享 (如有)
**MM-DD** Training/Sharing Title (主讲)
- 参会人数:N 人
- 培训内容要点
- 待办事项(如有)
#### 参与的会议
**MM-DD** Meeting Name
- Key discussion point 1
- Key discussion point 2
- Action items assigned to user
### 四、下周计划
(User provided or left blank)
User:
帮我生成上周的周报,我的 GitHub 用户名是 zhangsan,公司是 SerendipityOneInc,中文名是张三
Assistant Response:
让我收集你上周 (01-27 ~ 02-02) 的工作数据。
<collects GitHub PRs>
<searches Lark: "智能纪要 张三">
<searches Lark: "AI notes 张三">
<searches Lark: "双周会 会议">
<reads relevant meeting documents>
## 周报 (2026-01-27 ~ 2026-02-02)
### 一、代码开发工作
本周共提交 3 个 PR,全部已合并:
| 日期 | 仓库 | PR | 内容摘要 |
|------|------|-----|----------|
| 02-01 | project-a | #42 | 新增用户认证功能 |
| 01-30 | project-b | #18 | 修复登录页面 bug |
| 01-28 | project-a | #40 | 优化数据库查询性能 |
### 二、培训/会议工作
#### 主讲的培训/分享
**01-29** 微服务架构设计分享 (主讲)
- 参会人数:15 人
- 培训内容:微服务拆分原则、服务治理、链路追踪
- 待办:整理分享材料发给参会人员
#### 参与的会议
**01-27** Infra 双周会
- 讨论 Q1 OKR 进展
- 确认下周发布计划
- Action: 跟进 XX 系统上线
飞书文档已创建:https://starquest.feishu.cn/docx/xxxxxx
需要我调整格式或补充其他内容吗?
User:
Generate my weekly report for last week. GitHub: johndoe, Org: MyCompany
Assistant Response:
Let me collect your work data for last week (01-27 ~ 02-02).
<collects data>
## Weekly Report (2026-01-27 ~ 2026-02-02)
### Code Development
2 PRs merged this week:
| Date | Repository | PR | Summary |
|------|------------|-----|---------|
| 02-01 | api-service | #55 | Add rate limiting middleware |
| 01-29 | web-app | #123 | Fix responsive layout issues |
### Documentation & Meetings
**01-30** Architecture Review
- Reviewed microservices migration plan
- Decided on event-driven approach
Lark document created: https://starquest.feishu.cn/docx/xxxxxx
Would you like me to adjust the format or add more details?
Problem: User expects different week definition
Solution:
Problem: No PRs found in personal repos
Solution:
org:<organization> filterProblem: Lark API returns auth error
Solution:
Problem: Report is too long
Solution:
Problem: User participated in meetings/trainings but they don't appear in report
Root Cause: 智能纪要 (AI notes) and meeting transcripts are auto-generated by Lark. The document owner is often the meeting creator or system account, NOT the participant.
Solution:
search_key: "智能纪要 <用户中文名>"search_key: "培训 <用户中文名>"search_key: "<用户中文名> 分享" for tech sharing sessionsowner_ids filterExample:
// Search for meeting notes where 朱广彬 presented
{"search_key": "智能纪要 朱广彬", "count": 50, "useUAT": true}
// Search for trainings by 朱广彬
{"search_key": "培训 朱广彬", "count": 50, "useUAT": true}
// Search for tech sharing by 朱广彬
{"search_key": "朱广彬 分享 best practice", "count": 50, "useUAT": true}
Problem: Linear tools return auth error or no data
Solution:
RUBE_SEARCH_TOOLSProblem: No Linear issues found but user has activity
Solution:
lark-docs: Access Lark cloud documentsgithub-integration: GitHub PR and issue management