Skip to content
Productivity
Skill

/fix-duplicates

Find and merge duplicate entities. Use when user says \"clean up duplicates\", \"merge these people\", \"fix duplicate entities\", \"dedupe my contacts\", or when you notice potential duplicates during conversation.

From plugin
claudia
30135 skills6 agents

Claude Code

$ npx -y skills add kbanc85/claudia --skill fix-duplicates --agent claude-code

SKILL.md

fix-duplicates.SKILL.md
name: fix-duplicates
description: "Find and merge duplicate entities. Use when user says \"clean up duplicates\", \"merge these people\", \"fix duplicate entities\", \"dedupe my contacts\", or when you notice potential duplicates during conversation."
effort-level: medium

Fix Duplicates

Find and merge duplicate entities in the memory system. Duplicates happen when the same person, project, or organization gets stored under slightly different names.

Triggers

  • User says "find duplicates", "clean up duplicates", "dedupe"
  • User says "merge [name] with [name]"
  • User says "[Name] and [Other Name] are the same person"
  • You notice similar names during a conversation (e.g., "John Smith" and "Jon Smith")

Workflow

Step 1: Find Potential Duplicates

Search for entities with similar names using `claudia memory entities`:

claudia memory entities search --query "*" --limit 100 --project-dir "$PWD"

Then compare names using these heuristics:

  • Exact prefix match (first 5+ characters)
  • Levenshtein distance <= 2 for short names
  • Same first name + similar last name
  • Abbreviations (Bob/Robert, Mike/Michael, Liz/Elizabeth)
  • Missing middle names or initials

Present candidates grouped by type (person, project, organization).

Step 2: Present Candidates to User

Format:

Found potential duplicates:

**People:**
1. "John Smith" (ID: 42) and "Jon Smith" (ID: 87)
   - First has 12 memories, second has 3

2. "Michael Chen" (ID: 23) and "Mike Chen" (ID: 56)
   - First has 8 memories, second has 5

**Projects:**
1. "Website Redesign" (ID: 101) and "Website Re-design" (ID: 145)

Which would you like to merge? (e.g., "merge 1" or "merge all people")

Step 3: Execute Merge

When user confirms, call `claudia memory entities` to merge:

claudia memory entities merge --source-id 87 --target-id 42 --reason "Duplicate detected - same person with name variant" --project-dir "$PWD"

**Important:** Always merge the entity with fewer memories INTO the one with more memories. The target entity keeps its name and attributes; the source's name becomes an alias.

Step 4: Confirm Results

After merge:

Merged "Jon Smith" into "John Smith"
- 3 memories reassigned
- 2 relationships updated
- "Jon Smith" added as alias

"John Smith" now has 15 memories total.

Direct Merge Request

When user explicitly says "merge X with Y":

1. Search for both entities by name 2. Show what you found and confirm which is which 3. Ask which should be the primary (or recommend based on memory count) 4. Execute merge 5. Confirm result

Edge Cases

No Duplicates Found

I searched through your entities and didn't find any obvious duplicates. Your memory is looking clean!

Ambiguous Match

I found multiple entities that could be matches:
- "John Smith" (ID: 42) - works at Acme Corp
- "John Smith" (ID: 67) - consultant
- "Jon Smith" (ID: 87) - no additional context

These might be different people. Can you clarify which are the same?

Entity Not Found

I couldn't find an entity named "[name]". Here are similar ones:
- [list of similar names]

Never

  • Merge without user confirmation
  • Assume two entities are the same just because they share a first name
  • Delete the original entity (merges soft-delete the source)
  • Lose any memories or relationships in the merge
Read more
@kbanc85
Ships withclaudia

Terminal-based AI chief of staff. Remembers relationships, tracks commitments, helps you think strategically. Runs on Claude Code.

30135 skills6 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
301
Star history of kbanc85/claudia on GitHub, a chart by star-history.com

Other skills on claudia.

build-team

build-team

Propose and, after approval, configure a personalized team of Codex subagent roles based on the user's profile, goals, and…

@kbanc85@kbanc85Install Skill
claudia-core

claudia-core

Use Claudia's identity, persistent local memory, relationship context, project routing, judgment rules, and strategic operating…

@kbanc85@kbanc85Install Skill
databases

databases

Inspect Claudia's unified production memory database and backups. Use for database identity, health, counts, schema, WAL, backup…

@kbanc85@kbanc85Install Skill
onboarding

onboarding

Run Claudia's required first-conversation setup. Use automatically before substantive work whenever the current Claudia workspace…

@kbanc85@kbanc85Install Skill
auto-research

auto-research

Iteratively improve a local artifact (draft, document, page) by running a hill-climbing loop. The user names the artifact, the…

@kbanc85@kbanc85Install Skill
brain-monitor

brain-monitor

Launch the Brain Monitor TUI, a real-time terminal dashboard for watching Claudia's memory system. Triggers on \"brain monitor\",…

@kbanc85@kbanc85Install Skill

More skills from other plugins.

i-have-adhd

i-have-adhd

Shape output for a reader with ADHD: lead with the next action, number multi-step work, restate state across turns, suppress…

@ayghri@ayghriInstall Skill
ab-test-analysis

ab-test-analysis

Analyze A/B test results with statistical significance, sample size validation, confidence intervals, and ship/extend/stop…

@phuryn@phurynInstall Skill
distilly

distilly

Set up the owner profile so a personal agent knows who it works for (first-run setup, \"get to know me\"), or distill colleague,…

Questions about fix-duplicates.

Which coding agents can use fix-duplicates?
fix-duplicates installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.