Repository navigation
Conversation
…ery invariants Streamline root AGENTS.md from 23,962 B (399 lines) to 15,439 B (164 lines, -35.6% bytes / -58.9% lines) while preserving every unique owner route, external inbound anchor, and decision obligation: - Reorganize AGENTS.md into (1) compact mission & codebase map, (2) explicit precedence order plus 10 always-on invariants at top-of-file to prevent lost-in-the-middle skips, (3) a duplicate-free task-triggered owner routing table, and (4) pinned root contracts retaining all four external inbound anchors (#author-submission-and-review-entry, #merge-authority-and-validation, #bounded-future-facing-refactoring, #first-screen-review-evidence). - Preserve pre-staging path classification and content scanning (including all raw logs in both scan and publication boundaries), verified PR_BASE_REF guard for bilingual RFC diffs, full review publication exemptions (local-only/dry-run/private/security-sensitive), caller-facing capability triggers for frontend delivery, fixture scope-fit triggers, and skills/loopx-self-repair/SKILL.md as a verified local route. - Update docs/development/README.md and tests/test_repository_instruction_delivery.py to enforce per-file (24,000 B) and combined tracked ancestor-chain budgets (32 KiB minus 4 KiB host headroom, ignoring untracked local overrides and measuring symlinks at checkout location with Windows-safe test splitting), fast CommonMark-aware whole-repository inbound anchor checks (handling fenced/indented code blocks, escaped/unclosed backticks, reference/titled/root-relative/escaped/percent-encoded links, and pinned HTML blog anchors), duplicate-free outbound routes, and section-scoped always-on obligation retention with numbering-independent mutation property tests. Signed-off-by: song <xinxinsong66@gmail.com>
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
loopx-agent
left a comment
There was a problem hiding this comment.
Reviewer: model_agent · gpt-6.2-sol · OpenAI · runtime_reported · xhigh
[P2] 保留产品改动在实施前检查既有设置的义务。 原根指令要求产品改动在实施之前读交付指南,并先检查现有设置和能力编辑器再判断是否只改后端。新路由从 UI、前端、Lark、CLI、调用方能力及媒体开始枚举。只改后端且可能改变现有设置语义时,Agent 可以按新条文检查三个入口并判定是纯后端,仍未检查现有编辑器。旧条文明确在判定前要求此动作,路由所指的 task-first 章节也没有补回这一条件。 当前实现
动机 / Motivation
从仓库根指令判断产品需求如何交付的开发和评审 Agent。 根规则接近单文件上限,Workbench 子树合计只剩 3,818 字节的 Codex 发现容量。 压缩入口指令,保留原有任务触发条件、义务和可追溯的 owner,并增加交付检查。 本轮核对仓库可交付指令与链接解析,范围限于源码和隔离夹具。 未以多宿主启动采样或真实模型验证采纳率。 基线 9e4730c。 基线约定
改动思路 / Approach
保留可直接加载的根规则和四个外部引用锚点,并按任务路由详细 owner。新增检查以已跟踪文件为输入,分别验证宿主发现容量、实际章节可达性和需要始终生效的义务。 根 AGENTS.md、开发指南及指令交付测试。
具体改动 / Changes
-
PRIMARY_DELIVERY。压缩入口指令,保留原有任务触发条件、义务和可追溯的 owner,并增加交付检查。
-
PRESERVE_CONTRACT。保留产品改动在实施前检查既有设置的义务。
-
任务表路由产品变更,省去部分原义务。
产品交付路由 -
扫描现有 Markdown 中的根指令入站链接。
_extract_markdown_link_targets -
记载单文件、祖先链容量和已跟踪范围。
Agent Instruction Loading And Maintenance
对主干的风险 / Risks
后端更新现有能力的设置语义,前端文件无差异,交付前需要判定是否只改后端。 相同后端产品任务下,基线明文要求检查现有设置和能力编辑器。 独立运行 23 项指令交付测试并通过。根文件从 23,962 B 降至 15,439 B,Workbench 已跟踪指令链从 28,950 B 降至 20,427 B。
新检查把正文中没有起始方括号的普通文本 ](AGENTS.md#unknown-heading) 当成链接,并漏报 CommonMark 渲染为相同 href 的 [Runbook](AGENTS.md#unknown-heading)。两条已在隔离跟踪文件中与项目现有 micromark 对照。只检查实际链接节点,并覆盖两条用例。
我的整体评价 / Verdict
请求修改精确提交 bd255e6。保留所有产品改动在实施前的交付指南触发,并明确要求先检查现有 Settings 和 Capability Center,再判断只涉及后端。为该动作、时序和场景增加删条款测试。
English verdict: REQUEST_CHANGES at bd255e6. Restore the pre-implementation inspection of existing settings for product changes and make the anchor guard distinguish rendered links from plain text.
Signed-off-by: Codex <codex@openai.com> Signed-off-by: song <liusongstep@gmail.com>
songoow
left a comment
There was a problem hiding this comment.
Reviewer: model_agent · GPT-6 Astra Pro · OpenAI · self_reported
Approval conclusion (author-owned PR; GitHub blocks formal self-approval)
动机 / Motivation
每次从仓库根目录或 Workbench 启动的开发代理,都会加载根指令和当前目录的补充指令。主干根文件是 23,962 字节,与 Workbench 合计 28,950 字节,比新门槛高 278 字节;前一版精简还遗漏了所有产品改动在实施前的设置检查。现在合计 20,582 字节,且每项产品改动仍须先读交付指南,认定只涉及后端前还须核查现有设置与能力编辑器。验收范围是指令能否被完整发现、路由能否到达目标、关键义务是否仍被写明。
改动思路 / Approach
根指令保留跨任务义务,把场景细节路由到既有交付指南。链接测试直接读取 CommonMark 解析器产生的链接,中文文件名和字符引用走正常的 Markdown 语义。四个变更文件分别承担根指令、开发索引、测试依赖和交付检查;解析库只进入 test extra。预算仍由实际受版本控制的文件字节和目录发现顺序计算。独立用临时 Git 仓库验证了链接识别,再从真实目录计算两层指令的字节数。
具体改动 / Changes
独立检出中,中文页面的引用链接及标题内含右括号的有效链接各解析出一个正确锚点;数字和命名 HTML 字符引用可还原为 AGENTS.md。仓库 27 项测试全部通过。主干与当前树的 Workbench 局部文件均为 4,988 字节,根文件降至 15,594 字节。两层总长度为 20,582,低于保留 4 KiB 后的 28,672 字节上限。在临时仓库中,裸露的非法目标文本和内联代码没有产生链接。另行删除“所有产品”、把“实施前”改为“实施后”、跳过编辑器检查,三种改动都被义务测试拒绝。
本次按 docs/development/frontend-delivery.md(e410b012e67a2fa75ff0056b16ab1362b931764d)核对 PRODUCT_INTAKE 的实现。其中比较的是仓库实际调用方所获得的结果,远端整套发布流水线单独记录。
对主干的风险 / Risks
测试衡量交付的文字和链接,不衡量代理实际遵从率。控制平面 executor.py:91 的 F401 在基线和当前检出中来自逐字节相同的源文件;该静态检查不能归因于这四个文件。远端本次 Python 测试仍在排队。在临时仓库中,裸露的非法目标文本和内联代码没有产生链接。另行删除“所有产品”、把“实施前”改为“实施后”、跳过编辑器检查,三种改动都被义务测试拒绝。抽查包含含有括号的标题、转义的字符和代码内的伪链接,结论限定于实际 Markdown 链接。
我的整体评价 / Verdict
没有发现当前提交引入的合并阻塞项。根指令保留跨任务义务,把场景细节路由到既有交付指南。链接测试直接读取 CommonMark 解析器产生的链接,中文文件名和字符引用走正常的 Markdown 语义。四个变更文件分别承担根指令、开发索引、测试依赖和交付检查;解析库只进入 test extra。预算仍由实际受版本控制的文件字节和目录发现顺序计算。
English verdict: APPROVE at 218c0b7. The instruction budget, all-product pre-implementation intake, and rendered-link checks are verified.
Goal And Delivered Outcome
docs/development/README.md#agent-instruction-loading-and-maintenanceandAGENTS.md).AGENTS.mdhad grown to 23,962 B / 399 lines (only 38 bytes under Antigravity's 24,000 B per-file cap), andAGENTS.md(23,962 B) +apps/workbench/AGENTS.md(4,988 B) consumed 28,950 B inside Codex's 32 KiB combined discovery budget, leaving < 4 KiB of headroom for host/user instructions. High-priority always-on invariants were also scattered across ~30 subsections with duplicate prose/routes, andtests/test_repository_instruction_delivery.pychecked only root per-file size and 3 hardcoded consumer anchors.AGENTS.md: 23,962 B / 399 lines → 15,594 B / 164 lines (-34.9% bytes, -58.9% lines, +8,368 B freed).AGENTS.md + apps/workbench/AGENTS.mdchain: 28,950 B → 20,582 B (12,186 B under Codex's 32 KiB cap; 8,090 B under the 28,672 B budget with 4 KiB host headroom).skills/loopx-self-repair/SKILL.mdpromoted from bare text to a verified local route (37 unique routes, 0 duplicates vs 2 previously).#author-submission-and-review-entry,#merge-authority-and-validation,#bounded-future-facing-refactoring,#first-screen-review-evidence) and verified across tracked Markdown and HTML blog references.tests/test_repository_instruction_delivery.py(27/27 passing, including CommonMark links with character references, unmatched brackets, and 12 numbering-independent clause-deletion / modality-inversion mutation tests).main(9e4730c13f6439b872152efe49954779c1b5cedc).Follow-up verification at
218c0b73bThe follow-up restores the pre-implementation Settings and Capability Center inspection for all product changes. Test-only Markdown link extraction now consumes CommonMark link tokens. The 27 instruction-delivery cases and the targeted lint check pass on this tree.
Author Declaration
codex reviewpasses.Implemented against
docs/development/README.md#agent-instruction-loading-and-maintenanceand baselineAGENTS.mdat9e4730c13f6439b872152efe49954779c1b5cedc.AGENTS.md/AGENTS.override.mdchainsAGENTS.md,docs/development/README.md,_check_instruction_budgetsintests/test_repository_instruction_delivery.pypytest -v tests/test_repository_instruction_delivery.pyAGENTS.md(## Precedence & Always-On Invariants,## Task-Triggered Owner Routing,## Pinned Root Contracts,## First-Screen Review Evidence)test_root_instruction_routes_resolve_to_existing_files_and_sections,test_root_instructions_retain_always_on_obligations,test_obligation_check_detects_clause_deletions_and_modality_inversionsAGENTS.mdacross Markdown and HTML blog consumersAGENTS.mdpinned headings,_find_broken_inbound_anchorsandtest_pinned_external_html_blog_anchor_resolvesintests/test_repository_instruction_delivery.pytest_existing_consumers_can_follow_root_instruction_anchors,test_all_repository_markdown_inbound_links_to_root_instructions_resolve,test_pinned_external_html_blog_anchor_resolves@AGENTS.mdimport inCLAUDE.mdwithout eager detail importsCLAUDE.md,AGENTS.mdtest_claude_imports_one_shared_policy_without_eager_detail_importsbd255e64ec267d70a61218e84cf3489f692b25f3rebased cleanly ontoorigin/main(9e4730c13f6439b872152efe49954779c1b5cedc). Ranruff check,pytest -v tests/test_repository_instruction_delivery.py(23/23), related suites (test_workflow_skill_install.py,scripts/ci/test_impact_plan.py,test_pr_review_github_scan.py),scripts/check_rfc_bilingual.py,loopx checkboundary scan, andgit diff --check. Also ran two independent localcodex reviewrounds and incorporated all P2/P3 findings. Did not run unrelated frontend/runtime suites since no runtime code changed.Scope And Continuation
AGENTS.md,docs/development/README.md, andtests/test_repository_instruction_delivery.py.AGENTS.mdinto one precedence + always-on invariants block plus a duplicate-free routing table, and upgradedtests/test_repository_instruction_delivery.pyfrom static root-size checks to tracked-inventory ancestor-chain budgets, CommonMark-aware inbound anchor verification, and clause-mutation property tests.Validation
bd255e64ec267d70a61218e84cf3489f692b25f3(related non-instruction suites also run on pre-rebase content-identical treea34bc14709e7dddef2b6517a431f12acf10158ba).finishedsynthetic,public_fixturestaticpassedruff check tests/test_repository_instruction_delivery.py— 0 issues onbd255e64ec267d70a61218e84cf3489f692b25f3.unitpassedpython -m pytest -v tests/test_repository_instruction_delivery.py— 23 passed in 1.10s onbd255e64ec267d70a61218e84cf3489f692b25f3(budgets, tracked-only override isolation, symlink checkout-location chain, CommonMark block/inline/reference/root-relative/non-ASCII anchor checks, 9 clause-deletion & modality-inversion mutation cases).regression_paritypassedpython -m pytest -q tests/test_workflow_skill_install.py scripts/ci/test_impact_plan.py tests/test_pr_review_github_scan.py— 139 passed, 2 skipped, 49 subtests passed ona34bc14709e7dddef2b6517a431f12acf10158ba.staticpassedpython scripts/check_rfc_bilingual.py --base origin/main --head HEAD,git diff --check origin/main...HEAD, andloopx check --scan-path AGENTS.md --scan-path docs/development/README.md --scan-path tests/test_repository_instruction_delivery.py— public boundary scan clean (3 files, errors=0) onbd255e64ec267d70a61218e84cf3489f692b25f3.OSErroron environments without symlink privileges while ordinary chain andAGENTS.override.mdchecks always run.Frontend / Visual Evidence
nonenoneType of Change
LoopX Area
Technical Direction
docs/development/README.md#agent-instruction-loading-and-maintenance).Shared-authority RFC fixture impact
N/A
Boundary Checklist
.loopx/,.codex/goals/, and liveACTIVE_GOAL_STATE.md).python3 scripts/check_rfc_bilingual.py --base origin/main --head HEADpasses, or no paired RFC changed.none.Signed-off-bytrailer (git commit -s).