From supergraph
Builds throwaway code to validate uncertain approaches before committing. Supports logic prototypes (terminal state machines) and UI prototypes (multiple designs on one route with URL-param switcher). No persistence, no tests, single-command start.
How this skill is triggered — by the user, by Claude, or both
Slash command
/supergraph:prototypeThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Throwaway code to validate approach. Explore fast, decide, then delete or integrate.
Throwaway code to validate approach. Explore fast, decide, then delete or integrate.
Announce: "🧪 /supergraph:prototype — building throwaway prototype..."
/supergraph:analyze and /supergraph:plan when approach is uncertainAsk user (or infer from task):
Logic branch — validate state, algorithm, or data model
UI branch — validate layout, interaction, or multiple designs
Goal: validate core logic in a minimal terminal program.
Rules:
prototype-<slug>.ts / .py / etc.)npx ts-node prototype-<slug>.ts or equivalentStructure (TypeScript example):
// prototype-<slug>.ts — THROWAWAY, do not review
type State = "idle" | "processing" | "done" | "error"
type Event = { type: "start" } | { type: "finish" } | { type: "fail" }
function transition(state: State, event: Event): State {
// ...
}
// Run through sample cases
const cases = [ ... ]
cases.forEach(({ from, event, expected }) => {
const result = transition(from, event)
console.log(result === expected ? "✅" : "❌", { from, event, result, expected })
})
Run and observe:
npx ts-node prototype-<slug>.ts
Goal: compare multiple visual/interaction designs without committing.
Rules:
/prototype/<slug>?design=A|B|C switches between designsnpm run dev (or project equivalent)Structure:
app/prototype/<slug>/page.tsx (router + floating switcher)
app/prototype/<slug>/DesignA.tsx
app/prototype/<slug>/DesignB.tsx
app/prototype/<slug>/DesignC.tsx
Floating switcher (inline):
<div style={{position:'fixed',bottom:16,right:16,zIndex:9999,background:'#fff',padding:8,borderRadius:8,boxShadow:'0 2px 8px rgba(0,0,0,.2)'}}>
{["A","B","C"].map(d => (
<button key={d} onClick={() => router.push(`?design=${d}`)}
style={{margin:4, fontWeight: design===d ? 'bold' : 'normal'}}>
{d}
</button>
))}
</div>
Present findings to user:
Prototype: [slug]
Branch: Logic | UI
Findings:
- [What was validated]
- [What was ruled out]
- [Surprises / unexpected behavior]
Recommendation:
- Approach: [chosen approach]
- Confidence: high | medium | low
- Reason: [evidence from prototype]
Ask: "Ready to proceed to /supergraph:plan with this approach?"
After approach is decided:
# Delete prototype file(s)
rm prototype-<slug>.ts
# or git stash if user wants to keep for reference
Never commit prototype code to main branch.
npx claudepluginhub datit309/supergraph --plugin supergraphBuilds throwaway prototypes to answer design questions: a terminal app for state/logic exploration or multiple UI variations toggleable on a single route.
Builds a throwaway prototype to explore design options, sanity-check data models or state machines, or mock up UI variations. Routes between a terminal app for logic questions and toggleable UI variants.
Builds a throwaway prototype to answer design questions: a terminal app for state/logic exploration or UI variations switchable from one route.