context-recorder-advanced

context-recorder-advanced is a cursor rule for coding agents from Mr-chen-05/rules-2.1-optimized. It costs 0 tokens per session (2,877 once invoked), scanned A, original, MIT.

A set of advanced context-recorder rules for identifying project types and technology stacks, adding labels, and scoring stored project information.

In plain words
What is it for?
Detecting whether a project is frontend, backend, Python, or another type; generating technology and team labels; and rating memory completeness, evidence, freshness, and relevance.
Why use it?
It aims to organize project memories automatically and make them easier to classify, monitor, and retrieve.

Cursor rule

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/mr-chen-05/rules-2.1-optimized/context-recorder-advanced
Clone the repo
git clone --depth 1 https://github.com/Mr-chen-05/rules-2.1-optimized

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for context-recorder-advanced

README.md
[![agentmods](https://agentmods.dev/badge/rules/mr-chen-05/rules-2.1-optimized/context-recorder-advanced.svg)](https://agentmods.dev/rules/mr-chen-05/rules-2.1-optimized/context-recorder-advanced)
Your own site
<a href="https://agentmods.dev/rules/mr-chen-05/rules-2.1-optimized/context-recorder-advanced"><img src="https://agentmods.dev/badge/rules/mr-chen-05/rules-2.1-optimized/context-recorder-advanced.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 2,877 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.02877
Opus 5 $0.00000 $0.01438
Sonnet 5 $0.00000 $0.00575
Haiku 4.5 $0.00000 $0.00288

Measured 5d ago against content hash 737ebf1a1d66, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

context-recorder-advanced scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

global-rules/context-recorder-advanced.mdc · 405 lines

How it starts

The opening of the file, as written. The whole thing — 405 lines — stays where its author put it; the contents beside it link to each section on GitHub.

⚡ Context Recorder Advanced (记录员高级功能)

模块说明: 本文件包含性能优化、智能增强和高级功能配置

相关模块

  • context-recorder-core.mdc - 核心定义和主要规则
  • context-recorder-templates.mdc - 模板定义
  • context-recorder-edge-cases.mdc - 边界情况处理

智能化增强功能

项目类型自动识别

```yaml 检测规则: 文件结构分析: - package.json → frontend - pom.xml → backend - pyproject.toml → python - Cargo.toml → rust

技术栈识别: - React/Vue → frontend - Spring/Django → backend - Express → backend - Next.js → fullstack

目录结构: - src/components → frontend - src/main/java → backend - src/pages → frontend - api/ → backend

自动配置:

  • 根据项目类型加载对应模板区块
  • 设置合适的归档策略和触发条件
  • 配置相关的集成工具和监控指标 ```

智能标签系统

```yaml 自动标签生成: 技术标签: - 基于依赖文件分析 - 识别主要框架和库 - 标记编程语言

状态标签: - 基于项目进度 - 活动频率分析 - 开发阶段识别

团队标签: - 提交记录分析 - 协作模式识别 - 团队规模评估

标签管理:

  • 动态更新: 随项目发展自动调整
  • 权重计算: 基于使用频率
  • 关联推荐: 相似项目标签模式 ```

质量评分机制

```yaml 评分维度: 内容完整性 (权重 30%): - 必填字段完成度 (10分) - 描述详细程度 (10分) - 格式规范性 (10分)

证据充分性 (权重 25%): - 链接有效性 (10分) - 证据完整性 (10分) - 可追溯性 (5分)

时效性 (权重 25%): - 更新频率 (10分) - 信息新鲜度 (10分) - 版本标记 (5分)

关联性 (权重 20%): - 任务依赖标记 (5分) - 决策追溯链 (5分) - 问题关联 (10分)

总分计算: 最终评分 = 维度10.3 + 维度20.25 + 维度30.25 + 维度40.2 评分范围: 0-100分 等级划分: 90-100: ⭐⭐⭐⭐⭐ 优秀 70-89: ⭐⭐⭐⭐ 良好 50-69: ⭐⭐⭐ 一般 30-49: ⭐⭐ 较差 0-29: ⭐ 极差

评分透明化:

  • 每次评分时输出详细计算过程
  • 显示各维度得分和权重
  • 标记导致低分的具体原因
  • 提供具体的改进建议 ```

关联关系管理

```yaml 自动关联检测: 任务依赖: - 基于描述和时间序列分析 - 识别前置任务和后置任务 - 标记依赖关系链

决策影响: - 分析决策对后续任务的影响 - 追踪决策执行情况 - 评估决策效果

问题关联: - 识别相似问题 - 关联解决方案 - 建立知识库

关系可视化:

  • 依赖图谱: 显示任务和决策的依赖关系
  • 影响分析: 评估变更的潜在影响范围
  • 历史追溯: 追踪决策和问题的演化过程 ```

性能优化

大文件处理优化

```yaml 文件大小检测: 操作前检查: - 读取文件前先获取文件大小 - 如果文件 > 1MB,启用分块处理模式 - 记录文件大小到操作日志

分块操作策略: 区块定位: - 使用正则表达式 /^## / 定位区块边界 - 只读取需要修改的目标区块内容 - 保持其他区块完全不变

内存优化: - 优先使用增量更新工具 - 避免全文件重写 - 处理完成后立即释放内存 - 使用流式处理 ```

Read the full file on GitHub · 405 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 405 lines · 0 tokens per session scan A 737ebf1a1d66

Subscribe to this mod's changes

context-recorder-advanced is a cursor rule published in the GitHub repository Mr-chen-05/rules-2.1-optimized (172 stars, last pushed 10mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 2,877 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.