Skip to main content
command CX Codex

segment-customers — Claude Code command for customer segmentation

segment-customers is a Claude Code command that builds customer segments, scoring logic, and an activation brief for goals such as retention, upsell, or adoption.

Apache-2.0 ★ 450 updated 2026-04-03

Install into Claude Code · Manually: put the files in place All methods and platforms ↓
.claude/commands/segment-customers.md
Open on GitHub

What segment-customers does

Provide a business goal, data sources, and a segmentation method: rules, clustering, or a hybrid approach. The command assesses the selected data’s quality and coverage, then designs segments and checks their stability and interpretability. Results depend on the inputs you choose.

Outputs include a segmentation matrix with criteria, size, and metrics; scoring logic with weights and thresholds; and an activation brief that maps segments to channels and plays. You can also focus activation on sales, customer success, marketing, or product.

The workflow covers data profiling, segment design, scoring rules, persona descriptions, and an activation plan. It can call segmentation-architect, retention-analyst, and customer-insights-partner, alongside the segmentation-framework and activation-map skills.

What it helps with

  • Group customers around a retention or upsell goal
  • Assess the quality and coverage of data sources
  • Define weights and thresholds for segment scoring
  • Map customer segments to channels and actions

Example prompts for the agent

  • Create five upsell segments from usage and revenue data: /customer-analytics:segment-customers --goal "upsell" --inputs usage,revenue --method hybrid --segments 5
  • Use usage and support data to build retention segments: /customer-analytics:segment-customers --goal "retention" --inputs usage,support --method clustering --segments 4
  • Build marketing segments from survey and firmographic data: /customer-analytics:segment-customers --goal "marketing efficiency" --inputs survey,firmographic --method rules --segments 3 --activation marketing

How to install segment-customers

Manually: put the files in place

.claude/commands/segment-customers.md

Call it with /segment-customers. For all projects use ~/.claude/commands/

Questions about segment-customers

How do I install segment-customers in Claude Code?

Add the command file at .claude/commands/segment-customers.md.

What does segment-customers do?

It designs customer segments, defines scoring logic, and links the segments to an activation plan.

Which data sources can segment-customers use?

You can supply usage, firmographic, revenue, support, or survey data, along with a goal, method, and target segment count.

Source text

segment-customers.md · Apache-2.0
---
name: segment-customers
description: Generates customer segmentation models, scoring logic, and activation briefs.
usage: /customer-analytics:segment-customers --goal "upsell" --inputs usage,firmographic --method hybrid --segments 5
---

# Command: segment-customers

## Inputs
- **goal** – business goal (upsell, retention, adoption, marketing efficiency).
- **inputs** – comma-separated data sources (usage, firmographic, revenue, support, survey).
- **method** – rules | clustering | hybrid.
- **segments** – target number of segments/personas to output.
- **activation** – optional channel focus (sales, cs, marketing, product).

## Workflow
1. **Data Profiling** – evaluate selected inputs, quality, and coverage.
2. **Segmentation Design** – run clustering/heuristics, score stability, and interpretability.
3. **Scoring Logic** – define rules/weights for RevOps/data teams to implement.
4. **Persona Packaging** – craft segment personas with value props, risks, and KPIs.
5. **Activation Plan** – map segments to GTM plays, reporting, and refresh cadence.

## Outputs
- Segmentation matrix (definition, criteria, size, key metrics).
- Scoring workbook/API spec with weights and thresholds.
- Activation brief aligning segments to plays/channels.

## Agent/Skill Invocations
- `segmentation-architect` – leads modeling + documentation.
- `retention-analyst` – supplies usage/retention signals.
- `customer-insights-partner` – injects qualitative proof.
- `segmentation-framework` skill – provides templates + guardrails.
- `activation-map` skill – links segments to GTM workflows.

---

© gtmagents · Apache-2.0 · gtmagents/gtm-agents

Similar slash commands

All slash commands for Marketing and content →

From the same set224

The whole set →
synthesize-learnings synthesize-learnings generates experiment readouts, codifies product learnings, and routes action items to backlogs. Built for growth and experimentation analysis. CX Codex +1 ★ 450repo stars build-social-calendar The build-social-calendar command for Claude Code plans channel-specific posts with briefs, owners, deadlines, and approvals. Set a period, channels, and cadence. CX Codex +1 ★ 450repo stars create-industry-playbook create-industry-playbook builds a vertical point of view, a solution brief and a sales enablement kit for B2B SaaS teams. Industry, persona and depth come in as flags. CX Codex +1 ★ 450repo stars objection-handling objection-handling structures responses to prospect objections around budget, timing, priority, or competitors during sales outreach and calls. CX Codex +1 ★ 450repo stars build-exec-dashboard build-exec-dashboard turns flags for audience, KPIs, cadence and format into an executive dashboard spec, with a rollout kit attached. CX Codex +1 ★ 450repo stars monitor-revenue-health monitor-revenue-health generates revenue health dashboards with leading and lagging indicators, anomaly detection, and action registers. CX Codex +1 ★ 450repo stars plan-bi-roadmap plan-bi-roadmap — a Claude Code command that scores a BI initiative backlog by impact, effort, and strategic alignment, then drafts a governed roadmap. CX Codex +1 ★ 450repo stars publish-release-documentation publish-release-documentation turns a version, a list of audiences and a deadline into a release documentation packet: notes, a changelog entry and a workback tracker. CX Codex +1 ★ 450repo stars

Project sponsors

Companies that keep this analytics open