chore(slides): update lark-slides skill to 0715 (rev59) bundle#1972
chore(slides): update lark-slides skill to 0715 (rev59) bundle#1972R0bynZhu wants to merge 8 commits into
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughThe PR tightens Lark Slides creation and visual-review workflows, expands XML linting for paragraph-aware overflow and occlusion detection, updates layout and schema references, and normalizes the chart demonstration XML. ChangesLark Slides workflow and validation
Estimated code review effort: 4 (Complex) | ~45 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 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 |
🚀 PR Preview Install Guide🧰 CLI updatenpm i -g https://pkg.pr.new/larksuite/cli/@larksuite/cli@21d73b239cce06cbe49beac294bfe974883e1034🧩 Skill updatenpx skills add larksuite/cli#update-lark-slides-skill-0715-v10 -y -g |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 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-slides/references/lark-slides-screenshot.md`:
- Line 30: Update the slide selector table row to state that at least one of
--slide-id or --slide-number must be provided and both cannot be omitted,
reflecting the CLI’s either-or validation; retain the existing successful
slide_id behavior and add the missing trailing table delimiter.
In `@skills/lark-slides/references/validation-checklist.md`:
- Line 169: Update the validation checklist entry to report
xml_text_overlap_lint.py results separately from manual content/layout checks.
Keep error_count=0 limited to the linter’s actual XML/schema, overlap, canvas,
text-overflow, table-size, and icon validations, and list title hierarchy and
visual focus as independently verified checks.
🪄 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: 2b3fb781-84ce-43b4-8015-6852fa07d926
📒 Files selected for processing (4)
skills/lark-slides/SKILL.mdskills/lark-slides/references/lark-slides-screenshot.mdskills/lark-slides/references/validation-checklist.mdskills/lark-slides/scripts/xml_text_overlap_lint.py
🚧 Files skipped from review as they are similar to previous changes (2)
- skills/lark-slides/SKILL.md
- skills/lark-slides/scripts/xml_text_overlap_lint.py
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1972 +/- ##
==========================================
+ Coverage 75.05% 75.07% +0.02%
==========================================
Files 901 901
Lines 95391 95560 +169
==========================================
+ Hits 71591 71739 +148
- Misses 18307 18319 +12
- Partials 5493 5502 +9 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
4b1d3f2 to
fa6106b
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
skills/lark-slides/scripts/xml_text_overlap_lint.py (1)
795-819: 🎯 Functional Correctness | 🔵 Trivial | 💤 Low valueMalformed paragraph spacing silently disables overflow detection for the whole shape.
If any paragraph's
lineSpacing/beforeLineSpacing/afterLineSpacingfails the(multiple|fixed):Nregex,line_countis reset to0and the loop breaks, so the entire element is skipped fromdetect_text_may_overflow_shapeswith no warning emitted — a silent false negative in the exact check meant to catch overflow. Consider emitting a diagnostic (e.g., a lower-severitytext_overflow_unknownissue) instead of dropping the element silently.🤖 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-slides/scripts/xml_text_overlap_lint.py` around lines 795 - 819, Update the paragraph-spacing failure path in detect_text_may_overflow_shapes so invalid lineSpacing, beforeLineSpacing, or afterLineSpacing values do not silently skip the element. Emit a lower-severity text_overflow_unknown diagnostic with the relevant element context, then preserve the existing behavior of stopping height estimation for that element.
🤖 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-slides/SKILL.md`:
- Line 230: Update the visual-review workflow in the slide skill documentation
to keep screenshot-access failures represented consistently: either record them
as not_reviewed or formally include not_verified in the review-state lifecycle
and completion gate. Ensure any not_verified state prevents claiming visual
review completion, alongside existing not_reviewed and fix states.
---
Nitpick comments:
In `@skills/lark-slides/scripts/xml_text_overlap_lint.py`:
- Around line 795-819: Update the paragraph-spacing failure path in
detect_text_may_overflow_shapes so invalid lineSpacing, beforeLineSpacing, or
afterLineSpacing values do not silently skip the element. Emit a lower-severity
text_overflow_unknown diagnostic with the relevant element context, then
preserve the existing behavior of stopping height estimation for that element.
🪄 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: e964708e-2dfe-4a4e-a443-4fb127ede3e1
📒 Files selected for processing (10)
skills/lark-slides/SKILL.mdskills/lark-slides/references/lark-slides-pptx-template-workflows.mdskills/lark-slides/references/lark-slides-screenshot.mdskills/lark-slides/references/planning-layer.mdskills/lark-slides/references/slides_chart_demo.xmlskills/lark-slides/references/troubleshooting.mdskills/lark-slides/references/validation-checklist.mdskills/lark-slides/references/visual-planning.mdskills/lark-slides/references/xml-schema-quick-ref.mdskills/lark-slides/scripts/xml_text_overlap_lint.py
💤 Files with no reviewable changes (1)
- skills/lark-slides/references/lark-slides-pptx-template-workflows.md
🚧 Files skipped from review as they are similar to previous changes (5)
- skills/lark-slides/references/xml-schema-quick-ref.md
- skills/lark-slides/references/planning-layer.md
- skills/lark-slides/references/troubleshooting.md
- skills/lark-slides/references/validation-checklist.md
- skills/lark-slides/references/slides_chart_demo.xml
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
skills/lark-slides/scripts/xml_text_overlap_lint.py (1)
175-188: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick winPrevent literal newlines from being incorrectly preserved as hard breaks.
When
preserve_line_breaks=Trueis used, literal newlines (\n) embedded in pretty-printed XML text nodes are currently kept and split into multiple lines. In standard XML rendering, literal newlines inside text nodes are treated as whitespace, and only<p>or<br>dictate layout breaks. Retaining them will cause artificially inflated line counts and false-positive vertical overflow warnings.Replace literal
\rand\nwith spaces before converting<br>tags to align with standard XML logic.🐛 Proposed fix
def strip_xml(value: str, preserve_line_breaks: bool = False) -> str: stripped = re.sub(r"<!\[CDATA\[([\s\S]*?)\]\]>", r"\1", value) if preserve_line_breaks: + stripped = re.sub(r"[\r\n]+", " ", stripped) stripped = re.sub(r"<br\b[^>]*>", "\n", stripped) stripped = re.sub(r"<[^>]+>", " ", stripped)🤖 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-slides/scripts/xml_text_overlap_lint.py` around lines 175 - 188, Update strip_xml to normalize literal carriage returns and newlines to spaces before the preserve_line_breaks branch converts <br> tags, so only explicit break tags produce line boundaries while existing whitespace collapsing remains unchanged.
🤖 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-slides/scripts/xml_text_overlap_lint_test.py`:
- Around line 639-659: Update should_flag_horizontal_text_overflow to skip text
shapes that use horizontal wrapping, allowing the vertical overflow heuristic to
handle them instead. In
test_lint_xml_detects_horizontal_text_overflow_across_declared_box_gap,
explicitly set the source shape’s wrap attribute to false so the fixture tests
horizontal overflow without triggering text_may_overflow_shape.
---
Outside diff comments:
In `@skills/lark-slides/scripts/xml_text_overlap_lint.py`:
- Around line 175-188: Update strip_xml to normalize literal carriage returns
and newlines to spaces before the preserve_line_breaks branch converts <br>
tags, so only explicit break tags produce line boundaries while existing
whitespace collapsing remains unchanged.
🪄 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: 940fa848-bcf3-4333-b3ff-eb494def3211
📒 Files selected for processing (2)
skills/lark-slides/scripts/xml_text_overlap_lint.pyskills/lark-slides/scripts/xml_text_overlap_lint_test.py
afd3229 to
e605fa6
Compare
…xt-shape-overflow-pr Update the overlap lint and its tests to the text-shape-overflow-pr versions.
e14c300 to
7c84557
Compare
) * feat: add layout density lint for sparse slide containers - add XML-based sparse container detection with coverage metrics - return structured, actionable lint JSON - document lint usage and visual-review workflow - add regression tests for density-lint behavior * feat: add layout density lint for sparse slide containers - add XML-based sparse container detection with coverage metrics - return structured, actionable lint JSON - document lint usage and visual-review workflow - add regression tests for density-lint behavior * feat(slides): detect sparse short cards and slide-level density * docs: resolve slide lint scripts from loaded skill directory
170057c to
21d73b2
Compare
Refresh
skills/lark-slidesto the 0715 (rev59) bundle and add a scenario-driven design-system layer. Docs/scripts only — no Go code changed.Summary
Update the lark-slides skill on top of the merged 0715 snapshot (#1933): refresh SKILL.md / references / scripts to rev59, introduce a scenario design system (
slides_categories+ 7 scenario docs) withdoubao-design.mdas the fallback, and refactor SKILL.md so design opinions live in the design-system layer instead of as global hard constraints.Changes
references/slides_categories.md(scenario index/router) + 7 scenario docs —analysis-decision,business-plan,management-report,academic-research,education-training,tech-engineering,brand-creative. Planning now picks one primary scenario first and follows its doc.references/doubao-design.md; the former inline “豆包设计原则” becomes the fallback used only when no scenario matches.## 设计系统pointer;## 权威经验slimmed to pure technical constraints (design opinions — cards / fonts / image density / cover visual — moved into the design-system docs); scenario-selection added as the first planning step in### 生成流程(recorded intoslide_plan.json).scripts/xml_layout_density_lint.py(+ tests) for paragraph-aware overflow / out-of-canvas / image-text occlusion checks; minor update toxml_text_overlap_lint.py.slides_chart_demo.xml,lark-slides-screenshot.md,validation-checklist.md,troubleshooting.md,xml-schema-quick-ref.md,planning-layer.md,lark-slides-pptx-template-workflows.md.