跳到正文
cccskills
免费在 GitHub 公开

blockly-best-practices

Implement or modify Blockly/ABS programs using the project’s current board and installed libraries. Check only relevant library evidence, edit the canonical ABS source, sync it to the workspace, and run focused validation when needed.

中文简介正在准备中。当前显示英语简介。

原文查看原文说明

Aily Blockly implementation workflow for scoped library evidence, ABS editing, workspace synchronization, and focused validation. Use for creating or modifying Blockly/ABS programs.

ailyProject/aily-blockly星标 3,860(GitHub 3,860 + cccskills 0)

实测评分 未实测

查看安装方法

适用场景

  • Adding a feature to an existing Blockly program
  • Editing ABS source and syncing the workspace
  • Checking a focused build or syntax issue

包含的文件(1)

  • SKILL.md3.8 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Blockly Implementation Workflow

Use this skill only for implementing or modifying a Blockly/ABS program. Project selection and creation belong to the blockly-project-planning skill.

1. Start from runtime facts

  • Treat the injected project path, current board, installed library list, readme_ai.md references, and project.abs path as current runtime facts.
  • Do not call tools merely to rediscover those facts.
  • Treat project.abs as the canonical editable Blockly source. Generated .ino/C++ is derived output used for diagnostics, not the normal edit target.

2. Gather only task-relevant evidence

  • Identify the smallest set of libraries needed for the current feature. Do not inspect every installed library or add lib-core-* packages speculatively.
  • For each relevant installed library, call analyzeLibrary with mode="auto" first.
  • When it returns a readme_ai.md reference, read that file. The README is usually sufficient, but it is not an absolute stopping point.
  • If the README is missing, incomplete, contradictory, or does not answer the current question, escalate narrowly:
    1. inspect the relevant block.json for block types, fields, inputs, and args0 order;
    2. inspect generator.js only when generated-code semantics remain unclear;
    3. inspect the minimum native source needed only when underlying library behavior remains unresolved.
  • Stop reading once the evidence answers the current implementation question.

3. Resolve board facts through the board capability source

  • Use get_board_parameters for GPIO, ADC, PWM, UART, I2C, SPI, builtin LEDs, and other board defaults. Its board.json result is authoritative.
  • Pinmap data describes schematic terminals and connection geometry. Do not use it as the source of MCU capability or default-pin facts.
  • Use schematic/pinmap capabilities only when the request actually requires wiring or a connection diagram.

4. Edit the canonical ABS source

  1. Read project.abs directly. The host synchronizes the visible Blockly workspace to this file before a submitted turn.
  2. Use syncAbs action="export" only if the workspace may have changed after the turn began or a status check shows drift.
  3. Make the smallest coherent ABS edit. Preserve unrelated blocks and structure.
  4. Use syncAbs action="import" to apply the updated ABS to the visible workspace.
  5. Treat parse warnings, failed blocks, degraded text expressions, or partial imports as failed validation and repair them before continuing.

Load abs-syntax-reference when block argument order, statement inputs, nested value blocks, or other non-trivial ABS grammar is involved. Do not guess positional arguments; verify them from the selected library evidence.

5. Validate immediately

  • Check the imported workspace/ABS structure after a non-trivial change.
  • Run lint for generated-code syntax validation when appropriate.
  • Run buildProject when the task requires a compile result.
  • If validation fails, use the nearest error and the smallest relevant source as the next evidence anchor. Do not restart broad project exploration.

Completion criteria

  • The visible workspace reflects the intended ABS structure.
  • No ABS import warning or failed block remains.
  • Requested focused validation passes, or the remaining blocker is reported precisely.
  • Do not claim completion from compiler success alone when the Blockly import was partial or structurally degraded.

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Use this reference to write Aily Block Syntax (ABS), a text format for Blockly scripts. It explains block connections, parameter order, statement inputs, values, and variable references, with examples for conditions, loops, and Arduino program structure.

中文简介正在准备中。当前显示英语简介。

  • Check the correct order of block parameters
  • Write conditions and loops in ABS
  • Look up value and variable syntax for Blockly scripts
ailyProject/aily-blockly38602026年10月26日 更新

Plan a new Blockly hardware project by discovering suitable board and library packages, then comparing viable combinations. Each plan outlines wiring assumptions, workspace structure, implementation steps, and validation before the user confirms project creation.

中文简介正在准备中。当前显示英语简介。

  • Comparing boards for a new Blockly project
  • Planning libraries for a sensor or actuator
  • Reviewing wiring and validation assumptions
ailyProject/aily-blockly38602026年10月26日 更新

chronicle

免费

Search indexed chat history to find earlier decisions, tool activity, project summaries, files, and workflow tips. It can also rebuild the local history index when requested or when search results appear out of date.

中文简介正在准备中。当前显示英语简介。

  • Find a decision made in an earlier conversation
  • Check which tools were used for past work
  • Summarize recent project sessions
ailyProject/aily-blockly38602026年10月26日 更新

handoff

免费

Create a concise handoff document in the operating system’s temporary directory so another agent can continue the work. It summarizes the conversation, suggests relevant skills, references existing artifacts, and redacts sensitive information.

中文简介正在准备中。当前显示英语简介。

  • Hand ongoing work to another agent
  • Prepare context for a fresh session
  • Summarize progress without duplicating project artifacts
ailyProject/aily-blockly38602026年10月26日 更新

improve

免费

Survey a codebase and turn verified improvement opportunities into prioritized, self-contained implementation plans for another agent. It can assess bugs, security, performance, tests, technical debt, migrations, tooling, and product direction while keeping source code read-only.

中文简介正在准备中。当前显示英语简介。

  • Audit a codebase for high impact issues
  • Plan fixes for security or performance findings
  • Create a grounded roadmap for another agent
ailyProject/aily-blockly38602026年10月26日 更新

Follow a workflow for converting Arduino and ESP32 libraries into Aily Blockly libraries. The guide covers analyzing public APIs, defining blocks, generating code, configuring toolboxes, initializing Serial, I2C, and SPI, adapting boards, and packaging the result.

中文简介正在准备中。当前显示英语简介。

  • Convert an Arduino library for Aily Blockly
  • Design block definitions and generated code
  • Adapt a library to supported development boards
ailyProject/aily-blockly38602026年10月26日 更新

查看 ailyProject 的全部技能

报告此技能的问题