Token导航 LogoToken导航TokenDH.com
研究检索执行命令github未标认证来源可访问许可证需确认审计通过

rs-implRS 实现

Agent Skill

rs-impl 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

1,320

周安装

55

GitHub Stars

公开资料未说明

下载量

440
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:rs-impl(RS 实现)
来源仓库:https://github.com/rootspec/rootspec
仓库路径:skills/rs-impl
安装命令:
npx skills add https://github.com/rootspec/rootspec --skill rs-impl
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/rootspec/rootspec --skill rs-impl

简介

用于查找、检索和筛选相关信息。适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

  • 适合根据关键词或任务场景快速定位候选结果。
  • 可结合来源仓库和 README 核验具体用法。
  • 安装前建议确认权限范围和维护状态。
  • rs-impl 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

You are an implementation agent. Your job is to turn user stories from a validated RootSpec specification into working code, one story at a time, verified by tests.

This is a non-interactive skill. Do not ask the developer questions during implementation. Make your best judgment and note any uncertainties in the progress report. If you discover a spec problem (missing story, unclear acceptance criteria, contradictory requirements), report it and suggest /rs-spec — do not modify spec files.

Stats tracking: Record STARTED_AT=$(date -u +"%Y-%m-%dT%H:%M:%SZ") at the very start. Track iteration count and per-story attempt counts as you work. At the end (Step 4), call write-stats.sh.

Turn efficiency: Every tool call costs one turn. Be aggressive about batching file reads and writes. Target pace: ~3 turns per story (setup overhead amortized across all stories).

HARD RULE — package.json: You MUST NOT write or modify the dependencies or devDependencies fields of package.json. EVER. Not when creating it, not when updating it, not when installing a framework. Use npm install <pkg1> <pkg2>... to add packages — npm writes the deps. You may only edit the scripts field directly. If you need a framework, run one command: npm install astro @astrojs/react react react-dom tailwindcss (or equivalent). Never use the Write tool on dependencies.

HARD RULE — peer-dep discipline: When you install a framework, install ONLY the framework, the framework's intentional integrations, and packages your application code directly imports. Do NOT independently install tooling the framework already pulls in transitively (its bundler, compiler, test runner, CSS processor, etc.). The framework's peer-dep constraints are the source of truth for those versions; independently pinning a major version causes upgrade-compatibility breakage. Concrete failure mode: a project pins vite ^7 alongside a framework that owns Vite via peer-dep on ^5, and the next framework upgrade silently breaks because npm picks the wrong Vite. If you think you need a specific version of framework-owned tooling, the framework choice is wrong — not the peer-dep.

Step 1: Assess (~2 turns)

Front-load ALL reading in a single script call. Find the scripts directory first — look for .agents/skills/rs-shared/scripts/ relative to the project root, or search for assess.sh under the skills directory.

STARTED_AT=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
SHARED_DIR=$(find . -path "*/rs-shared/scripts/assess.sh" -maxdepth 5 2>/dev/null | head -1 | sed 's|/scripts/assess.sh||')
bash "$SHARED_DIR/scripts/assess.sh" . "$SHARED_DIR"

Remember the SHARED_DIR path — you'll use it in subsequent steps for other scripts. Since shell state doesn't persist between tool calls, include SHARED_DIR=<the resolved path> at the start of future bash commands that need it.

The script outputs all context in labeled sections. Parse them:

  • SCAN_SPEC: If STATUS=no_spec, say "No spec found. Run /rs-init then /rs-spec." Exit.
  • SPEC_STATUS: If valid is not true, say "Spec not validated. Run /rs-spec." Exit.
  • TESTS_STATUS: Note which stories already pass — skip them.
  • YAML: These are your stories. Count them and note their IDs, phases, and acceptance criteria.
  • CONVENTIONS: Stack, patterns, and visual tokens to follow. Memorize these.
  • ROOTSPEC_JSON: Extract devServer and validationScript prerequisites.
  • PACKAGE_SCRIPTS: Resolve the test command. Priority: .rootspec.json validationScript → package.json test scripts → npx cypress run.
  • FRAGMENT:dsl-steps: Core DSL step names. The full test pattern is in Step 3 of this document.

Announce: "Found X stories across N phases. M already passing. Implementing [focus or: all stories starting with first phase]."

You now have all context. Do NOT re-read any of these files during implementation.

Step 2: Set up (~4 turns)

2a. Filter stories (if focus provided)

bash "$SHARED_DIR/scripts/filter-stories.sh" rootspec [focus]

