From grammarly-pack
Integrates Grammarly Writing Score API into TypeScript apps to score documents on engagement, correctness, clarity, and tone. Includes batch scoring, rate limiting, and quality threshold enforcement.
How this skill is triggered — by the user, by Claude, or both
Slash command
/grammarly-pack:grammarly-core-workflow-aThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Integrate Grammarly's Writing Score API into your application. Score documents, track writing quality over time, and provide feedback. The API evaluates text across four dimensions: engagement, correctness, clarity, and tone.
Integrate Grammarly's Writing Score API into your application. Score documents, track writing quality over time, and provide feedback. The API evaluates text across four dimensions: engagement, correctness, clarity, and tone.
grammarly-install-auth setup// src/grammarly/scoring.ts
interface WritingScore {
overallScore: number;
engagement: number;
correctness: number;
clarity: number;
tone: number;
}
interface ScoreRequest {
text: string;
audienceType?: 'general' | 'knowledgeable' | 'expert';
domain?: 'academic' | 'business' | 'general' | 'email' | 'casual';
}
async function scoreDocument(req: ScoreRequest, token: string): Promise<WritingScore> {
const response = await fetch('https://api.grammarly.com/ecosystem/api/v2/scores', {
method: 'POST',
headers: { 'Authorization': `Bearer ${token}`, 'Content-Type': 'application/json' },
body: JSON.stringify(req),
});
if (!response.ok) throw new Error(`Grammarly API ${response.status}: ${await response.text()}`);
return response.json();
}
async function batchScore(documents: string[], token: string): Promise<WritingScore[]> {
const results: WritingScore[] = [];
for (const doc of documents) {
if (doc.split(/\s+/).length < 30) {
console.warn('Skipping: minimum 30 words required');
continue;
}
const score = await scoreDocument({ text: doc }, token);
results.push(score);
await new Promise(r => setTimeout(r, 500)); // Rate limit buffer
}
return results;
}
interface QualityGate {
minOverall: number;
minCorrectness: number;
minClarity: number;
}
function checkQualityGate(score: WritingScore, gate: QualityGate): { passed: boolean; issues: string[] } {
const issues: string[] = [];
if (score.overallScore < gate.minOverall) issues.push(`Overall ${score.overallScore} < ${gate.minOverall}`);
if (score.correctness < gate.minCorrectness) issues.push(`Correctness ${score.correctness} < ${gate.minCorrectness}`);
if (score.clarity < gate.minClarity) issues.push(`Clarity ${score.clarity} < ${gate.minClarity}`);
return { passed: issues.length === 0, issues };
}
// Usage: enforce quality before publishing
const score = await scoreDocument({ text: blogPost }, token);
const gate = checkQualityGate(score, { minOverall: 80, minCorrectness: 90, minClarity: 75 });
if (!gate.passed) console.error('Quality gate failed:', gate.issues);
| Limit | Value |
|---|---|
| Max text size | 4 MB |
| Max characters | 100,000 |
| Min words | 30 |
| Error | Cause | Solution |
|---|---|---|
400 | Text too short | Ensure >= 30 words |
413 | Text too large | Split into chunks < 100K chars |
429 | Rate limited | Implement exponential backoff |
For AI and plagiarism detection, see grammarly-core-workflow-b.
npx claudepluginhub ia23a-lachnita/claude-code-plugins-plus-fix-skills --plugin grammarly-pack7plugins reuse this skill
First indexed Jul 10, 2026
Showing the 6 earliest of 7 plugins
Integrates Grammarly Writing Score API into TypeScript apps to score documents on engagement, correctness, clarity, and tone. Includes batch scoring, rate limiting, and quality threshold enforcement.
Guides collaborative design exploration before implementation: explores context, asks clarifying questions, proposes approaches, and writes a design doc for user approval.
Creates structured, bite-sized implementation plans from specs or requirements before writing code. Useful for breaking down multi-step tasks into testable steps with file structure and task boundaries.