Getting the value of a taxonomy term reference field
You get the first item out of ['#items] with a "0":

{{ content.field_rating['#items'].0 }}


To get a field from the taxonomy term, I would use the node object, because you don't know how the render array in content will change if you configure the view mode differently:

{{ node.field_rating.0.entity.term_field.value }}