Download the PHP package survos/ai-workflow-bundle without Composer
On this page you can find all versions of the php package survos/ai-workflow-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package ai-workflow-bundle
Survos AI Workflow Bundle
State-bundle workflow primitives for async AI work over any subject.
The bundle defines a small shared lifecycle:
The important split is conceptual:
prepare: make source content and context available.observe: create neutral evidence from the source. For images this is usually thumbnail observation plus optional high-resolution reads; for text it may be dense summaries, language, or structure.analyze: apply application meaning to observed evidence and context.review: app-defined approval after analysis. This can be automatic policy, human review, or another app-specific gate.publish: project the result into fields, indexes, exports, webhooks, or other app outputs.
The bundle does not decide what those transitions do. Applications provide workflow listeners, task policy, and publishing behavior.
The bundle may define reusable tasks and prompt templates. Treat those as a prompt/task repository, not app policy: applications still decide which tasks to queue, when to append follow-up tasks, and what publish means.
Core Classes
Workflow\SubjectFlow: shared state-bundle definition.Contract\WorkflowSubjectInterface: minimal subject id plus queue/lock shape for entities. Claim subject type defaults to the PHP class name.Task\TaskInterface: callable workflow task that returns claims.Task\TaskResult: claims plus optional follow-up tasks.Task\TaskRegistry: lazy task lookup by name.Task\TaskRunner: consumes one queued task and records claims throughsurvos/claims-bundle.
Task outputs are not stored as opaque JSON result blobs. They are recorded as ClaimRun and Claim rows. Apps can still denormalize claim projections onto their own entities during publish.
Queueing Tasks
Applications queue and run tasks from workflow listeners. Use task constants instead of string literals so built-in task names stay refactorable:
TaskRunner::runNext() removes one task from the queue, records claims through survos/claims-bundle, and appends any follow-up tasks returned by the task. For image workflows, EnrichFromThumbnailTask::TASK is usually the first observation task; it can append higher-resolution observation tasks such as OcrMistralTask::TASK or TranscribeHandwritingTask::TASK.
Naming
Inside Survos\AiWorkflowBundle, class names intentionally avoid the Ai prefix where the namespace already carries it:
SubjectFlowTaskInterfaceTaskRegistryTaskRunner
Failure Model
There is no failed place in the initial workflow. Failures should be recorded on task runs, claims, or app-specific fields while the subject remains at its current milestone. Apps can add a failure place later if they need one.
All versions of ai-workflow-bundle with dependencies
survos/state-bundle Version ^2.5
survos/claims-bundle Version ^2.5
symfony/dependency-injection Version ^8.0
symfony/framework-bundle Version ^8.0
symfony/http-client Version ^8.0
symfony/messenger Version ^8.0
symfony/service-contracts Version ^3.6
symfony/twig-bundle Version ^8.0
twig/twig Version ^3.0
symfony/ai-bundle Version ^0.9
symfony/ai-agent Version ^0.9
symfony/ai-open-ai-platform Version ^0.9
symfony/ai-mistral-platform Version ^0.9
survos/data-contracts Version ^2.5