freshcrate
Skin:/
Home > Security > agenticchat

agenticchat

Turn natural language into executable code โ€” right in your browser. Lightweight AI chat powered by GPT-4o with sandboxed JavaScript execution.

Why this rank:Recent releaseHealthy release cadenceStrong adoption

Description

Turn natural language into executable code โ€” right in your browser. Lightweight AI chat powered by GPT-4o with sandboxed JavaScript execution.

README

๐Ÿค– Agentic Chat

Turn natural language into executable code โ€” right in your browser.

Azure Static Web Apps CI/CD CodeQL License: MIT HTML5 JavaScript OpenAI GitHub repo size GitHub last commit codecov

A lightweight, zero-dependency chat interface that sends your prompts to GPT-4o, extracts the JavaScript it writes, and executes it in a sandboxed iframe โ€” all from a single HTML file.

Live Demo ยท Report Bug ยท Request Feature


โœจ Features

Core

  • Natural Language โ†’ Code โ€” Ask a question or describe a task in plain English; GPT-4o returns JavaScript that gets executed automatically
  • Sandboxed Execution โ€” Generated code runs in an <iframe sandbox="allow-scripts"> with no access to the parent page's DOM, cookies, localStorage, or variables
  • Content Security Policy โ€” The sandbox iframe enforces default-src 'none'; connect-src https: so code can call external APIs but nothing else
  • Nonce Validation โ€” Each execution gets a crypto.randomUUID() nonce to prevent stale or replayed postMessage events
  • Multi-Model Support โ€” Switch between GPT-4o, GPT-4o-mini, GPT-4-turbo, and more via the model selector
  • API Key Management โ€” Detects YOUR_API_KEY placeholders in generated code and prompts for credentials per domain; keys are cached per session

Conversation Management

  • Conversation History โ€” Maintains a sliding window of up to 20 message pairs with automatic trimming and token-count warnings
  • Multi-Session โ€” Create, switch between, rename, and delete multiple conversation sessions with auto-save
  • Cross-Tab Sync โ€” Detects concurrent edits across browser tabs via BroadcastChannel
  • Conversation Fork โ€” Branch conversations from any message into new sessions
  • Chapters โ€” Insert named section dividers with a table-of-contents sidebar
  • Tags โ€” Colored tag labels on sessions with filtering and management
  • Auto-Tagger โ€” Heuristic topic detection and automatic tag suggestions

Search & Navigation

  • Message Search โ€” Full-text search across conversation messages with highlighting
  • Global Session Search โ€” Search across all saved sessions at once
  • Conversation Timeline โ€” Visual minimap sidebar for conversation navigation
  • Bookmarks & Pinning โ€” Bookmark messages for quick reference; pin important ones to a floating bar
  • Slash Commands โ€” /-triggered command dropdown with autocomplete and keyboard navigation

Productivity

  • Prompt Templates โ€” Built-in library of categorized prompt templates with search filtering
  • Snippet Library โ€” Save, tag, search, rename, and re-run generated code snippets
  • Quick Replies โ€” Contextual follow-up suggestion chips after AI responses
  • Formatting Toolbar โ€” Markdown formatting buttons above the chat input
  • Scratchpad โ€” Persistent notepad panel with copy/insert/download actions
  • Input History โ€” Navigate previous prompts with โ†‘/โ†“ arrow keys
  • File Drop Zone โ€” Drag-and-drop file inclusion (text-based files, 100 KB limit)
  • Focus Mode โ€” Distraction-free zen mode (Ctrl+Shift+F)

Analysis & Insights

  • Chat Stats โ€” Conversation analytics: word counts, code blocks, response timing
  • Cost Dashboard โ€” Persistent API spend tracker with budget alerts and daily chart
  • Message Diff โ€” Compare any two messages with visual line-level diff
  • Conversation Summarizer โ€” Heuristic summary with topics, decisions, and action items
  • Response Time Badge โ€” Per-response latency indicator

Personalization

  • Persona Presets โ€” Switchable system prompt presets with custom persona support
  • Theme Manager โ€” Dark/light theme with OS preference detection
  • Keyboard Shortcuts โ€” Global shortcuts with help modal
  • Voice Input โ€” Browser speech recognition with language selection
  • Read Aloud โ€” Text-to-speech for messages with voice/speed controls

Data

  • Message Annotations โ€” Private notes/annotations on messages with labels
  • Message Reactions โ€” Per-message emoji reactions with persistent counts
  • Data Backup โ€” Full backup/restore for all 21 data keys (export/import/selective/merge)
  • Zero Dependencies โ€” Single HTML file + CSS + JS. No build tools, no npm, no bundler. Just open and go.
  • Input Guardrails โ€” Character limit (50K chars), token estimate warnings (~80K threshold), real-time counter

AI & Reliability

  • Response Rating โ€” Thumbs up/down ratings on AI responses with model satisfaction dashboard
  • Smart Retry โ€” Automatic retry with exponential backoff for transient API failures
  • Message Editor โ€” Edit and resend user messages (truncates history and reloads into input)
  • Message Translator โ€” Inline message translation to 20+ languages via OpenAI API
  • Conversation Merge โ€” Combine 2+ sessions into one merged conversation with chronological interleaving
  • Conversation Replay โ€” Message-by-message playback with transport controls (play/pause/speed)
  • Prompt Library โ€” User-created prompt snippets with folders, search, usage tracking, import/export
  • Usage Heatmap โ€” GitHub-style 7x24 activity heatmap across all sessions
  • Word Cloud Generator โ€” interactive word frequency cloud from conversation with 5 color schemes, PNG download (Alt+W)

๐Ÿš€ Getting Started

Prerequisites

  • A modern web browser (Chrome, Firefox, Safari, Edge)
  • An OpenAI API key with GPT-4o access

Usage

  1. Open index.html in your browser โ€” or visit the live demo
  2. Paste your OpenAI API key into the key field (stored in memory only, never persisted)
  3. Type a question or task and press Enter
  4. Watch the generated code and its output appear in the console area
> "What's the current UTC time?"
โ†’ GPT-4o generates: return new Date().toUTCString();
โ†’ Output: Fri, 14 Feb 2026 10:00:00 GMT

> "Fetch the top Hacker News story"
โ†’ GPT-4o generates fetch() code targeting the HN API
โ†’ Output: { title: "...", url: "..." }

๐Ÿ—๏ธ How It Works

User Prompt  โ†’  GPT-4o (system prompt: reply with JS only)
                    โ†“
             Markdown response with ```js code block
                    โ†“
             Regex extraction of JavaScript
                    โ†“
             Sandboxed iframe execution
                    โ†“
             postMessage with nonce-validated result
                    โ†“
             Display output in console area
  1. A system prompt instructs GPT-4o to respond exclusively with JavaScript in a fenced code block
  2. The app extracts the code using regex and delivers it to a sandboxed iframe via postMessage (not template interpolation โ€” preventing script-tag injection)
  3. The iframe executes the code with new Function() inside an async wrapper
  4. Results are returned via postMessage with origin validation ('null' for sandboxed iframes) and nonce matching

Modules

The codebase is organized into 49 IIFE modules in app.js, each using the revealing-module pattern:

Core (7 modules)
Module Purpose
SafeStorage Safe localStorage wrapper for restricted-storage environments
ChatConfig Frozen constants โ€” model list, pricing, token limits, system prompt
ConversationManager Message history with sliding window trimming and token estimation
SandboxRunner Iframe sandbox lifecycle, execution, timeout, cancellation
ApiKeyManager OpenAI + per-service key storage, substitution, validation
UIController All DOM manipulation โ€” button states, modals, output
ChatController Orchestrates send flow: input โ†’ API โ†’ code extraction โ†’ sandbox
Features (42 modules)
Module Purpose
PromptTemplates Categorized prompt library with search and one-click insert
HistoryPanel Slide-out conversation history with Markdown/JSON export/import
SnippetLibrary Persistent code snippet storage with tagging and search
MessageSearch Full-text search across conversation messages
ChatBookmarks Bookmark individual messages for quick reference
SlashCommands Slash-command dropdown with autocomplete and keyboard nav
MessageReactions Per-message emoji reactions with persistent counts
KeyboardShortcuts Global keyboard shortcuts with help modal
VoiceInput Browser speech recognition with language selection
ThemeManager Dark/light theme with OS preference detection
SessionManager Multi-session persistence with auto-save and quota management
CrossTabSync Multi-tab conflict detection via storage events + BroadcastChannel
ChatStats Conversation analytics (word counts, code blocks, timing)
CostDashboard Persistent API spend tracker with budget alerts and daily chart
PersonaPresets Switchable system prompt presets with custom persona support
ModelSelector Model picker with localStorage persistence
FileDropZone Drag-and-drop file inclusion (text-based files, 100 KB limit)
FocusMode Distraction-free zen mode (Ctrl+Shift+F)
InputHistory Navigate previous prompts with โ†‘/โ†“ arrow keys
Scratchpad Persistent notepad panel with copy/insert/download actions
ResponseTimeBadge Response time indicator below token usage area
ConversationFork Branch conversations from any message into new sessions
QuickReplies Contextual follow-up suggestion chips after AI responses
MessagePinning Pin important messages to a floating quick-jump bar
ReadAloud Text-to-speech for messages with voice/speed controls
MessageDiff Compare any two messages with visual line-level diff
ConversationTimeline Visual minimap sidebar for conversation navigation
ConversationSummarizer Heuristic conversation summary with topics and action items
MessageAnnotations Private notes/annotations on messages with labels
ConversationChapters Named section dividers with TOC navigation
ConversationTags Colored tag labels on sessions with filtering and management
FormattingToolbar Markdown formatting buttons above chat input
GlobalSessionSearch Full-text search across all saved sessions
AutoTagger Heuristic topic detection and automatic tag suggestions
DataBackup Full backup/restore for all user data (21 keys, export/import)
ResponseRating Thumbs up/down ratings on AI responses with model satisfaction dashboard
ConversationMerge Combine 2+ sessions into one merged conversation (chronological interleave)
ConversationReplay Message-by-message playback with transport controls
PromptLibrary User-created prompt snippets with folders, search, usage tracking, import/export
MessageTranslator Inline message translation to 20+ languages via OpenAI API
MessageEditor Edit and resend user messages (truncate history + reload into input)
SmartRetry Automatic retry with exponential backoff for transient API failures
UsageHeatmap GitHub-style 7x24 activity heatmap across all sessions
SmartPaste Intelligent paste formatting โ€” auto-detects JSON, code, CSV, SQL, URLs, stack traces

๐Ÿ”’ Security Model

The app executes AI-generated code, so security is a first-class concern:

Layer Protection
Iframe Sandbox sandbox="allow-scripts" โ€” no DOM access, no cookies, no localStorage, no same-origin
CSP default-src 'none'; connect-src https: โ€” only outbound HTTPS allowed
Origin Check postMessage validated against 'null' origin (sandboxed iframe)
Nonce crypto.randomUUID() ties each execution to its result, preventing replay
Code Delivery Code sent via postMessage, not embedded in HTML (prevents </script> injection)
API Key Isolation OpenAI key stored in parent JS variable only โ€” never exposed to sandbox

โš ๏ธ Known Limitations

  • Outbound HTTPS is allowed โ€” The sandbox CSP includes connect-src https: so LLM-generated code can call external APIs. This is required for the core use case but means sandbox code can make network requests.
  • Service API keys are injectable โ€” When you provide a third-party API key (e.g., weather API), it's injected into sandbox code. A prompt injection attack could theoretically exfiltrate it. Your OpenAI key is safe (parent page only).

๐Ÿ› ๏ธ Tech Stack

Component Technology
Frontend Vanilla HTML5 + CSS + JavaScript (single file)
AI Model OpenAI GPT-4o via REST API
Sandbox HTML5 iframe sandbox with CSP
Hosting GitHub Pages
CI/CD GitHub Actions
Security CodeQL analysis

๐Ÿ“ Project Structure

agenticchat/
โ”œโ”€โ”€ index.html              # Single-page UI with CSP headers
โ”œโ”€โ”€ app.js                  # All application logic (48 modular IIFEs)
โ”œโ”€โ”€ style.css               # Responsive dark-theme styling
โ”œโ”€โ”€ package.json            # npm metadata + test scripts
โ”œโ”€โ”€ jest.config.js          # Jest test configuration
โ”œโ”€โ”€ Dockerfile              # Multi-stage container build
โ”œโ”€โ”€ CONTRIBUTING.md         # Contribution guidelines
โ”œโ”€โ”€ LICENSE                 # MIT License
โ”œโ”€โ”€ README.md               # This file
โ”œโ”€โ”€ docs/
โ”‚   โ””โ”€โ”€ index.html          # API reference & architecture docs (GitHub Pages)
โ”œโ”€โ”€ tests/
โ”‚   โ”œโ”€โ”€ setup.js                  # DOM mocking & app.js loader for jsdom
โ”‚   โ”œโ”€โ”€ app.test.js               # Core module tests (800+)
โ”‚   โ”œโ”€โ”€ annotations.test.js       # MessageAnnotations tests
โ”‚   โ”œโ”€โ”€ auto-tagger.test.js       # AutoTagger tests
โ”‚   โ”œโ”€โ”€ chapters.test.js          # ConversationChapters tests
โ”‚   โ”œโ”€โ”€ conversation-merge.test.js # ConversationMerge tests
โ”‚   โ”œโ”€โ”€ conversation-replay.test.js # ConversationReplay tests
โ”‚   โ”œโ”€โ”€ conversation-tags.test.js # ConversationTags tests
โ”‚   โ”œโ”€โ”€ cost-dashboard.test.js    # CostDashboard tests
โ”‚   โ”œโ”€โ”€ data-backup.test.js       # DataBackup tests
โ”‚   โ”œโ”€โ”€ formatting-toolbar.test.js # FormattingToolbar tests
โ”‚   โ”œโ”€โ”€ message-editor.test.js    # MessageEditor tests
โ”‚   โ”œโ”€โ”€ message-translator.test.js # MessageTranslator tests
โ”‚   โ”œโ”€โ”€ messagediff.test.js       # MessageDiff tests
โ”‚   โ”œโ”€โ”€ model-compare.test.js     # ModelCompare tests
โ”‚   โ”œโ”€โ”€ modules.test.js           # Module existence/integration tests
โ”‚   โ”œโ”€โ”€ pinning.test.js           # MessagePinning tests
โ”‚   โ”œโ”€โ”€ prompt-library.test.js    # PromptLibrary tests
โ”‚   โ”œโ”€โ”€ readaloud.test.js         # ReadAloud tests
โ”‚   โ”œโ”€โ”€ response-rating.test.js   # ResponseRating tests
โ”‚   โ”œโ”€โ”€ smart-retry.test.js       # SmartRetry tests
โ”‚   โ”œโ”€โ”€ summarizer.test.js        # ConversationSummarizer tests
โ”‚   โ”œโ”€โ”€ timeline.test.js          # ConversationTimeline tests
โ”‚   โ””โ”€โ”€ usageHeatmap.test.js      # UsageHeatmap tests
โ””โ”€โ”€ .github/
    โ”œโ”€โ”€ copilot-instructions.md    # Copilot coding agent context
    โ”œโ”€โ”€ copilot-setup-steps.yml    # Copilot agent setup workflow
    โ”œโ”€โ”€ dependabot.yml             # Automated dependency updates
    โ”œโ”€โ”€ labeler.yml                # Auto-label configuration
    โ”œโ”€โ”€ PULL_REQUEST_TEMPLATE.md   # PR template
    โ”œโ”€โ”€ ISSUE_TEMPLATE/
    โ”‚   โ”œโ”€โ”€ bug_report.yml         # Bug report form
    โ”‚   โ”œโ”€โ”€ feature_request.yml    # Feature request form
    โ”‚   โ””โ”€โ”€ config.yml             # Issue template config
    โ””โ”€โ”€ workflows/
        โ”œโ”€โ”€ ci.yml                 # Build + test + lint
        โ”œโ”€โ”€ codeql.yml             # CodeQL security scanning
        โ”œโ”€โ”€ docker.yml             # Docker build & push
        โ”œโ”€โ”€ labeler.yml            # Auto-labeler workflow
        โ”œโ”€โ”€ pages.yml              # GitHub Pages deployment
        โ”œโ”€โ”€ publish.yml            # npm package publishing
        โ””โ”€โ”€ stale.yml              # Stale issue/PR management

๐ŸŒ Browser Compatibility

Browser Version Status Notes
Chrome 90+ โœ… Full Recommended โ€” best sandbox + speech API support
Firefox 88+ โœ… Full Voice input requires media.navigator.enabled
Safari 15+ โœ… Full Minor speech recognition differences
Edge 90+ โœ… Full Chromium-based, same as Chrome
Opera 76+ โœ… Full Chromium-based
Mobile Chrome 90+ โš ๏ธ Partial Voice input may require user gesture; layout adapts
Mobile Safari 15+ โš ๏ธ Partial sandbox iframe works but some CSP edge cases exist

Requirements: All browsers must support crypto.randomUUID() (HTTPS or localhost only), iframe sandbox, and BroadcastChannel. No polyfills needed for modern browsers.

โ“ Troubleshooting

"Failed to fetch" or network errors when sending prompts
  • Verify your OpenAI API key is valid and has GPT-4o access
  • Check that your API key has sufficient credits/quota
  • Ensure you're not behind a corporate proxy that blocks api.openai.com
  • Try switching to a different model (e.g., GPT-4o-mini) in the model selector
Generated code doesn't execute / "Sandbox error"
  • The sandbox iframe blocks DOM access by design โ€” code that references document, window.location, or localStorage will fail
  • Code can only make outbound HTTPS requests (connect-src https:)
  • Check the browser console for CSP violation messages
  • If you see timeout errors, the generated code may be stuck in an infinite loop
Voice input not working
  • Speech recognition requires HTTPS (or localhost) โ€” it won't work over plain HTTP
  • Firefox: ensure media.navigator.enabled is true in about:config
  • Safari: grant microphone permission when prompted
  • Some browsers require a user gesture (click) to activate the microphone
Data lost between sessions
  • All data is stored in localStorage โ€” clearing browser data will erase it
  • Use the Data Backup feature (Settings โ†’ Backup) to export your data regularly
  • localStorage has a ~5 MB limit per origin โ€” the quota indicator in Settings shows usage
  • Cross-tab sync uses BroadcastChannel; if you edit in two tabs simultaneously, the last write wins
Cost dashboard shows unexpected charges
  • The cost tracker estimates based on token counts and published OpenAI pricing
  • Actual billing may differ slightly due to system prompt tokens and retry attempts
  • Reset the tracker via Settings โ†’ Cost Dashboard โ†’ Reset
  • Set a budget alert threshold to get warnings before hitting your limit

๐Ÿค Contributing

Contributions are welcome! Here's how:

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'feat: add amazing feature')
  4. Push to your branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Guidelines

  • This is a single-file app โ€” keep it that way unless there's a compelling reason to split
  • All 49 modules live in app.js as revealing-module IIFEs
  • Security is paramount โ€” any change that touches the sandbox must be reviewed carefully
  • Test with various prompt types before submitting (simple questions, API calls, error cases)

๐Ÿ“„ License

Distributed under the MIT License. See LICENSE for details.


Release History

VersionChangesUrgencyDate
v2.46.0# Agentic Chat v2.46.0 โ€” Deadline-tracker perf, SW LRU bound, sandbox hardening, README badge refresh This release rolls up 10 commits since **v2.45.0** focused on performance, security hardening, test repair, and developer ergonomics. ## โšก Performance - **deadline-tracker:** `_save()` is now only invoked when `_checkUrgent` actually mutated state, eliminating a chatty write loop on every render. (#156, `2179559`) - **service worker:** `_lastRevalidated` is now a bounded **LRU of 512 entries**High5/20/2026
v2.44.0# Agentic Chat v2.44.0 โ€” Action Items, Conversation DNA, Learning Tracker & Cleaner Escapes A meaty release: three new autonomous "Smart*" modules, a perf pass on the learning tracker, shared HTML-escape consolidation across three more IIFEs, plus code coverage tooling and on-page SEO. ## โœจ New autonomous modules - **SmartActionItemExtractor** โ€” surfaces concrete commitments, TODOs, and next-steps from the live conversation; owner/confidence/kind heuristics so the panel is actionable instHigh5/17/2026
v2.43.0## What's New ### โœจ Features - **SmartIntentAligner** โ€” autonomous intent alignment verification engine with 7 analysis engines (topic drift, scope mismatch, constraint violation, format mismatch, depth mismatch, hallucination risk, relevance decay), composite 0-100 alignment scoring, corrective prompt generation, 4-tab panel, and floating badge. Shortcut: Ctrl+Shift+Y. 53 tests. - **SmartConversationWeather** โ€” weather-metaphor conversation health tracker with 6 atmosphere dimensions, 5 weathHigh5/2/2026
v2.42.0## โœจ New Features - **SmartGoalTracker** โ€” Autonomous goal extraction and progress tracking (Alt+Shift+G) - **SmartPatternAutomator** โ€” Workflow pattern detection and automation engine (Alt+Shift+J) - **SmartCognitiveLoad** โ€” Autonomous cognitive load monitor with overwhelm detection (Alt+Shift+L) - **SmartAdaptiveTone** โ€” Communication style profiler and tone adapter (Alt+Shift+Y) ## ๐Ÿ”’ Security - Route SmartFactMemory, SmartPatternAutomator, SmartConversationOracle, SmartGoalTracker, SmartAHigh5/1/2026
v2.40.0## What's New ### โœจ Smart Conversation Digest (Alt+Shift+J) Cross-session summary panel that analyzes all saved sessions and produces structured summaries: - Overview stats (session count, message count, sentiment) - Top topics extracted via TF-IDF tokenization - Action items detected from conversation patterns - Unresolved questions with heuristic answer-matching - Per-session breakdown with sentiment indicators - Markdown export for offline review - Today/7-day/30-day time windows ### ๐ŸŒฟ ConHigh4/25/2026
v2.32.0## What's New ### โœจ Features - **Smart Conversation Memory** โ€” autonomous cross-session knowledge base that surfaces relevant context from past conversations - **Smart Session Prioritizer (Alt+Shift+P)** โ€” intelligently rank and surface your most important sessions ### โšก Performance - **Spatial grid index for WordCloud** โ€” O(1) collision detection replaces O(placed) linear scan via 64px grid partitioning - **Pre-compiled RegExp in ModelAdvisor** โ€” eliminates up to 39 RegExp allocations per \_aHigh4/22/2026
v2.31.0## What's New ### โœจ Features - **Conversation Momentum Tracker** (Alt+Shift+M) โ€” real-time visualization of conversation pacing and engagement dynamics ### โšก Performance - Cached related-messages and follow-ups in SmartContextSidebar, cached anchor TF-IDF vector and topics in ConversationDriftDetector โ€” eliminates O(M) token-scoring on every MutationObserver fire - Cached entity extraction and stats in SmartContextSidebar render path โ€” avoids O(Mร—L) regex+concat work during streaming - Single-High4/21/2026
v2.30.0## What's New ### โœจ Smart Model Advisor (Alt+Shift+A) Proactive model recommendation engine that analyzes your conversation patterns and suggests optimal model switches based on task complexity, token usage, and response quality. ### โœจ Smart Context Sidebar (Alt+Shift+I) Proactive intelligence panel that surfaces relevant context, suggestions, and insights alongside your conversations in real time. ### โšก Performance - **Allocation-free sentiment scoring** in MoodRing and ConversationSentimentHigh4/21/2026
v2.29.0## What's New ### โœจ Smart Context Compressor (Alt+Shift+C) Intelligent context window management that compresses conversation history while preserving key information โ€” keeps conversations going longer without losing important context. ### โšก Performance - **Single-loop word counting** in ChatStats and ConversationSummarizer โ€” replaces multi-pass array allocations with a single iteration, reducing GC pressure on long conversations. **Full Changelog**: https://github.com/sauravbhattacharya001/aHigh4/20/2026
v2.28.4## What's Changed ### Refactor - **Extract SSE line parser and unify streaming/non-streaming API call paths** โ€” Consolidates duplicate SSE parsing logic into a shared parser module, reducing code duplication across streaming and non-streaming call paths. Both paths now share the same robust line-parsing pipeline. (7f4a1c7) ### Performance - **Eliminate throwaway array allocations in hot paths** โ€” Replaces temporary array allocations (spreads, slices, intermediate maps) in frequently-called funHigh4/20/2026
v2.28.3## What's Changed ### Refactoring - **UsageHeatmap**: Use cached data in render/export paths; remove dead code in ConversationSentiment - **DOMCache**: Fix stale/null cache entries with WeakRef validation for safer DOM element reuse ### Performance - **SessionLinker**: Cache TF-IDF index to avoid redundant recomputation across linked-session lookups ### Documentation - Overhaul README to reflect 94 modules, add keyboard shortcuts reference **Full Changelog**: https://github.com/sauravbhattacHigh4/19/2026
v2.28.2## Security ### ConversationAutopilot Hardening - Use ApiKeyManager.getOpenAIKey() instead of reading raw DOM input value, preventing API key exposure via DOM inspection - Add rate limiter (5s minimum between API calls) to prevent rapid-fire spend - Cap 'unlimited' step mode to 50 steps max to prevent unbounded API cost ### ConversationShareLink DoS Protection - Cap decoded JSON payload to 5 MB and encoded base64 to ~7 MB before processing - Limit messages to 200 max and per-message content toHigh4/17/2026
v2.28.1## What's Changed ### CI/CD - **Bump actions/upload-pages-artifact from v4 to v5** โ€” keeps GitHub Pages deployment on the latest stable action version (#150) ### Maintenance - **Improved Dependabot config** โ€” grouped Actions dependency updates for cleaner PRs; added ignore rule to block Docker base image major version bumps that could break builds **Full Changelog:** https://github.com/sauravbhattacharya001/agenticchat/compare/v2.28.0...v2.28.1High4/16/2026
v2.28.0## What's New ### โœจ Features - **Conversation Drift Detector** โ€” proactive topic coherence monitoring alerts when conversations stray off-topic - **Conversation Mood Ring** โ€” real-time sentiment monitor accessible via Alt+M shortcut - **Smart Session Linker** โ€” TF-IDF cosine similarity discovers related sessions (Alt+L) - **Conversation Autopilot** โ€” goal-directed autonomous exploration mode ### โ™ป๏ธ Refactoring - Extracted shared TextAnalytics module from duplicated NLP code across features - RHigh4/16/2026
v2.27.0## What's Changed ### Performance Improvements - **CostDashboard**: Add in-memory cache for cost log entries, eliminating redundant file reads on repeated dashboard opens - **SessionNotes**: Cache \_loadAll()\ results to avoid redundant JSON parsing when notes haven't changed - **SmartTitle**: Cache \generate()\ results to skip redundant regex work for previously-seen inputs All three changes reduce UI latency during normal usage by avoiding repeated I/O and computation for data that rarely chHigh4/5/2026
v2.26.0## What's New ### โœจ Features - **Word Cloud Generator (Alt+W)** โ€” Interactive word frequency visualization with 5 color schemes, spiral placement, and PNG export - **Prompt Enhancer (Alt+E)** โ€” AI-powered prompt improvement with 5 enhancement modes (Clarity, Detail, Concise, Expert, Creative) and word-level diff highlighting ### โšก Performance - **Service worker async/await refactor** โ€” Cleaner cache-first flow with properly awaited client notifications - **MessageScheduler precision timer** โ€” Medium4/5/2026
v2.25.0## What's New in v2.25.0 ### Features - **ConversationScreenshot** โ€” Export any chat as a shareable PNG image for easy sharing and archiving ### Performance - **Debounced annotation badge rendering** with incremental processing for smoother UI updates ### Security - **Non-root nginx container** โ€” Docker nginx now runs as a non-root user for improved container security ### Code Quality - **Refactor:** Extract diff row styling into a data-driven \DIFF_STYLES\ config for easier customization Medium4/4/2026
v2.24.0## What's New ### โœจ Features - **Voice Chat Mode** โ€” hands-free conversational loop activated with Alt+V. Speak, get AI responses read aloud, and continue the conversation without touching the keyboard. - **Conversation Stash** โ€” git-stash-style save/restore for conversations (Ctrl+Shift+Z). Quickly shelve your current conversation, switch context, then pop it back when ready. ### โšก Performance - **Single-pass MessageFilter** โ€” counts and cached UsageHeatmap data reduce redundant iterations ovMedium4/3/2026
v2.23.1## Security - **Fix IncognitoMode privacy leak in SafeStorage** โ€” Previously, only SessionManager respected incognito mode. 48+ other modules (DraftRecovery, Bookmarks, Reactions, ClipboardHistory, Annotations, ConversationTags, etc.) still wrote directly to localStorage, leaking user data during 'private' sessions. All SafeStorage writes now route through an incognito-aware layer that uses volatile in-memory storage when incognito mode is enabled. **Full Changelog**: https://github.com/sauravMedium4/3/2026
v2.23.0## What's New ### โœจ Features - **Sticky Notes Board** โ€” visual draggable brainstorming canvas accessible via Alt+N (#2e26209) ### โšก Performance - Passive event listeners + rAF-throttled scroll lock for smoother UI (#05adbce) - O(1) budget checks in CostDashboard via incremental running totals (#b1c0792) - Eliminate redundant data scanning in UsageHeatmap and ConversationHealthCheck (#3a879ce) ### ๐Ÿ”ง Refactoring - Extract ToastManager utility โ€” deduplicate 4 toast notification implementations Medium4/2/2026
v2.22.0## โœจ New Features - **Ambient Sound Player** โ€” procedural background soundscapes for focus (Alt+A) - **API Inspector** โ€” debug panel for API request/response logging - **Message Reply/Quote** โ€” reply to specific messages with context - **ScrollLock** โ€” suppress auto-scroll when reading history ## ๐Ÿ”’ Security - Harden nginx config with server-level CSP and fix header inheritance - Add Referrer-Policy, Permissions-Policy, X-Content-Type-Options headers - Remove unsafe localStorage API key fallbacMedium4/2/2026
v2.21.0## What's Changed ### โšก Performance - **Batch timeline refresh DOM writes** โ€” uses DocumentFragment to minimize reflows during timeline refresh operations, improving rendering performance ### ๐Ÿ“š Documentation - **36 undocumented modules added to docs site** โ€” comprehensive documentation coverage for previously undocumented modules **Full Changelog**: https://github.com/sauravbhattacharya001/agenticchat/compare/v2.20.0...v2.21.0Medium4/1/2026
v2.20.0## What's New ### โฑ๏ธ Conversation Timer - **Per-session active time tracking** โ€” see how long you've been actively chatting in each session - Toggle with **Alt+T** keyboard shortcut - Tracks active engagement time, not idle time **Full Changelog:** https://github.com/sauravbhattacharya001/agenticchat/compare/v2.19.0...v2.20.0Medium3/31/2026
v2.19.0## What's New ### โœจ Features - **Message Reply/Quote** โ€” reply to specific messages with context threading - **Incognito Mode** โ€” private sessions with Alt+I shortcut - **Smart Auto-Rename** โ€” sessions automatically rename after the first assistant reply ### โšก Performance - **Batch streaming DOM writes** โ€” token rendering uses requestAnimationFrame for smoother streaming ### ๐Ÿ› Fixes - Allow microphone for VoiceInput + migrate DOM lookups to DOMCache - Migrate 6 modules from raw localStorage Medium3/31/2026
v2.18.0## What's Changed ### Refactoring - **SmartPaste & MessageContextMenu**: Reduced duplication across paste handling and context menu modules - **MessageDiff**: Migrated to shared \createModalOverlay\ helper; fixed redundant DOMCache ternary patterns ### Documentation - **ConversationSessions & FocusMode**: Added comprehensive JSDoc annotations covering all public methods, parameters, and return types **Full Changelog**: https://github.com/sauravbhattacharya001/agenticchat/compare/v2.17.0...vMedium3/30/2026
v2.17.0## What's Changed ### Refactoring - **Migrated body-level MutationObservers to shared ChatOutputObserver** โ€” consolidates scattered DOM observation logic into a single, efficient observer pattern, reducing redundant observers and improving maintainability. **Full Changelog**: https://github.com/sauravbhattacharya001/agenticchat/compare/v2.16.0...v2.17.0Medium3/30/2026
v2.16.0## What's Changed ### Security - Sanitize shared conversation URL data against prototype pollution - Replace inline onclick handlers with event delegation in PinBoard (XSS fix) - Resolve dependency vulnerabilities in brace-expansion and picomatch - Add Referrer-Policy, Permissions-Policy, X-Content-Type-Options headers; remove unsafe localStorage API key fallback ### Performance - Skip HistoryPanel.refresh() DOM rebuild when panel is closed - Avoid innerHTML += in renderStats and PersonaPresetMedium3/30/2026
v2.15.1## What's Changed ### Security - Added Referrer-Policy, Permissions-Policy, and X-Content-Type-Options headers - Removed unsafe localStorage API key fallback ### CI - Fixed copilot-setup-steps.yml: use workflow_dispatch trigger, clean up lint step **Full Changelog**: https://github.com/sauravbhattacharya001/agenticchat/compare/v2.15.0...v2.15.1Medium3/29/2026
v2.15.0## What's New ### โœจ Features - **Conversation Share Link Generator** โ€” press Alt+S to generate a shareable link for the current conversation - **ScrollLock** โ€” auto-scroll is now suppressed when you're reading history, so new messages won't yank you away ### โšก Performance - **Pre-compiled topic keyword regexes** in ConversationChapters.suggestTitle for faster title suggestions ### ๐Ÿ”ง Fixes - **Pages deployment workflow** improvements for more reliable GitHub Pages builds **Full Changelog**: Medium3/29/2026
v2.14.0## What's New ### ๐Ÿ”’ Security - **Lock down sandbox CSP** to prevent API key exfiltration (#120) - **Prevent prototype pollution** in ChatGPT conversation importer (#128) - **Fix XSS in custom theme handling** (#112) - **Fix XSS in stats panel and theme creator** (#95) - **Replace inline onclick handlers** with addEventListener for CSP compliance (#90) - **Prevent \\$\-pattern injection** in API key substitution (#86) - **Add client-side rate limiter** to prevent API budget drain (#117) - **ResMedium3/28/2026
v2.13.0## What's Changed ### Performance - **Throttle SW background revalidation** โ€” Service worker now rate-limits background cache revalidation to avoid redundant fetch storms on page load ### Refactoring - **Consolidate OpenAI API calls** โ€” All OpenAI fetch logic now routes through the shared \OpenAIClient\ module, reducing duplication and making API key/endpoint management consistent - **Remove duplicate PomodoroTimer** โ€” Eliminated redundant timer module; \FocusTimer\ already covers the same fMedium3/28/2026
v2.12.0## What's New ### โœจ Message Highlighter - **Select and highlight text** in any chat message with customizable colors - Keyboard shortcut: **Alt+H** to activate highlight mode - Useful for marking important parts of AI responses or noting key information ### Full Changelog - \5d97014\ feat: add Message Highlighter โ€” select and highlight text in messages with colors (Alt+H) **Full Changelog**: https://github.com/sauravbhattacharya001/agenticchat/compare/v2.11.0...v2.12.0Medium3/27/2026
v2.11.0## What's New in v2.11.0 ### โœจ Features - **Mood Tracker** โ€” Real-time conversation sentiment analysis that visualizes the emotional tone of your chats - **ChatGPT Conversation Import** โ€” Import your existing ChatGPT conversation history directly into AgenticChat - **Conversation Export** โ€” Export conversations in multiple formats: Markdown, Text, HTML, and JSON ### โšก Performance - **Consolidated MutationObservers** โ€” Merged 7 separate MutationObservers into a single ChatOutputObserver, signifMedium3/27/2026
v2.10.0## What's New ### โœจ Features - **PDF Export for Conversations** โ€” Export any chat conversation to a formatted PDF document for archiving or sharing ### ๐Ÿ”’ Security - **HSTS & COOP headers** โ€” Added HTTP Strict-Transport-Security and Cross-Origin-Opener-Policy headers for enhanced browser security - **Production file integrity** โ€” Fixed missing production files to ensure complete deployments ## Full Changelog https://github.com/sauravbhattacharya001/agenticchat/compare/v2.9.0...v2.10.0Medium3/27/2026
v2.9.0## What's Changed ### Refactored - **Extracted shared OpenAIClient module** โ€” Eliminated duplicated API fetch calls across the codebase by centralizing all OpenAI API interactions into a single, reusable \OpenAIClient\ module. This reduces code duplication, makes API configuration changes easier, and provides a single point for error handling and retry logic. **Full Changelog**: https://github.com/sauravbhattacharya001/agenticchat/compare/v2.8.0...v2.9.0Medium3/26/2026
v2.8.0## What's New ### โœจ Features - **Notification Sound** โ€” Background tab chime when AI responds, so you never miss a reply - **Message Translator** โ€” Translate any message to 29 languages via OpenAI API ### ๐Ÿ”’ Security - Escape HTML in CommandPalette \_highlightMatch\ to prevent XSS injection ### ๐Ÿ›  Improvements - Extract \createModalOverlay\ helper to DRY up 3 inline-styled modal patterns - Add Node compatibility matrix and security audit CI jobs - Add browser compatibility table and troubleshMedium3/26/2026
v2.7.0## What's New ### Message Scheduler (Alt+Q) Queue messages with a configurable delay for automatic sending. Useful for timed prompts and batch workflows. ### Emoji Picker (Ctrl+Shift+;) Full emoji picker with category browsing, fuzzy search, and recent emoji tracking. Click or keyboard-navigate to insert. ### Security Hardening - Tightened sandbox iframe CSP policy - API keys are now scrubbed from memory on page unload to prevent leakage via crash dumps or dev tools ### Service Worker Auto-UMedium3/25/2026
v2.6.0## What's New ### โœจ Features - **Typing Indicator** โ€” Animated bubble shows when AI is generating a response - **Pin Board** (Alt+P) โ€” Pin important messages across sessions for quick reference - **Word Cloud Generator** (Alt+W) โ€” Visualize conversation topics at a glance - **Session Calendar** (Alt+C) โ€” Browse and navigate sessions by date - **Session Archive** โ€” Declutter the sessions panel by archiving old conversations - **Response Length Presets** (Alt+L) โ€” Control AI response verbosity (bMedium3/24/2026
v2.5.0## What's New ### Message Diff Viewer - **Compare any two messages** with word-level diff highlighting - Select two messages and instantly see additions (green) and deletions (red) - Useful for tracking how AI responses evolve or comparing similar messages **Full Changelog**: https://github.com/sauravbhattacharya001/agenticchat/compare/v2.4.0...v2.5.0Low3/22/2026
v2.4.0## What's New ### โœจ Features - **Message Reader View** โ€” full-width overlay for comfortable reading of long messages (#1e9ba14) ### ๐Ÿ› Fixes - **SafeStorage in ModelCompare & TextExpander** โ€” use consistent safe storage abstraction instead of raw localStorage (#2862957) ### โšก Performance - **Remove duplicate DOMContentLoaded init** โ€” eliminated redundant initialization for OfflineManager and TextExpander (#40c779d) ### ๐Ÿ“š Documentation - **Docs site improvements** โ€” added search, back-to-topLow3/21/2026
v2.3.0## What's New ### โœจ Text Expander Define shorthand triggers that auto-expand inline as you type. Create custom abbreviations for frequently used prompts, code snippets, or boilerplate text. Supports dynamic placeholders and multi-line expansions. **Full Changelog:** https://github.com/sauravbhattacharya001/agenticchat/compare/v2.2.0...v2.3.0Low3/21/2026
v2.2.0## What's New ### โœจ Features - **SmartScroll** โ€” Floating jump-to-latest button with unread badge and per-session scroll memory - **Prompt A/B Tester** โ€” Compare two model responses side-by-side (Ctrl+Shift+B) ### ๐Ÿ”’ Security - Prototype pollution protection added to SafeStorage.getJSON ### ๐Ÿงช Testing - Comprehensive SessionManager test suite **Full Changelog**: https://github.com/sauravbhattacharya001/agenticchat/compare/v2.1.0...v2.2.0Low3/20/2026
v2.1.0## What's New in v2.1.0 A massive feature release with 30+ new features, performance improvements, security fixes, and quality-of-life enhancements since v2.0.0. ### โœจ New Features - **Command Palette** โ€” VS Code-style universal command launcher (Ctrl+Shift+P) - **Split View** โ€” Side-by-side session comparison (Ctrl+Shift+2) - **Custom Theme Creator** โ€” Interactive theme builder with 8 presets (Nord, Dracula, Monokai, Solarized, Gruvbox, Catppuccin, High Contrast) - **Smart Paste** โ€” Auto-forLow3/20/2026
v2.0.0# AgenticChat v2.0.0 **103 commits** since v1.0.0 โ€” the biggest release yet. ## โœจ New Features (43) ### Core Chat - **Streaming responses** โ€” token-by-token display - **Model selector** dropdown - **System prompt presets** (personas) - **Voice Input** โ€” speech-to-text via Web Speech API - **Keyboard shortcuts** with help modal - **Drag-and-drop file input** for including file contents - **Focus/Zen Mode** โ€” distraction-free interface - **Input history** โ€” navigate previous prompts with โ†‘/โ†“ - Low3/8/2026
v1.0.0# AgenticChat v1.0.0 The first stable release of AgenticChat โ€” a lightweight browser-based chat interface that turns natural language prompts into executable JavaScript, powered by OpenAI GPT-4o. ## โœจ Features - **Natural Language โ†’ Code**: Chat with GPT-4o and execute generated JavaScript directly in the browser - **Sandboxed Execution**: Code runs in an isolated iframe sandbox with CSP protections to prevent XSS, API key theft, and cross-origin attacks - **Conversation History**: Maintains Low2/15/2026

Dependencies & License Audit

Loading dependencies...

Similar Packages

WeKnoraLLM-powered framework for deep document understanding, semantic retrieval, and context-aware answers using RAG paradigm.v0.6.1
ai-test-case๐Ÿค– Generate automated test cases for your GitHub repositories using AI, ensuring comprehensive coverage with seamless integration and multi-language support.main@2026-06-06
ai-notes-apiNo descriptionmaster@2026-06-06
local-ai-devenv๐Ÿค– Automate coding, testing, and deployment with a local AI environment powered by a team of intelligent agents.main@2026-06-06
VSCode-Local-CopilotNo descriptionmain@2026-06-05

More in Security

clineAutonomous coding agent right in your IDE, capable of creating/editing files, executing commands, using the browser, and more with your permission every step of the way.
E2BOpen-source, secure environment with real-world tools for enterprise-grade agents.
OpenSandboxSecure, Fast, and Extensible Sandbox runtime for AI agents.
vm0the easiest way to run natural language-described workflows automatically