.agents/skills/adopt/SKILL.md
Adopt the opinionated TypeScript architecture in an existing project. Runs a review first, then proposes incremental changes the user can accept or discard. Remembers discarded proposals so they aren't re-suggested. Triggers on phrases like "adopt the architecture", "migrate my project", "align my project with the rules", "adopt tseng", or "make my project conform". Also invocable via the /tseng:adopt slash command.
npx skillsauth add kagenti/humr adoptInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
echo "Architecture docs: ${CLAUDE_SKILL_DIR}/architecture/"
echo "Version: $(cat "${CLAUDE_SKILL_DIR}/VERSION")"
Incrementally adopts the opinionated TypeScript architecture in an existing project. Unlike bootstrap (greenfield only), adopt works with existing code and lets the user control which changes to apply. Produces an immutable review record that is locked once the user finalizes their decisions.
The current tseng version is shown above (injected from the VERSION file). This version is embedded in the review record.
Run the full review process to understand the current state:
architecture/index.md from the architecture docs directory (shown above).tseng/ files (index.md, project-structure.md, adoption.md, reviews/) in the checklist — those are outputs of the adopt process, not rules to audit.Determine the next review number by reading tseng/reviews/index.md (or starting at 001).
Write the checklist to tseng/reviews/NNN.md:
# Review #NNN
<!-- tseng_version: {version} -->
<!-- status: open -->
<!-- created: {YYYY-MM-DD} -->
Generated from architecture docs (tseng v{version}).
## Stack
- [ ] Uses tRPC for API layer
- [ ] ...
## Architecture
- [ ] ...
Update tseng/reviews/index.md with the new row (status: open). Never modify existing rows.
Launch a subagent to audit every checklist item (same as review skill).
Use this exact subagent prompt template:
You are auditing a TypeScript project at {project_path} against a checklist of architecture rules.
Go through EVERY item below. For each one:
- Check the project files to determine if the rule is satisfied
- Mark it ✅ (pass) or ❌ (fail) or ⚠️ (partially met / not applicable)
- Cite the specific file and line that proves your assessment
- If it fails, briefly say what's wrong
Do NOT check anything beyond this list. Do NOT add suggestions, improvements, or opinions. Only verify what's listed.
CHECKLIST:
{checklist_contents}
Check if tseng/adoption.md exists in the target project. If it does, read it. This file tracks previously discarded proposals — any violation listed there under ## Discarded must NOT be re-proposed.
From the audit results, collect all ❌ and ⚠️ items that are NOT in the discarded list. Group them into concrete change proposals:
Present proposals to the user as a numbered list. Each proposal should include:
Ask the user which proposals to accept and which to discard. The user can respond with numbers, ranges, "all", or "none".
For any discarded proposals, ask the user for a brief reason (e.g., "will cover this later", "using a different pattern intentionally", "not relevant for this project"). This context is recorded in adoption.md so future runs (especially upgrade) can understand why something was rejected, not just that it was.
For each accepted proposal, make the actual code changes. Follow the architecture docs as the source of truth.
After applying changes:
tseng/project-structure.md with project metadata.tseng/adoption.md (see Phase 8).tseng/index.md using the template from the architecture docs. Include sections for all files that now exist in tseng/.Now that the user has finalized their decisions, update the review record tseng/reviews/NNN.md:
[x] — rule satisfied (passed audit or was just applied)[ ] — rule not satisfied (user discarded the proposal or it remains unaddressed)<!-- status: locked -->
<!-- locked: {YYYY-MM-DD} -->
tseng/reviews/index.md to show locked status.Once a review is locked, it must NEVER be modified again. It is a permanent record of the project's state at that point in time.
Write tseng/adoption.md with the current state:
# Adoption State
## Applied
- [rule description] — applied on [date] (review #NNN)
- ...
## Discarded
- [rule description] — discarded on [date] (review #NNN)
> Reason: [user-provided context, e.g. "will adopt after auth migration"]
- ...
## Remaining
- [rule description]
- ...
Merge with any existing content — don't lose previously recorded items. Include the review number so each decision is traceable. Every discarded entry must include the user's reason on the line below — this context is critical for future upgrade runs to judge whether a re-proposal is warranted.
Ensure the project's root CLAUDE.md includes a reference to tseng/index.md so future Claude sessions pick up adoption context. If CLAUDE.md doesn't exist, create it. If it exists, append only if the reference is missing.
Add this block:
## TSEng
This project follows the [TypeScript Engineering](tseng/index.md) architecture.
bootstrap skill instead.tseng/project-structure.md with the correct role. A project may have multiple server and client packages.role: other and not audited./tseng:adopt multiple times. Each run produces a new review record.development
Create a PRD through user interview, codebase exploration, and module design, then submit as a GitHub issue after user approval. Use when user wants to write a PRD, create a product requirements document, or plan a new feature. Always present the PRD for user approval before submitting.
testing
Upgrade a previously bootstrapped or adopted project when the architecture evolves. Diffs the current architecture rules against the project's last locked review, identifies new or changed rules, and proposes incremental changes. Triggers on phrases like "upgrade my project", "sync with latest architecture", "update to new rules", "upgrade tseng", or "architecture changed, update my project". Also invocable via the /tseng:upgrade slash command.
development
Spec out a feature or change with full knowledge of the opinionated TypeScript architecture and the project's adoption state. Conducts a thorough discovery interview to understand domain concerns, bounded contexts, and application services, then produces a high-level architectural specification — never concrete implementation details. Triggers on phrases like "spec this feature", "design this change", "architect this", "help me spec", "what modules do I need", or "think through this feature". Also invocable via the /tseng:spec slash command.
development
Review an existing TypeScript project against the opinionated architecture rules. Use when the user asks to review, audit, check, or validate their project's architecture. Triggers on phrases like "review my project", "check the architecture", "audit my code structure", "validate my project", or "does my project follow the rules". Also invocable via the /tseng:review slash command.