Search by

adachsoft / agent-manager-lib

Arkadiusz Adach

Manage AI agent definitions with CRUD, partial updates, cloning, and per-agent tool configurations

Package info

gitlab.com/a.adach/agent-manager-lib

Issues

pkg:composer/adachsoft/agent-manager-lib

Statistics

Installs: 14

Dependents: 1

Suggesters: 0

Stars: 0

v0.1.0 2026-11-27 22:53 UTC

This package is auto-updated.

Last update: 2026-11-27 21:53:34 UTC


README

A framework-independent PHP library for managing AI agent definitions stored by an adachsoft/ai-agent-config-repository implementation. It provides a small public API for application code to create, inspect, search, update, delete, and clone agents, including each agent's tool configuration directory.

Main capabilities

  • Create and retrieve agent definitions.
  • List or search agents by identifier, name, and description.
  • Apply partial updates to existing definitions.
  • Delete an agent definition without deleting its tool configuration directory.
  • Clone an agent definition together with its per-agent tool configuration directory.
  • Use the manager through an interface and construct it with a factory.

Requirements

  • PHP 8.3 or later.
  • An AgentConfigRepositoryInterface implementation from adachsoft/ai-agent-config-repository.
  • A base directory for per-agent tool configuration directories.

Installation

Install the library with Composer:

composer require adachsoft/agent-manager-lib

Your application must also provide an implementation of AgentConfigRepositoryInterface from adachsoft/ai-agent-config-repository and a base directory for per-agent tool configuration directories.

Usage

Create the manager with AgentManagerFactory, then use the returned AgentManagerInterface in your application services. The repository implementation is responsible for storing agent definitions; the supplied base directory is used when cloning per-agent tool configuration.

Integration

use AdachSoft\AgentManagerLib\PublicApi\Factory\AgentManagerFactory;
use AdachSoft\AiAgentConfigRepository\PublicApi\Vo\AgentIdVo;

// $repository is an application-configured AgentConfigRepositoryInterface implementation.
$manager = AgentManagerFactory::create(
    agentConfigRepository: $repository,
    agentToolConfigsBaseDirectory: '/var/lib/my-app/agent-tool-configs',
);

$id = new AgentIdVo('assistant');
$manager->createAgent($id, [
    'name' => 'Assistant',
    'description' => 'Helps users with general questions.',
    // Add the remaining fields required by your repository's agent definition schema.
]);

$agent = $manager->getAgent($id);

See the examples for additional operations and integration notes.