feat(base): clarify dashboard multi-block read pattern and arrange constraints - #2117
Conversation
…nstraints - SKILL.md: update routing table to say "一个或多个图表计算结果" for +dashboard-block-get-data; add three new Dashboard guidance bullets covering arrange precision limits, creation verification shortcut, and multi-block serial read pattern - lark-base-dashboard-block-get-data.md: add multi-block serial loop example with safety note that IDs must come verbatim from +dashboard-block-list - lark-base-dashboard.md: tighten arrange caution block (x/y/w/h wording, two new caution bullets); fix verification guideline to not call +dashboard-block-get-data just to confirm creation; add multi-block read hint after scenario 5
📝 WalkthroughWalkthroughDashboard skill and reference documentation now define layout constraints, creation verification semantics, routing guidance, and single-call retrieval of multiple component computation results. ChangesDashboard guidance
Estimated code review effort: 1 (Trivial) | ~5 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
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/references/lark-base-dashboard-block-get-data.md`:
- Around line 76-82: Add strict Bash error handling before the block_ids loop in
the dashboard block retrieval example by enabling set -euo pipefail, so any
failed +dashboard-block-get-data invocation stops the batch and preserves the
failure status.
🪄 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 Plus
Run ID: b01e6c29-781f-4b68-ab71-fec45f31d2ee
📒 Files selected for processing (3)
skills/lark-base/SKILL.mdskills/lark-base/references/lark-base-dashboard-block-get-data.mdskills/lark-base/references/lark-base-dashboard.md
| ```bash | ||
| block_ids=(cht_block_1 cht_block_2) | ||
| for block_id in "${block_ids[@]}"; do | ||
| lark-cli base +dashboard-block-get-data \ | ||
| --base-token bascn***************CtadY \ | ||
| --block-id "$block_id" | ||
| done |
There was a problem hiding this comment.
🩺 Stability & Availability | 🟠 Major | ⚡ Quick win
Do not mask failed component reads.
Without set -e or explicit status handling, the loop continues after a failed +dashboard-block-get-data call and returns the status of the final iteration. A later success can therefore make the whole batch appear successful despite missing results.
Proposed fix
```bash
+set -euo pipefail
block_ids=(cht_block_1 cht_block_2)
for block_id in "${block_ids[@]}"; do📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| ```bash | |
| block_ids=(cht_block_1 cht_block_2) | |
| for block_id in "${block_ids[@]}"; do | |
| lark-cli base +dashboard-block-get-data \ | |
| --base-token bascn***************CtadY \ | |
| --block-id "$block_id" | |
| done |
🤖 Prompt for 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.
In `@skills/lark-base/references/lark-base-dashboard-block-get-data.md` around
lines 76 - 82, Add strict Bash error handling before the block_ids loop in the
dashboard block retrieval example by enabling set -euo pipefail, so any failed
+dashboard-block-get-data invocation stops the batch and preserves the failure
status.
🚀 PR Preview Install Guide🧰 CLI updatenpm i -g https://pkg.pr.new/larksuite/cli/@larksuite/cli@799fa8c0249768b60020ae397da74d3e553acb15🧩 Skill updatenpx skills add yballul-bytedance/cli#auto-research-sync/01KYP0J73XH4GFGPXDPTZV1BGG/mr-1293-80299c24 -y -g |
Summary
Improves the
lark-baseskill documentation for the Dashboard module based on Auto Research evaluation findings. The changes address three recurring agent failure patterns: (1) agents calling+dashboard-block-get-dataon each block in a separate model turn instead of batching, (2) agents silently using+dashboard-arrangewhen users request precise layout positioning, and (3) agents redundantly calling+dashboard-block-get-datajust to confirm a successful creation.Changes
skills/lark-base/SKILL.md: Updated the routing table entry for+dashboard-block-get-datato say "一个或多个图表计算结果"; added three new Dashboard guidance bullets to the## Dashboard / Workflow / Rolesection covering: arrange precision limitations and confirmation requirement, creation-success verification shortcut, and the multi-block serial read pattern.skills/lark-base/references/lark-base-dashboard-block-get-data.md: Added a multi-block serial loop example (bashforloop) immediately after the single-block usage example, with a security note that block IDs must come verbatim from+dashboard-block-listoutput.skills/lark-base/references/lark-base-dashboard.md: Tightened the+dashboard-arrangecaution block to usex/y/w/hwording and added two new caution bullets (user-confirmation requirement for precise layout, stop-after-one-call rule); updated the verification guideline to clarify creation success does not require a follow-up+dashboard-block-get-datacall; added a multi-block read hint after Scenario 5.Test Plan
git diff --checkpassed with exit code 0 (no whitespace errors).Related Issues
Auto research task: 01KYP0J73XH4GFGPXDPTZV1BGG
Summary by CodeRabbit