Starlight automatically renders the frontmatter title as H1, so having a duplicate # Title in the body creates redundancy. Removed from 29 content files across all sections.
34 lines
942 B
Plaintext
34 lines
942 B
Plaintext
---
|
|
title: Why Mixins?
|
|
description: The architectural decision behind mcwaddams's modular structure.
|
|
---
|
|
|
|
import { Aside } from '@astrojs/starlight/components';
|
|
|
|
> *"What would you say... you do here?"*
|
|
|
|
mcwaddams uses Python mixins to organize 20 tools into logical groups without creating multiple MCP servers.
|
|
|
|
## The Pattern
|
|
|
|
```python
|
|
class MCWaddamsServer(
|
|
UniversalMixin, # 7 cross-format tools
|
|
WordMixin, # 10 Word-specific tools
|
|
ExcelMixin, # 3 Excel-specific tools
|
|
):
|
|
pass
|
|
```
|
|
|
|
## Benefits
|
|
|
|
1. **Single server** — One MCP configuration, not three
|
|
2. **Shared utilities** — Validation, caching, format detection
|
|
3. **Clear boundaries** — Each mixin owns its tools
|
|
4. **Easy testing** — Test mixins in isolation
|
|
5. **Simple extension** — Add PowerPoint mixin without touching Word code
|
|
|
|
<Aside type="note">
|
|
See [Architecture](/explanation/architecture/) for the full design.
|
|
</Aside>
|