11# GitHub Copilot Instructions
22
3- > ** ⚡ Token Efficiency Note** : This is a minimal pointer file (~ 500 tokens, auto-loaded by Copilot).
4- > For complete operational details, reference: ` #file:AGENTS.md ` (~ 2,500 tokens, loaded on-demand)
3+ > ** Token Efficiency Note** : This is a minimal pointer file (~ 500 tokens, auto-loaded by Copilot).
4+ > For complete operational details, reference: ` #file:AGENTS.md ` (~ 2,500 tokens, loaded on-demand)
55> For specialized knowledge, use: ` #file:SKILLS/<skill-name>/SKILL.md ` (loaded on-demand when needed)
66
7- ## 🎯 Quick Context
7+ ## Quick Context
88
9- ** Project** : Spring Boot REST API demonstrating modern Java patterns
10- ** Stack** : Java 25 (LTS) • Spring Boot 4 • JPA/Hibernate • SQLite • Maven • Docker
11- ** Pattern** : Controller → Service → Repository → JPA (layered architecture)
9+ ** Project** : Spring Boot REST API demonstrating modern Java patterns
10+ ** Stack** : Java 25 (LTS) • Spring Boot 4 • JPA/Hibernate • SQLite • Maven • Docker
11+ ** Pattern** : Controller → Service → Repository → JPA (layered architecture)
1212** Philosophy** : Learning-focused PoC emphasizing Spring Boot best practices
1313
14- ## 📐 Core Conventions
14+ ## Core Conventions
1515
1616- ** Naming** : camelCase (methods/variables), PascalCase (classes)
1717- ** Annotations** : Use Spring stereotypes (@RestController , @Service , @Repository )
1818- ** Lombok** : Reduce boilerplate (@Data , @Builder , @AllArgsConstructor )
1919- ** Dependency Injection** : Constructor injection (Lombok @RequiredArgsConstructor )
2020- ** Testing** : JUnit 5 + AssertJ for fluent assertions
2121- ** Build** : Use ` ./mvnw ` wrapper, NOT system Maven
22+ - ** Commit Messages** : Follow Conventional Commits with issue number suffix
23+ - Format: ` type(scope): description (#issue) ` (max 80 chars)
24+ - Example: ` docs: optimize AI agent instructions for token efficiency (#259) `
25+ - Types: ` feat ` , ` fix ` , ` chore ` , ` docs ` , ` test ` , ` refactor `
2226
23- ## 🏗️ Architecture at a Glance
27+ ## Architecture at a Glance
2428
2529```
2630Controller → Service → Repository → JPA → Database
@@ -34,7 +38,7 @@ Validation Cache Query Methods
3438- ** DTOs** : ModelMapper for entity ↔ DTO transformations
3539- ** Cache** : Spring Cache abstraction (1-hour TTL)
3640
37- ## ✅ Copilot Should
41+ ## Copilot Should
3842
3943- Generate idiomatic Spring Boot code with proper annotations
4044- Use JPA repository patterns (derived queries, @Query )
@@ -44,7 +48,7 @@ Validation Cache Query Methods
4448- Use ModelMapper for DTO transformations
4549- Implement proper exception handling with @ControllerAdvice
4650
47- ## 🚫 Copilot Should Avoid
51+ ## Copilot Should Avoid
4852
4953- Field injection (use constructor injection)
5054- Using ` new ` for services (breaks DI)
@@ -53,7 +57,7 @@ Validation Cache Query Methods
5357- System.out.println (use SLF4J logging)
5458- Hardcoded configuration (use @Value or application.yml)
5559
56- ## ⚡ Quick Commands
60+ ## Quick Commands
5761
5862``` bash
5963# Run with hot reload
@@ -69,12 +73,12 @@ docker compose up
6973# Actuator: http://localhost:9001/actuator/health
7074```
7175
72- ## 📚 Need More Detail?
76+ ## Need More Detail?
7377
74- ** For operational procedures** : Load ` #file:AGENTS.md `
75- ** For Docker expertise** : * (Planned)* ` #file:SKILLS/docker-containerization/SKILL.md `
78+ ** For operational procedures** : Load ` #file:AGENTS.md `
79+ ** For Docker expertise** : * (Planned)* ` #file:SKILLS/docker-containerization/SKILL.md `
7680** For testing patterns** : * (Planned)* ` #file:SKILLS/testing-patterns/SKILL.md `
7781
7882---
7983
80- 💡 ** Why this structure?** Copilot auto-loads this file on every chat (~ 500 tokens). Loading ` AGENTS.md ` or ` SKILLS/ ` explicitly gives you deep context only when needed, saving 80% of your token budget!
84+ ** Why this structure?** Copilot auto-loads this file on every chat (~ 500 tokens). Loading ` AGENTS.md ` or ` SKILLS/ ` explicitly gives you deep context only when needed, saving 80% of your token budget!
0 commit comments