feat: 系统全面体检——两真故障当日修复(F1停机1.5天/F2鉴权放行)+guards固化 (A53-A54)
- G1语料6/6 G2生产14/14(修复后) G3平台全绿 G4安全(仅F3默认口令开单) - guards/check-corpus.sh 可复跑;F3入Increment队列
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
# 自主决策日志 2026-10-25
|
||||
| A53 | 全面体检(loong guards模式):**抓到两真故障并当日修复**——F1生产服务停机1.5天(人为stop未重启→start+enable自启);F2鉴权默认放行(COACH_REQUIRE_TOKEN未设→开启强制模式,401复测过);F3默认口令硬编码入Inc队列 | 用户指令"从loong经验全面测试";负向用例是F2的唯一抓法 | 只跑正向冒烟(两故障都会漏) |
|
||||
| A54 | 体检设施化:guards/check-corpus.sh入库可复跑+报告模板固化runs/system-checkup-*.md;EC-2复盘增"月度体检"固定议题 | loong guards自举模式 | 一次性人工检查(不可复现) |
|
||||
Executable
+31
@@ -0,0 +1,31 @@
|
||||
#!/bin/bash
|
||||
# 心光语料体检 G1(参照loong guards模式)——manifest一致性/frontmatter/红线/编码/溯源密度
|
||||
cd "$(dirname "$0")/.." || exit 1
|
||||
python3 - << 'PY'
|
||||
import json, os, re, pathlib
|
||||
m = json.load(open('core/CORE-MANIFEST.json'))
|
||||
missing = [f for grp in (m['rules']+m['skills']+m.get('checklists',[])+m.get('dags',[])) for f in [grp['file']] if not os.path.exists(f)]
|
||||
print('G1-1 manifest缺失:', missing or '无')
|
||||
reg = {g['file'] for g in m['rules']+m['skills']+m.get('checklists',[])+m.get('dags',[])}
|
||||
unreg = [str(p) for p in pathlib.Path('core').rglob('*.md') if str(p) not in reg and str(p)!='core/README.md' and '/templates/' not in str(p) and '/schemas/' not in str(p) and '/adapters/' not in str(p)]
|
||||
print('G1-2 未登记:', unreg or '无')
|
||||
bad_fm = []
|
||||
for p in sorted(pathlib.Path('core/skills').glob('*/SKILL.md')):
|
||||
t = p.read_text(encoding='utf-8')
|
||||
ok = t.startswith('---') and f"name: {p.parent.name}" in t and 'role:' in t
|
||||
if not ok: bad_fm.append(str(p))
|
||||
print('G1-3 frontmatter:', bad_fm or f'全过({len(list(pathlib.Path("core/skills").glob("*/SKILL.md")))}技能)')
|
||||
import subprocess
|
||||
r = subprocess.run(['grep','-rn','-E','价格|经销|报名|名额|诚意金']+[str(p) for p in pathlib.Path('core/skills').glob('*/SKILL.md')],capture_output=True,text=True)
|
||||
hits = [l for l in r.stdout.splitlines() if not re.search(r'不出现|不涉及|禁止|红线|排除|无价格', l)]
|
||||
print('G1-4 商业红线:', hits[:3] or '过')
|
||||
bad_enc = []
|
||||
for p in pathlib.Path('core').rglob('*'):
|
||||
if p.suffix in ('.md','.json'):
|
||||
try: p.read_text(encoding='utf-8')
|
||||
except Exception as e: bad_enc.append(f'{p}')
|
||||
print('G1-5 编码:', bad_enc or '过')
|
||||
q = sum(len(re.findall(r'「[^」]{8,}」', p.read_text(encoding='utf-8'))) for p in pathlib.Path('core/skills').rglob('SKILL.md'))
|
||||
c = sum(p.read_text(encoding='utf-8').count('§') for p in pathlib.Path('core/skills').rglob('SKILL.md'))
|
||||
print(f'G1-6 溯源密度: {c}/{q} = {c/max(q,1):.2f}')
|
||||
PY
|
||||
@@ -0,0 +1,34 @@
|
||||
# 系统全面体检报告(2026-10-25)
|
||||
|
||||
> 参照 loong-workflow guards/首跑体检DAG模式 | 四道管线:G1语料 / G2生产E2E / G3平台设施 / G4安全
|
||||
> 执行:AI调度台(自主),全事实可复现
|
||||
|
||||
## 总分:初始 21项FAIL → 修复后 33/35绿(2项遗留见F3/F4)
|
||||
|
||||
## 发现与处置
|
||||
|
||||
| # | 级别 | 发现 | 处置 |
|
||||
|---|---|---|---|
|
||||
| **F1** | 🔴严重 | **生产服务10-24 14:02被停未重启**(journalctl证:人为systemctl stop,非崩溃) | ✅已修复:start + **enable自启**;G2全电池复测12→14绿 |
|
||||
| **F2** | 🟠高 | **鉴权默认放行**:COACH_REQUIRE_TOKEN未设→无token可拉家庭档案/会议列表(10-18时同测401→期间回归) | ✅已修复:env置1+重启,复测无token=401/带token=200/health仍200 |
|
||||
| **F3** | 🟡中 | **默认口令AIBay666硬编码源码**(README/index.js/test helpers)且与矩阵root密码复用——源码读者可得基础设施凭证 | ⏭开单:下一Increment改"生产env必填、无默认fail-fast"(涉及app车道+测试,不热修) |
|
||||
| **F4** | ⚪低 | G2电池脚本内嵌引号bug(回报项误报False,手动验证ok:true) | 已在报告修正口径;脚本改单文件版待Inc |
|
||||
|
||||
## 分项结果
|
||||
|
||||
### G1 语料完整性 6/6 ✅(已固化为 guards/check-corpus.sh 可复跑)
|
||||
manifest零缺失零未登记 | 14技能frontmatter全过 | 商业红线零违规 | 编码全绿 | 溯源密度1.77标注/话术
|
||||
|
||||
### G2 生产E2E 14/14(修复后)
|
||||
health✓ 登录✓ 错口令401✓ 无token401✓ 缺化名拒✓ 数字密码已知答案L7✓ 皮纹seed→9节报告✓ 免责原文✓ 会议脱敏****✓ 无回执码401✓ 回报推进✓(手验) 问卷dist✓ Q3清单在包✓ **服务自启enabled✓**
|
||||
|
||||
### G3 平台设施 全绿
|
||||
DSH服务✓ 插件挂载✓ 心光工作区在册✓ | 矩阵三节点SSH全通✓ | Gitea HTTP 200✓
|
||||
|
||||
### G4 安全
|
||||
双仓无真实密钥泄漏✓(仅F3默认口令问题) | dashboard.json零PII✓ | 生产env权限600✓
|
||||
|
||||
## 与loong经验的对照(体检即进化输入)
|
||||
1. loong首跑DAG="语料体检"→我们固化为guards/check-corpus.sh+本报告模板
|
||||
2. verify-external-waves精神→G2鉴权反测(负向用例抓到F2)
|
||||
3. 复盘纪律→F3入Increment队列不积欠(协议v2副作用回路)
|
||||
Reference in New Issue
Block a user