Plain Language Analysis
Privacy Notice: This AI analysis assistance is intended only to help develop public-facing content. Do not include personal or sensitive information. This tool is not intended for internal communications.
Analyze Content
Technical Documentation
How It Works
The Plain Language Analyzer uses a combination of proven readability algorithms and advanced artificial intelligence to evaluate and improve government content. The system processes your text through multiple analysis stages:
Processing Flow
- Text Preprocessing: Content cleaning and normalization
- Quantitative Analysis: Calculation of readability metrics
- AI Qualitative Analysis: Contextual evaluation with GPT-4
- Suggestion Generation: Actionable recommendations
- Composite Scoring: Final score based on multiple factors
Technology Stack
Backend
- Python 3.11+ - Core language
- Flask - Web framework
- textstat - Readability metrics library
- OpenAI GPT-4 - AI engine for contextual analysis
- Beautiful Soup - Web content extraction
- Trafilatura - Main text extraction
Frontend
- Bootstrap 4 - UI framework
- JavaScript (ES6+) - Client-side logic
- Font Awesome - Icons
- Jinja2 - Template engine
Readability Algorithms
The system uses multiple scientifically validated readability formulas to assess text complexity:
Flesch Reading Ease
Formula: 206.835 - 1.015 × (total words / total sentences) - 84.6 × (total syllables / total words)
Score of 0-100 where higher scores indicate easier text. Scores of 60-70 are considered appropriate for general audiences.
Flesch-Kincaid Grade Level
Formula: 0.39 × (total words / total sentences) + 11.8 × (total syllables / total words) - 15.59
Indicates the grade level required to understand the text. Treasury Board recommends Grade 8 for public readability.
Gunning Fog Index
Formula: 0.4 × [(words / sentences) + 100 × (complex words / total words)]
Measures complexity based on complex words (3+ syllables). Lower scores indicate clearer text.
SMOG Index
Formula: 1.0430 × √(polysyllables × 30 / sentences) + 3.1291
Simple Measure of Gobbledygook - estimates years of education needed to understand the text.
Advanced AI Analysis
Beyond quantitative metrics, the tool uses OpenAI GPT-4 for in-depth qualitative analysis:
- Contextual Analysis: Understanding of content meaning and intent
- Jargon Detection: Identification of technical and bureaucratic terms
- Structure Improvement: Suggestions for better organization
- Sentence Simplification: Rewriting of complex sentences
- Active Voice Clarity: Passive to active conversion
- Tone Consistency: Ensuring consistent voice
Scoring Methodology
The final Plain Language Score (A-F) is calculated using a weighted composite scoring system:
| Factor | Weight | Description |
|---|---|---|
| Grade Level | 40% | Flesch-Kincaid against Grade 8 target |
| Reading Ease | 30% | Normalized Flesch score |
| Sentence Length | 15% | Average words per sentence (optimal: 15-20) |
| Word Complexity | 15% | Percentage of difficult words and syllables |
Data Processing & Privacy
- All analysis is performed in real-time - no data stored permanently
- AI requests processed through secure APIs with encryption
- No personal or sensitive information should be submitted
- Sessions are isolated - no data sharing between users
- Compliant with Government of Canada security standards
Performance Metrics
Technical Note: The analyzer combines industry best practices with Treasury Board of Canada guidelines for plain language. The composite scoring ensures a balanced evaluation across multiple dimensions of readability rather than relying on a single metric.