# mike-bronner/laravel-model-caching

Eloquent model-caching made easy.

Repository: https://github.com/mike-bronner/laravel-model-caching
Canonical: https://ross.abutalabs.com/products/laravel-model-caching
Language: PHP
License: MIT
License Family: permissive
Topics: laravel, caching, models, package
Last push: 2026-08-01T15:58:40+00:00

## Health v2 (maintenance only)
Score: 96/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 95, release rhythm 95, longevity 100
- inputs: {"age_days": 3272, "days_push": 32, "days_rel": 32, "gap_med": 7, "n_releases_24m": 20}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2371, forks 228 (observed 2026-08-28T04:06:41.819306+00:00)

## What it is
A Laravel package that adds automatic, self-invalidating caching to Eloquent models and relationships via a trait. It caches query results and flushes relevant cache entries when models are created, updated, or deleted.

## Use cases
- cache eloquent query results automatically
- avoid manual cache invalidation in laravel
- speed up read-heavy laravel pages
- cache model relationships in laravel
- reduce database queries in laravel app
- drop-in caching layer for laravel models

## When to choose
- your laravel app makes many repeated Eloquent queries
- you want caching without manual cache key management
- you need cache entries invalidated automatically on model changes
- you want a drop-in trait-based caching solution

## When to avoid
- you don't use Laravel or Eloquent
- your data changes so frequently that caching offers no benefit
- you need fine-grained custom cache strategies
- you use a cache driver with limited memory and huge datasets

## Facets
- artifact type: library
- maturity: active
- function: caching, orm, database
- domain: web-development, databases, backend, performance
- platform: php
- tags: eloquent, laravel-package, cache-invalidation, query-caching, trait, laravel

## Member repositories
- mike-bronner/laravel-model-caching (main) score 96

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:41.819306+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:35:22.769441+00:00, confidence not recorded.
  - readme: https://github.com/mike-bronner/laravel-model-caching (fetched 2026-08-28T04:06:41.819306+00:00, sha b2dbb20c43d6)
- Data as of 2026-08-30T08:39:29.467469+00:00.
