Плавная деградация при недоступных сервисах
engineering
graceful-degradation is a Claude Code skill that enforces a graceful degradation pattern when optional services are unavailable, guiding users with actionable recovery instructions instead of silent failures. The skill mandates checking service availability early — before spending compute — and caching the health-check result for the session with a 60-second TTL to avoid repeated endpoint polling. Every fallback message must cover three things: which service is missing, which features are degraded, and step-by-step instructions to restore them. A reference TypeScript implementation demonstrates the LMStudio check against `localhost:1234` with a 2000 ms timeout and a structured fallback message that lets the workflow continue without AI-assisted tactics. It is aimed at developers who need predictable handling of local or optional service dependencies without empty results or cryptic errors.
- #error-handling
- #service-availability
- #fallback-patterns
- #caching
- #user-experience