-
Notifications
You must be signed in to change notification settings - Fork 51
Description
Ticket Contents
Description
[Provide a brief description of the feature, including why it is needed and what it will accomplish.]
This feature proposes the integration of an offline, AI-assisted writing support tool into the Sugar Write Activity. The AI assistant will provide real-time grammar suggestions, vocabulary enhancements, and creativity prompts to help children improve their writing skills.
It is designed specifically for low-resource, offline environments, where internet access is limited or unavailable. The tool will operate entirely on-device using lightweight natural language processing (NLP) models. This ensures privacy, accessibility, and educational equity for students in remote and underserved areas.
By enhancing the writing experience, this assistant supports literacy development, encourages self-expression, and bridges the digital divide through ethical and inclusive AI.
Goals & Mid-Point Milestone
Goals
- [Goal 1]
- [Goal 2]
- [Goal 3]
- [Goal 4]
- [Goals Achieved By Mid-point Milestone]
A working offline NLP model should be integrated with the Write Activity.
Basic grammar correction and suggestions should be functional.
A simple UI prototype should be in place for user interaction.
Privacy and offline operation should be confirmed and tested.
A set of writing prompts should be ready for deployment.
Setup/Installation
No response
Expected Outcome
The final product will be an offline, AI-assisted writing tool integrated into the Sugar Write Activity, designed for children. It will provide real-time grammar corrections, spelling suggestions, and creative writing prompts, all operating offline to ensure privacy and data security.
Key Features:
Offline Operation: All processing will happen locally, with no internet required.
Grammar and Spelling Suggestions: Real-time corrections for common mistakes (e.g., "goed" to "went").
Context-Aware Writing Feedback: Suggestions for improving vocabulary and sentence structure.
Creative Writing Prompts: Context-sensitive prompts to inspire creativity.
Child-Friendly UI: Simple and intuitive design for easy navigation.
Privacy: No data sent externally—everything stays on the device.
Behavior:
The tool will provide non-intrusive feedback, allowing the child to focus on writing.
Real-time corrections and suggestions will appear as they type.
Writing prompts will help overcome writer’s block and improve creativity.
Acceptance Criteria
Offline Functionality:
The tool must work completely offline without requiring an internet connection.
All data (text input, corrections, suggestions) must be processed and stored locally on the device.
Real-Time Grammar and Spelling Correction:
The AI should detect and highlight common grammar and spelling mistakes in real-time (e.g., verb tense errors, incorrect word usage).
Inline corrections should be suggested directly in the text, without interrupting the child’s writing flow.
Context-Aware Suggestions:
The system must provide relevant suggestions for improving sentence structure and vocabulary based on the context of the text.
The AI should offer suggestions like replacing generic words with more descriptive ones.
Creative Writing Prompts:
The tool must generate context-sensitive writing prompts when it detects writer’s block or when the child’s writing focuses on a specific theme.
The prompts should be appropriate for the child's age and writing level.
User Interface (UI):
The UI must be simple, intuitive, and accessible to children with minimal technical knowledge.
Feedback (corrections and prompts) must appear in a non-intrusive manner, either as inline suggestions or in a side panel.
Privacy and Security:
The system must ensure no data is sent externally. All processing and storage must happen locally on the device, in line with Sugar Journal principles.
There should be no data leakage or sharing of writing content with external services.
Smooth Performance:
The tool should work smoothly on low-resource devices (e.g., XO laptops, Raspberry Pi).
Feedback should appear with minimal delay during typing, even on less powerful devices.
Compatibility with Sugar Write Activity:
The feature must integrate seamlessly with the existing Sugar Write Activity interface without causing any performance issues or crashes.
The tool should not disrupt the core writing functionalities of the Write Activity.
Implementation Details
Python:
The primary language for implementing the AI model, backend logic, and integration with Sugar Write Activity.
Natural Language Processing (NLP) Model:
ONNX Runtime: For running pre-trained NLP models locally, providing efficient performance for grammar checking, text suggestions, and prompt generation.
spaCy: For text preprocessing and grammar checks, helping with tokenization, sentence parsing, and error detection.
TinyBERT/DistilBERT: Lightweight transformer models converted to ONNX format for efficient offline execution, used for grammar and context-aware suggestions.
GUI Integration (Updated):
Tkinter: A built-in Python library for creating simple and cross-platform graphical user interfaces. It’s easy to use and will allow for a lightweight and user-friendly interface.
Local Storage:
SQLite/JSON Files: For storing local data (e.g., writing content, user preferences, prompts) to maintain data privacy and security.
No external database or cloud storage is used, ensuring all data stays on the device.
Offline Model Loading:
The pre-trained models (TinyBERT or DistilBERT) will be saved in ONNX format for local usage.
ONNX Runtime will be used to load and execute the models for offline grammar and sentence correction.
Error Detection and Suggestions:
Custom error detection pipeline using spaCy to find spelling and grammatical errors.
The AI will suggest corrective actions based on context, using the trained models for sentence improvement.
Writing Prompts Generation:
The AI will use a predefined set of prompts tailored to different writing themes (e.g., animals, nature) stored locally.
Context-based suggestions will be generated by analyzing the child’s input text and triggering related writing prompts.
Mockups/Wireframes
No response
Product Name
Write Activity
Organisation Name
Sugar Labs
Domain
Education
Tech Skills Needed
Artificial Intelligence, Python
Mentor(s)
Category
AI