Add the small path finder function