---
description: iOS 前端递归架构与问题目录的稳定证据索引
status: request_changes
updated: 2026-08-28
confidence: high
sensitivity: internal
---

# 证据索引

## Revision ledger

| Source | Revision / observed at | Authority | Limitation |
|---|---|---|---|
| current main 运行基线 | `repo://ailoha-agent-iOS@6922f359ad08da70242e4ec0c5c4a1486bc2908d`，2026-08-28 | 全新 iOS 26.5 Simulator 上的 clean build、首次启动、登录页、最大 Dynamic Type 与 scheme test 结果 | 未登录；未运行真账号、生产 API、APNs / ActivityKit、ETTrace、memgraph 或真机 |
| current main 登录可访问性 | 同一 revision，iPhone 17 Pro Simulator / iOS 26.5，2026-08-28 | Large/AXXXL、Reduce Motion on/off 对比帧、运行语义树、current-main 源码闭环 | Debug 未登录入口；不是 spoken VoiceOver；Release、账号内旅程与真机未知 |
| iOS code | `repo://ailoha-agent-iOS@5e6ac6e41c53780c85808c92290d2bd38f809123`, 2026-08-11 21:28 +08 | 运行实现事实 | 本轮静态读取，未改代码 |
| Figma | `figma://UR45i9TtpX95auUs46rsHL/2391:25876`, 2026-08-11 | 历史可读设计节点 | 只验证到 Onboarding 问卷节点；2026-08-28 fresh read 受 Professional View seat tool-call limit 阻断，节点生命周期仍未知，不能称 current |
| 飞书 iOS | `feishu://wiki/OPTZwOQC7ilug3klEPtca8Drnfs`, 2026-08-11 读取 | 产品/协作文档 | 子文档最后编辑为 2026-06-22，不覆盖之后代码 |
| 本地工程快照 | `python3 scripts/ios_report_snapshot.py --repo ../ailoha-agent-iOS --output /tmp/ios-frontend-refactor-snapshot.json --skip-patch-ids`，2026-08-11 | 计数与工程结构 | `/tmp` 临时文件不提交；结果摘要写入报告 |
| Wave 0 local overlay | `repo://ailoha-brain/tasks/active/IOS-20260812-frontend-refactor-wave0`，2026-08-12 | 隔离 worktree 的当前 remediation 候选与 Chief-local 验证 | 87-file manifest `45ba87810f933d57eeb48030afb52a41b53d28e4f7708bef932728dfde6fe44c`；未 commit/PR/merge/release；65/65 + 129/129 enumerated mutations，protected CI 未接入 |
| Wave 0 attack review | `repo://ailoha-brain/tasks/active/IOS-20260812-frontend-refactor-wave0/review.md`，2026-08-12 | 与 Task Chief 独立的历史反例与 verdict | exact `45ba8781…e44c` 为 request_changes（0 P0 + 1 P1）；Calendar closed，credential regex inventory 仍有同根邻接绕过 |

Wave 0 旧 frozen manifests 曾取得 hosted 31/31、10 条关键 race 各 10 轮共 100/100、ARPC Package 6/6、credential 12 + account/external-effect 50 个 compile-valid mutation、系统 Python 3.9.6 Lightweight 与 generic Simulator Debug/Release 收据；后续独立复审继续发现真实 pre-send、logout session、Calendar/system effect、journal、late Activity owner、Screenshot writer 与跨文件 property/closure-return 边界。Exact `45ba8781…e44c` 的 verdict 是 0 P0 + 1 P1；Calendar logout/reset 已关闭。Hosted 65/65、credential 40 + account/effect 89、Lightweight、Debug/Release 与 diff-check 只证明枚举 source→known-sink 变体及声明的 account/effect seam，不是 production、integrated 或 approved 状态。

## High-impact claim ledger

