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.
npx skills add seed-forge/harness-ai-kit --skill diag-mysql-replicationgit clone --depth 1 https://github.com/seed-forge/harness-ai-kitWrote 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.
[](https://agentmods.dev/skills/seed-forge/harness-ai-kit/diag-mysql-replication)<a href="https://agentmods.dev/skills/seed-forge/harness-ai-kit/diag-mysql-replication"><img src="https://agentmods.dev/badge/skills/seed-forge/harness-ai-kit/diag-mysql-replication/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/seed-forge/harness-ai-kit/diag-mysql-replication"><img src="https://agentmods.dev/badge/skills/seed-forge/harness-ai-kit/diag-mysql-replication.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00070 | $0.01347 |
| Opus 5.5 | $0.00028 | $0.00539 |
| Sonnet 5.5 | $0.00014 | $0.00269 |
| Haiku 4.5 | $0.00007 | $0.00135 |
Grade A, and why
diag-mysql-replication 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 3mo 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.
How it starts
The opening of the file, as written. The whole thing — 178 lines — stays where its author put it; the contents beside it link to each section on GitHub.
MySQL Replication Lag Full-Chain Diagnostics
用途
当用户报告主从延迟、读写分离数据不一致、或定期复制健康巡检时触发。
本技能是自包含诊断 Runbook。
输入
- 主库和从库的 MySQL 连接信息
- 可选:已知延迟时间段或特定大事务
输出
- 复制延迟分析报告(填充输出模板)
- 延迟根因 + 修复建议
前置条件
| 项 | 要求 |
|---|---|
| 权限 | REPLICATION CLIENT, PROCESS |
| 版本 | MySQL 5.7+(8.0+ 优先用 performance_schema replication 表) |
诊断步骤
Step 1: 检查复制状态
-- 从库上执行
SHOW REPLICA STATUS\G -- MySQL 8.0.22+
SHOW SLAVE STATUS\G -- MySQL 5.7 / 8.0 < 8.0.22
-- 关键字段
-- Seconds_Behind_Source: 延迟秒数(NULL 表示复制中断)
-- Replica_IO_Running / Replica_SQL_Running: 线程是否正常
-- Last_Error / Last_SQL_Error: 最近的错误信息
-- Retrieved_Gtid_Set / Executed_Gtid_Set: GTID 进度
Step 2: 对比主从 GTID / Position
-- 主库
SHOW MASTER STATUS;
-- 或 MySQL 8.0+
SHOW BINARY LOG STATUS;
-- 从库
SHOW REPLICA STATUS\G
-- 比较 Master_Log_File/Read_Master_Log_Pos 与 Executed_Gtid_Set
Step 3: 检查从库 SQL 线程瓶颈
-- 从库当前执行的 SQL
SHOW PROCESSLIST;
-- 大事务检测(从库 relay log 中的大事务)
SELECT * FROM performance_schema.events_transactions_summary_by_thread_by_event_name
WHERE EVENT_NAME LIKE 'transaction%'
ORDER BY COUNT_STAR DESC LIMIT 10;
-- 从库并行复制状态(8.0+)
SELECT * FROM performance_schema.replication_applier_status_by_worker;
Step 4: 检查复制配置
-- 复制模式
SHOW VARIABLES LIKE 'rpl_semi_sync%';
SHOW VARIABLES LIKE 'slave_parallel_type'; -- LOGICAL_CLOCK / WRITESET
SHOW VARIABLES LIKE 'slave_parallel_workers';
SHOW VARIABLES LIKE 'binlog_format'; -- ROW / MIXED / STATEMENT
SHOW VARIABLES LIKE 'sync_binlog';
SHOW VARIABLES LIKE 'innodb_flush_log_at_trx_commit';
Step 5: 检查网络与 IO 延迟
-- 从库 IO 线程状态
SHOW REPLICA STATUS\G
-- 关注 Slave_IO_State: "Waiting for source to send event" 可能表示网络问题
-- 关注 Slave_SQL_State: "Reading event relay log" vs "Waiting for dependent transaction"
输出模板
MySQL Replication Lag Analysis Report
════════════════════════════════════════
Master: {master_host}:{master_port}
Replica: {replica_host}:{replica_port}
Analysis Time: {timestamp}
Replication Status
IO Thread: {io_running} (state: {io_state})
SQL Thread: {sql_running} (state: {sql_state})
Lag: {seconds_behind}s
Last Error: {last_error}
GTID Progress
Master: {master_gtid_set}
Replica: {replica_gtid_set}
Gap: {gtid_gap_description}
Configuration
Binlog Format: {binlog_format}
Parallel Workers: {parallel_workers} ({parallel_type})
Semi-Sync: {semi_sync_status}
sync_binlog: {sync_binlog}
flush_log_at_trx: {flush_log_at_trx}
Bottleneck Analysis
{bottleneck_analysis}
Root Cause
{root_cause}
Recommendations
1. [Config] {config_fix}
2. [SQL] {sql_fix}
3. [Infra] {infra_fix}
What ships with it
3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 3mo ago First seen · 178 lines · 70 tokens per session scan A 3206c63ce042
diag-mysql-replication is a skill published in the GitHub repository seed-forge/harness-ai-kit (26 stars, last pushed 3mo ago), licensed Apache-2.0. It adds 70 tokens to every session and 1,347 once invoked, about $0.0003 per session on Opus 5.5. 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.
diag-mysql-replication compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| diag-mysql-replicationseed-forge/harness-ai-kit | Skill | 26 | 3mo ago | Apache-2.0 | A | 70 | Claude Code, Codex |
| sql-optimization-patternswshobson/agents | Skill | 43k | 2d ago | MIT | A | 44 | Claude Code |
| rescuesuboss87/FDEOps | Skill | 776 | yesterday | MIT | A | 48 | Claude Code, Codex |
| lcx-report-bugcode-yeongyu/oh-my-openagent | Skill | 71k | today | none | A | 85 | Codex |
| ast-grepcode-yeongyu/oh-my-openagent | Skill | 71k | today | none | A | 61 | Claude Code, Codex |
| debuggingcode-yeongyu/oh-my-openagent | Skill | 71k | today | none | A | 53 | Claude Code, Codex |
| lcx-doctorcode-yeongyu/oh-my-openagent | Skill | 71k | today | none | A | 93 | Codex |