I’d see this to be implemented in Lemmy itself. Hashtags are a global thing, not instance-specific, and should already be available to Lemmy via AP.
Lemmy would “just” need the ability to display a hashtag as a “community” containing posts made under that hashtag. Question is what to do with replies but given Lemmys design, they could probably simply be left out because, if it’s truly on-topic, the post will likely contain the hashtag too and therefore land in the hashtag “community”.