Isolate JSON and Lua insertion