agentleFS
strikersamstrikersam/autonomous-ai-agency/.claude/skills/user-research/SKILL.md

user-research

Skill12 starsChanged 29 days agoMITView on GitHub

User research skill — plan interviews, synthesize findings, and generate personas

19 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use prd-writer, competitive-analysis and 2 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • nimbalystSkill

    prd-writer

    Create structured Product Requirements Documents (PRDs) with prioritized requirements. Use when writing product specs, feature requirements, or project briefs.

    Also in 3 projects that use this

  • AnthropicSkill

    competitive-analysis

    Framework for building competitive landscape decks — market positioning, competitor deep-dives, comparative analysis, strategic synthesis. Use when the user asks for a competitive landscape, competitor analysis, peer comparison, market positioning assessment, strategic review, or investment memo deck. Also triggers on "who are the competitors to X", "benchmark X against peers", "build a market map", or any request to systematically evaluate competitive dynamics across an industry.

    Also in 3 projects that use this

  • Microsoft AzureSkill

    git-workflow

    Squad branching model: dev-first workflow with insiders preview channel

    Also in 3 projects that use this

  • BlockSkill

    frontend-design

    Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.

    Also in 5 projects that use this

The file

We split this skill into the rules it gives an agent

8 rules. 0 are common, 4 are distinctive, and 4 are very specific to this project.

  • 0

    Common

    Most of the 10 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Plan: Before kicking off a new research initiative — defines scope, objectives, methods, and sample size.

    line 30
  2. Distinctive:

    Qual: After collecting 3+ interview transcripts or open-ended responses — finds themes and pain points.

    line 31
  3. Distinctive:

    Quant: After collecting numeric survey data or experiment metrics — produces the descriptive stats and segment cuts.

    line 32
  4. Distinctive:

    Synthesize: After both qual and quant are available — produces the executive brief a stakeholder will read.

    line 33
  5. Very specific:

    All four capabilities are pure functions (plan_research, analyze_qualitative, analyze_quantitative, synthesize_research) that take and …

    line 40
  6. Very specific:

    All inputs and outputs use Pydantic v2 with extra="forbid" so the executor cannot smuggle unknown fields past validation:

    line 53
  7. Very specific:

    After auto_register() is called (or after agent/capability_registry.py discovers the module), the agent loop can invoke:

    line 112
  8. Very specific:

    Default z=1.96 (95% confidence), e=0.05, p=0.5.

    line 140

“Common” is measured: kept by at least 6 in 10 of the 10 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skill: user-research

Module: agent/user_research_skill.py Agent tools registered: user_research_plan, user_research_qual, user_research_quant, user_research_synthesize Capability tag: user_research (sub-tags: plan, qualitative, quantitative, synthesis) Maturity: stable

Purpose

Structured user-research workflows for the agent platform. Implements the four core capabilities adapted from the cookiy-ai/user-research-skill reference architecture:

CapabilityTool nameWhat it does
Planuser_research_planProduce a structured research plan (objectives, hypotheses, methods, sample size, timeline) from a research question.
Qualuser_research_qualExtract themes, pain points, and desires from interview transcripts or open-ended survey responses.
Quantuser_research_quantCompute descriptive statistics (mean, median, σ, distribution, segment cuts) for a numeric series.
Synthesizeuser_research_synthesizeCombine qual + quant into a decision-ready research brief with executive summary, findings, and recommendations.

When to Use

  • Plan: Before kicking off a new research initiative — defines scope, objectives, methods, and sample size.
  • Qual: After collecting 3+ interview transcripts or open-ended responses — finds themes and pain points.
  • Quant: After collecting numeric survey data or experiment metrics — produces the descriptive stats and segment cuts.
  • Synthesize: After both qual and quant are available — produces the executive brief a stakeholder will read.

Architecture

The skill is implemented as a pure-function library with a thin tool-wrapping layer:

  • All four capabilities are pure functions (plan_research, analyze_qualitative, analyze_quantitative, synthesize_research) that take and return Pydantic v2 models.
  • The functions are then registered with the agent ToolRegistry via the @registry.agent_tool decorator, so the agent loop can invoke them like any other tool.
  • No LLM calls inside the skill. The LLM is the executor that uses the tool; the tool provides the structural framework (Pydantic contracts, sample-size math, theme extraction heuristics, descriptive stats). This keeps the skill fast, testable, and free of hidden costs.

