AGENTS.md@internal/configA

AGENTS.md@internal/config 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/config/AGENTS.md@git:20261024.9b44441

Pins git:20261024.9b44441 in mdr.lock. Pin the fingerprint instead.

Audit grade
A, 14 of 14 checks passed
Kind
AGENTS.md file
Repository
iohub/yagent
Path
internal/config/AGENTS.md
Versions recorded
4
Latest version
git:20261024.9b44441, committed Oct 24, 2026
First version recorded
Oct 21, 2026
Size
9,549 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/config — TOML 加载、归一化、文本级写回

> 范围:本目录内不可派生的约束。全局见仓库根 `AGENTS.md` §7。
> 引导**界面**在 `internal/tui/setup*.go`,这里只负责"值从哪来、怎么写回去"。

## 边界

解析顺序(`--config` 原样使用、绝不自动创建 → `~/.yagent/config/config.toml` 不存在则用内嵌模板生成,
0600)、三级 provider 解析、缺省值归一化、文本级写回、provider 生命周期与首启判据。
**不负责这些值怎么被用**——各消费方读结构体或全局单例。

## 硬约束

**1. `validate()` 是缺省值唯一写入点,往里加提前 return 之前先确认下面的归一化段还会被执行**
(`config.go:621-622`)。曾经 Bedrock 豁免写成 `return nil`,于是 max steps、`[browser]` 缺省、
TUI 键位、压缩参数**全部停在零值**——表现不是报错,是能力静默缺失(根 AGENTS.md §11 坑 14)。
回归 `TestLoadFromFile_BedrockNoLongerExempted`(`validate_test.go:110`)同时断言"归一化照常发生"。

**2. "0 有语义 / 缺省为真"的键一律看键的存在性,不看零值。**
段级 `sectionHasDecodedKey`(`config.go:353-365`)+ 单键 `md.IsDefined`
(`:486-487,505-507,518-519,530-531,542-543,554-555`);九个内部判定字段(mcp/skills 共用一行注释)
的理由逐条写在 `:228-252`。**只剩失效键的段落 == 没写过**(`:352`,`[browser] enabled` 踩过)。
两套取值约定别混:`max_parallel_*` 用 1 = 严格串行、≤0 = 默认;
而 `[llm] max_in_flight_requests` 的 **0 有语义(不限流)**,所以必须靠存在性区分"没写 → 8"与"写了 0 → 不限"。

**3. 写 config.toml 只能文本级替换。** `SetKeyInSection` 是唯一内核(`persist.go:13-23`),
`RemoveKeyInSection` / `RemoveSection` 与三个 `Persist*` 都建在它上面。
禁止 `toml.NewEncoder` 整份重编码——模板里每个键都靠注释自我说明,重编码会把用户注释蒸发。
…

Read the whole file at its exact version.

How to install

The exact contents, by fingerprint
mdr add iohub/yagent/internal/config/AGENTS.md@sha256:f706ec71bb39922d

The line at the top of this page pins the label git:20261024.9b44441, 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_fjazxkx5lu6ywm66.svg)](https://markdownregistry.com/a/art_fjazxkx5lu6ywm66)

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

Versions

The registry has recorded 4 versions of this file, between Oct 21, 2026 and Oct 24, 2026, about one every day.

versioncommittedcommitsizeaudit
git:20261024.9b44441 latest2026-10-24 9b44441 9,549 BA view · diff
git:20261023.dd5a6e42026-10-23 dd5a6e4 6,368 BA view · diff
git:20261023.34d22952026-10-23 34d2295 6,389 BA view · diff
git:20261021.9f5bf872026-10-21 9f5bf87 5,805 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 (9549 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_fjazxkx5lu6ywm66
GET https://markdownregistry.com/api/v1/resolve?ref=iohub/yagent/internal/config/AGENTS.md
GET https://markdownregistry.com/api/v1/blob/f706ec71bb39922d18eb4a2cd3b0b663ea8baf8e0b9800aa82b6ae6fbe9437ad

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/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
AGENTS.md@internal/mcp AGENTS.md file
iohub/yagent · internal/mcp/AGENTS.md
git:20261024.9b44441 · audit A · 31 stars

Every file in iohub/yagent

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