Download the PHP package waaseyaa/ai-agent without Composer

On this page you can find all versions of the php package waaseyaa/ai-agent. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package ai-agent

waaseyaa/ai-agent

Layer 5 — AI

Waaseyaa agent runtime: the executor, the run service, the Messenger handler, and the in-process audit-log persistence. This package turns a registered AgentDefinition and an initiator account into a persisted AgentRun with real-time SSE progress, token / cost accounting, HITL approvals, and an append-only audit trail.

Where to start

The canonical doctrine spec is docs/specs/agent-executor.md. It owns the success criteria, NFR thresholds, audit invariants, SSE event vocabulary, HITL state machine, security posture, and the Waaseyaa\AI\Tools\ToolRegistryInterface contract.

For the tool catalogue (8 stock tools + remote MCP source) see packages/ai-tools/README.md.

Surfaces

Surface Entry point Notes
CLI packages/cli/src/Command/Ai/{AiRunCommand,AiPurgeRunsCommand,AiReapStalledRunsCommand}.php bin/waaseyaa ai:run "<prompt>" --inline for sync; omit --inline for async enqueue.
HTTP packages/ai-agent/src/Controller/AgentRunController.php (routes: packages/ai-agent/src/Routing/AgentRouteServiceProvider.php) POST /api/ai/agent/run, GET /api/ai/agent/run/{id}, DELETE /api/ai/agent/run/{id}, POST /api/ai/agent/run/{id}/approve. Per-route capability checks + initiator ownership via AgentRunAccessPolicy.
SSE BroadcastStorage push on agent.run.<id> Consume via GET /broadcast?channels=agent.run.<id>. Events: run_started, iteration, tool_call, tool_result, approval_required, run_completed, run_failed, run_cancelled.
Messenger worker packages/ai-agent/src/Message/{RunAgent,RunAgentHandler}.php Consumes the RunAgent message; CAS-guarded against duplicate delivery (NFR-015).
Scheduler packages/scheduler/src/Schedule/Ai/AgentScheduleEntries.php Daily purge + 5-minute stalled-run reaper.

Bimaaji-backed tools

Four #[AsAgentTool] adapters expose bimaaji's application-graph introspection and validated-mutation surface to the embedded agent runtime. Discovered via the package-manifest compiler; their dependencies (ApplicationGraphGenerator, MutationValidator, PatchGenerator) resolve from the container after BimaajiServiceProvider::register().

Tool name Capability Class Purpose
bimaaji_introspect_graph bimaaji.read Waaseyaa\AI\Agent\Tool\Bimaaji\IntrospectGraphTool Full application-graph snapshot (six default sections).
bimaaji_introspect_section bimaaji.read Waaseyaa\AI\Agent\Tool\Bimaaji\IntrospectSectionTool Section-scoped payload (admin, entities, jsonapi, public_surface, routing, sovereignty).
bimaaji_propose_mutation bimaaji.mutate Waaseyaa\AI\Agent\Tool\Bimaaji\ProposeMutationTool Validate a proposed schema mutation against the current graph; returns the full MutationResult envelope (status + errors).
bimaaji_generate_patch bimaaji.mutate Waaseyaa\AI\Agent\Tool\Bimaaji\GeneratePatchTool Re-validate the request and emit a PatchSet in memory (never touches the filesystem — the consuming agent loop decides what to do with the patches).

Capabilities: bimaaji.read is privileged architectural introspection and should be granted only to authenticated agents that need it; it is not an anonymous-safe capability. bimaaji.mutate is default-off per AD-02 and should be granted only to agents that need to propose schema changes. The mutation tools enforce the deny via AbstractAgentTool::requireCapability(); rejected calls surface as AgentToolResult::error(summary: 'forbidden') and are recorded in the audit log.

Example — run the reference demo agent inline:

bimaaji_demo (packages/ai-agent/tests/Fixture/BimaajiDemoAgent.php) is the test-only reference agent that wires the four tools into a single introspect → propose → generate workflow. Real production agents should mirror its shape — declare the four tool names in tools: and gate the agent on bimaaji.read; per-tool capabilities are enforced inside each tool.

See also:

Extension points

Register agent bundles and tools via attribute discovery — the package-manifest compiler scans both.

After adding new attributes run bin/waaseyaa optimize:manifest (or restart the dev server).

Persisted entities

Entity Purpose
Waaseyaa\AI\Agent\Entity\AgentRun Run record: initiator, bundle snapshot, status, transcript (truncated at the configured cap), token/cost totals, approval state, timestamps.
Waaseyaa\AI\Agent\Entity\AgentAuditLog Append-only event log: one row per provider call / tool call / tool result / approval. Purged only by AiPurgeRunsCommand.

Repositories live in packages/ai-agent/src/Repository/. The legacy in-memory Waaseyaa\AI\Agent\AgentAuditLog value-object list inside AgentExecutor is removed.

Services

Class Role
AgentRunService enqueue() (async path) and runInline() (CLI/dev sync path).
AgentExecutor Per-iteration loop: provider call, tool dispatch via ToolRegistryInterface, HITL gating, cancellation poll.
AgentDefinitionRegistry Resolves AgentDefinition VOs by id.
StalledRunReaper Transitions runs stuck past max_runtime_seconds to failed.
Mcp\McpClientToolSource + StreamableHttpMcpClient Adapts remote MCP servers into the local tool registry; completes initialize/initialized, preserves negotiated protocol + session headers, supports JSON or SSE-framed responses, and applies capability prefix tool.mcp.<server>.<name>.

Quality gates

Every change to this package MUST keep the following green:

Tests:


All versions of ai-agent with dependencies

PHP Build Version
Package Version
Requires php Version >=8.5
symfony/messenger Version ^7.0
symfony/uid Version ^7.0
waaseyaa/access Version ^0.1.0-alpha.302
waaseyaa/ai-observability Version ^0.1.0-alpha.302
waaseyaa/ai-tools Version ^0.1.0-alpha.302
waaseyaa/api Version ^0.1.0-alpha.302
waaseyaa/bimaaji Version ^0.1.0-alpha.302
waaseyaa/audit Version ^0.1.0-alpha.302
waaseyaa/database-legacy Version ^0.1.0-alpha.302
waaseyaa/entity Version ^0.1.0-alpha.302
waaseyaa/entity-storage Version ^0.1.0-alpha.302
waaseyaa/foundation Version ^0.1.0-alpha.302
waaseyaa/http-client Version ^0.1.0-alpha.302
waaseyaa/config Version ^0.1.0-alpha.302
waaseyaa/routing Version ^0.1.0-alpha.302
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package waaseyaa/ai-agent contains the following files

Loading the files please wait ...