PHPackages                             dimakornev13/explorer - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Search &amp; Filtering](/categories/search)
4. /
5. dimakornev13/explorer

ActiveLibrary[Search &amp; Filtering](/categories/search)

dimakornev13/explorer
=====================

Next-gen Elasticsearch driver for Laravel Scout.

4.1.0(1y ago)0300MITPHPPHP ^8.2

Since Oct 31Pushed 8mo agoCompare

[ Source](https://github.com/dimakornev13/Explorer)[ Packagist](https://packagist.org/packages/dimakornev13/explorer)[ Docs](https://jeroen-g.github.io/Explorer/)[ RSS](/packages/dimakornev13-explorer/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (13)Versions (39)Used By (0)

Explorer
========

[](#explorer)

[![Latest Version on Packagist](https://camo.githubusercontent.com/9736a2aae650d1e91c45f4e6f2da1145ade02b517f3935416c973b3a733e45ca/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6a65726f656e2d672f6578706c6f7265722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/jeroen-g/explorer)

[![CI](https://github.com/Jeroen-G/Explorer/actions/workflows/ci.yml/badge.svg)](https://github.com/Jeroen-G/Explorer/actions/workflows/ci.yml)

Next-gen Elasticsearch driver for Laravel Scout with the power of Elasticsearch's queries.

Installation
------------

[](#installation)

Via Composer

```
composer require jeroen-g/explorer
```

You will need the configuration file to define your indexes:

```
php artisan vendor:publish --tag=explorer.config
```

Also do not forget to follow the [installation instructions for Laravel Scout](https://laravel.com/docs/scout#installation), and in your Laravel Scout config, set the driver to `elastic`.

Usage
-----

[](#usage)

Be sure to also have a look at the [docs](docs/index.md) to see what is possible! There is also a [demo app](https://github.com/Jeroen-G/explorer-demo) available that might be insightful.

### Configuration

[](#configuration)

You may either define the mapping for you index in the config file:

```
return [
    'indexes' => [
        'posts_index' => [
            'properties' => [
                'id' => 'keyword',
                'title' => 'text',
            ],
        ]
    ]
];
```

Or you may define the model for the index, and the rest will be decided for you:

```
return [
    'indexes' => [
        \App\Models\Post::class
    ],
];
```

In the last case you may implement the `Explored` interface and overwrite the mapping with the `mappableAs()` function.

Essentially this means that it is up to you whether you like having it all together in the model, or separately in the config file.

### Advanced queries

[](#advanced-queries)

The documentation of Laravel Scout states that "more advanced "where" clauses are not currently supported". Only a simple check for ID is possible besides the standard fuzzy term search:

```
$posts = Post::search('lorem ipsum')->get();
```

Explorer expands your possibilities using query builders to write more complex queries.

For example, to get all posts that:

- are published
- have "lorem" somewhere in the document
- have "ipsum" in the title
- maybe have a tag "featured", if so boost its score by 2

You could execute this search query:

```
$posts = Post::search('lorem')
    ->must(new Matching('title', 'ipsum'))
    ->should(new Terms('tags', ['featured'], 2))
    ->filter(new Term('published', true))
    ->get();
```

### Commands

[](#commands)

Be sure you have configured your indexes first in `config/explorer.php` and run the Scout commands.

#### Searching indexes

[](#searching-indexes)

```
php artisan elastic:search "App\Models\Post" lorem
```

Changelog
---------

[](#changelog)

Please see the [changelog](changelog.md) for more information on what has changed recently.

Credits
-------

[](#credits)

- [Jeroen](https://github.com/jeroen-g)
- [Vincent](https://github.com/blackshadev)
- [All Contributors](../../contributors)

License
-------

[](#license)

MIT. Please see the [license file](license.md) for more information.

###  Health Score

43

—

FairBetter than 91% of packages

Maintenance54

Moderate activity, may be stable

Popularity11

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity78

Established project with proven stability

 Bus Factor1

Top contributor holds 65% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~50 days

Recently: every ~120 days

Total

36

Last Release

263d ago

Major Versions

v1.2.0 → v2.0.02021-05-07

2.5.1 → 3.0.02022-03-11

2.6.0 → 3.2.02022-07-08

3.15.0 → 4.0.02025-01-05

PHP version history (5 changes)v1.0.0PHP ^7.4|^8.0

3.0.0PHP 8.0.\*||8.1.\*

3.4.0PHP 8.0.\*||8.1.\*||8.2.\*

3.11.0PHP 8.0.\*||8.1.\*||8.2.\*||8.3.\*

4.0.0PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/e87a31b60fa7bf6fd4df8f133233aeabfe7473f003f921476ba1a33696f6f5a9?d=identicon)[moxyrus](/maintainers/moxyrus)

---

Top Contributors

[![Jeroen-G](https://avatars.githubusercontent.com/u/1116853?v=4)](https://github.com/Jeroen-G "Jeroen-G (292 commits)")[![blackshadev](https://avatars.githubusercontent.com/u/2979104?v=4)](https://github.com/blackshadev "blackshadev (80 commits)")[![a-drew](https://avatars.githubusercontent.com/u/6550234?v=4)](https://github.com/a-drew "a-drew (14 commits)")[![4ice](https://avatars.githubusercontent.com/u/6935261?v=4)](https://github.com/4ice "4ice (7 commits)")[![askdkc](https://avatars.githubusercontent.com/u/7894265?v=4)](https://github.com/askdkc "askdkc (6 commits)")[![AiAe](https://avatars.githubusercontent.com/u/3695158?v=4)](https://github.com/AiAe "AiAe (5 commits)")[![jackbayliss](https://avatars.githubusercontent.com/u/13621738?v=4)](https://github.com/jackbayliss "jackbayliss (4 commits)")[![enrise-mbraam](https://avatars.githubusercontent.com/u/118975804?v=4)](https://github.com/enrise-mbraam "enrise-mbraam (4 commits)")[![JakubMerkandi](https://avatars.githubusercontent.com/u/145023659?v=4)](https://github.com/JakubMerkandi "JakubMerkandi (4 commits)")[![Ar0010r](https://avatars.githubusercontent.com/u/47714178?v=4)](https://github.com/Ar0010r "Ar0010r (4 commits)")[![quintenbuis](https://avatars.githubusercontent.com/u/36452184?v=4)](https://github.com/quintenbuis "quintenbuis (3 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (3 commits)")[![dimakornev13](https://avatars.githubusercontent.com/u/56150953?v=4)](https://github.com/dimakornev13 "dimakornev13 (3 commits)")[![thecaliskan](https://avatars.githubusercontent.com/u/13554944?v=4)](https://github.com/thecaliskan "thecaliskan (3 commits)")[![bartjuh4](https://avatars.githubusercontent.com/u/245335?v=4)](https://github.com/bartjuh4 "bartjuh4 (2 commits)")[![Xammie](https://avatars.githubusercontent.com/u/13081809?v=4)](https://github.com/Xammie "Xammie (1 commits)")[![alevani](https://avatars.githubusercontent.com/u/28229423?v=4)](https://github.com/alevani "alevani (1 commits)")[![allankeller](https://avatars.githubusercontent.com/u/1382174?v=4)](https://github.com/allankeller "allankeller (1 commits)")[![AndersMagnusson-AngryCreative](https://avatars.githubusercontent.com/u/59443484?v=4)](https://github.com/AndersMagnusson-AngryCreative "AndersMagnusson-AngryCreative (1 commits)")[![chrsz](https://avatars.githubusercontent.com/u/16120752?v=4)](https://github.com/chrsz "chrsz (1 commits)")

---

Tags

searchlaravelelasticsearchelasticexplorerscout

###  Code Quality

TestsPHPUnit

Code StyleECS

### Embed Badge

![Health badge](/badges/dimakornev13-explorer/health.svg)

```
[![Health](https://phpackages.com/badges/dimakornev13-explorer/health.svg)](https://phpackages.com/packages/dimakornev13-explorer)
```

###  Alternatives

[jeroen-g/explorer

Next-gen Elasticsearch driver for Laravel Scout.

397612.3k](/packages/jeroen-g-explorer)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
