AGENTS.md@internal/tuiA

AGENTS.md@internal/tui from iohub/yagent is an AGENTS.md file: the standing instructions coding agents read in that repo.

Install it, pinned
mdr add iohub/yagent/internal/tui/AGENTS.md@git:20261105.fb6340a

Pins git:20261105.fb6340a in mdr.lock. Pin the fingerprint instead.

Audit grade
A, 14 of 14 checks passed
Kind
AGENTS.md file
Repository
iohub/yagent
Path
internal/tui/AGENTS.md
Versions recorded
14
Latest version
git:20261105.fb6340a, committed Nov 5, 2026
First version recorded
Oct 23, 2026
Size
26,223 bytes
Repository stars
31
License
Apache-2.0

Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.

What the file says

# internal/tui — Bubble Tea v2 界面

> 范围:本目录内不可派生的约束。全局见仓库根 `AGENTS.md` §6.8。
> **这里没有专属守卫**(`check_*.sh` 共十一把,管的是依赖方向、裸 go、原子写、文件行数、测试卫生),所以 TUI 的全部不变量只由代码注释 + 渲染/尺寸矩阵测试钉住。

## 边界

唯一面向用户的 model/Update/View。只消费事件总线并按其渲染:**不生产事件、不做压缩判定、
不写配置生效逻辑**(写回内核在 `internal/config/persist.go`)。不 import `internal/agents`
(落点由 `app` 侧计算)。

## 硬约束

**1. `listenForEvents` 是一次性 cmd,没有重放队列。** 只有"事件被消费"才补回监听
(`tui_update.go:9-17` 的 `keepListening`),给按键或 resize 补会让监听 goroutine 按按键次数堆积。
任何新增叠加模式/守卫都必须消费 `taskEventMsg` 并重新武装监听器,否则界面永久断流
(根 AGENTS.md §11 坑 6)。

**2. 弹窗守卫是白名单,`taskCompleteMsg` 必须透传。** `tui_update.go:46-56`:弹窗打开时只放行
少数消息类型。`taskCompleteMsg` 是 `taskRunning` **唯一的清零点**,吞掉的表现是界面永久卡在
"运行中"且最终答案不落地。**求助与授权已不是弹窗**(`ask_state.go` / `ask_panel.go`):它们是 footer 的一块,不进这道守卫。

**3. 布局尺寸只有一个口径。** `computeFooterHeight`(`tui_render.go:16-18`)与 `View()` 的 footer
拼接逐行对应(`tui_view.go:212-214`);视口行高与正文四列宽度也只算一次 —— `computeBodyLayout`
(`tui_view.go:40`)= 高 `termHeight - footer - tabBarHeight`、宽 `termWidth - 滚动条列 - dashboard 列`,
resize(`tui_render.go:137`)、切标签页(`tui_tabs.go:283`)、后台标签页尺寸(`tui_update_system.go:135`)
全部走它。差一行整屏抖动;差一列(旧 resize 用 `termWidth - dashboardWidth` 且没扣 tab 栏)的代价是
…

Read the whole file at its exact version.

How to install

The exact contents, by fingerprint
mdr add iohub/yagent/internal/tui/AGENTS.md@sha256:80814d36f42263ab

The line at the top of this page pins the label git:20261105.fb6340a, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.

Badge

mdr badge

