Skip to content

docs(base): clarify complete and partial updates - #1993

Merged
zhouyue-bytedance merged 3 commits into
larksuite:mainfrom
huarenmin13:agent/base-update-contract-boundary
Jul 23, 2026
Merged

docs(base): clarify complete and partial updates#1993
zhouyue-bytedance merged 3 commits into
larksuite:mainfrom
huarenmin13:agent/base-update-contract-boundary

Conversation

@huarenmin13

@huarenmin13 huarenmin13 commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Summary

Clarify the command-contract boundary for Base updates. This is a focused follow-up to #1879: full-update commands must start from trusted current configuration, while true partial/delta commands should use the smallest legal payload.

Changes

  • Replace the obsolete schema-routing statement with a command-aware update boundary.
  • Require the first actual request to a full-update command to be derived from trusted complete configuration; reuse it when already available, otherwise read first.
  • Separate valid delta updates from fail-first partial probes for full-update commands, and consolidate the shorter rule introduced in docs(base): reduce filter and update retry loops #1879.

Test Plan

  • node scripts/skill-format-check/index.js
  • go test ./internal/qualitygate/skillscan/...
  • make unit-test
  • go vet ./...
  • gofmt -l . (no output)
  • go mod tidy (no changes)
  • go run github.com/golangci/golangci-lint/v2/cmd/golangci-lint@v2.1.6 run --new-from-rev=origin/main (0 issues)
  • git diff --check

Related Issues

Summary by CodeRabbit

  • Documentation
    • 更新了“使用边界/写入前置规则”,执行更新前需先查对应快捷命令的 --help/参考文档。
    • 若命令要求完整配置:首次更新必须基于可信的当前配置执行读-改-写,仅变更用户明确指定内容,并保留其他仍适用的可写配置。
    • 若支持局部/增量:提交最小合法 payload。
    • 禁止通过“不完整请求试错补参”来完成更新;并调整了原有前置规则表述衔接方式。

Consolidate the update rule introduced in larksuite#1879 and make the command-contract boundary explicit. Full-update commands must use trusted current configuration for the first actual request, while delta commands should send the smallest legal payload.
@coderabbitai

coderabbitai Bot commented Jul 21, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 30b62bb5-804b-4031-b5b9-434674bbbd77

📥 Commits

Reviewing files that changed from the base of the PR and between f0f27ac and 9fcd621.

📒 Files selected for processing (1)
  • skills/lark-base/SKILL.md

📝 Walkthrough

Walkthrough

更新 lark-base 技能文档中的 update 操作约束,明确契约查阅、read-modify-write、最小合法 payload 和写入前置规则。

Changes

Lark Base update guidance

Layer / File(s) Summary
Update contract rules
skills/lark-base/SKILL.md
新增 update 执行前的命令契约查阅及配置提交要求,并移除“写入前置规则”中的重复旧说明。

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

  • larksuite/cli#1937:同样调整 skills/lark-base/SKILL.md 中字段更新的 read-modify-write 契约。
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly reflects the main documentation change about complete and partial update behavior.
Description check ✅ Passed The description follows the template with Summary, Changes, Test Plan, and Related Issues, and it covers the main scope.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added domain/base PR touches the base domain size/M Single-domain feat or fix with limited business impact labels Jul 21, 2026
@huarenmin13

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 21, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@skills/lark-base/SKILL.md`:
- Line 32: 更新该 SKILL.md 中关于完整配置更新的说明:对于要求完整配置的更新(尤其是 PUT
风格字段更新),必须保留当前配置中的全部可写属性,仅修改用户明确指定的字段;首次请求应基于可信的当前配置执行
read-modify-write,并继续遵循命令要求的 payload 结构。
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: fa604b63-c7cd-479d-91b0-d8df677dc12e

📥 Commits

Reviewing files that changed from the base of the PR and between 483aade and f0f27ac.

📒 Files selected for processing (1)
  • skills/lark-base/SKILL.md

Comment thread skills/lark-base/SKILL.md Outdated
Address review feedback by requiring unchanged writable configuration to remain intact, except when the requested update makes a setting inapplicable.
@huarenmin13
huarenmin13 force-pushed the agent/base-update-contract-boundary branch from 47b4e30 to 215c199 Compare July 22, 2026 00:44
@huarenmin13
huarenmin13 marked this pull request as ready for review July 22, 2026 03:08
@github-actions

Copy link
Copy Markdown

🚀 PR Preview Install Guide

🧰 CLI update

npm i -g https://pkg.pr.new/larksuite/cli/@larksuite/cli@9fcd6218b2c7de67fae88c075d10c24e62d2ac2a

🧩 Skill update

npx skills add huarenmin13/cli#agent/base-update-contract-boundary -y -g

@zhouyue-bytedance
zhouyue-bytedance merged commit f0176af into larksuite:main Jul 23, 2026
23 of 37 checks passed
kiraWangRuilong pushed a commit that referenced this pull request Jul 24, 2026
* docs(base): clarify complete and partial updates

Consolidate the update rule introduced in #1879 and make the command-contract boundary explicit. Full-update commands must use trusted current configuration for the first actual request, while delta commands should send the smallest legal payload.

* docs(base): clarify full-update state preservation

Address review feedback by requiring unchanged writable configuration to remain intact, except when the requested update makes a setting inapplicable.

* docs(base): strengthen update contract guidance
@liangshuo-1 liangshuo-1 mentioned this pull request Jul 24, 2026
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

domain/base PR touches the base domain size/M Single-domain feat or fix with limited business impact

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants