help@rskworld.in +91 93305 39277
RSK World
  • Home
  • Development
    • Web Development
    • Mobile Apps
    • Software
    • Games
    • Project
  • Technologies
    • Data Science
    • AI Development
    • Cloud Development
    • Blockchain
    • Cyber Security
    • Dev Tools
    • Testing Tools
  • About
  • Contact

Theme Settings

Color Scheme
Display Options
Font Size
100%
Back to Project
RSK World
voice-assistant-chatbot
RSK World
voice-assistant-chatbot
Voice Assistant Chatbot - JavaScript + Web Speech API + Speech Recognition + Text-to-Speech + Voice Commands + AI
voice-assistant-chatbot
  • .gitignore470 B
  • DATA_STORAGE.md6.2 KB
  • ERROR_FIXES.md4.1 KB
  • GITHUB_RELEASE_INSTRUCTIONS.md5.9 KB
  • LICENSE1.2 KB
  • README.md8.1 KB
  • RELEASE_NOTES.md6.5 KB
  • config.js2.3 KB
  • index.html7 KB
  • script.js41.6 KB
  • styles.css9.7 KB
DATA_STORAGE.md
DATA_STORAGE.md
Raw Download

DATA_STORAGE.md

# Data Storage Information

<!--
Voice Assistant Chatbot - Data Storage Documentation
Developed by: RSK World
Website: https://rskworld.in
Email: help@rskworld.in
Phone: +91 93305 39277
Year: 2026
-->

## Where Data is Saved

All data is stored in your browser's **localStorage**, which is a browser-based storage mechanism that persists data even after you close the browser.

### Storage Location

**Browser localStorage** - Data is stored locally in your browser, not on any server.

### Data Stored

The application stores three types of data:

#### 1. Settings (`voiceAssistantSettings`)
- **Storage Key**: `voiceAssistantSettings`
- **Data Saved**:
- Voice selection
- Speech rate (0.5 - 2.0)
- Pitch (0 - 2.0)
- Volume (0 - 1.0)
- Language selection
- Continuous listening mode (on/off)
- Auto-speak responses (on/off)
- Show audio visualizer (on/off)
- Dark mode (on/off)
- **Persistence**: ✅ Saved automatically, persists across sessions
- **Location**: Browser's localStorage

#### 2. Conversation History (`voiceAssistantHistory`)
- **Storage Key**: `voiceAssistantHistory`
- **Data Saved**:
- All user messages
- All bot responses
- Timestamps for each message
- Message types (user/bot)
- **Persistence**: ✅ Saved automatically after each message
- **Location**: Browser's localStorage
- **Note**: Keeps last 50 messages if storage quota is exceeded

#### 3. Statistics (`voiceAssistantStats`)
- **Storage Key**: `voiceAssistantStats`
- **Data Saved**:
- Total messages count
- User messages count
- Bot messages count
- Voice interactions count
- Session start time
- **Persistence**: ✅ Saved automatically every 10 seconds and on updates
- **Location**: Browser's localStorage

## How to Access Stored Data

### Method 1: Browser Developer Tools

1. **Open Developer Tools**:
- Press `F12` or `Ctrl+Shift+I` (Windows/Linux)
- Press `Cmd+Option+I` (Mac)
- Or right-click → Inspect

2. **Go to Application/Storage Tab**:
- Click on "Application" tab (Chrome/Edge)
- Or "Storage" tab (Firefox)
- Expand "Local Storage"
- Click on your website URL

3. **View Data**:
- You'll see three keys:
- `voiceAssistantSettings`
- `voiceAssistantHistory`
- `voiceAssistantStats`
- Click on any key to view its JSON data

### Method 2: Export Feature

Use the **Export** button in the chatbot interface to download your conversation history as a text file.

### Method 3: JavaScript Console

Open browser console (F12) and run:

```javascript
// View settings
console.log(JSON.parse(localStorage.getItem('voiceAssistantSettings')));

// View conversation history
console.log(JSON.parse(localStorage.getItem('voiceAssistantHistory')));

// View statistics
console.log(JSON.parse(localStorage.getItem('voiceAssistantStats')));
```

