AgentSkillsCN

new-ability-low

搭建一项低层次能力(以脚本为支撑)。关键词:能力、低层次、脚本、脚手架搭建。

SKILL.md
--- frontmatter
name: new-ability-low
description: "Scaffold a low-level ability (script-backed). Keywords: ability, low-level, script, scaffolding."

Scaffold: New Low-Level Ability

This document is an entrypoint for low-level ability scaffolding. The step-by-step flow is in /.system/skills/ssot/repo/scaffolding/new-ability-low/SKILL.md.


1. Purpose & Scope

Purpose: Register a new low-level ability in the ability registry and update relevant ABILITY.md index files.

Scope:

  • Creates ability registration in /.system/registry/low-level/
  • Regenerates ABILITY.md indexes for specified entrypoints
  • Validates implementation references

Out of scope:

  • Implementing the actual script/API/MCP handler
  • High-level workflow/agent abilities
  • Hook bindings (added separately)

2. Inputs & Preconditions

Required Inputs

ParameterTypeDescription
operation_keystringUnique operation identifier (e.g., skills.sync_wrappers)
summarystringOne-line description of what this ability does
kindenumImplementation type: script, api, mcp
entrypointsarrayABILITY catalog roots where ability appears (e.g., /modules/integration)

Conditional Inputs (based on kind)

The implementation sub-object contains kind-specific fields:

ParameterConditionDescription
implementation.scriptkind=scriptPath to script (repo-root absolute, e.g., /scripts/my_op.py)
implementation.commandkind=scriptShell command template (alternative to script)
implementation.api_endpointkind=apiAPI endpoint URL or reference
implementation.mcp_toolkind=mcpMCP tool name

Note: For kind=script, either implementation.script or implementation.command is required.

Optional Inputs

ParameterTypeDefaultDescription
parametersobject{}JSON Schema for input parameters
tagsarray[]Classification tags

Preconditions

  1. Phase 4 registry tooling is available (scripts/devops/registry/abilities.py)
  2. operation_key does not already exist in ability registries
  3. Specified entrypoints have valid ABILITY.md files with marker blocks
  4. Implementation reference (script/api/mcp) is valid or will be created

3. Step-by-Step Flow (AI + Human)

See /.system/skills/ssot/repo/scaffolding/new-ability-low/SKILL.md.


4. Tools & Scripts

ToolPurpose
scripts/devops/scaffold/new_ability_low.pyOrchestrator script
scripts/devops/registry/abilities.pyRegistry validation and index regeneration
scripts/devops/registry/common.pyShared utilities

5. Outputs & Side Effects

Files Created/Modified

code
/.system/registry/low-level/<operation_key>.yaml   # New registry entry
<entrypoint>/ABILITY.md                            # Index block regenerated

Registry Entry Structure

yaml
operation_key: skills.sync_wrappers
summary: Regenerate provider skill wrappers from SSOT
kind: script
entrypoints:
  - /modules/integration
implementation:
  script: /scripts/devops/skills/sync_skills.py
  command: python scripts/devops/skills/sync_skills.py --regenerate --target integration --publish-set integration_default
parameters:
  type: object
  properties:
    regenerate:
      type: boolean
      description: Whether to regenerate wrappers

Note: The implementation sub-object contains kind-specific fields. For kind=script, at least one of script or command is required.


6. Safety & Rollback

Safety Measures

  • --dry-run always available for preview
  • Human approval required before execution
  • Schema validation on registry entry
  • Consistency checks via abilities.py --check

Rollback Procedure

If registration fails or needs reverting:

  1. Delete the registry entry:
    bash
    rm /.system/registry/low-level/<operation_key>.yaml
    
  2. Regenerate ABILITY.md indexes:
    bash
    python scripts/devops/registry/abilities.py --scope integration --regenerate
    

7. Related Documents

  • /.system/skills/ssot/repo/architecture-core-mechanisms/ability-workflow/SKILL.md - Ability development workflow
  • /.system/registry/schemas/ability_low.schema.yaml - Low-level ability schema
  • /.system/registry/schemas/V1_CORE.md - V1-core required fields