Agent skill
before-dev
Discovers and injects project-specific coding guidelines from .trellis/spec/ before implementation begins. Reads spec indexes, pre-development checklists, and shared thinking guides for the target package. Use when starting a new coding task, before writing any code, switching to a different package, or needing to refresh project conventions and standards.
Install this agent skill to your Project
npx add-skill https://github.com/mindfold-ai/Trellis/tree/main/packages/cli/src/templates/kiro/skills/before-dev
SKILL.md
Read the relevant development guidelines before starting your task.
Execute these steps:
-
Discover packages and their spec layers:
bashpython3 ./.trellis/scripts/get_context.py --mode packages -
Identify which specs apply to your task based on:
- Which package you're modifying (e.g.,
cli/,docs-site/) - What type of work (backend, frontend, unit-test, docs, etc.)
- Which package you're modifying (e.g.,
-
Read the spec index for each relevant module:
bashcat .trellis/spec/<package>/<layer>/index.mdFollow the "Pre-Development Checklist" section in the index.
-
Read the specific guideline files listed in the Pre-Development Checklist that are relevant to your task. The index is NOT the goal — it points you to the actual guideline files (e.g.,
error-handling.md,conventions.md,mock-strategies.md). Read those files to understand the coding standards and patterns. -
Always read shared guides:
bashcat .trellis/spec/guides/index.md -
Understand the coding standards and patterns you need to follow, then proceed with your development plan.
This step is mandatory before writing any code.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
create-command
Scaffolds a new skill file with proper naming conventions and structure. Analyzes requirements to determine skill type and generates appropriate content. Use when adding a new developer workflow skill, creating a custom skill, or extending the Trellis skill set.
finish-work
Pre-commit quality checklist covering lint, typecheck, tests, code-spec sync, API changes, database migrations, cross-layer verification, and manual testing. Blocks commit if infra or cross-layer specs lack executable depth. Use when code is written and tested but not yet committed, before submitting changes, or as a final review before git commit.
update-spec
Captures executable contracts and coding knowledge into .trellis/spec/ documents after implementation, debugging, or design decisions. Enforces code-spec depth for infra and cross-layer changes with mandatory sections for signatures, contracts, validation matrices, and test points. Use when a feature is implemented, a bug is fixed, a design decision is made, a new pattern is discovered, or cross-layer contracts change.
check
Validates recently written code against project-specific development guidelines from .trellis/spec/. Identifies changed files via git diff, discovers applicable spec modules, runs lint and typecheck, and reports guideline violations. Use when code is written and needs quality verification, to catch context drift during long sessions, or before committing changes.
check-cross-layer
Post-implementation verification across multiple code dimensions: cross-layer data flow, code reuse analysis, import path validation, and same-layer consistency checks. Identifies missed update sites, type mismatches, and duplicated constants. Use when changes span 3+ architectural layers, after modifying shared constants or configs, after batch file modifications, or when creating new utility functions.
start
Initializes an AI development session by reading workflow guides, developer identity, git status, active tasks, and project guidelines from .trellis/. Classifies incoming tasks and routes to brainstorm, direct edit, or task workflow. Use when beginning a new coding session, resuming work, starting a new task, or re-establishing project context.
Didn't find tool you were looking for?