Inspiration: Fixing the AI Privacy Problem
Today's AI writing assistants are powerful, but they all share a fundamental flaw: they force users to send their private text to the cloud. We type confidential work emails, sensitive research, and private messages into a text box, and that data is processed on a server we don't control.
The new on-device AI models inspired me in Chrome to build a tool that breaks this trade-off. Nano Polish was created to be the first truly private writing assistant, giving users powerful AI features with a 100% guarantee that their data never leaves their computer.
How It's Built: Privacy-First Architecture
Nano Polish is built as a Chrome Extension (Manifest V3) that leverages two of Chrome's built-in AI APIs:
- The Proofreader API: To instantly find and correct grammar and spelling errors.
- The Rewriter API: To offer tonal suggestions (e.g., "Formal," "Concise," "Casual").
The key technical challenge was accessing the AI. The window.ai object is not available in content scripts due to Chrome's "isolated worlds" security policy. The solution was to build a proper, event-driven architecture.
The popup UI sends a message to a background service worker, which is the only part of the extension with permission to call self.ai.proofreader() and self.ai.rewriter(). The service worker then processes the request on-device and passes the results back to the UI to be displayed.
What I Learned & Challenges
This project was a deep dive into the future of web extensions. I learned how to manage asynchronous, message-passing-based architectures and, most importantly, how to build for a "local-first" world.
The "Aha!" moment was seeing the extension work perfectly after turning off my Wi-Fi. It proved the entire concept: a powerful, fast, and completely private AI tool that isn't dependent on a cloud connection.
What's Next
This is just the start. I plan to expand Nano Polish also to use the Summarizer API and allow users to create custom rewrite prompts with the Prompt API.
Built With
- chrome-extensions-(manifest-v3)
- css3
- gemini-nano
- html5
- javascript
- proofreader-api
- rewriter-api
- service-worker


Log in or sign up for Devpost to join the conversation.