All skills
lexler avatar

/refactoring-team

@628d2e9
by Lada Kesselerlexler/skill-factory238 stars
61

Iterative code refactoring through progressive lenses via a worker-reviewer agent team.

Use this Skill: https://skilld.dev/gh/lexler/skill-factory/refactoring-team

This session only. Nothing lands on disk.

referenceslenses18-mutable-state.md

≈314 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Lens: Mutable State & Side Effects

State that changes in ways that are hard to track, or functions that do invisible work alongside their main purpose.

The Question

Where does state change in this code, and can a reader predict those changes?

How to Spot

  • Global or module-level mutable state
  • Functions that modify their arguments unexpectedly
  • Temporal coupling: functions that must be called in a specific order because they share mutable state
  • Side effects mixed into computations — a calculation that also logs, sends, or writes
  • Functions returning void that do all their work through mutation

Process

For each function, ask: does it change anything beyond its return value? If so, is that change visible to the caller? For shared state, ask: who can modify this, and can they step on each other?

Trade-off

Some mutation is necessary and natural. The goal is not purity everywhere but predictability — a reader should be able to tell what a function changes without reading its implementation. Push side effects to the edges, keep the core logic pure.

Go Deeper

What other state changes are hidden? Where are side effects mixed into computations? Where does temporal coupling force a specific calling order?

Source: SKILL.md on GitHub

No alerts6d3 checks · Risk SAFE
  • Gen Agent Trust Hub6d

    The skill facilitates an automated, iterative refactoring workflow using a worker-reviewer agent team. It processes local source code and executes user-provided test commands to verify changes. The skill operates using local scripts and standard development tools without any detected malicious behaviors or obfuscation.

  • Socket6d

    No alerts

  • Snyk6d

    Risk: LOW · No issues

Signed by skilld at 628d2e9. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub last month.

Steadyupdated 7 months ago
disable-model-invocation
true
argument-hint
[target-path]
Other metadata
hooks
{
  "TeammateIdle": [
    {
      "hooks": [
        {
          "type": "command",
          "command": "${CLAUDE_SKILL_DIR}/references/guard-idle-worker.sh"
        }
      ]
    }
  ]
}

README badge

README badge for lexler/skill-factory/refactoring-team