From arch-advisor
Use this skill when integrating AI agents with existing enterprise systems, legacy APIs, ERPs, CRMs, or when migrating from legacy to agent-based systems. Trigger when someone says 'we have existing systems the agent must use', 'we need to integrate with our ERP/CRM', 'legacy system has a different data model', 'how do we migrate gradually?', 'our legacy system is unstable', 'we need to call a SOAP service', 'agents and legacy systems must coexist'. Also trigger for: Anti-Corruption Layer, Saga pattern, Strangler Fig migration, REST adapter, message queue integration.
How this skill is triggered — by the user, by Claude, or both
Slash command
/arch-advisor:legacy-integrationThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
| Requirement | Pattern |
| Requirement | Pattern |
|---|---|
| Real-time, strong consistency, request-response | REST adapter |
| Near-real-time, decoupled, async processing | Message Queue (RabbitMQ/Kafka) |
| Large batch, high volume, scheduled | File Transfer |
| Complete audit history, replay capability | Event Sourcing |
| Distributed transaction with rollback | Saga Pattern |
Always use an ACL when:
The ACL is a translation layer:
[Agent] ← [ACL: toDomain()] ← [Legacy System]
[Agent] → [ACL: toLegacy()] → [Legacy System]
toDomain(): maps legacy response to clean domain model
toLegacy(): maps agent's request to legacy format
The ACL must also:
Every REST adapter needs:
async call(endpoint: string, payload: unknown): Promise<DomainResponse> {
// retry: 3 attempts, backoff: 1s, 2s, 4s
// timeout: 15s per attempt
// circuit breaker: open after 5 failures in 60s
// map HTTPError to DomainError
}
Use when an operation spans multiple services and must be rolled back if any step fails.
Choreography Saga (event-driven):
Orchestration Saga (central coordinator):
For agent systems: prefer orchestration — easier to trace and debug.
Compensation must be idempotent: compensations may run more than once (retries, failures). Ensure they are safe to repeat.
Gradually replace a legacy system without a big-bang migration:
Phase 1 (10% → new system): route a small percentage to the new agent-based system; monitor closely Phase 2 (25%): expand if Phase 1 metrics are acceptable Phase 3 (50%): parallel operation; compare outcomes Phase 4 (100%): complete cutover; keep legacy in read-only for 30 days
Go/no-go criteria per phase:
Automated rollback: if error rate exceeds threshold for N minutes, automatically route 100% back to legacy.
Add circuit breakers per legacy endpoint. When legacy is down:
Do not retry indefinitely. Set a maximum retry count and a dead-letter queue for failed operations.
npx claudepluginhub clenci/arch-advisor --plugin arch-advisorReplaces a legacy system incrementally by intercepting calls and routing traffic to a new implementation slice by slice, avoiding big-bang rewrites.
Orchestrates legacy system modernization using the strangler fig pattern, with phased assessment, dependency mapping, and risk-managed component replacement.
Modernize legacy systems without rewriting from scratch. Use strangler fig, facade, and strategic refactoring.