From grammarly-pack
Optimizes Grammarly API costs via caching, text validation, sampling, and usage tracking. Use for billing analysis, cost reduction, or budget alerts.
npx claudepluginhub jeremylongshore/claude-code-plugins-plus-skills --plugin grammarly-packThis skill is limited to using the following tools:
Grammarly API pricing is enterprise/custom. Contact Grammarly for volume pricing.
Optimizes Grammarly API performance with caching, parallel calls, and batching strategies to reduce latency in JS/TS integrations.
Optimizes Groq LLM inference costs using task-based model routing, prompt token minimization, and usage monitoring. For billing analysis, cost reduction, or budget alerts.
Guides Next.js Cache Components and Partial Prerendering (PPR) with cacheComponents enabled. Implements 'use cache', cacheLife(), cacheTag(), revalidateTag(), static/dynamic optimization, and cache debugging.
Share bugs, ideas, or general feedback.
Grammarly API pricing is enterprise/custom. Contact Grammarly for volume pricing.
Same text produces same scores — cache aggressively to avoid duplicate API calls.
function shouldScore(text: string): boolean {
const words = text.split(/\s+/).length;
if (words < 30) return false; // API will reject
if (words > 50000) return false; // Too expensive, chunk first
return true;
}
// For bulk content, score a sample instead of everything
function selectSample(documents: string[], sampleRate = 0.2): string[] {
return documents.filter(() => Math.random() < sampleRate);
}
let apiCalls = { score: 0, ai: 0, plagiarism: 0 };
// Increment on each call, report daily
For architecture, see grammarly-reference-architecture.