beifeng724/personal-workbench-skills / skills/personal-workbench-builder
personal-workbench-builder
VerifiedBuild a durable personal or professional workbench as a runnable application, or produce a six-stage generic prompt pack for building it. Use when the user wants to turn a recurring workflow into a dashboard, management system, workspace, personal operating system, or long-lived website with multiple connected modules and persistent state. Trigger for project, CRM, creator, learning, family, finance, travel, teaching, legal, or team workbenches. Do not trigger for marketing sites, one-off scripts, ordinary coding tasks, or informational questions.
scripts/create_spec.py
View on GitHub#!/usr/bin/env python3
"""Create a canonical workbench-spec.md from a JSON decision record."""
from __future__ import annotations
import argparse
import json
from pathlib import Path
from typing import Any
LEVELS = {"L1", "L2", "L3", "L4"}
MODES = {"direct", "prompt-pack"}
COMMUNICATION = {"plain", "guided", "technical"}
STATES = ("spec-approved", "ui-approved", "implementation-complete", "verification-passed")
def cell(value: object) -> str:
return str(value if value not in (None, "") else "pending").replace("|", "\\|").replace("\n", " ")
def get(data: dict[str, Any], *keys: str, default: object = None) -> object:
for key in keys:
if key in data:
return data[key]
return default
def requirement_rows(data: dict[str, Any]) -> str:
requirements = data.get("requirements", [])
return "\n".join(
f"| {cell(item.get('id', index + 1))} | {cell(item.get('text'))} | "
f"{cell(item.get('acceptance') or item.get('acceptance_condition'))} | "
f"{cell(item.get('status', 'confirmed'))} | {cell(item.get('order', index + 1))} |"
for index, item in enumerate(requirements)
) or "| - | pending | pending | draft | - |"
def state_rows(data: dict[str, Any]) -> str:
states = data.get("states", {})
rows = []
for name in STATES:
entry = states.get(name, states.get(name.replace("-", "_"), {}))
if isinstance(entry, dict):
passed = bool(entry.get("passed"))
evidence = entry.get("evidence")
else:
passed = bool(entry)
evidence = data.get(f"{name.replace('-', '_')}_evidence")
rows.append(f"| {name} | {'passed' if passed else 'pending'} | {cell(evidence)} |")
return "\n".join(rows)
def control_rows(data: dict[str, Any]) -> str:
controls = data.get("controls", [])
return "\n".join(
f"| {cell(item.get('id', index + 1))} | {cell(item.get('page') or item.get('module'))} | "
f"{cell(item.get('label') or item.get('accessible_name'))} | "
f"{cell(item.get('intended_behavior') or item.get('behavior'))} | "
f"{cell(item.get('acceptance') or item.get('acceptance_condition'))} | "
f"{cell(item.get('test_method'))} | {cell(item.get('actual_result') or item.get('result'))} | "
f"{cell(item.get('evidence'))} | {cell(item.get('status', 'not-run'))} |"
for index, item in enumerate(controls)
) or "| - | - | - | pending | pending | pending | pending | pending | not-run |"
def render(data: dict[str, Any]) -> str:
level = str(data.get("complexity", "L1"))
mode = str(data.get("output_mode", "direct"))
communication = str(data.get("communication_mode", "guided"))
if level not in LEVELS:
raise ValueError(f"complexity must be one of {sorted(LEVELS)}")
if mode not in MODES:
raise ValueError(f"output_mode must be one of {sorted(MODES)}")
if communication not in COMMUNICATION:
raise ValueError(f"communication_mode must be one of {sorted(COMMUNICATION)}")
sensitive = ", ".join(data.get("sensitive_categories", [])) or "none found; continue checking"
return f"""# Workbench Specification
## 1. Decision Record
- Working title: {cell(data.get('title'))}
- User goal: {cell(data.get('goal'))}
- Output mode: {mode}
- Communication mode: {communication}
- Complexity: {level}
- Classification evidence: {cell(data.get('classification_evidence'))}
- Specification status: {cell(data.get('status', 'draft'))}
- Current workflow state: {cell(data.get('current_state', 'draft'))}
| State | Status | Evidence |
|---|---|---|
{state_rows(data)}
## 2. Users And Repeated Workflow
- Primary user: {cell(data.get('primary_user'))}
- Other users: {cell(data.get('other_users', 'none'))}
- Trigger and frequency: {cell(data.get('frequency'))}
- Current workflow: {cell(data.get('current_workflow'))}
- Pain points: {cell(data.get('pain_points'))}
- Desired outcome: {cell(data.get('desired_outcome'))}
## 3. Confirmed Scope
| ID | Requirement in user's words | Acceptance condition | Status | Implementation order |
|---|---|---|---|---|
{requirement_rows(data)}
## 4. Excluded AI Proposals
None recorded. Add only proposals invented by the agent, never confirmed user requirements.
## 5. Conflicts, Dependencies, And Approved Deferrals
None recorded. Any deferral requires explicit user approval.
## 6. Information Architecture And UI
- Pages/modules: {cell(data.get('modules'))}
- Design method: generated
- Visual brief: {cell(data.get('visual_brief'))}
- Reference sources: {cell(data.get('reference_sources') or data.get('reference_screenshot'))}
- Reference license review: {cell(data.get('reference_license_review'))}
- Visual fingerprint: {cell(data.get('visual_fingerprint') or data.get('visual_direction'))}
- Reference sanitation notes: {cell(data.get('reference_sanitation'))}
- Theme mode: {cell(data.get('theme_mode'))}
- Expression: {cell(data.get('expression'))}
- Motion: {cell(data.get('motion'))}
- Density: {cell(data.get('density'))}
- Design system path: design-system/MASTER.md
- Page override paths: {cell(data.get('page_overrides'))}
- Fidelity target: {cell(data.get('fidelity_target'))}
- UI confirmation status: {cell(data.get('ui_confirmation_status', 'draft'))}
- Accessibility needs: {cell(data.get('accessibility_needs'))}
- Empty/loading/error/success/permission/offline states: {cell(data.get('ui_states'))}
## 7. Devices, Sync, And Data Lifecycle
- Primary devices: {cell(get(data, 'devices', 'primary_devices'))}
- Mobile context: {cell(data.get('mobile_context'))}
- Sync expectation: {cell(get(data, 'sync_expectation', 'sync'))}
- Data importance: {cell(data.get('data_importance'))}
- Acceptable data loss: {cell(get(data, 'acceptable_data_loss', 'acceptable_loss'))}
- Persistence approach: {cell(get(data, 'persistence', 'persistence_approach'))}
- Deployment profile: {cell(get(data, 'deployment_profile', 'deployment'))}
- Backup owner and frequency: {cell(data.get('backup_owner_frequency'))}
- Restore method: {cell(data.get('restore_method'))}
- Demo-data removal: required
## 8. Data And Storage
- Entities and retention: {cell(data.get('data_entities'))}
- Backup envelope format/version: {cell(data.get('backup_format', 'personal-workbench-backup v1'))}
- Current schema version: {cell(data.get('schema_version'))}
- Migration path and tested source versions: {cell(data.get('migration_path'))}
- Corrupt/future-version behavior: preserve current data and original input
- Import mode: {cell(data.get('import_mode', 'user chooses merge or overwrite'))}
- Pre-overwrite backup: required
- Last successful backup: {cell(data.get('last_backup'))}
- Last restore rehearsal: {cell(data.get('last_restore_rehearsal'))}
## 9. Users, Permissions, And Audit
- Authentication: {cell(data.get('authentication'))}
- Roles and data isolation: {cell(data.get('permissions'))}
- Audit trail: {cell(data.get('audit'))}
## 10. Integrations And Automation
{cell(data.get('integrations'))}
## 11. Architecture And Deployment
- Runtime: {cell(data.get('runtime'))}
- Storage/database: {cell(data.get('storage_database'))}
- Hosting: {cell(get(data, 'deployment_profile', 'hosting'))}
- Secret management: never expose secrets in frontend code
- Monitoring and recovery: {cell(data.get('operations'))}
- Startup/port behavior: {cell(data.get('startup_port_behavior'))}
- Ownership and recurring maintenance: {cell(data.get('owner'))}
- User/AI responsibility split: {cell(data.get('responsibility_split'))}
## 12. Privacy And Security Review
- Sensitive categories: {sensitive}
- Data minimization and safeguards: {cell(data.get('privacy_safeguards'))}
- Unresolved risk: {cell(data.get('unresolved_risk', 'none recorded'))}
## 13. Verification Plan
| Control ID | Page/module | Label or accessible name | Intended behavior | Acceptance condition | Test method | Actual result | Evidence | Status |
|---|---|---|---|---|---|---|---|---|
{control_rows(data)}
- Required scenarios: functional, persistence, migration, import/export, recovery, responsive, accessibility, error, privacy, and security as applicable.
- Tests actually run: {cell(data.get('tests_run', 'not yet'))}
- Known limitations: {cell(data.get('known_limitations', 'not yet assessed'))}
## 14. Version And Recovery Record
- `workbench-manifest.json` path: {cell(data.get('manifest_path'))}
- Generated by / skill version / app version: {cell(data.get('version_record'))}
- Current code baseline: {cell(data.get('code_baseline'))}
- Code snapshot or Git commit before material change: {cell(data.get('code_snapshot'))}
- Data backup before migration or overwrite: {cell(data.get('migration_backup'))}
- Rollback target and result: {cell(data.get('rollback_result'))}
## 15. Confirmation Log
| Time | State or sections confirmed | Exact user decision | Reopened by |
|---|---|---|---|
| - | - | awaiting confirmation | - |
## 16. Delivery Checklist
- [ ] Runnable project or six prompt stages
- [ ] Usage, backup, restore, update, migration, recovery, and deployment instructions
- [ ] `workbench-manifest.json`
- [ ] Control inventory, actual test evidence, and remaining limitations
- [ ] Applicable license and third-party notices
"""
def main() -> None:
parser = argparse.ArgumentParser()
parser.add_argument("input", type=Path, help="JSON decision record")
parser.add_argument("-o", "--output", type=Path, default=Path("workbench-spec.md"))
args = parser.parse_args()
data = json.loads(args.input.read_text(encoding="utf-8"))
args.output.write_text(render(data), encoding="utf-8", newline="\n")
print(f"Wrote {args.output}")
if __name__ == "__main__":
main()
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| 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: 472k | Updated | Claude CodeCodex | Verified | Install |
| 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: 322k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| 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 available | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |