| name | onboard |
| description | Role-based onboarding card injection for new team members |
| args | [role] |
| user_invocable | true |
/session-memory:onboard — Team Onboarding
Inject relevant knowledge cards for a new team member based on their role.
Steps
-
Parse role argument (optional):
- If provided:
frontend, backend, fullstack, devops, designer, pm, etc.
- If not provided: show all onboarding + high-importance cards
-
Collect onboarding cards from .claude/memory/cards/*.md:
Priority order:
- Cards with
type: onboarding (always included)
- Cards with
type: decision + importance >= 2 (architectural context)
- Cards with
type: constraint (must-know limitations)
- Cards with
type: gotcha + importance >= 2 (critical pitfalls)
- Cards with
type: runbook (operational procedures)
Role filtering (when role is specified):
- Match against card
tags field
frontend → tags containing: frontend, ui, css, react, next, component
backend → tags containing: backend, api, database, server, auth, migration
fullstack → include both frontend and backend tags
devops → tags containing: devops, ci, cd, deploy, infra, docker, k8s
designer → tags containing: design, ui, ux, figma, style
pm → tags containing: process, decision, constraint, requirement
- No role match → include all cards
-
Display format:
=== Team Onboarding Package ===
Role: [role or "all"]
Cards: [count] knowledge cards
--- Onboarding ---
1. [onboarding] Dev Environment Setup (importance: 3)
TL;DR: Install Node 20, run `npm install`, copy .env.example to .env
Files: package.json, .env.example
2. [onboarding] Git Workflow (importance: 2)
TL;DR: Feature branches from main, PR required, squash merge
Files: .github/PULL_REQUEST_TEMPLATE.md
--- Key Decisions ---
3. [decision] PostgreSQL over MongoDB (importance: 3)
TL;DR: Chose PostgreSQL for ACID compliance and complex queries
Files: src/db/schema.ts
--- Constraints ---
4. [constraint] API Rate Limit (importance: 2)
TL;DR: External API limited to 100 req/min, must use queue
Files: src/services/api-client.ts
--- Watch Out ---
5. [gotcha] Auth null check (importance: 2)
TL;DR: req.user can be null before middleware
Files: src/auth.ts
--- Runbooks ---
6. [runbook] Database Migration (importance: 2)
TL;DR: Run migrate:generate, then migrate:run, test on staging first
Files: src/db/migrations/
=== End Onboarding ===
Tip: Use /session-memory:search to find specific topics
-
If no cards exist:
- Suggest creating initial onboarding cards:
"No onboarding cards found. Create your first with /session-memory:card"
- Offer to auto-generate starter cards based on project structure
-
Track onboarding delivery:
- Record onboarding event to events file for analytics
- Log: which cards were delivered, to which role
Role Tag Mapping
| Role | Tag keywords |
|---|
| frontend | frontend, ui, css, react, next, component, tailwind, style |
| backend | backend, api, database, server, auth, migration, queue, cache |
| fullstack | (frontend + backend combined) |
| devops | devops, ci, cd, deploy, infra, docker, k8s, terraform, aws |
| designer | design, ui, ux, figma, style, component, accessibility |
| pm | process, decision, constraint, requirement, scope, timeline |
Important Rules
- Always include
type: onboarding cards regardless of role
- Sort by importance (descending) within each type group
- Show full TL;DR for each card
- If a card has
visibility: private, skip it (onboarding should be team-visible)
- Maximum 20 cards per onboarding package