In this paper, we investigate the hidden-charm pentaquarks asD ( * ) Λ c andD ( * ) Σ ( * ) c molecules coupled to the five-quark states. Furthermore, we extend our calculations to the hidden-bottom sector. The coupling to the five-quark states is treated as the short range potential, where the relative strength for the meson-baryon channels is determined by the structure of the five-quark states. We found that resonant and/or bound states appear in both the charm and bottom sectors.The five-quark state potential turned out to be attractive and, for this reason, it plays an important role to produce these states. In the charm sector, we need the five-quark potential in addition to the pion exchange potential in producing bound and resonant states, whereas, in the bottom sector, the pion exchange interaction is strong enough to produce states. Thus, from this investigation, it emerges that the hidden-bottom pentaquarks are more likely to form than their hidden-charm counterparts; for this reason, we suggest that the experimentalists should look for states in the bottom sector.