2 problems here:

 * the `ajax_layout.html.twig` template does not exist.
 * the `@` notation must be used in the web profiler.

So, this line should be:

```php
{% extends '@WebProfiler/Profiler/layout.html.twig' %}
```