I have a plugin where in I have to change the title of the page dynamically by sending parameter to the_title filter

You can use the is_page() function to only change it on a certain page. I’m assuming the slug of your company page is in fact company

add_filter( 'the_title','wpse_277956_the_title', 10, 2 );

function wpse_277956_the_title( $title, $id ){
   if( in_the_loop() && is_page( 'company' ) ) {    
         return bmg_company_detail_shortcode( false, false );
   }
   return $title;
}