public function interpretLayout(array $layout)
    {
        $this->assignedModuleKeys = [];

        $modulePresences = $this->modulesInterpreter->interpret();

        $layout = $this->mergeModulePresencesIntoLayout($this->interpretNestedGroupLayout($layout), $modulePresences);

        $layout = new LayoutData([
            'layout'      => $layout,
            'alternative' => $modulePresences->alternative()->toarray(),
        ]);

        $this->filterEmptyGroups($layout);

        return $layout;
    }