Skip to main content
Batoi AIF Docs

Laravel and Symfony Adapters

Integrate AIF with Laravel or Symfony without adding framework dependencies to the core.

Version Foundation release Early foundation work Reviewed Jul 21, 2026 Next review Sep 21, 2026

Owner: Batoi Engineering Reviewed by: Batoi AIF Maintainers Source revision: cd680e8

AIF is the public engineering framework. For the managed intelligence capability used across supported Platform and Flex workflows, see Batoi Intelligence.
Browse Batoi AIF Documentation Laravel and Symfony Adapters

Laravel and Symfony Adapters

The AIF repository includes isolated Laravel and Symfony integration packages under examples/laravel and examples/symfony. Each example has its own Composer manifest and tests; neither framework is a core AIF dependency.

Shared Boundary

Controllers, jobs, commands, and message handlers should call AifGateway or AifApi. They should not call provider adapters directly.

Each framework integration is responsible for:

  • loading environment and secret configuration
  • constructing the provider registry
  • resolving authenticated execution context
  • wiring policy, audit, review, evaluation, and metrics adapters
  • exposing host-owned routes and error handling

Laravel

The Laravel example includes a service provider, configuration, controller, routes, and execution-context resolver. Bind the gateway as an application service and resolve caller context from authenticated, trusted server state.

Symfony

The Symfony example includes service configuration, an AIF factory, controller, and execution-context resolver. Register AIF services in the container and keep provider-specific configuration behind environment or secret-management facilities.

The examples are integration references, not required runtime packages. Review the current source in the Batoi AIF repository before adopting them.