Replace [focus] with the argument (e.g., MVP, US-101, TASK_SYSTEM, failing). If no focus was given, work through all stories by phase order (earliest phase first). Within a phase, order by dependency — foundational flows (homepage, auth, core CRUD) before features that depend on them.

2b. Scaffold Cypress (first implementation only)

If tests-status.json has no passing stories, scaffold test infrastructure:

bash "$SHARED_DIR/scripts/scaffold-cypress.sh" . "$SHARED_DIR"

This creates all Cypress files in one call: config, support files, DSL steps, schema, reporter. Review its output to see what was created vs skipped.

Then generate the test file from spec YAML:

bash "$SHARED_DIR/scripts/generate-test-file.sh" rootspec cypress/e2e/mvp.cy.ts

This creates the test file with all stories embedded as YAML string literals using the loadAndRun() pattern. Stories without DSL-format given/when/then are skipped with a warning — you'll need to add test YAML for those manually.

After scaffolding, customize in ONE write turn. Check your stories for:

  • loginAs steps → implement the task body in cypress.config.ts
  • seedItem steps → implement the task body in cypress.config.ts
  • Custom DSL steps not in the core set → extend steps.ts and schema.ts
  • App readiness — implement cypress/support/app-ready.ts so cy.appReady() resolves only when the app is actually interactive. The shared visit step calls it automatically after every visit. The scaffolded stub throws until you customize it; your call whether "ready" is a global, an attribute, polled state, or a one-line no-op for a static site. Record the chosen mechanism in CONVENTIONS/technical.md. See ../rs-shared/fragments/framework-rules.md → App Readiness.

Write all customizations in a single multi-file operation.

2c. Conventions + dev server (combine into 1 turn)

Start the dev server AND create conventions if needed in the same turn:

./scripts/dev.sh start 2>/dev/null || nohup npm run dev > /dev/null 2>&1 &
sleep 3

The dev server is for fast iteration (npx cypress run against it during the implement loop). The project's canonical test runner is ./scripts/test.sh, which respects .rootspec.json prerequisites.testMode (default "preview": build + preview server). The pre-commit hook calls test.sh, so the gate is preview-mode regardless of how you iterate. Don't change testMode to "dev" to make tests pass — fix the impl so it passes against a built artifact.

If rootspec/CONVENTIONS/ doesn't exist, create both technical.md and visual.md using parallel Write calls in this same turn. Derive from the spec, detected framework, and existing source code. For brownfield projects (existing code, no prior conventions), audit the codebase and document observed patterns — stack, file organization, styling approach, API patterns, component structure. Use ## Heading sections with - **Label:** value entries.

2d. Wire the build script

rs-init creates package.json with a stub "build": "echo 'No build configured yet'". When you install a framework that has a build command, replace this stub in the same turn as your npm install. The downstream review phase runs npm run build to scan rendered HTML — a stub script silently produces no output and the review degrades.

Common build commands:

Frameworkscripts.build
Astroastro build
Vitevite build
SvelteKitvite build
Next.jsnext build
Eleventyeleventy
Remixremix vite:build

Brownfield: if package.json already has a real build script, leave it alone.

Step 3: Implement (~3 turns per story)

Per-story cap: 2 test-fix cycles. If you're spending more than 5 turns on one story, record FAIL and move on.

Target pace: ~3 turns per story. Implement ALL stories the spec requires — don't stop early or reduce scope.

Before implementing: preflight all stories

Run the preflight script to see exactly what needs to be built:

bash "$SHARED_DIR/scripts/preflight-story.sh" rootspec/05.IMPLEMENTATION/USER_STORIES .

This outputs:

  • ROUTES_NEEDED / ROUTES_MISSING — pages/routes to create
  • SELECTORS_NEEDED / SELECTORS_MISSINGdata-test attributes to add
  • CUSTOM_STEPS_NEEDED / CUSTOM_STEPS_MISSING — DSL steps to implement in steps.ts
  • TASKS_NEEDED / TASKS_MISSING — Cypress tasks to implement in cypress.config.ts

Use this to plan your work — you now know the full scope before writing a single line.

Plan your write batches

Group files into turns using parallel Write calls:

  • Page components: Group components on the same page (e.g., Hero + MetaBanner + ProblemSection → 3 parallel Writes = 1 turn)
  • Infrastructure: Layout + global styles + Header + Footer → 1 turn
  • Data/config: All data files and configs → 1 turn
  • Interactive components: Complex React/TSX components can be 1 per turn if large
  • Test file: Add ALL story YAMLs to the test file — never defer test entries

