Skip to content

Persistent Sequential Compose Agents #574

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 23 commits into
base: main
Choose a base branch
from

Conversation

QuantGeekDev
Copy link

Hey everyone! Here's the persistence feature for sequential workflows (sequential mode in Composer Playground)

This was requested in this issue: #521

Here is a video showcasing the functionality

To test this out:

run docker compose --profile db up -d to set up dev db. make sure Docker Desktop is running if you're on mac or windows.
run mise run beeai-server:db:migrate to run the migrations.
run mise run beeai-server:build
run mise run beeai-ui:build just in case
run mise run beeai-ui:run
open another terminal, run mise run beeai-server:run

Then go to the Compose Playground, and create a sequential agents workflow. Click "Save", and type in a name and description for the workflow.

When you go back to the workflows view, you will be able to see your saved workflow, open it, and run it.

Pending:

  • Set this up to run via the CLI commands

The sequential-agent container is broken. My workaround has been to use an older version in the agent-registry.yaml. To achieve this I modified the github.py file to work with local files. This is out of scope for this PR - but I can add it as a commit if anyone has issues getting this to work in their dev environment

Signed-off-by: Alex Andru <[email protected]>
Signed-off-by: Alex Andru <[email protected]>
@sandijean90
Copy link

Hi Andru,
Thanks so much for this PR — it's impressive, and the video was especially helpful in walking through the feature.

Also really appreciated you jumping into the last community meeting and contributing to the discussion . We just added you to the Contributor Clubhouse on Discord — feel free to jump in and jam with other folks building cool stuff.

Just a quick note: we’re in the middle of our alpha launch right now, so reviews might take a bit longer than usual. That said, we’ve seen the PR and we’re on it.

@QuantGeekDev
Copy link
Author

@sandijean90 Thanks! I'd love to participate with the ACP stuff since it's my area of knowledge but I wanted to enter with something tangential to get more exposure to the inner workings of the beeai-platform. I'll jump onto ACP related issues when I free up some more time

Copy link
Collaborator

@jezekra1 jezekra1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, thanks for the contribution!
Nice feature but I have few notes to the implemetation:

  • we're not using a database to persist data locally, so far we only needed to store a few configuration files and the filesystem has been sufficient
  • beeai-server is aiming to be primarily a lightweight desktop application that is packaged and installed in brew as a python server that is spinning up docker containers on its own, see how we manage telemetry collector. So running docker-compose is not a feasible option, we could run the database as a docker container on start, but:
  • I'd argue that this feature does not justify the addition of a database and if so, we'd probably use sqlite instead of spinning an extra process which takes extra user resources.

We cannot merge this as-is unfortunately, if we add database the proper way to do it is to write database adapter for all the existing repositiories (Provider, Env, Telemetry) and make it optional or configure sqlite in bootstrap.py locally.

There is a certain benefit to yaml files which you can inspect in ~/.beeai though instead of opaque sqlite db file, so I'm not quite certain that we want to go with database for local installation.

@jezekra1
Copy link
Collaborator

jezekra1 commented May 2, 2025

Converting this from open to draft as there is a lot of work to be done if we want to merge this

@jezekra1 jezekra1 marked this pull request as draft May 2, 2025 08:33
@QuantGeekDev
Copy link
Author

Thanks for the feedback - makes sense, went in there blind and made a few choices. I also think that SQLITE is a good option for the system as is. My thinking was that at some point someone will want to deploy this, and having a proper db will be one of the first steps towards turning this into something that can be deployed with multi-tenancy in mind if someone wants it. The current use case is unclear to me- it expects a lot of setup from the user but then gives them a very easy interface for building agents. Perhaps if we move towards deploying this and trying to use this within an org, it's ok to have 1 technical person deploy it and have it be used by non-technical peers. Is this something that has been considered before? Happy to work on the changes. Agree re: docker-compose, this is what I meant by Set this up to run via the CLI commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants