-
Notifications
You must be signed in to change notification settings - Fork 380
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
Embedded Wallets #55
Comments
Hey was just going through the code base and I saw that the wallet is being created from the private key |
Ig, its created on the browser |
hey @Rudrakc - not sure what your question here is, and how it's related to embedded wallet |
Hey @thearyanag , We can do it in this way - (considering, we could also change the inputs): Take in the users address as the input and provide the access to the private key for the embedded wallet - we can make it a child wallet which is approved by the parent wallet, in our case - its the user's address Let me know if we can go with this approach |
Hey @thearyanag key idea is to streamline wallet interactions by allowing users to connect their own wallets directly to the agent. Once connected, the agent will interact seamlessly with the user wallet, which is linked to their identity (via wallet address or email address). The Solana-Agent-Kit will act as a single, unified framework for all users—staying consistent across the platform while still enabling personalized wallet usage. 1-Agent Keypair: The agent will maintain its own unique keypair for processing and enhanced security, ensuring robust operation across all interactions. |
I was thinking, we can change the keypair being passed to something like wallet interface, which could be something like
this way we could use any embedded wallet, or private key wdyt @0xNoushad / @skushagra9 |
@thearyanag Can we have 2 approaches?
|
I think a better approach would be to add a flag/parameter that allows for the agent kit to be wallet independent. All it needs is an address and it's able to create and compile transactions/messages into a serializable string or object, then send that as a response for the integrator's users to sign themselves. That way the toolkit accounts for integrators building server or on-device autonomous agents and wallets and also accounts for integrators that want the agent on the server and user keys on their device (for security and liability reasons). Of course, this would involve a big refactor but I think it's worth it, I wouldn't mind opening a PR for it |
Although this requires a refactor of the current implementation of the tools, I think it will open up direct client side integration and many more as they can integrate without revealing security (private keys). Moreover, it copes up with the most of the embedded wallet services available as they also expect the versioned tx or a buffer. |
Yes, this makes much more sense |
interesting, is someone working on this? |
Why does this seem like it's AI generated |
Refining words |
Will this not work ? To generate a new key and wallet when initializing a bot or after an action Or have agent ask u to input a wallet before a task that requires wallet |
Any update or more discussions regarding this approach? I feel like this is the most useful way to build the tooling in this repo |
hey @michaelessiet - can you attach a dummy implementation on how are you thinking to implement it? |
A simple example would be to just return the transaction variable from the Jupiter trade function My hacky approach was to sign the transaction from a wallet property on the agent. This allowed me to sign transactions with the Privy server-side client (example) But the solution proposed by @michaelessiet would be more ergonomic allowing for any method of transaction signing such as the Phantom chrome extension |
@slimeonmyhead do you then think this would cover all the cases?
|
@thearyanag Ideally, the agent constructor would only require Then you could use
|
Will do. I'm currently working on a drift integration. I'll do this once I'm done with that |
Is your feature request related to a problem? Please describe. Feature
Ideally, at scale - it's not feasible in many cases to create a unique wallet for each agent per user
Describe the solution you'd like
A solution, where an embedded wallet is created for the agent, linked to a identity - can be a user's wallet address, or any field in database
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Just for reference purposes
The text was updated successfully, but these errors were encountered: