feat: Add 0G plugin for file storage
This PR adds a new plugin for 0G.
Risks
Low. This change involves adding a new plugin, which is isolated and should not affect existing functionality.
Background
What does this PR do?
This PR adds a new plugin for 0G, which includes an action that allows users to upload local files to 0G Storage. Future work will include extending 0G support for model serving, state persistence via KV store, and enhanced file management capabilities.
What kind of change is this?
Features (non-breaking change which adds functionality).
Why are we doing this? Any context or related work?
To extend the functionality of Eliza.
Documentation changes needed?
Require a change to the project documentation.
Testing
Where should a reviewer start?
The review can start with the new 0G plugin code, focusing on the action that uploads files to ensure it handles files correctly and integrates well with 0G Storage.
Detailed testing steps
-
Set Environment Variables
Configure the following variables:
ZEROG_INDEXER_RPCZEROG_EVM_RPCZEROG_PRIVATE_KEYZEROG_FLOW_ADDRESSMore details
-
Add 0g-plugin into character file Ensure the
@ai16z/plugin-0gis properly added and configured in the character file.
- Interact with the Agent
Send a message to the agent: Upload the file at /path/to/your/file.txt to zg storage.
Screenshots
Before
After
Database changes
Deployment instructions
Hey @Wilbert957 Great work!
There are conflicts that needs to be resolved before a merge could happen, could you fix that?
In the package.json for 0g-plugin, kind add dev command ("dev": "tsup --watch").
Thanks for your notification. Sure, I'll fix it ASAP.
Shakker Nerd @.***> 于2024年11月19日周二 23:09写道:
Hey @Wilbert957 https://github.com/Wilbert957 Great work!
There are conflicts that needs fixing, could you fix that?
In the package.json for 0g-plugin, kind add dev command ("dev": "tsup --watch").
— Reply to this email directly, view it on GitHub https://github.com/ai16z/eliza/pull/416#issuecomment-2485981520, or unsubscribe https://github.com/notifications/unsubscribe-auth/BGT4B6HYQLKT3KSBOW3CFJT2BNICXAVCNFSM6AAAAABSBTEVX6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIOBVHE4DCNJSGA . You are receiving this because you were mentioned.Message ID: @.***>
Hey @Wilbert957 Great work!
There are conflicts that needs to be resolved before a merge could happen, could you fix that?
In the package.json for 0g-plugin, kind add dev command (
"dev": "tsup --watch").
I've fixed it. Could you please check?
Kindly attach a screengrab of the upload/file storage interaction.
@Wilbert957 This has been updated.
Please resolve conflicts and add a test and / or screen grab of working plugin functionality thanks so much! Amazing work with this plugin you are the GOAT!
Kindly attach a screengrab of the upload/file storage interaction.
@Wilbert957 This has been updated.
Sure, thanks. I've attached a screengrab.
Please resolve conflicts and add a test and / or screen grab of working plugin functionality thanks so much! Amazing work with this plugin you are the GOAT!
Sure, thanks. I've attached a screengrab.
Please resolve conflicts and add a test and / or screen grab of working plugin functionality thanks so much! Amazing work with this plugin you are the GOAT!
I've resolved conflicts~
Hey @Wilbert957 Great work!
There are conflicts that needs to be resolved before a merge could happen, could you fix that?
In the package.json for 0g-plugin, kind add dev command (
"dev": "tsup --watch").
I've resolved conflicts~
Hey @Wilbert957 Great work!
There are conflicts that needs to be resolved before a merge could happen, could you fix that?
In the package.json for 0g-plugin, kind add dev command (
"dev": "tsup --watch").
Hi @shakkernerd
I hope you're doing well! I wanted to kindly remind you that my pull request (#PR-416) is awaiting your review and approval. Your feedback would be greatly appreciated.
Hi, @monilpat. Conflicts resolved. Would know if can merge? Your feedback would be greatly appreciated.