symfony/models-dev
Symfony integration for models.dev, giving your app structured metadata on AI models—context windows, pricing, and capabilities—via a simple, cacheable service, so you can query and compare providers without hardcoding model specs.
Architecture fit
symfony/models-dev) signals a Symfony-flavored integration for the models.dev catalog — the community-maintained dataset of LLM model metadata (provider, context window, modalities, input/output/cached token pricing). That is a data-access concern, not a framework concern, so the core value should be transportable to Laravel as long as the implementation is not bundle-coupled.Bundle + DI extension + YAML config tree (Symfony-only), or a plain PHP client with PSR-18/PSR-16 dependencies (framework-agnostic)? Laravel is built on Symfony components, but it does not load Symfony bundles; only extra.laravel.providers is auto-discovered. If the useful logic lives inside DependencyInjection/ and Resources/config/, we would be re-implementing the wiring in a Laravel service provider — acceptable, but it must be scoped as work, not assumed free.Integration feasibility
ModelCatalog) so the package is swappable. Transitive dependencies are the real gate: symfony/framework-bundle, symfony/http-client, or symfony/cache contracts would force adapter work (Laravel has its own cache/HTTP layers; symfony/http-client is not a default Laravel dependency).Technical risk
composer.json.Key questions
require constraints, and do they conflict with our Laravel/PHP matrix?Stack fit
composer.json. The package must not require symfony/framework-bundle at runtime for us to adopt it; if it does, we vendor the useful classes behind our own interface rather than installing the bundle.App\Contracts\ModelCatalog with find(string $modelId): ?ModelInfo — so the vendor package is an implementation detail. This is the single highest-leverage decision in the whole integration: it makes abandonment a one-file swap.Migration path
Compatibility
getenv reads at autoload) — these break under Octane and in queued workers.config/ai.php-style files; namespace under config/models-dev.php.Sequencing
composer require on a throwaway branch; inspect composer why/composer show --tree; read the DI/config surface; decide bundle vs. library.ModelCatalog interface, fixture-based tests using a checked-in snapshot.Maintenance
composer outdated watch plus a calendar reminder to review upstream quarterly. If upstream goes quiet for two release cycles, fork into app/Support/ModelsDev and drop the dependency.Support
Scaling
Failure modes
nulls that surface as wrong cost numbers. Mitigate with a schema-version assertion and an alert on deserialization mismatches.unknown handling that fails closed for billing paths and open for display paths.Ramp-up
How can I help you explore Laravel packages today?