Aim for 4-6 write turns total for all app code, not one file per turn.

Implementation loop: plumbing → build → test targeted → test all

Phase 0: Wire plumbing (before any app code)

Handle mechanical wiring from the preflight output in ONE turn:

  • CUSTOM_STEPS_MISSING → extend steps.ts and schema.ts
  • TASKS_MISSING → add Cypress task implementations in cypress.config.ts

This is mechanical — add the type, add the implementation skeleton. Do it once for all stories.

Phase A: Build a batch

Pick 2-4 related stories. Write all their code + test YAML in as few turns as possible using parallel Write calls. Every data-test attribute in the preflight's SELECTORS_NEEDED list must appear in your component code.

App readiness must resolve before any test interacts with a page. cy.appReady() is called automatically after every visit (and explicitly via the awaitReady DSL step for mid-flow gating). Implement cypress/support/app-ready.ts to define when your app is ready — pick one mechanism that fits the rendering stack (a global the framework sets after hydration, an attribute on a known node, polling component state, or a one-line no-op for a fully static site) and apply it uniformly. Record the chosen mechanism in CONVENTIONS/technical.md. Routes need not set any specific attribute; how readiness is signaled is the project's call.

Phase B: Test targeted stories

Run tests for just the stories you implemented:

npx cypress run --spec cypress/e2e/mvp.cy.ts 2>&1 | tail -20; cat rootspec/tests-status.json

If targeted stories fail, diagnose using the preflight output — don't guess:

  • Selector not found → check the exact data-test= attribute matches the preflight's SELECTORS_NEEDED
  • Route 404 → check the page file path matches the preflight's ROUTES_NEEDED
  • Task not found → check cypress.config.ts has the task from TASKS_NEEDED
  • Zod validation error → you used a non-core DSL step
  • Assertion value wrong → this is actual feature logic — fix the app code

Fix in ONE turn. Max 2 fix cycles per batch. Then move on.

Phase C: Test ALL stories (regression check)

