Skip to content

AGI-comming/functional-skill-creator / skills/fskill-creator

fskill-creator

Verified

Create, maintain, or migrate functional skills; supports creating from a requirement brief and migrating an existing legacy skill directory into a functional skill structure.

functions/add_runtime_capabilities.md

View on GitHub
# add_runtime_capabilities

## Purpose

Provision self-contained report log, runtime wrapper, unit testcase runner, corresponding viewer, and smoke tests for the target functional skill.

## Input

| Field | Required | Description |
|---|---:|---|
| `skill_blueprint.include_report` | yes | Whether to generate report log runtime. |
| `skill_blueprint.include_unittest` | yes | Whether to generate unittest / testcase runner. |
| `skill_artifacts` | yes | The drafted skill artifacts. |

## Output

| Field | Description |
|---|---|
| `runtime_artifacts.script_files` | Report/runtime/test helper files to write into `scripts/`. |
| `runtime_artifacts.tool_files` | Viewer files to write into `tools/`. |
| `runtime_artifacts.testcase_files` | Runtime smoke testcases or report tests. |
| `runtime_artifacts.warnings` | Runtime warnings that cannot be resolved or need review. |
| `skill_artifacts` | Artifacts merged with runtime guidance. |

## Logic

1. When `include_report=true`, generate or preserve `scripts/report.mjs` and `scripts/runtime.mjs`:
   - `report.mjs` handles `off` / `local` / `remote` report mode, redaction, JSONL writing, and token estimate.
   - `runtime.mjs` binds the current skill name and exports `runStep`, `writeStepReport`, and `applyReportMode`.
2. When `include_report=true`, generate or preserve `scripts/test_report.mjs` smoke test.
3. When `include_unittest=true`, generate or preserve `scripts/test_cases.mjs`, ensure `testcases/unit/` exists, and suggest `.case.json` for high-risk functions.
4. When `include_report=true`, generate `tools/log_viewer.mjs`.
5. When `include_unittest=true`, generate `tools/tester_viewer.mjs`.
6. All runtime files must be vendored into the target skill; the uploaded skill must not depend on external toolkit paths.
7. If the target skill already has runtime files with the same names, prefer preserving the user's version and emit a review warning rather than silently overwriting.

## Errors

| Code | When |
|---|---|
| `[RUNTIME_CAPABILITY_CONFLICT]` | Target runtime file conflicts with the standard template and cannot be safely merged. |
| `[REPORT_RUNTIME_MISSING]` | `include_report=true` but report runtime could not be generated or preserved. |
| `[TEST_RUNTIME_MISSING]` | `include_unittest=true` but testcase runner could not be generated or preserved. |

## Observability

Record report runtime file count, test runner file count, viewer file count, runtime conflicts, and warning count.
reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.Stars: 470kUpdated Claude CodeCodexVerifiedInstall
diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.Stars: 322kUpdated Claude CodeCodexVerifiedInstall
dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependenciesStars: 322kUpdated Claude CodeCodexVerifiedInstall
executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is availableStars: 322kUpdated Claude CodeCodexVerifiedInstall