Skip to content
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

Add file upload/extension support in .yaml #56

Open
george-lhj opened this issue Dec 13, 2024 · 8 comments
Open

Add file upload/extension support in .yaml #56

george-lhj opened this issue Dec 13, 2024 · 8 comments
Assignees
Labels
enhancement New feature or request mas Multiagent system and orchestration
Milestone

Comments

@george-lhj
Copy link
Collaborator

Currently in the UI, I need to pass in files into the agents (.pkl and .txt) into the query in order to have the necessary context; so something like this.
Screenshot 2024-12-13 at 11 52 39 AM

We need to add functionality to be able to do this through the .yaml file so that we can directly go through the terminal and call all the agents sequentially without the need for the UI.

Not sure if this should be in POC0/1.

@george-lhj george-lhj added enhancement New feature or request help wanted Extra attention is needed labels Dec 13, 2024
@george-lhj george-lhj added this to the POC0 milestone Dec 13, 2024
@psschwei
Copy link
Collaborator

For now, to handle passing files between agents we should create a working directory for each run (say, /tmp/weather-job/run_234r2342) and assume all agents can read/write in that directory.

@maximilien maximilien self-assigned this Jan 7, 2025
@maximilien
Copy link
Member

OK, taking this to complement issue #27. The proposal as we left it in December is to provide a working directly for agents. By convention and default, I propose the directory to be:

/<TMP>/bee-hive/<workflow_name>__ # the __ is there to prevent collision

We can also include a way to override this in the workflow.

LMK if you agree @psschwei and @developer-gliu and will close this and add that to the issue #27

@george-lhj
Copy link
Collaborator Author

the naming convention is fine w/me. But the overall issue for this still isn't solved for now I think.

Even when we create a tmp file holder location, we need to be able to actually upload these files and let it read as context for the agent. I've been looking for examples but there doesn't seem to have a single one (although Paul did find one that can successfully output a file for the answer through api that I got working). As a workaround for the demo, I have just been reading this files into the agent and using threading, but this isn't scalable

@george-lhj
Copy link
Collaborator Author

george-lhj commented Jan 7, 2025

the naming convention is fine w/me. But the overall issue for this still isn't solved for now I think.

Even when we create a tmp file holder location, we need to be able to actually upload these files and let it read as context for the agent. I've been looking for examples but there doesn't seem to have a single one (although Paul did find one that can successfully output a file for the answer through api that I got working). As a workaround for the demo, I have just been reading this files into the agent and using threading, but this isn't scalable

saw on stack overflow that if you want to upload a file to OpenAI, you need to pass it in as a prompt and as text(as of March last year ). I'm not sure if that's still true. Since Bee is built on top and has mostly the same functionality, that means we would have to read these files in as text to the prompt, and use threading to keep track of all the context/prompts throughout the session.

@psschwei
Copy link
Collaborator

psschwei commented Jan 7, 2025

provide a working directly for agents [...] /<TMP>/bee-hive/<workflow_name>__ [...] LMK if you agree

that location is fine with me

we need to be able to actually upload these files and let it read as context for the agent. I've been looking for examples but there doesn't seem to have a single one

I believe this can be done via the UI, so it in theory should be possible... we may need to ask the framework team for guidance.

if you want to upload a file to OpenAI, you need to pass it in as a prompt and as text [...] Since Bee is built on top and has mostly the same functionality

@developer-gliu good to know and something we should keep in mind for the python version of the framework (cc @vabarbosa)

@planetf1
Copy link
Collaborator

planetf1 commented Jan 9, 2025

The framework currently seems to use the /api/v1/files endpoint

I've not tried this myself

@psschwei psschwei modified the milestones: POC0, POC1, POC2 Jan 14, 2025
@maximilien
Copy link
Member

maximilien commented Jan 22, 2025

OK. Let me see what I can do to add this to #27

@maximilien maximilien added mas Multiagent system and orchestration and removed help wanted Extra attention is needed labels Jan 22, 2025
@maximilien
Copy link
Member

@george-lhj , can we close this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request mas Multiagent system and orchestration
Projects
None yet
Development

No branches or pull requests

4 participants