Claude-code-plugins-plus-skills grammarly-performance-tuning

install
source · Clone the upstream repo
git clone https://github.com/jeremylongshore/claude-code-plugins-plus-skills
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/jeremylongshore/claude-code-plugins-plus-skills "$T" && mkdir -p ~/.claude/skills && cp -r "$T/plugins/saas-packs/grammarly-pack/skills/grammarly-performance-tuning" ~/.claude/skills/jeremylongshore-claude-code-plugins-plus-skills-grammarly-performance-tuning && rm -rf "$T"
manifest: plugins/saas-packs/grammarly-pack/skills/grammarly-performance-tuning/SKILL.md
source content

Grammarly Performance Tuning

Latency Benchmarks

APITypical LatencyNotes
Writing Score1-3sDepends on text length
AI Detection1-2sFast for short text
Plagiarism10-60sAsync, requires polling

Instructions

Cache Score Results

import { LRUCache } from 'lru-cache';
import { createHash } from 'crypto';

const scoreCache = new LRUCache<string, any>({ max: 500, ttl: 3600000 });

async function cachedScore(text: string, token: string) {
  const key = createHash('sha256').update(text).digest('hex');
  const cached = scoreCache.get(key);
  if (cached) return cached;
  const score = await grammarlyClient.score(text);
  scoreCache.set(key, score);
  return score;
}

Parallel API Calls

// Score + AI detect in parallel (they're independent)
async function fullAudit(text: string, token: string) {
  const [score, ai] = await Promise.all([
    grammarlyClient.score(text),
    grammarlyClient.detectAI(text),
  ]);
  return { score, ai };
}

Resources

Next Steps

For cost optimization, see

grammarly-cost-tuning
.