- How do I install symfony/ai-decart-platform in a Laravel application?
- Install it with composer require symfony/ai symfony/ai-decart-platform, then register the Symfony AI client and Decart provider in a Laravel service provider. Put credentials in config/services.php and .env rather than hardcoding them. There is no Laravel-specific installer or package discovery glue, so expect to write a small binding yourself. The upstream README is a stub, so follow the main Symfony AI documentation for the exact provider registration.
- Is symfony/ai-decart-platform a Laravel package?
- No. It is a Composer-installable Symfony AI platform bridge that adapts Decart's API, notably the Lucy model, to Symfony AI provider contracts. Laravel can use it because Laravel consumes Symfony components, but the integration is indirect and you supply the service provider wiring. Treat it as an adapter dependency, not a Laravel-first SDK.
- Which Decart capabilities does this bridge support, such as streaming, embeddings, or tool calling?
- The package README does not publish a capability matrix, usage example, or configuration reference. You need to inspect the Symfony AI provider contracts and Decart platform docs to confirm whether chat completions, streaming, embeddings, tool calling, or structured output are exposed. Budget a two-to-four day spike rather than assuming parity with other providers. Anything unsupported would require bypassing the bridge and calling Decart directly.
- Which Symfony AI or Laravel versions does symfony/ai-decart-platform require?
- The bridge targets Symfony AI, which is pre-1.0 and has already changed its provider and routing abstractions around v0.8.0. It does not declare Laravel framework constraints because it is not a Laravel package; your Laravel version only needs to support the Symfony components it pulls in. Check the package composer.json and pin exact versions, because floating constraints are risky during pre-1.0 churn.
- How should I configure Decart API credentials in Laravel?
- Add a Decart entry to config/services.php and read the API key from .env, then bind the Symfony AI client and Decart provider in a service provider. Avoid scattering credentials or provider construction across controllers. Follow the main Symfony AI configuration docs because this repository's README does not document the options. Cache the configured client as a singleton so you do not rebuild it per request.
- Should I call the Decart bridge directly from Laravel controllers?
- No. Wrap it behind your own interface, such as AiTextGenerator, and implement that interface with a Decart adapter. This is roughly one day of work and makes provider swaps, fallbacks, and test doubles real instead of theoretical. Controllers should depend on your interface, not on Symfony AI or Decart classes. That keeps the commercial lock-in to Decart separate from your application architecture.
- Is symfony/ai-decart-platform production-ready for a Laravel app?
- Treat it as early-adopter software: the package has minimal adoption signals, and Symfony AI is still pre-1.0. The mitigating factor is that the code lives in the Symfony AI monorepo, so track that repository for issues and releases rather than this release artifact. Pin exact versions, verify the actual current release and cadence, and do vendor diligence on Decart pricing, data handling, and deprecation policy before committing.
- How does the Decart bridge handle HTTP retries, timeouts, and observability in Laravel?
- Symfony AI uses Symfony HttpClient, while many Laravel applications standardize on Guzzle or Illuminate HTTP. That can produce inconsistent retry, timeout, proxy, and tracing behavior for outbound AI traffic. Decide deliberately which HTTP stack owns Decart calls and instrument that path. If you must standardize, wrap the provider behind your own adapter so you can control transport behavior.
- What are alternatives to using symfony/ai-decart-platform in Laravel?
- You can call Decart's API directly with Guzzle or Laravel's HTTP client, use a different Symfony AI provider bridge, or adopt a Laravel-oriented AI package. The bridge's main value is Symfony AI's provider abstraction, which lets you route across multiple backends. If you do not need that portability, a direct client may be simpler but increases Decart-specific coupling.
- How do I test a Laravel integration that uses the Decart bridge?
- Fake your internal AiTextGenerator interface in feature and unit tests so most tests never touch Decart. Add a small contract test suite that exercises the real bridge against a sandbox or recorded responses, and keep live API calls out of CI. Also test timeout and failure paths because the bridge's HTTP behavior may differ from your usual Laravel HTTP fake setup.