ワンクリックで
layered-architecture
Layered architecture patterns for separating presentation, application, domain, and data layers.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Layered architecture patterns for separating presentation, application, domain, and data layers.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
Optimize token usage and context window discipline. Reduce costs and improve response quality through smart context management.
Unified context lifecycle for FlowDeck sessions — ingest, filter, prune, protect, summarize, and persist with telemetry.
Predict affected files, modules, APIs, tests, and DB paths before changes. Returns an impact map for human review.
Map architecture, conventions, and file structure into `.codebase/`. Use when onboarding or before deep feature work.
Plan differently when the agent has low certainty — ask for clarification or narrow scope instead of pretending full understanding.
Protect critical context from pruning during compaction. Preserve active plans, safety files, pending operations, and user intent anchors.
SOC 職業分類に基づく
| name | layered-architecture |
| description | Layered architecture patterns for separating presentation, application, domain, and data layers. |
| origin | FlowDeck |
When building traditional monolithic or client-server applications where clear vertical separation of concerns improves maintainability (e.g., MVC applications, REST APIs, data-driven apps).
// Presentation Layer - Controllers/Handlers
class OrderController {
constructor(private readonly orderService: OrderService) {}
async createOrder(req: Request, res: Response): Promise<void> {
const order = await this.orderService.createOrder(req.body)
res.status(201).json(order)
}
}
// Business Logic Layer - Services
class OrderService {
constructor(
private readonly orderRepository: OrderRepository,
private readonly paymentGateway: PaymentGateway
) {}
async createOrder(data: CreateOrderDto): Promise<Order> {
const order = new Order(data.items)
if (data.paymentMethod === 'prepaid') {
await this.paymentGateway.charge(order.total, data.paymentToken)
}
return this.orderRepository.save(order)
}
}
// Data Access Layer - Repositories
interface OrderRepository {
save(order: Order): Promise<void>
findById(id: string): Promise<Order | null>
findByCustomer(customerId: string): Promise<Order[]>
}
class PostgresOrderRepository implements OrderRepository {
constructor(private readonly db: Database) {}
async save(order: Order): Promise<void> {
await this.db.query('INSERT INTO orders (...) VALUES (...)', order.toDbFormat())
}
}