<pattern> {
for $element in collection('corpus-titre-description.udpipe')//p/item/a[4][text()='DET']
let $next_element := $element/parent::item/following-sibling::item[1]/a[4]
let $next_element2 := $next_element/parent::item/following-sibling::item[1]/a[4]
let $next_element3 := $next_element2/parent::item/following-sibling::item[1]/a[4]
return if ($next_element='ADJ' and $next_element2='NOUN' and $next_element3='ADJ' ) 
then <item>{concat($element/preceding-sibling::a[2], ' ', $next_element/preceding-sibling::a[2], ' ', $next_element2/preceding-sibling::a[2], ' ', $next_element3/preceding-sibling::a[2])}</item>
}
</pattern>