Tags drift into near-duplicates fast: “ai” and “AI”, “how-to” and “howto”, a singular next to its plural. Each one spins up its own thin archive page, splits the posts that should sit together, and makes the tag list a mess to navigate. The first move in cleaning it up is making sure every post under the redundant tag also carries the one you are keeping.
This finds those posts, shows you the scope, and only adds the canonical tag once you approve. It is honest about where it stops.
I have two tags that mean the same thing: [duplicate-tag] and the one I want tokeep, [canonical-tag]. I want every post to carry the canonical one.
First pass, read only: confirm both tags exist, and list every post that has[duplicate-tag] so I can see the scope. Change nothing yet.
Once I approve, add [canonical-tag] to each of those posts, working in smallbatches and showing me each batch before it saves, and list every post youtouched at the end. Be straight with me about the limits: this appends thecanonical tag, it does not strip the old one off the posts, and it cannotdelete the leftover tag. I will remove the old tag and delete the empty onefrom the WordPress admin myself.Why this is safe to run
The first pass is reads. Confirming both tags and listing every post under the duplicate writes nothing, so you approve the exact set before anything changes.
The write is a single, additive operation: it appends the canonical tag to each approved post. It does not replace a post’s tags, so nothing you already had gets dropped, and it never touches the post body or status. It stays inside its lane on purpose, and the recipe says so rather than overpromising: with only the add-post-terms write, it cannot strip the old tag off the posts, and there is no delete-term ability here, so it cannot delete the redundant tag either. Those two finishing steps are quick to do by hand in the WordPress admin once every post carries the canonical tag. The write ability stays off until you enable it, each call is checked against the capability of the user you bound the agent to, and every post it tags lands in the Activity Log so you can review the whole run.
Already connected? Skip the paste. Ask your agent for the “re-point posts from a duplicate tag” recipe, or just name the two tags, and it runs the same read-then-approve flow on your own site.