Two critical bug fixes for entity linking: 1. **Path cleaning**: Replace hardcoded "users/jpmschweitzer/" with regex pattern to handle any user namespace. Now properly cleans paths for all users. 2. **Longest-first matching**: Move protected_ranges computation inside entity loop to recompute after each entity is processed. Prevents nested links like [[Machine](/machine) Learning](/ml) when processing multi-word entities. These fixes ensure entity linking works correctly across all users and prevents nested markdown links when entity names overlap. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>