inspector-apm / neuron-ai
PHP AI Framework with built-in observability.
1.5.4
2025-03-14 19:15 UTC
Requires
- php: ^8.0
- guzzlehttp/guzzle: ^7.0
- psr/log: ^1.0|^2.0|^3.0
Requires (Dev)
- elasticsearch/elasticsearch: ^7.0|^8.0
- phpunit/phpunit: ^9.0
- symfony/process: ^4.0|^5.0|^6.0|^7.0
Suggests
- elasticsearch/elasticsearch: ^7.0|^8.0
- inspector-apm/inspector-php: ^3.9
- symfony/process: ^4.0|^5.0|^6.0|^7.0
This package is auto-updated.
Last update: 2025-03-14 19:17:11 UTC
README
Neuron AI
Open source framework to integrate AI Agents into your existing PHP application - powered by Inspector.dev
Before moving on, please consider giving us a GitHub star ⭐️. Thank you!
Requirements
- PHP: ^8.0
Install
Install the latest version of the bundle:
composer require inspector-apm/neuron-ai
Create an Agent
Extend NeuronAI\Agent
class to create your own agent:
use NeuronAI\Agent; use NeuronAI\Providers\AIProviderInterface; use NeuronAI\Providers\Anthropic\Anthropic; class MyAgent extends Agent { public function provider(): AIProviderInterface { return new Anthropic( key: 'ANTHROPIC_API_KEY', model: 'ANTHROPIC_MODEL', ); } }
Talk to the Agent
Send a prompt to the agent to get a response from the underlying LLM:
$response = MyAgent::make() ->run( new UserMessage("Hi, I'm Valerio") ); echo $response->getContent(); // Nice to meet you Valerio, how can I help you today?
Official documentation
Go to the official documentation
Contributing
We encourage you to contribute to the development of the Inspector bundle! Please check out the Contribution Guidelines about how to proceed. Join us!
LICENSE
This bundle is licensed under the MIT license.