@tpmjs/nps-analysis
Analyzes NPS survey responses to categorize by promoter/passive/detractor and extract themes from comments. Provides NPS score, distribution, and actionable insights.
Test @tpmjs/nps-analysis (npsAnalysisTool) with AI-powered execution
0/2000 characters
Install this tool and use it with the AI SDK
npm install @tpmjs/nps-analysispnpm add @tpmjs/nps-analysisyarn add @tpmjs/nps-analysisbun add @tpmjs/nps-analysisdeno add npm:@tpmjs/nps-analysisimport { npsAnalysisTool } from '@tpmjs/nps-analysis';import { generateText } from 'ai';
import { openai } from '@ai-sdk/openai';
import { npsAnalysisTool } from '@tpmjs/nps-analysis';
const result = await generateText({
model: openai('gpt-4o'),
tools: { npsAnalysisTool },
prompt: 'Your prompt here...',
});
console.log(result.text);How AI agents can use this tool
Use this tool to analyze NPS survey results, identify themes from promoters and detractors, and extract actionable insights for product and customer success teams.
Theme extraction is keyword-based. For deeper sentiment analysis, consider using an AI model. Requires sufficient response volume for meaningful analysis.
(responses: { date: string; score: number; comment: string; respondentId: string }[]) => Promise<unknown>Available configuration options
responsesobject[]NPS survey responses with score (0-10) and optional comment
Schema extracted: 3/1/2026, 4:27:13 AM
ERROR: No README data found!
Downloads/month
126
GitHub Stars
0
Quality Score