| Claim | Type | Evidence | Confidence | 可反证条件 |
|---|---|---|---|---|
| C-ACCOUNT-01 正常登出未清理 Contact/Calendar/Task 等全局状态 | fact | `repo://ailoha-agent-iOS/Ailoha/GlobalService/Auth/AuthService.swift#L598`; `repo://ailoha-agent-iOS/Ailoha/AilohaApp.swift#L557`; Task 只在 environment switch reset：`repo://ailoha-agent-iOS/Ailoha/GlobalService/Task/TaskLifecycleCoordinator.swift#L705-L734` | high | 找到正常登出前后统一调用的 account reset 路径 |
| C-ACCOUNT-02 新账号可能看到旧联系人/日历数据或复用 task correlation state | inference | Contact page 1 响应前保留旧数组：`repo://ailoha-agent-iOS/Ailoha/GlobalService/Contact/ContactManager.swift#L204-L210`；Calendar 5 分钟 cache hit与 `clearCache` 不清 published events：`repo://ailoha-agent-iOS/Ailoha/Pages/Calendar/CalendarViewModel.swift#L354-L382,#L469-L471`；TaskState 仅有 environment reset：`repo://ailoha-agent-iOS/Ailoha/GlobalService/Task/TaskStateManager.swift#L729-L745` | high | app-level 双账号测试证明 UI/state 在认证切换时先清空或实例被重建 |
| C-LOG-01 credential 前缀绕过 redactor 并进入持久/周期日志 | fact | token/API key producers：`repo://ailoha-agent-iOS/Ailoha/GlobalService/ScreenshotTask/ScreenshotIntentRunner.swift#L152`、`repo://ailoha-agent-iOS/Ailoha/AppDelegate.swift#L150`、`repo://ailoha-agent-iOS/Ailoha/GlobalService/RealtimeTranscribeService.swift#L92`；redactor：`repo://ailoha-agent-iOS/AilohaShared/ALHLogRedactor.swift#L45`；periodic sink：`repo://ailoha-agent-iOS/Ailoha/Utils/ALHLogger.swift#L336` | high | redactor unit test证明这些精确消息均完全脱敏，或生产配置证明调用不可达且不落盘 |
| C-STATE-01 Task 并非全局单一 source of truth | fact | `TaskStateManager` 与 `HomeViewModel` 分别持有 task state；`repo://ailoha-agent-iOS/Ailoha/GlobalService/Task/TaskStateManager.swift`; `repo://ailoha-agent-iOS/Ailoha/Pages/Home/HomeViewModel.swift` | high | Home 改为只投影统一 repository/store 且无独立 REST merge/mutation |
| C-DESIGN-01 颜色与排版 token 存在多个不一致来源 | fact | `ALHColors.primaryAccent`、`AilohaColorTokens.accent`、`WidgetCardKit.figmaAccent` 以及 raw literal 扫描 | high | 生成式 token contract 证明所有 consumer 来自同一源且值差异有语义说明 |
| C-DESIGN-02 current main 已是 Chat V2-only、三项 visible bottom nav、12-route Onboarding 与部分生成 token 链；Theme preference 仍被强制 dark 覆盖。历史 Figma 节点的 current 生命周期未知 | fact + design-lifecycle unknown | `repo://ailoha-agent-iOS@6922f359`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-product-design-alignment-2026-08-28/product-design-alignment-audit.json`; `brain://reports/ios-frontend-refactor-map/product-design-alignment.md` | high for code surface; current Figma/design acceptance unknown | 新 revision 改变路由、可见 tab、Onboarding route、theme 或 token consumer；或 design owner 给出绑定 current implementation 的 Figma successor 与接受记录 |
| C-A11Y-01 品牌排版 adapter 固定字号，登录页在 Large 与 AXXXL 下仍维持相同语义结构与视觉排版，Dynamic Type 没有进入品牌字体 | fact + runtime evidence | `repo://ailoha-agent-iOS/Packages/AilohaDesignSystem/Sources/AilohaDesignSystem/AilohaTypography.swift#L63-L94`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-accessibility-runtime-2026-08-28/accessibility-runtime-audit.json` | high for login; other surfaces unknown | 新 revision 使用 relative text style；登录页 Large→AXXXL 的实际字号/布局改变且中英窄屏无关键裁切 |
| C-A11Y-02 登录背景视频在 Reduce Motion 开启后仍继续变化；组件无条件播放并在结束后循环 | fact + runtime mechanism evidence | `repo://ailoha-agent-iOS/Packages/OnboardingKit/Sources/OnboardingFeature/Components/LoopingVideoPlayerView.swift#L61-L91`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-accessibility-runtime-2026-08-28/accessibility-runtime-audit.json` | high for login | 新 revision 消费统一 motion policy；Reduce Motion on 的 3 秒未剪视频保持静态且 off 时正常播放 |
| C-A11Y-03 登录页 Google、Apple 与同意协议能被 Debug 运行语义树发现；完整 VoiceOver 旅程尚未证明 | fact + explicit unknown | `repo://ailoha-agent-iOS/Packages/OnboardingKit/Sources/OnboardingFeature/Pages/OnboardLoginPage.swift#L166-L241`; `brain://reports/ios-frontend-refactor-map/current-main-accessibility-runtime-baseline-2026-08-28.md` | high for runtime discovery; spoken behavior unknown | Release semantic snapshot 无空名称/Debug action，真实 VoiceOver 完成登录、协议、alert 与状态反馈并留下 transcript |
| C-PERF-01 多个 broad ObservableObject 可能造成过度 invalidation | inference | Contact/Calendar/Home/Task 的大量 `@Published` 与组合视图订阅 | medium | Observation trace 表明更新范围被局部化且 frame/CPU 无异常 |
| C-PERF-02 固定启动品牌序列完成前不创建 `RootPage`，让登录动作排在约 2.35 秒品牌 gate 之后 | fact | `repo://ailoha-agent-iOS/Ailoha/Pages/Splash/SplashView.swift`; `brain://reports/ios-frontend-refactor-map/current-main-startup-visual-readiness-baseline-2026-08-28.md` 的五次视频与 UI 语义观察 | high | 新 revision 的 trace 证明正确壳层在品牌呈现期间准备，且同 fixture 就绪耗时不再受固定序列阻断 |
| C-PERF-03 current main 修改一条普通 Calendar occurrence 会全量重建日期投影，成功保存还可能因乐观写入与服务端 upsert 执行两次；formatter churn 与 O(N) full scan 是两个独立成本 | fact + mechanism evidence | `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Calendar/CalendarViewModel.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/Utils/CalendarTimeContract.swift`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-calendar-projection-2026-08-28/calendar-projection-three-process-summary.json`; [Notion 实施总包](https://app.notion.com/p/3c9a444a6c00818197c0dc2377a7d078) | high for control flow and Foundation mechanism; device impact unknown | 新 revision 不再由任意 events 赋值触发 full projection；同 fixture 的 ordinary delta 只触达旧/新日期且与 full oracle 等价；真机 Release trace 裁决产品影响 |
| C-PERF-04 current main 多图输入把整批图片交成 `[UIImage]` 并在附件状态常驻；每张 detached 预检压缩后，上传 actor 再压一次。10×48MP Simulator 机制实验的 current-style 峰值增量中位数为 785.1MB，一次 prepare 文件化候选为 82.0MB；释放后两边都回落 | fact + mechanism evidence | `repo://ailoha-agent-iOS@6922f359/Ailoha/Components/InputPanel.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/GlobalService/Task/TaskAttachmentManager.swift`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-photo-import-2026-08-28/photo-import-three-run-summary.json`; [Notion 实施总包](https://app.notion.com/p/3c9a444a6c0081d5a99ee67c58b55c4e) | high for source and Simulator mechanism; real-device/production impact unknown | 新 revision 逐张产出受控 preview + upload file、同 item 只编码一次、取消不再继续；真机 Release 的真实格式矩阵推翻或确认收益 |
| C-PERF-05 current main Chat V2 的任一非等价 TaskData、单次 feedback 或 expansion 会 full rebuild 全历史 rows，renderer 再全量准备 snapshot；5000 行 Debug Simulator 单行追加三次的配对合计中位数约 81.9ms，优化编译的 production projector + renderer-preparation 五进程机制结果约 8.49ms | fact + mechanism/runtime evidence | `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Task/TaskChatViewModel.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Task/ChatRowItem.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Task/ChatCollectionView.swift`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-chat-projection-2026-08-28/chat-projection-five-process-summary.json`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-chat-update-2026-08-28/debug-simulator-chat-update-summary.json`; [Notion 实施总包](https://app.notion.com/p/3c9a444a6c0081febd30cdd74a913ecb) | high for source, O(n) mechanism and Debug page path; real-device/production impact unknown | 新 revision 的 feedback / expansion / processing 只触碰目标 row，append 只重算已证明安全的边界；与 full oracle 等价且真机 Release 5000 行 p95 达预算，或 trace 证明当前实现未超预算 |
| C-ONB-01 current main 只渲染姓名页且只积累 `fullName`，但 bundled questionnaire 的三项字段都 required，并用其 version 提交；本地 config→client contract gap 成立 | fact | `repo://ailoha-agent-iOS@6922f359/Packages/OnboardingKit/Sources/OnboardingCore/OnboardingFlow.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Onboarding/OnboardingPage.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/GlobalService/Onboarding/OnboardingCoordinator.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/Resources/OnboardingQuestionnaireFallback.json`; `repo://ailoha-agent-iOS@6922f359/api-contracts/http_api_v1.yaml`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-onboarding-design-contract-2026-08-28/onboarding-design-contract-audit.json` | high for local contract; production rejection unknown | 去敏 DEV fresh-account GET/POST 证明 name-only 被当前 schema 接受；或代码改为独立 name-only schema，required-field closure guard 对新增缺失字段会变红 |
| C-PERF-06 current main 的联系人字段草稿与页面业务状态共用 root `ObservableObject`；12 次姓名输入稳定触发 12 次 Contact page、12 次 Notes body、12 次全量备注解析与日期分组。Debug Simulator 1,000 / 5,000 notes 的每次无关 Notes 投影中位数约 23.6 / 91.5ms；优化编译的 production grouping 五进程结果约 14.9 / 74.3ms | fact + mechanism/runtime evidence | `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Contact/ContactDetailViewModel.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Contact/ContactDetailPage.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Contact/Detail/ContactNotesView.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/Pages/Contact/ContactNotesGrouping.swift`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-contact-detail-2026-08-28/contact-detail-typing-debug-simulator-summary.json`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-contact-detail-2026-08-28/contact-notes-projection-five-process-summary.json` | high for source, fan-out and Debug page path; real-device/production impact and notes distribution unknown | 新 revision 让 editor-local draft 在确认前不发布 root 变化；20 次姓名/company 输入的 Notes body/projection 为 0，note 事务至多投影一次并与 full oracle 等价；真机 Release 达输入预算或 trace 证明当前实现无用户影响 |
| C-LA-01 current main 已有精确 end、pending-end 与 observer lease 等局部可靠性支点，但 Live Activity 仍缺跨 App/Widget/local/remote 的统一 attention、freshness、business revision、cardinality 与 disclosure 合同；这证明合同碎片化，不证明生产事故 | fact + architecture inference | `repo://ailoha-agent-iOS@6922f359/AilohaShared/ScreenshotTaskAttributes.swift`; `repo://ailoha-agent-iOS@6922f359/AilohaShared/LiveActivityEnder.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/GlobalService/DeviceRegistrationService.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/GlobalService/Task/LiveActivityAutoExpiryService.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/GlobalService/Task/TaskCreationService.swift`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-live-activity-transfer-contract-2026-08-28/live-activity-transfer-contract-audit.json`; [Notion Agent 执行版](https://app.notion.com/p/3c9a444a6c0081cb8228d9c2ec4e3944) | high for current source contract; production impact and target design unknown | 新 revision 具有可执行的 surface policy、canonical projection、显式单卡/多卡政策、跨 owner 单调 revision 与 disclosure allowlist；`ALH-LA-01…12`、三段未剪视频和真机失败矩阵全部通过 |
| C-LA-02 current main 的六类真实任务可产生多张 task-bound 卡，但设备注册只携带一组 activity id/update token；21 个富字段中已有地点、电话、邮箱、联系人 notes 等由 Widget 直接渲染，且未发现统一 redaction/privacy policy。它证明 cardinality、disclosure 与 direct-action 的产品政策缺口，不证明线上事故或目标方案已接受 | fact + product-policy inference | `repo://ailoha-agent-iOS@6922f359/AilohaShared/ScreenshotTaskAttributes.swift`; `repo://ailoha-agent-iOS@6922f359/AilohaWidget/TaskLiveActivityView.swift`; `repo://ailoha-agent-iOS@6922f359/Ailoha/GlobalService/DeviceRegistrationService.swift`; `brain://reports/ios-frontend-refactor-map/evidence/current-main-live-activity-product-policy-2026-08-28/live-activity-product-policy-audit.json`; `brain://reports/ios-frontend-refactor-map/current-main-live-activity-product-policy-decisions-2026-08-28.md`; [Notion 共同设计版](https://app.notion.com/p/3c9a444a6c00815c8cb1d9807f49dce8) | high for current source surface; user preference, incident and accepted target unknown | 新 revision 由具名 owner 接受显式卡片数量、D0–D4 allowlist 与动作边界；或新源码证明每个 rich field 都受统一 disclosure projection 控制、所有活动均可按 activity id 独立更新，当前判断失效 |
| C-DOC-01 飞书/Figma/代码处于不同时间切片 | fact | 飞书编辑时间、Figma 问卷节点、代码中的 Setup 2.0/Try It/V1-V2 flags/三 Tab | high | 上游提供绑定当前 commit 的 successor 文档与设计 revision |

## Product / design sources

- Figma Onboarding question screen：393×852，dark `#1A1A1A`，Lora 24 标题，Manrope 按钮，accent `#C8F04A`，5 个选项，Continue disabled，水平 24pt。它是视觉证据，不是当前全流程定义。
- 飞书当前 iOS 节点及子文档：
  - Onboarding `feishu://wiki/Lfmbwi538inMWMk49K6cQJZJnkd`
  - Chat `feishu://wiki/Tcf7w6VB5iYqdQk04z1cKaoOngO`
  - Calendar `feishu://wiki/BkAMwt8l2ijueWkELGoc8LkTnmh`
  - Contact `feishu://wiki/ENskwk5lIizpVTkqscHcmp8Snce`
  - Screenshot Task `feishu://wiki/IjwowypjUihJTqk6MJ6cQzbannF`
  - Home `feishu://wiki/IxBVwtA0IiKKVzk4sexczzDhnBb`
  - ARPC `feishu://wiki/O2R4wGvP1iKl3mk0HnncMEBjnIb`
  - Auth `feishu://wiki/DzMuwUzB9iwwMfkRImfct2bPnse`
  - Task lifecycle `feishu://wiki/F7ZewDFdRizJDCkCteXcoan5nTg`
  - Live Activity `feishu://wiki/WmEdw9EZ9ibcIJkvejtcxJc2n3b`
- `feishu://wiki/SYl7wUv1LiJqgWkeCW3cuOkKnWf` 标题为 iOS 架构重构，正文实际是 Agent/backend 架构；只作为治理问题证据，不作为 iOS 设计输入。

## Representative code evidence by domain

| Domain | Composition/state | UI/consumer | Transport/storage |
|---|---|---|---|
| App shell | `repo://ailoha-agent-iOS/Ailoha/AilohaApp.swift`; `RootPage`; `MainTabPage` | `BottomNavigationBar`; `NavigationUIState` | `ServiceLocator`; `Router` |
| Onboarding | `Packages/OnboardingKit/.../OnboardingCore`; `OnboardingCoordinator.swift` | Setup 2.0 / Questionnaire / Try It pages | Auth/API + local Try It constants |
| Task/Chat | `TaskLifecycleCoordinator`; `TaskStateManager`; `TaskChatViewModel`; `HomeViewModel` | Release 历史仍有 V1/V2；current main 为 `TaskChatPageV2` + `ChatCollectionView` | REST, ARPC topic, App Group |
| Contact | `ContactManager`; `ContactDetailViewModel` | Contact list/detail/edit/share/cluster | REST + ARPC merge + in-memory caches |
| Calendar | `CalendarViewModel`; detail/editor state | month/day/detail/sheet | REST + EventKit mirror + five-minute cache |
| Extensions | `SharedConstants`; `SharedDataManager`; pending ledgers | Widget/Live Activity/notification content | App Group + ActivityKit + API |
| Design | DesignSystem package, app tokens, WidgetCardKit | 128 importing files + raw literal consumers | Figma/manual values |

## Static scan commands

扫描可由仓库标准工具重新执行，关键模式包括：

```bash
rg -n --glob '*.swift' 'static let shared|NotificationCenter|UserDefaults'
rg -n --glob '*.swift' '@Published|@StateObject|@ObservedObject|@EnvironmentObject'
rg -n --glob '*.swift' 'onTapGesture|DragGesture|accessibility(Label|Hint|Action)|fixedSize'
rg -n --glob '*.swift' 'prefix\([0-9]+\)|accessToken|refreshToken|apiKey|updateToken'
rg -n --glob '*.swift' 'TODO|FIXME|fatalError|as!|Task\.sleep|asyncAfter'
```

命中需要人工沿数据流解释；本报告没有把正则计数直接当成缺陷数量。