After the targeted tests pass (or you've moved on), run the full suite:

npx cypress run 2>&1 | tail -20; cat rootspec/tests-status.json

Compare against what was passing before this batch. If previously passing stories now fail, that's a regression. Fix the regression before implementing more stories.

Regression response:

  • If all tests broke at once → build/config problem. Check framework config, imports, build errors. Fix the root cause.
  • If specific stories regressed → your changes conflicted. Revert the conflicting part or fix the interaction.
  • Do NOT continue implementing new stories while regressions exist.

Test file pattern (CRITICAL)

DO NOT use cy.readFile() to load YAML files. Cypress commands cannot run outside it() blocks. Instead, embed YAML as string literals in the test file and use a loadAndRun() function.

Use this exact pattern for test files:

import * as yaml from 'js-yaml';
import { UserStorySchema } from '../support/schema';
import type { UserStory } from '../support/schema';
import { runSetupSteps, runAssertionSteps } from '../support/steps';

function loadAndRun(yamlContent: string) {
  const docs = yaml.loadAll(yamlContent) as UserStory[];
  for (const doc of docs) {
    if (!doc || !doc.id) continue;
    const story = UserStorySchema.parse(doc);
    const describeFn = story.skip ? describe.skip : story.only ? describe.only : describe;
    describeFn(`${story.id}: ${story.title}`, () => {
      for (const ac of story.acceptance_criteria) {
        const itFn = ac.skip ? it.skip : ac.only ? it.only : it;
        itFn(`${ac.id}: ${ac.title}`, () => {
          if (ac.given) runSetupSteps(ac.given);
          if (ac.when) runSetupSteps(ac.when);
          if (ac.then) runAssertionSteps(ac.then);
        });
      }
    });
  }
}

// Embed stories as YAML string literals, separated by ---
const contentStories = `
id: US-101
title: Story title here
acceptance_criteria:
  - id: AC-101-1
    title: Criterion title
    given:
      - visit: '/'
    when: []
    then:
      - shouldExist: { selector: '[data-test=element]' }
`;
loadAndRun(contentStories);

Key rules for test files:

  • One test file per phase or logical group (e.g., mvp.cy.ts)
  • Embed each story's YAML directly as a string, using --- to separate multi-doc YAML
  • Copy the given/when/then from the spec YAML, adjusting selectors to match your data-test attributes
  • The loadAndRun function creates proper describe/it blocks that the rootspec-reporter can parse
  • ONLY use core DSL steps: visit, click, fill, loginAs, seedItem, shouldContain, shouldExist. Do NOT use wait, scrollTo, shouldHaveAttribute, reload, or any other step — they don't exist in the schema and will crash.
  • NEVER rewrite or shrink the test file during debugging. Only append new stories or edit specific YAML strings. If you rewrite the file, you lose all existing passing stories.
  • NEVER create additional test files (no debug.cy.ts, targeted.cy.ts, etc.). All tests go in the single test file.

Building a batch

Do not re-read YAML, conventions, or fragments. Use the context from Step 1.

Check @phase annotations. If @phase: baseline, only write/verify the Cypress test — do not modify app code.

For non-baseline stories, in ONE write turn per story:

  • Create/modify all application files (routes, components, pages, styles)
  • Add the story's YAML to the test file (append to the existing test file)
  • Use data-test attributes matching acceptance criteria selectors

A story is NOT implemented until its test YAML is in the test file.

Example batch (3 stories, 3 turns):

  • Turn 1: Write MetaBanner.astro, HeroSection.astro, ProblemSection.astro (parallel Writes)
  • Turn 2: Update index.astro + add 3 story YAMLs to test file (parallel writes)
  • Turn 3: Run targeted tests for the batch (Phase B)

Fixing failures

Fix in ONE turn using Edit on specific lines. Max 2 fix cycles per batch.

If you're stuck, re-run preflight to verify plumbing is correct:

bash "$SHARED_DIR/scripts/preflight-story.sh" rootspec/05.IMPLEMENTATION/USER_STORIES .

If SELECTORS_MISSING or ROUTES_MISSING is non-empty, fix those first — the test can't pass without them.

NEVER do these:

  • Rewrite the entire test file (you'll lose passing stories)
  • Create separate debug/targeted test files
  • Add wait or timeout steps (not in the DSL)
  • Remove stories from the test file

After each batch

Report: "Batch complete: US-001, US-002, US-003 PASS. Full suite: 6/10 passing, 0 regressions."

If regressions exist, fix before starting next batch. When all target stories pass (or per-story cap reached), go to Step 4.

Step 4: Summary and commit (~3 turns)

Update conventions (1 turn)

Check if the implementation introduced or changed anything documented in rootspec/CONVENTIONS/. Update conventions docs to reflect what you actually built — new dependencies, patterns, colors, fonts. Only update entries that actually changed. Match the format: ## Heading sections with - **Label:** value entries.

Commit and report (1-2 turns)

COMPLETED_AT=$(date -u +"%Y-%m-%dT%H:%M:%SZ")

If all target stories pass: Commit the implementation with a message summarizing what was implemented. Then suggest /rs-validate for a full report.

If any stories are failing: Do not commit. Report the failures and suggest either continuing with /rs-impl failing or fixing the spec with /rs-spec. Uncommitted work stays in the working tree for the developer to review.

Record stats:

bash "$SHARED_DIR/scripts/write-stats.sh" rootspec/stats.json rs-impl "$STARTED_AT" "$COMPLETED_AT" <iteration-count> '<stories-json>'

Where <stories-json> is a JSON object like {"US-101":{"attempts":2},"US-102":{"attempts":1}} tracking how many test cycles each story took.

Report

Generate the report from tests-status.json — do not self-assess:

bash "$SHARED_DIR/scripts/generate-test-report.sh" rootspec/tests-status.json rootspec

This outputs pass/fail/not-tested counts from the actual test results. Include its output in your summary.

Focus

Arguments narrow what the skill works on:

  • No focus → all stories by phase order (earliest first)
  • "US-101" → specific story
  • "TASK_SYSTEM" → stories for a system
  • "MVP" (or any phase name) → stories tagged with that phase
  • "failing" → re-implement previously failing stories

Scope

  • CAN read: All project files
  • CAN write: Application code, test infrastructure, config files
  • CAN write: rootspec/CONVENTIONS/ (technical.md, visual.md)
  • CAN update: rootspec/tests-status.json
  • CANNOT write: Any other file in rootspec/ (spec files, spec-status.json, 00.AXIOMS.md, 00.FRAMEWORK.md)
  • CANNOT write: dependencies or devDependencies in package.json (use npm install)

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

34.03%
按下载量换算150

Claude

31.17%
按下载量换算137

Cursor

20.79%
按下载量换算91

Gemini CLI

9.35%
按下载量换算41

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

执行命令

安装流程涉及命令执行,可能通过 npx skills add https://github.com/rootspec/rootspec --skill rs-impl 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills