Currently, there is no standard way to identify if a block builder has built a block. To find this information out, you need to use a combination of tactics. You can infer some information from the fee recipient; you can query relays to ask questions. But ultimately, there is no standard way to retrieve this information.
Use the block extra data field to identify the block builder and relay. Something simple like reserving some space for each (first 7 bytes for block builder, then 7 bytes for relay from their public keys, perhaps). This could be somewhat enforced by relays that adhere to this ‘standard’ rejecting blocks that do not conform.
It would be relatively easy to implement and would provide block explorers, searchers and infrastructure providers an easy way to indicate to users how a block may have been built and routed.