Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Structures software around the Dependency Rule so business logic stays independent of frameworks, databases, and delivery mechanisms.
88% 100%+13 ptsof test cases passed
Passed 24 of 24 test cases with the skill, and 21 of 24 without it.
I need an architectural review of our payment service. Currently, our API controllers handle HTTP requests, instantiate TypeORM repositories directly, and contain some of our discount calculation logic. Can you evaluate our current setup against clean architecture principles? Please report our architecture score, list all the diagnostic rows that failed, and detail the specific inversions needed to fix every issue.
Provides an architecture score on the 0-10 scale derived from evaluating the 7 quick diagnostic questions.
3 of 3 safety checks passed
The Dependency Rule is the single most important concept in Clean Architecture. It states that source code dependencies can only point inward. Nothing in an inner circle can know anything at all about something in an outer circle. This includes names -- functions, classes, variables, data formats, or any other named software entity declared in an outer circle must not be mentioned by code in an inner circle.
This reference covers the concentric circles model, how data crosses boundaries, why direction matters, how frameworks violate the rule, and how to keep the inner circle pure.
Clean Architecture organizes code into concentric circles, each representing a different level of abstraction and policy. The innermost circles contain the highest-level, most general policies. The outermost circles contain the lowest-level, most concrete details.
Entities encapsulate enterprise-wide business rules. These are the most general, most stable rules in the system. They are the least likely to change when something external changes -- a page navigation change, a security policy change, or a database migration should not affect entities.
Characteristics of well-designed entities:
Example:
class LoanApplication:
def __init__(self, applicant_income: float, requested_amount: float, credit_score: int):
self.applicant_income = applicant_income
self.requested_amount = requested_amount
self.credit_score = credit_score
def debt_to_income_ratio(self) -> float:
return self.requested_amount / (self.applicant_income * 12)
def is_creditworthy(self) -> bool:
return self.credit_score >= 680 and self.debt_to_income_ratio() < 0.43
This entity knows nothing about databases, HTTP, or frameworks. It encapsulates the business rule that determines creditworthiness.
Skills that do similar work, with their benchmark result.
Next to this one in the catalogue, plus more from the same author.