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

feat: Adding plugin for B² Network #2010

Merged
merged 43 commits into from
Jan 14, 2025
Merged

Conversation

threewebcode
Copy link
Contributor

@threewebcode threewebcode commented Jan 8, 2025

B² Network is a Bitcoin Layer2 network. Add this plugin to integrate with Eliza so that users can interact with B² Network through Eliza agent.

Relates to

Add B² Network plugin into Eliza system.

Risks

Low

Main implementation risk is that the Plugin doesn't work correctly.

Background

What does this PR do?

B² Network is the first Bitcoin Rollup based on zero-knowledge proof verification commitment, while also offering a DA Layer solution for other Bitcoin rollups.

Adds support for Eliza to interact with B² Network and allows users to interact with B² Network through Eliza agent.

What kind of change is this?

Features (non-breaking change which adds functionality).

Documentation changes needed?

If documentation change is needed: I have updated the documentation accordingly.

Testing

Where should a reviewer start?

Spin up an agent with the b2 plugin

Detailed testing steps

Please refer to REAME.md in this plugin

@threewebcode threewebcode changed the title feat: plugin for b2 network feat: Adding plugin for B² Network Jan 9, 2025
@threewebcode
Copy link
Contributor Author

@shakkernerd Could you please help review this PR?

@shakkernerd
Copy link
Member

@shakkernerd Could you please help review this PR?

Okay, I will look into it.

@AIFlowML
Copy link
Collaborator

Is it me blind or we miss agent/index.ts and the .json ?
Sorry if they are present I was checking from the phone.

Copy link
Member

@shakkernerd shakkernerd left a comment

Choose a reason for hiding this comment

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

@threewebcode Basically, I can see repeated patterns in the code and I have commented on most, kindly use those comments to make the necessary adjustments.

packages/plugin-b2/src/actions/stake.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/actions/stake.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/actions/stake.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/actions/transfer.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/actions/transfer.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/actions/unstake.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/actions/unstake.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/actions/unstake.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/actions/unstake.ts Show resolved Hide resolved
@shakkernerd
Copy link
Member

shakkernerd commented Jan 13, 2025

Is it me blind or we miss agent/index.ts and the .json ? Sorry if they are present I was checking from the phone.

It is in the changed file list. Their order numbers are 5 and 37 . You can see it from following screenshot.

What he meant is the implementation of your plugin in agent/src/index.ts is missing. And to do this, you'll need to add/install your plugin to agent/package.json.
You can check how other plugins are implemented for an idea on how this is done OR I can help do this later on.

@threewebcode
Copy link
Contributor Author

@threewebcode Basically, I can see repeated patterns in the code and I have commented on most, kindly use those comments to make the necessary adjustments.

Thanks for your feedback. All of them are resolved.

@shakkernerd
Copy link
Member

@threewebcode Basically, I can see repeated patterns in the code and I have commented on most, kindly use those comments to make the necessary adjustments.

Thanks for your feedback. All of them are resolved.

You are welcome. I added a few above.
Kindly resolve those and this is good to go.

@threewebcode
Copy link
Contributor Author

@threewebcode Basically, I can see repeated patterns in the code and I have commented on most, kindly use those comments to make the necessary adjustments.

Thanks for your feedback. All of them are resolved.

You are welcome. I added a few above. Kindly resolve those and this is good to go.

Please help take a look again.

@shakkernerd
Copy link
Member

@threewebcode Basically, I can see repeated patterns in the code and I have commented on most, kindly use those comments to make the necessary adjustments.

Thanks for your feedback. All of them are resolved.

You are welcome. I added a few above. Kindly resolve those and this is good to go.

Please help take a look again.

A few of the changes aren't done yet.

@threewebcode
Copy link
Contributor Author

threewebcode commented Jan 13, 2025

@threewebcode Basically, I can see repeated patterns in the code and I have commented on most, kindly use those comments to make the necessary adjustments.

Thanks for your feedback. All of them are resolved.

You are welcome. I added a few above. Kindly resolve those and this is good to go.

Please help take a look again.

A few of the changes aren't done yet.

Sorry. I can not see any new comments added by you. Could you please clarify them?. Moreover, there is no unresolved code review conversation above.

@shakkernerd
Copy link
Member

@threewebcode Basically, I can see repeated patterns in the code and I have commented on most, kindly use those comments to make the necessary adjustments.

Thanks for your feedback. All of them are resolved.

You are welcome. I added a few above. Kindly resolve those and this is good to go.

Please help take a look again.

A few of the changes aren't done yet.

Sorry. I can not see any new comments added by you. Could you please clarify them?. Moreover, there is no unresolved code review conversation above.

image image image

@threewebcode
Copy link
Contributor Author

@threewebcode Basically, I can see repeated patterns in the code and I have commented on most, kindly use those comments to make the necessary adjustments.

Thanks for your feedback. All of them are resolved.

You are welcome. I added a few above. Kindly resolve those and this is good to go.

Please help take a look again.

A few of the changes aren't done yet.

Sorry. I can not see any new comments added by you. Could you please clarify them?. Moreover, there is no unresolved code review conversation above.

image image image

@shakkernerd Thanks for your helpful review and detailed instructions. The codes are refactored and refined. Please take a look again.

Copy link
Member

@shakkernerd shakkernerd left a comment

Choose a reason for hiding this comment

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

Looks good!

packages/plugin-b2/src/plugins/index.ts Outdated Show resolved Hide resolved
packages/plugin-b2/src/providers/index.ts Outdated Show resolved Hide resolved
.env.example Outdated Show resolved Hide resolved
@shakkernerd shakkernerd merged commit f5e1859 into elizaOS:develop Jan 14, 2025
5 of 6 checks passed
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.

4 participants