Pydantic Models (extra="forbid")

All inputs and outputs use Pydantic v2 with extra="forbid" so the executor cannot smuggle unknown fields past validation:

  • ResearchPlan — output of Plan
  • ResearchObjective, ResearchHypothesis, ResearchMethod — sub-models
  • QualAnalysis, QualTheme, QualQuote — output of Qual
  • QuantAnalysis, QuantSegment — output of Quant
  • ResearchBrief — output of Synthesize

Usage

As a Python library

from agent.user_research_skill import (
    plan_research, analyze_qualitative,
    analyze_quantitative, synthesize_research,
)

# 1. Plan
plan = plan_research(
    title="Why do users churn after onboarding?",
    primary_question="What causes week-1 churn?",
    audience="Product team",
    objectives=[{"statement": "Identify the top 3 friction points"}],
    methods=[{"method": "interview", "target_participants": 8}],
)
print(plan.target_sample_size)  # computed from method target + stats

# 2. Qual
qual = analyze_qualitative(
    source="8 customer interviews",
    transcripts=[
        "Login is broken and slow, hate it.",
        "Login is broken, otherwise fine.",
        "Love the new dashboard, but login is broken.",
    ],
)
for theme in qual.pain_points:
    print(theme.name, theme.frequency)

# 3. Quant
quant = analyze_quantitative(
    source="NPS survey Q4",
    values=[9, 9, 8, 10, 9, 8, 9, 10, 7, 9],
    metric_name="NPS",
    metric_type="rating",
)
print(quant.mean, quant.median, quant.stdev)

# 4. Synthesize
brief = synthesize_research(title="Q4 NPS + Interview Synthesis",
                             quant=quant, qual=qual)
print(brief.executive_summary)
print(brief.recommendations)

As an agent tool

After auto_register() is called (or after agent/capability_registry.py discovers the module), the agent loop can invoke:

# In an agent prompt, the model can call:
{
  "tool": "user_research_plan",
  "args": {
    "title": "Onboarding friction study",
    "primary_question": "What blocks first-week activation?",
    "audience": "Product",
    "objectives": [{"statement": "Identify top 3 blockers"}],
    "methods": [{"method": "interview", "target_participants": 6}]
  }
}

…and receive a validated ResearchPlan back.

Sample-Size Math

The plan_research function computes the target sample size from the larger of:

  1. The sum of target_participants across all methods.
  2. The standard normal-approximation sample size for a proportion, with finite-population correction when population_size is supplied.

Formula: n0 = z² · p(1-p) / e², then n = n0 / (1 + (n0-1)/N). Default z=1.96 (95% confidence), e=0.05, p=0.5.

Sentiment + Theme Heuristics

The analyze_qualitative function uses a small rule-based sentiment classifier (positive / neutral / negative) and a keyword-based theme extractor. Themes are filtered by min_theme_frequency (default 2) to avoid single-mention noise. Real production sentiment should use an LLM call — these heuristics are deliberately minimal so the skill scaffolding is fast and testable.

Tests

tests/test_user_research_skill.py covers:

  • Plan: minimal plan, sample-size math, ID uniqueness, scope, extras rejection
  • Qual: theme extraction, participant ID handling, sentiment, min-frequency filter
  • Quant: basic stats, distributions, segments, edge cases
  • Synthesize: quant-only, qual-only, combined, segment gap detection
  • Tool registration: 4 tools, capability discovery, idempotency, OpenAI export
  • End-to-end: plan → qual → synthesize

Run with:

pytest -x tests/test_user_research_skill.py -v

Auto-Registration

The skill auto-registers with the module-level ToolRegistry singleton on first import of agent.user_research_skill. To force registration in a custom registry, call register_user_research_tools(registry) explicitly.

Files

FilePurpose
agent/user_research_skill.pyPydantic models + 4 capability functions + tool registration
tests/test_user_research_skill.py35+ tests covering all capabilities and edge cases
.claude/skills/user-research/SKILL.mdThis document

See Also

  • agent/capability_registry.py — the dynamic tool registry
  • .claude/skills/research/SKILL.md — general-purpose research skill (broader scope, this skill is user-research-specific)
  • https://github.com/cookiy-ai/user-research-skill — the reference architecture this is adapted from

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.