shared-logic-extraction

Extract duplicated Desktop App runtime logic into shared use cases.

1|1|Updated Nov 14, 2025
One-click install
npx skills add https://github.com/erikalira/python-tts --skill shared-logic-extraction
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: shared-logic-extraction
Source: https://github.com/erikalira/python-tts/tree/main/.codex/skills/shared-logic-extraction
Command: npx skills add https://github.com/erikalira/python-tts --skill shared-logic-extraction

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Identify duplicated logic across the Desktop App runtime and the shared layers in src, then extract it into shared use cases or services.

Core Features & Use Cases

  • Detection & classification: Pinpoint overlapping functionality across the Desktop App and shared infrastructure in src, mapping to cohesive use cases.
  • Extraction planning: Propose concrete refactor targets (modules, services, interfaces) with minimal disruption to existing flows.
  • Guided migration: Provide a step-by-step extraction plan and validation notes to ensure compatibility across entrypoints.

Quick Start

Identify duplicated logic areas and propose a shared module that serves both the Desktop App and the core runtime, then outline a concrete extraction plan.

Frequently Asked Questions about shared-logic-extraction

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I identify duplicated logic between a desktop app and a shared runtime?

To identify duplicated logic between a desktop app and a shared runtime, map overlapping functionality across both layers and classify it into cohesive use cases. This reveals where shared services can replace redundant code paths.

What is the best way to extract shared services from a desktop app without breaking existing flows?

The best way to extract shared services without breaking flows is defining clear ownership and stable contracts. Propose concrete refactor targets for modules and interfaces, ensuring minimal disruption to current operations.

How do I plan a code refactoring migration for shared logic across multiple entrypoints?

Plan a code refactoring migration for shared logic by outlining a step-by-step extraction plan with validation notes. This ensures compatibility and stable contracts are maintained across all application entrypoints.

When do I need to consolidate duplicated code into shared use cases?

You need to consolidate duplicated code into shared use cases when a codebase spans both a desktop app and core runtime, and the maintenance burden of overlapping functionality becomes too high to manage efficiently.

Does extracting shared logic require defining new interfaces for the core runtime?

Yes, extracting shared logic requires defining new interfaces to establish stable contracts between the desktop app and core runtime. This enforces clear ownership and ensures compatibility across all entrypoints.