Improve safety and bot test