Andrew Wisniewski I Universal Composability Digital Ownership & Autonomous AI I Agentic Ethereum 2
Agentic Ethereum · 31 Jan 2025 · 9:45
Andrew Wisniewski from the Lit Protocol developer relations team asks how an agent owner can trust the developer who runs their agent's wallet. The workshop presents the Lit Agent Wallet, built on Programmable Key Pairs and Lit Actions, where an admin defines tools, delegates and policies. A command line demo mints a wallet, permits a signing tool, and shows a message rejected for breaking its policy.
Speakers
Topics
From Agentic Ethereum, hosted by ETHGlobal.
Transcript
[Music] Hi everyone, Andrew from the Lit Protocol DevRel team here. recently our team has been working to resolve a pretty crucial issue in the AI agent space—which is: how do we trust an agent developer with our agent's wallet? and so we've come up with an interesting solution using the Lit SDK, and that is the Lit Agent Wallet. so what is Lit Agent Wallet? it provides AI agents with immunity to tampering by agent developers. this means that the agent owner (whether that be a DAO multisig or EOA) can be assured that their agent’s funds aren't tampered with by the developer responsible for executing the agent’s intents or actions.
so before we get any further into the explanation, let's quickly cover some terms from the Lit SDK. so Lit has Programmable Key Pairs, or PKPs. Lit Actions are immutable JavaScript code published to IPFS. and we define a sub-agent as a GPT-4 model that parses an intent (whether from a user or AI) and from that intent correctly selects a Lit Action–based tool for the PKP to execute. now that we've covered some Lit-specific definitions, let's explore how the framework separates the interests of the agent owner and the developer. we define the agent owner as the admin. the admin is responsible for the ownership of the PKP NFT, and the admin also defines the tools and the policies that restrict these tools. so, for example, if we have a tool
to transfer ERC-20 tokens from our agent to any other address, we can restrict our agent to only send permitted tokens to permitted addresses, and to transfer only a specific amount of each token. next is our delegate. delegates can be thought of as the developers responsible for executing the agent’s intent. their execution scope is limited by the tools and policies defined by the admin, and they must be specifically chosen by the admin to execute the agent’s intent. if you are a developer yourself and you are building with an agent framework like Eliza, in this case you would be the admin, and your delegate would be the LLM that Eliza is using.
so this diagram is a pretty granular view of how the framework operates. we can see that the LLM provides transaction parameters to an executor or developer. that executor or developer provides the transaction parameters and authentication to a specific tool, and that specific tool performs signing. that tool is again a Lit Action published to IPFS, so it goes to that tool with the correct IPFS CID, and we can see on the bottom right it signs the transaction.
but before that, we see that the admin has delegation and policies. so under delegation, we have the delegation engine where we delegate specific executors or developers. then, after we have successfully added a developer or delegated them as we said previously, we have the policies. it has to verify with this policy to ensure that the parameters passed in by the developer are restricted (or, I guess, within the confines of this policy). and after we pass a policy, we then perform the signing.
so for this project, we have a couple of prerequisites: you have to have Node.js version 18.12 or greater, Git (of course, to clone the repository), pnpm (which can be installed with npm or yarn), an Ethereum wallet, and for that Ethereum wallet you will need Lit test LPT tokens. you can grab those from the faucet linked on screen, or it will appear if you just search “Lit faucet.” and then the CLI demo: so we'll add the package from npm. the CLI is just a simple demonstration of how you can use the Lit Agent Wallet package—it’s kind of the first use case of it. so we'll add the package from npm, and
then we'll run the executable `lit-agent-wallet`. and next we'll go into the demonstration of that. so after installing the `aw-cli` package, we will run the `lit-agent-wallet` command, and we'll be prompted to select a Lit network. so these are the three Lit networks for development, pre-production (test), and production. Lit Agent Wallets are scoped to these networks, so once you've minted a wallet, it can't be moved across networks. so just please keep that in mind for development. in this example, we'll be using `do-dev`. we'll start as an admin. it asks us if we would like to manage an existing agent wallet or mint a new one. for the demo, we will mint a new one, and we'll say yes, we would
like to manage it. we'll start by going into the tools, and we will permit a tool for our wallet. so the `aw-cli` demo comes with three tools: ERC20-transfer, a swapping tool, and a signing tool. so we'll just say we'd like to permit the signing tool. we'll then go to delegates. we will first add a delegatee, so we'll enter in the address. and then we're going to go back to the delegates menu, and we're going to permit our tool for the
delegatee. so you can see we select the delegatee, we select the tool, and now the tool is permitted. so then we'll go to policies. we'll set the tool policy. so we'll select the tool, our delegatee, and then it will ask us to enter the IPFS CID for the policy. those can be found in the README—there's a default policy which I will copy-paste here. so nice, we've set the tool policy. so one last step here: we will go to our policies, and now we will set a tool policy parameter for `sign-ecdsa` and then again for our delegatee as well. then we have to enter the parameter
name. so the `sign-ecdsa` tool has one policy attached to it, and that is allowed prefixes. so we'll enter that, and then you enter in the type. so the type is an array of strings, so we'll say we allow the prefix “hi.” nice. so we have added one policy parameter to our tool. and this is the step where we move to the side of the delegate now. so next we'll run the `lit-agent-wallet` command again from the perspective of the delegate.
so again, we'll have to select the `do-dev` network where we minted our PKP or agent wallet, of course. we'll select delegate role, and we can look at our delegated PKPs. so you can see I've used this wallet before because we have three PKPs delegated to it, but the most recent one is the one we just minted with the admin. so we can say “get registered tools,” select our PKP, and as you can see we have our `sign-ecdsa` tool with the policy enabled. we can also get the tool policy, so if we just wanted to see the IPFS CID of that tool policy, we could do that as well.
so finally, we'll go “execute tool.” we'll go to our agent wallet, `sign-ecdsa`, and as we remember, we set a prefix. so any message we send has to start with that prefix. so we can say “hi there,” and so we'll execute the tool. and as you can see, we got the signature—sign message success. it signed the message “hi there.” again, we can execute the tool, select our PKP, `sign-ecdsa`, but this time we'll say “I will not say hi there again.” this message doesn't start with the one allowed prefix, which is “hi.” so we'll try executing this tool. as you can see, there was an error,
and our error was “message must start with one of these prefixes,” and that prefix is “hi.” so yeah, that's it for this demonstration. if you have any questions, I recommend you reach out in our Telegram—we have a dedicated channel for questions about the Agent Wallet. I also recommend taking a look at the API docs. there's a lot of good information there on how you can build with the Lit Agent Wallet yourself. and yeah, I hope this demonstration was helpful. thanks for watching. [Music]
Related talks
- Agents with Allowances: Embedded Wallet Tools for a new Economy
- The Last Wallet You'll Ever Open
- The Good and Bad of Building (DeFi) on Ethereum | Austin Griffith, Francesco Andreoli
- From Vibe-Coded Demos to Production Money
- The $7.5M Sandwich Bot Hack: What Agent Transaction Security Requires
- AI Agent Custody and Fund Access - Dejan Radic | ResolverSys.com
- Crypto x AI, AI x Crypto: A Survey
- Enforceable Guardrails for Agentic Finance
- Emile Baizel I Building GenAI applications with Amazon Bedrock I Agentic Ethereum 2025