## Data Privacy

- ✅ **All data is stored locally** in your browser
- ✅ **No data is sent to any server**
- ✅ **No external API calls** for data storage
- ✅ **Complete privacy** - your conversations stay on your device

## Clearing Data

### Clear All Data

1. **Using Browser Settings**:
- Go to browser settings
- Privacy/Security section
- Clear browsing data
- Select "Cookies and other site data"
- Choose time range
- Click "Clear data"

2. **Using Developer Tools**:
- Open Developer Tools (F12)
- Go to Application/Storage tab
- Right-click on Local Storage
- Select "Clear"

3. **Using the Chatbot**:
- Click "Clear Chat" button
- Confirm the action
- This clears conversation history and resets statistics

### Clear Specific Data

In browser console (F12):

```javascript
// Clear settings
localStorage.removeItem('voiceAssistantSettings');

// Clear conversation history
localStorage.removeItem('voiceAssistantHistory');

// Clear statistics
localStorage.removeItem('voiceAssistantStats');

// Clear all chatbot data
localStorage.removeItem('voiceAssistantSettings');
localStorage.removeItem('voiceAssistantHistory');
localStorage.removeItem('voiceAssistantStats');
```

## Storage Limits

- **localStorage Limit**: Typically 5-10 MB per domain
- **Automatic Management**: If storage is full, the app keeps only the last 50 messages
- **Warning**: If you see storage errors, consider clearing old data

## Data Format

### Settings Format
```json
{
"voice": "Google US English",
"rate": 1.0,
"pitch": 1.0,
"volume": 1.0,
"language": "en-US",
"continuousMode": false,
"autoSpeak": true,
"showVisualizer": false,
"darkMode": false
}
```

### Conversation History Format
```json
[
{
"type": "user",
"message": "Hello",
"timestamp": "2026-01-04T10:30:00.000Z"
},
{
"type": "bot",
"message": "Hello! How can I assist you?",
"timestamp": "2026-01-04T10:30:01.000Z"
}
]
```

### Statistics Format
```json
{
"totalMessages": 10,
"userMessages": 5,
"botMessages": 5,
"voiceInteractions": 3,
"sessionStartTime": 1704366000000
}
```

## Backup and Restore

### Backup Data

1. Export conversation history using the Export button
2. Or copy data from browser console:
```javascript
// Copy to clipboard
navigator.clipboard.writeText(localStorage.getItem('voiceAssistantHistory'));
```

### Restore Data

In browser console:
```javascript
// Restore conversation history
localStorage.setItem('voiceAssistantHistory', 'YOUR_JSON_DATA_HERE');

// Then refresh the page
location.reload();
```

## Troubleshooting

### Data Not Persisting
- Check if localStorage is enabled in your browser
- Check browser storage permissions
- Try clearing browser cache and reloading

### Storage Full Error
- Clear old conversation history
- Use the Export feature to save important conversations
- Clear browser data if needed

### Data Lost After Browser Update
- Browser updates sometimes clear localStorage
- Always export important conversations
- Consider using browser sync features (if available)

## Contact

For questions about data storage:
- **Website**: https://rskworld.in
- **Email**: help@rskworld.in
- **Phone**: +91 93305 39277

---

© 2026 RSK World. All rights reserved.

About RSK World

Founded by Molla Samser, with Designer & Tester Rima Khatun, RSK World is your one-stop destination for free programming resources, source code, and development tools.

Founder: Molla Samser
Designer & Tester: Rima Khatun

Development

  • Game Development
  • Web Development
  • Mobile Development
  • AI Development
  • Development Tools

Legal

  • Terms & Conditions
  • Privacy Policy
  • Disclaimer

Contact Info

Nutanhat, Mongolkote
Purba Burdwan, West Bengal
India, 713147

+91 93305 39277

hello@rskworld.in
support@rskworld.in

© 2026 RSK World. All rights reserved.

Content used for educational purposes only. View Disclaimer