Helps developers keep class abstractions cohesive and free of unrelated responsibilities.
This skill appears to be prompt-only guidance/documentation with no required secrets, no declared remote endpoints, and no indicated code execution or data access capability. Given the open-source GitHub source, overall risk is low, though supply-chain confidence is limited by unknown maintenance status and minimal community adoption.
The material explicitly states that no keys or environment variables are required; as a prompt-only skill, it does not appear to request, store, or transmit credentials, so credential exposure risk is low.
No remote endpoints are declared, and the content is only guidance on class abstraction design; there is no indication of sending user data to external services.
The system flags it as prompt-only, and the README is presented as documentation with example code rather than an executable tool specification; there is no described ability to spawn processes, run commands, or invoke system capabilities.
The material does not declare any ability to read, write, or modify local files, databases, clipboard contents, or other resources; it appears to provide only programming design guidance without data permissions.
The source is an open-source GitHub repository, which is a clear risk-reducing factor because it is auditable; however, the license is undeclared, it has 0 stars, and maintenance status is unknown, so community validation and maintenance signals are weak. Review repository contents and change history before production use.
Copy the install command and let the AI configure it · recommended for beginners
Please install the "Maintaining Consistent Abstractions" skill from askskill: 1. Download https://raw.githubusercontent.com/obra/clank/main/skills/architecture/maintaining-consistent-abstractions/SKILL.md 2. Save it as ~/.claude/skills/maintaining-consistent-abstractions/SKILL.md 3. Reload skills and tell me it's ready
Please review the following object-oriented code and determine whether the class interface maintains a single, consistent level of abstraction. Identify methods that mix in serialization, database persistence, or other unrelated concerns. Then provide refactoring suggestions and revised example code.
Provides issue analysis, responsibility separation suggestions, and a refactored code example with cleaner abstractions.
I have an Order class that handles business rules but also directly implements toJson, saveToDb, and loadFromDb. Using the principle of maintaining consistent abstractions, design a cleaner structure and explain which responsibilities should stay in the Order class and which should move to other components.
Shows a responsibility-based class design and explains the boundary between domain and infrastructure logic.
Please create a code review checklist for the team focused on 'maintaining consistent abstractions.' Cover class interface design, method naming, responsibility boundaries, and how to detect cases where business logic is mixed with serialization, storage, or transport concerns.
Produces an actionable review checklist to help the team consistently spot and fix abstraction-level violations.
A class interface should present ONE cohesive abstraction. All methods should work toward a consistent purpose at a consistent level.
Core principle: Each class implements one Abstract Data Type (ADT). If you can't identify what ADT the class implements, it has poor abstraction.
Goal: Anyone using the class should see a clear, consistent set of related operations, not a miscellaneous grab-bag.
Apply when designing any class:
Warning signs of poor abstraction:
Baseline violation:
class Employee:
def calculate_annual_salary(self): # ✅ Domain operation
return self.salary * 12
def update_department(self, dept): # ✅ Domain operation
self.department = dept
def to_json(self): # ❌ Serialization detail
return json.dumps({...})
def get_details(self): # ✅ Domain operation
return {...}
Problem: Employee is a domain concept. JSON is a serialization format. Mixing these means:
✅ Separate concerns:
class Employee:
"""Domain: Employee business logic only."""
def __init__(self, name, employee_id, department, salary):
self.name = name
self.employee_id = employee_id
self.department = department
self.salary = salary
def calculate_annual_salary(self): # Domain
return self.salary * 12
def update_department(self, dept): # Domain
self.department = dept
# Separate serializer
class EmployeeSerializer:
"""Concern: Serialization formats."""
@staticmethod
def to_json(employee: Employee) -> str:
return json.dumps({
'name': employee.name,
'id': employee.employee_id,
...
})
@staticmethod
def to_xml(employee: Employee) -> str:
# Can add XML without touching Employee
pass
Now: Employee knows nothing about formats. Add CSV/XML/Protobuf without changing Employee.
Baseline violation:
class Program:
"""Initialize application components."""
def _init_database(self): # Database concern
pass
def _setup_web_server(self): # Web concern
pass
def _start_background_jobs(self): # Jobs concern
pass
def _init_command_stack(self): # Command concern
pass
def _init_report_formatter(self): # Reports concern
pass
Problem: These are unrelated functions grouped because they happen at startup (temporal cohesion). The class has no consistent abstraction - it's a miscellaneous collection.
Code Complete specifically calls this out as poor abstraction.
✅ Each subsystem initializes itself:
class DatabaseSystem:
"""Abstraction: Database operations."""
def initialize(self):
# Database-specific initialization
pass
class WebServer:
"""Abstraction: Web serving."""
def start(self):
# Web server initialization
pass
class BackgroundJobManager:
"""Abstraction: Job processing."""
def start(self):
# Job system initialization
pass
# Coordinator stays high-level
…
Write evergreen comments focused on what and why, not historical context.
Compare 2-3 approaches before execution to choose a stronger solution.
Plan with pseudocode first, refine approaches, then translate into working code.
Search past Claude Code chats to recover facts, decisions, and context.
Design systems by hiding implementation details behind domain-level interfaces.
Name code by domain meaning to improve clarity and team alignment.
Helps you spot multi-purpose routines and refactor them into single-responsibility units.
Helps developers avoid common testing anti-patterns and write more reliable tests.
Improve code clarity and maintainability by assigning each variable one purpose.
Design, implement, and refactor hexagonal architecture with clear, testable boundaries.
Improve interface polish through spacing, typography, motion, and interaction details.