Apply software design principles across architecture and implementation using deterministic decision workflows, SOLID checks, structural patterns, and anti-pattern detection; use when reviewing designs, refactoring modules, or resolving maintainability and coupling risks.
Does it follow best practices?
Evaluation — 99%
↑ 1.01xAgent success when using this tile
Validation for skill structure
The dependency graph must be a Directed Acyclic Graph (DAG). Cycles create ripple effects where changes propagate unpredictably through the system.
Incorrect (cyclic dependency):
// modules/orders/OrderService.ts
import { CustomerService } from '../customers/CustomerService'
export class OrderService {
constructor(private customers: CustomerService) {}
async createOrder(customerId: string) {
const customer = await this.customers.findById(customerId)
// ...
}
}
// modules/customers/CustomerService.ts
import { OrderService } from '../orders/OrderService' // Cycle!
export class CustomerService {
constructor(private orders: OrderService) {}
async getCustomerWithOrders(customerId: string) {
const orders = await this.orders.findByCustomer(customerId)
// ...
}
}
// Neither module can be deployed or tested independentlyCorrect (break cycle with dependency inversion):
// modules/orders/ports/CustomerProvider.ts
export interface CustomerProvider {
findById(id: string): Promise<Customer>
}
// modules/orders/OrderService.ts
import { CustomerProvider } from './ports/CustomerProvider'
export class OrderService {
constructor(private customers: CustomerProvider) {}
async createOrder(customerId: string) {
const customer = await this.customers.findById(customerId)
// ...
}
}
// modules/customers/CustomerService.ts
// No import from orders module
export class CustomerService implements CustomerProvider {
// Implements the interface defined in orders module
}
// modules/customers/adapters/OrderAdapter.ts
import { OrderService } from '../../orders/OrderService'
export class CustomerOrderAdapter {
constructor(private orders: OrderService) {}
async getOrdersForCustomer(customerId: string) {
return this.orders.findByCustomer(customerId)
}
}Alternative (extract shared abstraction):
Create a new component that both depend on, breaking the cycle into a DAG.
Reference: Clean Architecture - Acyclic Dependencies Principle
Install with Tessl CLI
npx tessl i pantheon-ai/software-design-principlesevals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
references