[![mdr](https://markdownregistry.com/badge/art_yk5stje2ftlakdgd.svg)](https://markdownregistry.com/a/art_yk5stje2ftlakdgd)

2 badge image fetches in 30 days. What the badge shows.

Versions

The registry has recorded 14 versions of this file, between Oct 23, 2026 and Nov 5, 2026, more than one a day.

versioncommittedcommitsizeaudit
git:20261105.fb6340a latest2026-11-05 fb6340a 26,223 BA view · diff
git:20261104.e5176722026-11-04 e517672 26,205 BA view · diff
git:20261104.7d351c62026-11-04 7d351c6 25,842 BA view · diff
git:20261104.dfea0b52026-11-04 dfea0b5 25,685 BA view · diff
git:20261103.b0fccd22026-11-03 b0fccd2 24,881 BA view · diff
git:20261026.7fb3f5e2026-10-26 7fb3f5e 24,324 BA view · diff
git:20261026.9356d9b2026-10-26 9356d9b 24,002 BA view · diff
git:20261026.7381d712026-10-26 7381d71 22,422 BA view · diff
git:20261025.f3f17152026-10-25 f3f1715 21,987 BA view · diff
git:20261024.9b444412026-10-24 9b44441 20,889 BA view · diff
git:20261023.dd5a6e42026-10-23 dd5a6e4 13,411 BA view · diff
git:20261023.69303802026-10-23 6930380 13,717 BA view · diff
git:20261023.83789462026-10-23 8378946 11,440 BA view · diff
git:20261023.c9d48a32026-10-23 c9d48a3 9,778 BA view

Audit of the latest version

A  14 of 14 checks passed. Fixed automatic checks with no AI involved, so the same checks give the same answer every run.
  • pass: Size between 200 bytes and 200 KB (26223 bytes)
  • pass: No zero-width or bidi control characters
  • pass: No instruction hidden inside an HTML comment
  • pass: No link to an exfiltration or paste host
  • pass: No credential-shaped string
  • pass: No instruction to send local credentials anywhere
  • pass: No text hidden with inline styles
  • pass: No prompt-injection phrasing
  • pass: No curl or wget piped into a shell
  • pass: No recursive delete of root, home or parent
  • pass: No instruction to read or print local credentials
  • pass: No base64 blob over 200 characters
  • pass: No link to a raw IP address
  • pass: No script tag

Source

GitHub

iohub/yagent · 31 stars · license Apache-2.0 · pushed 2026-11-05 · branch main

API

GET https://markdownregistry.com/api/v1/artifacts/art_yk5stje2ftlakdgd
GET https://markdownregistry.com/api/v1/resolve?ref=iohub/yagent/internal/tui/AGENTS.md
GET https://markdownregistry.com/api/v1/blob/80814d36f42263ab3cfd3733c1709a6211ff338ee2a91316cb4362cfdf7eef97

Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.

Guides: how to write a good AGENTS.md · AGENTS.md vs CLAUDE.md · which agent file does what.

More from iohub/yagent

AGENTS.md AGENTS.md file
iohub/yagent · AGENTS.md
git:20261103.104f21a · audit A · 31 stars
AGENTS.md@internal AGENTS.md file
iohub/yagent · internal/AGENTS.md
git:20261026.7381d71 · audit A · 31 stars
AGENTS.md@internal/agents AGENTS.md file
iohub/yagent · internal/agents/AGENTS.md
git:20261103.104f21a · audit A · 31 stars
AGENTS.md@internal/agents/director AGENTS.md file
iohub/yagent · internal/agents/director/AGENTS.md
git:20261103.104f21a · audit A · 31 stars
AGENTS.md@internal/app AGENTS.md file
iohub/yagent · internal/app/AGENTS.md
git:20261024.9b44441 · audit A · 31 stars
AGENTS.md@internal/blackboard AGENTS.md file
iohub/yagent · internal/blackboard/AGENTS.md
git:20261026.89c0391 · audit A · 31 stars
AGENTS.md@internal/blueprint AGENTS.md file
iohub/yagent · internal/blueprint/AGENTS.md
git:20261026.9762922 · audit A · 31 stars
AGENTS.md@internal/browserctl AGENTS.md file
iohub/yagent · internal/browserctl/AGENTS.md
git:20261030.25a3126 · audit A · 31 stars
AGENTS.md@internal/compression AGENTS.md file
iohub/yagent · internal/compression/AGENTS.md
git:20261028.19903d6 · audit A · 31 stars
AGENTS.md@internal/config AGENTS.md file
iohub/yagent · internal/config/AGENTS.md
git:20261024.9b44441 · audit A · 31 stars
AGENTS.md@internal/http AGENTS.md file
iohub/yagent · internal/http/AGENTS.md
git:20261026.7381d71 · audit A · 31 stars
AGENTS.md@internal/llm AGENTS.md file
iohub/yagent · internal/llm/AGENTS.md
git:20261027.0637c8b · audit A · 31 stars

Every file in iohub/yagent

Browse by kind, by grade A, or by owner.