[ Case study 01 / 06 ]All work →

InPlaceAI

Instant In-Place Text Formatter & Tone Enhancer

Type
Chrome Extension & Web Platform
Role
Full Stack Developer, Chrome Extension Developer, API Architect, Security Implementation, UI/UX Design
Stack
Chrome MV3, React, Node.js, Express.js, MongoDB

A Chrome extension and cloud backend that refines grammar, tone, and clarity directly inside web form fields and editable inputs without switching tabs or copy-pasting.

02  /  The brief

The business problem

Context

Professionals, job seekers and everyday users write emails, messages and posts directly in browser text fields all day.

Problem

Polishing that text with AI means copying it into a chat tab, waiting, and pasting it back. That breaks focus many times a day, and most people simply don't bother.

Constraints

  1. 01Has to work inside any website's text fields without breaking that site's own styling or scripts
  2. 02Results have to feel instant, or the shortcut is no faster than switching tabs
  3. 03Users' AI API keys must be stored encrypted, never in plain text
  4. 04Must pass Chrome Web Store policy and privacy review to reach users at all

Approach

Moved the AI to where the writing happens: one keyboard shortcut rewrites the current field in place, with a floating toolbar for tone and one-click undo. A bring-your-own-key model on Groq gives sub-second responses and means the product carries no AI inference cost per user.

Outcome

Published on the Chrome Web Store after passing its policy review.

03  /  Overview

About the project

What it is
A Chrome extension with a companion web application that improves grammar, style, and tone directly inside web text inputs and editable fields without tab switching.
Who it’s for
Professionals, writers, job seekers, and daily web users drafting messages, emails, and posts who want quick, private AI text rewriting directly inside their active browser fields.
Why it exists
Copy-pasting drafts between browser tabs and external chat windows creates friction. InPlace AI eliminates context switching by running AI tone shifts and grammar corrections in-place using personal Groq API keys.

04  /  My role

What I built

  • 01

    Extension Architecture

    Engineered Manifest V3 extension with custom Shadow DOM toolbar, hotkey listeners, and multi-tier DOM text injection.

  • 02

    Backend & Security

    Built Express REST API on Vercel with Mongoose connection pooling, JWT authentication, and AES-256-GCM key encryption.

  • 03

    Web Application

    Created Next.js 16 landing and dashboard portal with real-time Groq API rate-limit monitoring and setup guide.

  • 04

    Store Publishing

    Prepared store metadata, visual promotional assets, privacy declarations, and resolved policy reviews for Chrome Web Store approval.

05  /  Capabilities

What it can do

  1. 01In-Place Shortcut Rewriting (Ctrl+Shift+F)
  2. 02Multi-Tone Transformation (Professional, Friendly, Concise)
  3. 03Shadow DOM Floating Toolbar with 1-Click Undo
  4. 04Bring Your Own Key (BYOK) Architecture

06  /  Under the hood

Engineering deep dive

  • The floating toolbar is attached to document.body via an open Shadow Root with an ultra-high z-index (2147483647). Scoped styles prevent host page CSS from distorting toolbar elements and prevent extension styling from leaking into third-party sites.

07  /  Decisions

Challenges and trade-offs

  1. 01

    Challenge

    How to inject an interactive floating toolbar into arbitrary websites without CSS conflicts

    Decision

    Encapsulated the entire toolbar within a Shadow DOM root attached to a top-level host element.

    Trade-off

    Requires manual event binding and style encapsulation inside shadow boundaries, but completely prevents stylesheet collisions with host websites.

  2. 02

    Challenge

    How to avoid unsustainable LLM API costs as the user base grows

    Decision

    Implemented a Bring Your Own Key (BYOK) architecture where users store their own personal Groq keys encrypted with AES-256-GCM.

    Trade-off

    Requires an initial key setup step during onboarding, but eliminates API expenses for the operator and enables sustainable free usage.

  3. 03

    Challenge

    How to secure the serverless backend against unauthorized origins while supporting both web and extension clients

    Decision

    Built custom CORS middleware that strictly matches against the published Chrome extension ID (chrome-extension://cnkjbefikmodehokmediafilhbodogkp) and the verified web portal origin.

    Trade-off

    Requires distinct configuration between development and production, but prevents external web apps from hitting user endpoints.

  4. 04

    Challenge

    Chrome Web Store review rejected the initial release under violation Yellow Argon (Keyword Spam) due to mentions of specific platforms in metadata.

    Solution

    Audited manifest, store description, and code comments to replace third-party brand names with generic capability terms ('Universal Field Compatibility').

    Result

    Passed Chrome Web Store review on version 1.0.1 and successfully published to the store.

  5. 05

    Challenge

    Modern single-page applications (React, Vue) ignored programmatic value changes on form inputs because internal state was not triggered.

    Solution

    Used the native HTMLInputElement.prototype value setter followed by synthetic 'input' and 'change' bubbling events to force framework state reconciliation.

    Result

    Reliable in-place replacement across modern reactive forms and messaging applications.

  6. 06

    Challenge

    Canvas-based editors like Google Docs and Sheets restrict direct DOM text manipulation.

    Solution

    Implemented an automated host check detecting docs.google.com and sheets.google.com, routing improved text to the system clipboard via navigator.clipboard with a copy confirmation panel.

    Result

    Consistent user experience with fallback workflow for non-DOM canvas editors.

08  /  Architecture

System design

  1. 01

    Chrome Manifest V3 architecture featuring a background service worker, popup interface, and injected content script with isolated Shadow DOM host

  2. 02

    Three-tier DOM text injection engine detecting standard input/textarea value setters, contenteditable Range/Selection commands, and clipboard fallback for canvas editors

  3. 03

    Express.js REST API deployed as serverless functions on Vercel with strict CORS checking restricted to the extension origin and web portal

  4. 04

    AES-256-GCM authenticated encryption for user-supplied Groq API keys stored in MongoDB Atlas, decrypted only in volatile memory during inference

  5. 05

    Next.js 16 web app built with React 19 and Tailwind CSS for account authentication, API key management, and real-time Groq quota monitoring

09  /  Performance

What makes it fast

Sub-400ms
inference turnaround powered by Groq LPU acceleration and LLaMA 3.3 70B
Vanilla
JavaScript extension content scripts with zero bundler overhead and minimal memory footprint
Debounced
selection and mouse event listeners to prevent layout recalculation during user scrolling
Mongoose
connection pooling reused across warm Vercel serverless function invocations

10  /  Security

Security model

AES-256-GCM encryption with 32-byte secret key and 12-byte random IVs for user API keys
JWT authentication (HS256) with 24-hour expiration for extension and web sessions
Strict CORS middleware enforcing origin verification against the published Chrome extension ID
Transient in-memory processing with zero database logging of user text or prompt contents

11  /  Deployment

How it ships

  1. 01

    Google Chrome Web Store — Published extension under ID cnkjbefikmodehokmediafilhbodogkp

  2. 02

    Vercel Serverless — Express.js backend running on Vercel with routing configured via vercel.json

  3. 03

    Vercel Edge — Next.js 16 web application deployed with edge asset caching

  4. 04

    MongoDB Atlas — Cloud database cluster with TLS encryption and automatic failover

12  /  Gallery

Screens

Interactive Formatting Demo
Chrome Web Store Feature Tile
Extension Popup & Login
Web Dashboard & Live Quota
BYOK Setup & Key Storage

Architecture diagrams

InPlace AI Architecture & Workflow

13  /  Links

See it for yourself

[ Next project ]

SoulsAnimal Registration & Care Platform