• Extensions
  • Blomstra Search, an elasticsearch fulltext search extension

where can I test this extension without installing it, Is there any website already using it?

i have checked previous posts and went to https://sorhadi.net/ to check
i picked a line from this discussion
Yediğimizi mide hazmederken karın ağrısı when i search using this search not showing any result.

Does flarum or blomstra/search supports full-sentence search?

https://imgur.io/a/LwziYgK

    Hari try this site; forum.mutluanneleriz.com please don't link, https://blomstra.community also has it running but that dataset is much less. Mutluanneleriz contains gigabytes on data in elastic.

      luceos i have taken this line kaydeden koleksiyonun adını yazsın kaydedeyim and searched, the search is not showing the below mentioned disucssion

      forum.mutluanneleriz.com/?q=kaydeden%20koleksiyonun%20adını%20yazsın%20kaydedeyim
      forum.mutluanneleriz.com/d/798517-trendyol-koleksiyon-sadece-burada-paylasabilirsiniz/11

        Hari looks like it.

        There's definitely room for more tuning and matching mechanisms. I also think it could do with some unit tests. Previous releases of this extension have been mostly about getting data into elastic, improving performance for seeding massive datasets and showing some sensible results.

        5 days later

        Nice plugin. Is it possible to index uploaded PDF files (e.g. uploaded via FoF/Upload extension) this way? Or is there another way to do that?

          avandorp it is possible, but getting there is not done with the flick of a hand. Flarum itself has no mechanism yet to search files, so that would be step 1. Then one would need to sync uploads (or rather their information) to elastic.

          Thanks for the fast answer. Naively I imagined that in uploader I would hook up to the File/WasSaved event and via an ElasticSearch ingester I would put the pdf content into the search index. But being new to Flarum I don't see where I would get the info of where the search would have to point to. Where in Flarum would be the right place to do so?

            avandorp Flarum has Search Sources in js. This source would then be added to search, in addition this search source then would need an endpoint that queries elastic for related resources.

            Ref:

            Also look at how I extended DiscussionSearch endpoint: https://github.com/blomstra/flarum-ext-search/blob/main/src/Api/Controllers/SearchController.php
            Here we are replacing the old search source, you can mimic this by just adding your own files source: https://github.com/blomstra/flarum-ext-search/blob/aabba9c2d0ff90a15be9ddcd1cc257a497d45607/js/src/forum/index.ts#L16

            3 months later

            luceos

            You can try to search for Chinese words, visit this link, copy the "测试中文搜索功能" to your forum, and see if you can only search for a single Chinese word, for example, "孔子" only searches for "孔", "曹操" searches for "" 曹" or "操", "blomstra/search" used to be able to search for phrases, but after the latest update, only a single word can be searched.

              2 months later

              Hi there @luceos this looks like a really useful extension and I am somewhat familiar with setting up Elasticsearch so that's maybe a positive too. Thank you 👏

              We have a new Flarum setup we're really happy with, but we'd like to get search to return posts as results, rather than discussions—if it's just discussions, then it's hard to find the right post. Does Flarum built in search or does your Blomstra Search extension support listing search results as posts?

                attentive it's not possible out of the box, but it could most certainly be added to either. Let me know if you need further help.

                Do you mean "added" as in by forking and altering the code? I could maybe try to do that, I'm a software contractor although PHP is not my thing.

                The reason I ask is that the leading complaint on my newly migrated bulletin board (used to be MyBB) is that when you search for a keyword with the out of the box feature, you can't get a list of posts as the results.

                Since we have a heap of 1,000+ post discussions with repeated keywords, this is a bit of a pain … being able to filter the results by discussion would be terrific too.

                  attentive being able to filter the results by discussion would be terrific too.

                  I think this has been discussed previously as an option for core. A more advanced search component would however be required as currently not even the gambits are visible to users (user:luceos search for instance), a component that will allow searching within discussions would therefor be needed for this change.

                  5 days later

                  Thank you for your responses @matteocontrini and @luceos … yeah I reckon this area will have to see attention longer term for Flarum, I don't think the core search feature is quite good enough currently. We are all loving the platform however (we're using it on our tight-knit, long-lived Arsenal forum that's been going since 2006 or so on an old PHP stack).

                  I am a bit tied up with my day job at the moment, and perhaps will never have time to work on this, but it seems like something that should be doable with the right combination of Elastic indexers, search criteria, etc.

                  3 months later

                  Hi,

                  I using this extension for a 500k messages board. I have indexed all my content with ./flarum blomstra:search:index --recreate, since the rebuild with index creation I have no error in my logs... But I haven't any search result so. My Elastic is open on localhost:9200 and the communication between Flarum and Elastic seem OK. Is there a way to debug index / query ?

                  Hum... After running ./flarum queue:work it seem OK... I must start this like a service ?