flow-attention-refresh
注意力刷新协议。在关键时刻强制读取核心文档,防止目标遗忘。被 flow-dev, flow-ralph 等命令引用。
Best use case
flow-attention-refresh is best used when you need a repeatable AI agent workflow instead of a one-off prompt. It is especially useful for teams working in multi. 注意力刷新协议。在关键时刻强制读取核心文档,防止目标遗忘。被 flow-dev, flow-ralph 等命令引用。
注意力刷新协议。在关键时刻强制读取核心文档,防止目标遗忘。被 flow-dev, flow-ralph 等命令引用。
Users should expect a more consistent workflow output, faster repeated execution, and less time spent rewriting prompts from scratch.
Practical example
Example input
Use the "flow-attention-refresh" skill to help with this workflow task. Context: 注意力刷新协议。在关键时刻强制读取核心文档,防止目标遗忘。被 flow-dev, flow-ralph 等命令引用。
Example output
A structured workflow result with clearer steps, more consistent formatting, and an output that is easier to reuse in the next run.
When to use this skill
- Use this skill when you want a reusable workflow rather than writing the same prompt again and again.
When not to use this skill
- Do not use this when you only need a one-off answer and do not need a reusable workflow.
- Do not use it if you cannot install or maintain the related files, repository context, or supporting tools.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/flow-attention-refresh/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How flow-attention-refresh Compares
| Feature / Agent | flow-attention-refresh | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
注意力刷新协议。在关键时刻强制读取核心文档,防止目标遗忘。被 flow-dev, flow-ralph 等命令引用。
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Flow Attention Refresh - 注意力刷新协议
## Overview
解决 "Lost in the Middle" 效应:当上下文过长时,原始目标被"推出"注意力窗口。
```
问题:
上下文开始: [原始目标 - 距离很远,被"遗忘"]
↓
... 50+ 工具调用 ...
↓
上下文末尾: [最近的工具输出 - 在注意力窗口]
解决:
在关键时刻强制读取目标文档 → 将目标"拉回"注意力窗口
```
## The Iron Law
```
BEFORE MAJOR DECISION → READ GOAL FILES → THEN ACT
```
## Refresh Protocols
### Protocol 1: Flow Entry (每个 flow-* 命令开始)
**触发点**: 任何 `/flow-*` 命令的 Entry Gate
**动作**:
```yaml
read:
- BRAINSTORM.md "成功标准" 章节
- TASKS.md 当前阶段任务列表
focus: 本次命令要达成什么?
```
**实现**: 已由现有 Brainstorm Alignment Check 覆盖
---
### Protocol 2: Task Start (flow-dev 每个任务开始)
**触发点**: `flow-dev` TDD 循环中,每个任务执行前
**动作**:
```yaml
read:
- TASKS.md 当前任务 T### 段落 + DoD
- quickstart.md 相关命令
focus: 这个任务的验收标准是什么?
```
**实现位置**: flow-dev.md 阶段 3 TDD 循环
**代码片段**:
```markdown
**注意力刷新** (Protocol 2):
→ Read: TASKS.md 当前任务 T### 段落
→ Focus: 任务目标和 DoD
→ Then: 开始执行任务
```
---
### Protocol 3: Ralph Iteration (Ralph 循环每次迭代)
**触发点**: `/flow-ralph` 每次迭代开始
**动作**:
```yaml
read:
- TASKS.md 第一个未完成任务
- ERROR_LOG.md 最近 5 条记录
focus: 下一步行动 + 避免重复错误
```
**实现位置**: flow-ralph.md Ralph Loop 开始处
**代码片段**:
```markdown
**注意力刷新** (Protocol 3):
→ Read: TASKS.md 找到第一个 `- [ ]` 任务
→ Read: ERROR_LOG.md 最近 5 条(如存在)
→ Focus: 下一步行动是什么?有什么错误需要避免?
→ Then: 执行任务
```
---
### Protocol 4: Error Recovery (遇到错误后)
**触发点**: 测试失败、构建错误、运行时异常后
**动作**:
```yaml
read:
- ERROR_LOG.md 当前错误记录
- TASKS.md 当前任务定义
focus: 错误根因 + 解决方案
```
**实现位置**: flow-tdd skill 错误处理部分
**代码片段**:
```markdown
**错误恢复刷新** (Protocol 4):
→ Record: 将错误追加到 ERROR_LOG.md
→ Read: ERROR_LOG.md 当前错误 + 历史相似错误
→ Read: TASKS.md 当前任务
→ Focus: 根因分析,避免盲目修复
→ Then: 有针对性地修复
```
---
## Integration Map
```
现有机制:
┌──────────────────────────────────────┐
│ flow-brainstorming skill │
│ ↓ 触发于 /flow-init │
│ ↓ 输出 BRAINSTORM.md │
└──────────────────────────────────────┘
↓
┌──────────────────────────────────────┐
│ Brainstorm Alignment Check │
│ ↓ 在每个 flow-* Entry Gate │
│ ↓ 读取 BRAINSTORM.md 验证对齐 │
│ ↓ = Protocol 1 │
└──────────────────────────────────────┘
新增机制:
┌──────────────────────────────────────┐
│ flow-attention-refresh skill (本文件) │
│ ↓ 被 flow-dev, flow-ralph 引用 │
│ ↓ 在更细粒度的时刻刷新注意力 │
│ ↓ Protocol 2, 3, 4 │
└──────────────────────────────────────┘
```
## Rationalization Prevention
| Excuse | Reality |
|--------|---------|
| "我记得目标是什么" | 上下文 50+ 工具调用后,你真的不记得了 |
| "读文件浪费时间" | 读文件 < 1秒,返工 > 10分钟 |
| "这个任务很简单" | 简单任务也会偏离目标 |
| "刚刚读过了" | 每次迭代都要读,这是协议 |
## Red Flags - STOP
如果你发现自己:
- 开始任务前没有读取 TASKS.md
- 遇到错误后没有先记录 ERROR_LOG.md
- Ralph 循环中忘记读取上次错误
- 做决策时没有参考 BRAINSTORM.md
**STOP。执行对应的 Protocol。**
---
**[PROTOCOL]**: 变更时更新此头部,然后检查 CLAUDE.mdRelated Skills
req-change-workflow
Standardize requirement/feature changes in an existing codebase (especially Chrome extensions) by turning "改需求/需求变更/调整交互/改功能/重构流程" into a repeatable loop: clarify acceptance criteria, confirm current behavior from code, assess impact/risk, design the new logic, implement with small diffs, run a fixed regression checklist, and update docs/decision log. Use when the user feels the change process is chaotic, when edits tend to sprawl across files, or when changes touch manifest/service worker/OAuth/storage/UI and need reliable verification + rollback planning.
defou-workflow
将原始想法转化为结构清晰、判断明确、具有长期价值的“得否”风格内容报告。
defou-stanley-workflow
Defou x Stanley 融合工作流:结合深度结构化思考与人性弱点洞察,生成极简、犀利且具有长期价值的爆款内容。
agentic-workflow
Practical AI agent workflows and productivity techniques. Provides optimized patterns for daily development tasks such as commands, shortcuts, Git integration, MCP usage, and session management.
workflow-patterns
Use this skill when implementing tasks according to Conductor's TDD workflow, handling phase checkpoints, managing git commits for tasks, or understanding the verification protocol.
workflow-orchestration-patterns
Design durable workflows with Temporal for distributed systems. Covers workflow vs activity separation, saga patterns, state management, and determinism constraints. Use when building long-running processes, distributed transactions, or microservice orchestration.
workflow-automation
Workflow automation is the infrastructure that makes AI agents reliable. Without durable execution, a network hiccup during a 10-step payment flow means lost money and angry customers. With it, workflows resume exactly where they left off. This skill covers the platforms (n8n, Temporal, Inngest) and patterns (sequential, parallel, orchestrator-worker) that turn brittle scripts into production-grade automation. Key insight: The platforms make different tradeoffs. n8n optimizes for accessibility
webflow-automation
Automate Webflow CMS collections, site publishing, page management, asset uploads, and ecommerce orders via Rube MCP (Composio). Always search tools first for current schemas.
tdd-workflows-tdd-refactor
Use when working with tdd workflows tdd refactor
tdd-workflows-tdd-red
Generate failing tests for the TDD red phase to define expected behavior and edge cases.
tdd-workflows-tdd-green
Implement the minimal code needed to make failing tests pass in the TDD green phase.
tdd-workflows-tdd-cycle
Use when working with tdd workflows tdd cycle