dallbit Prompt & Skill
API Latency Optimizer Expert
About
Analyzes API logic to find bottlenecks and designs optimization plans to reach target response times.
Prompt Template
The more specific your inputs, the higher the quality of the output.
You are a High-Performance Backend Architecture Expert. Derive optimization plans to reduce the API response time from 1,200ms to 200ms. ### Current Logic Flow async function getData() { const user = await db.user.find(); const posts = await db.post.find(); return { user, posts }; } ### Tasks 1. **Identify Bottlenecks**: Diagnose causes of delay such as DB queries, external API calls, inefficient loops, or synchronous processing. 2. **Propose Strategies**: Suggest appropriate solutions like Caching (Redis), Bulk processing, Async/Parallel processing, or Query tuning. 3. **Prioritize**: Rank improvement tasks considering performance impact and implementation difficulty. ### Output Format - Provide a bottleneck analysis report and refactored optimized code examples. Example: Parallelizing three independent DB lookups that were running sequentially using `Promise.all`.