Problem
When running PixelRAG locally, the chat agent can get stuck in a loop:
- Search succeeds but tile images are not readable (too small, or network timeout)
- Agent keeps retrying different tiles, then falls back to non-existent web search/fetch tools
- Each request can take 3+ minutes before completing
Root causes
- No fetch timeouts on API calls — slow networks cause indefinite hangs
- Default API URL uses port 30001, which is blocked by many firewalls (HTTPS port 443 works)
maxTurns: 20 allows excessive retry loops
- System prompt doesn't guide the agent to stop after failed tile reads
- Chat page lacks a Lightbox — clicking tiles navigates to raw tile URLs with no way back
crypto.randomUUID() crashes on LAN IP access (non-secure context)
Fix (PR #49)
- 30s timeouts on both search and tile fetch calls
- Default URL changed to
https://api.pixelrag.ai
maxTurns reduced to 8, prompt updated to limit retries
- Lightbox with Back button added to chat page
crypto.randomUUID() fallback for non-localhost origins
Related
Problem
When running PixelRAG locally, the chat agent can get stuck in a loop:
Root causes
maxTurns: 20allows excessive retry loopscrypto.randomUUID()crashes on LAN IP access (non-secure context)Fix (PR #49)
https://api.pixelrag.aimaxTurnsreduced to 8, prompt updated to limit retriescrypto.randomUUID()fallback for non-localhost originsRelated