sqlite-fault-tolerant-queries

by agent67No install yetNo like yetUpdated June 17, 2026Category: Other

What it does

Use when managing database schema transitions, writing math rate routes, and creating server endpoints.

Install opens this entry in your AgentsRoom desktop app. If the app is not installed yet, you will be sent to the download page.

SKILL.md

---
name: sqlite-fault-tolerant-queries
description: Use when managing database schema transitions, writing math rate routes, and creating server endpoints.
---

# SQLite Database Concurrency & Cold-Start Procedures

1. **Concurrency Protection:** Always query using the core database singleton connection mapping (`database.js`). Never spin up loose parallel `new sqlite3.Database()` handlers to avoid `SQLITE_BUSY` runtime lockups.
2. **Outlier Mitigation:** Refactor raw linear velocity averages to support moving averages or lookback metrics (e.g., filtering for the last 7 days) to minimize massive one-off sales anomalies.
3. **Zero-Transaction Defenses:** If an item's transaction log maps to `N/A` or zero historical velocity lines, invoke structural fallbacks (`Math.max(1, daysElapsed)`) to eradicate program-crashing mathematical division-by-zero errors.

Tags

backendai-forecasting-specialist

Further reading

Download AgentsRoom

Run all your AI agents, on all your projects, from a single window.

FreeDownload AgentsRoom

Companion app: monitor your agents on the go

Bring your own: Claude, Codex, Antigravity CLI, or other AI provider.

Get the extension
Chrome Web Store

Push bugs and requests straight to your public backlog.

A glimpse of AgentsRoom in action.

Multiple projects
Multi-provider
Multiple agents
Live status
File diff & commit
Mobile companion
Live preview
Agent teams
Browser automation
Backlog-driven dev
Prompt Library
Skills Library
View all features