Transcription: OpenAgents Episode 063 - Agent Pays L402 Endpoint

June 9, 2026 ยท View on GitHub

Source: https://twitter.com/OpenAgentsInc/status/1751700732963672411 Wiki source: https://raw.githubusercontent.com/wiki/OpenAgentsInc/openagents/Video-Series.md Media title: OpenAgents - Episode 063: Agent Pays L402 Endpoint We equip our agents with the ab... Upload date: 20240128 Transcription model: mlx-whisper/mlx-community/whisper-tiny Generated at: 2026-06-01T20:03:25Z

Machine-generated transcript. Review speaker labels and wording before using this as quote-grade source material.

[00:00] Christopher David: We've explored L402. Now let's just try to code it up. Let us try to equip our agent, the agent that we've built that can now do five things.

[00:09] Christopher David: You can validate text input. You can generate a vector embedding converting the user input to a vector

[00:14] Christopher David: embedding. You can want a similarity search over a knowledge base of those embeddings.

[00:18] Christopher David: It can take the top k and pass those to an LM to generate a response. We're using

[00:23] Christopher David: the mixed rules to be a V of E that's together API and it can count the values it can interact with a

[00:29] Christopher David: wasom plugin using ex-tism for any arbitrary code. Any arbitrary developer writes and uploads to our interface here.

[00:37] Christopher David: We can call that. So that's awesome. That plugin system enables people to maybe write their own L402 plugins or other API plugins.

[00:48] Christopher David: But in this video I want us to get an agent actually doing the thing.

[00:54] Christopher David: Doing the same thing we did in the last video except we did it via the UI and I want an agent, this

[01:00] Christopher David: agent that we built here, to hit that same API, hit that weather API and pay for it.

[01:09] Christopher David: Okay, let's do it. So quick review. We have on our command line here. If we do P to run all of our tests, they pass.

[01:24] Christopher David: If we do PF, oops, P filter plugin to just run our plugin tests.

[01:30] Christopher David: We're going to do in this video pretty much the same thing that we did when we added support for plugins.

[01:37] Christopher David: Our agent being able to use plugins we started with a test.

[01:43] Christopher David: And then, yeah, built it up via test driven development. So for plugins we say,

[01:52] Christopher David: the relevant ones here are that.

[02:03] Christopher David: Where is it?

[02:07] Christopher David: Oops, P filter plugin. I'm looking for the agent step being able to process a plugin.

[02:25] Christopher David: Oh, I think we defined it maybe as an integration test.

[02:31] Christopher David: Okay, let's pop open, um, me of him by the way.

[02:38] Christopher David: Let's go test. Let's just open up.

[02:46] Christopher David: Just give me anything here and do this.

[02:50] Christopher David: Go down to step test. This might be it.

[02:54] Christopher David: Okay, yeah, so can process a plugin.

[02:57] Christopher David: It wasn't running because we added this to our integration group test, which we're skipping over because it takes a little bit to do.

[03:08] Christopher David: Okay, so what we're going to do here is do a version of this test.

[03:14] Christopher David: This is the unit test.

[03:17] Christopher David: We just want to make sure that if a step has a type of category of, well, I guess we'll just call it L for O2 for now.

[03:28] Christopher David: We're kind of bundling two different things.

[03:31] Christopher David: We need to have a category for just straight up API call.

[03:35] Christopher David: That's been on our to do list to do.

[03:39] Christopher David: In this video, we're basically doing API call plus the whole L for O2 shant check.

[03:44] Christopher David: And then we can split them off for a refog now later.

[03:47] Christopher David: But we have five categories here. We want to add a category for L for O2.

[03:53] Christopher David: So, let's just, we got co pilot work in. Let's just say, can process an L for O2.

[04:06] Christopher David: Yep.

[04:11] Christopher David: Okay. Just start with this.

[04:15] Christopher David: This is my first test running as Neo Vim.

[04:26] Christopher David: Let's get something running on our terminal here code.

[04:39] Christopher David: Okay, give me P filter L for O2.

[04:44] Christopher David: Okay, we have hello from step test.

[04:47] Christopher David: So what do we want to start?

[04:50] Christopher David: We know that we're going to want to run a cedar. That might be the first thing that we built.

[04:54] Christopher David: We ran the cedar there of plug-in cedar.

[04:59] Christopher David: We don't actually need to see the plug-in.

[05:05] Christopher David: We don't need to see the plug-in.

[05:07] Christopher David: But I do think we need to see a step.

[05:11] Christopher David: Yeah, let's see what we need to do.

[05:15] Christopher David: Can I yank three lines?

[05:17] Christopher David: Did that work?

[05:20] Christopher David: I don't think I did.

[05:22] Christopher David: Oh, yes it did.

[05:25] Christopher David: Okay, so we're going to create a step with the category of L for O2.

[05:32] Christopher David: Let's capitalize it just because it's nice and fancy.

[05:37] Christopher David: Okay.

[05:40] Christopher David: All right. Is it okay? Terminal?

[05:43] Christopher David: All right. It's okay. We didn't assert anything.

[05:47] Christopher David: So we're creating a step with the category of L for O2.

[05:53] Christopher David: And then we're going to create a step executed.

[05:56] Christopher David: Like we're going to try to just run it and then see what happens.

[06:02] Christopher David: So create a new step executed for the step. Thank you, co-partheid.

[06:06] Christopher David: Step executed is...

[06:10] Christopher David: Okay, out of my way buffer thing. There we go.

[06:17] Christopher David: And I don't want...

[06:19] Christopher David: I don't want...

[06:22] Christopher David: Oops. Oh no.

[06:24] Christopher David: Oh no.

[06:28] Christopher David: Oh no.

[06:31] Christopher David: Oh no.

[06:34] Christopher David: Bro, I just broke everything.

[06:37] Christopher David: Oh my gosh.

[06:40] Christopher David: Oh yeah. Cap plug on.

[06:45] Christopher David: Okay.

[06:48] Christopher David: Cap slot is not cruise control for cool.

[06:52] Christopher David: What's the saying?

[06:53] Christopher David: Okay. Try as again. Create a new step executed.

[06:57] Christopher David: To the user factory. No. Step executed.

[07:01] Christopher David: How do I get this thing out of the way so I can tab over?

[07:07] Christopher David: No. No. No. No.

[07:10] Christopher David: There we go. Okay. Step executed.

[07:12] Christopher David: To do it. To do it. Now for input.

[07:19] Christopher David: What is the input to an L for O2 going to be?

[07:30] Christopher David: I'm guessing it's going to be the URL.

[07:37] Christopher David: And for this, I want to grab that from this.

[07:44] Christopher David: Yeah. Tell me the weather in London.

[07:47] Christopher David: Oops.

[07:51] Christopher David: Throw that there. Tell me the weather in London.

[07:54] Christopher David: All right.

[08:01] Christopher David: Okay. If I do that.

[08:05] Christopher David: And then I run the step.

[08:12] Christopher David: I'm going to expect the output to be.

[08:15] Christopher David: Copilot just guessing here.

[08:18] Christopher David: Okay.

[08:21] Christopher David: So this of course is going to fail, but we wanted to fail in a way that when we write the code.

[08:26] Christopher David: It'll pass.

[08:28] Christopher David: First of all, it's going to have proper branch.

[08:32] Christopher David: Let's call this branch.

[08:34] Christopher David: L for O2.

[08:39] Christopher David: And let's run the test.

[08:44] Christopher David: Okay.

[08:50] Christopher David: Call to undefined method app model.

[08:52] Christopher David: Step executed L for O2.

[08:54] Christopher David: As expected because our.

[08:58] Christopher David: Trate action category in the step executed model.

[09:05] Christopher David: Is looking for a method called.

[09:10] Christopher David: L for O2 because we're calling the function with the same name as the category right there online.

[09:15] Christopher David: 20.

[09:16] Christopher David: Okay. So these are defined in step actions.

[09:20] Christopher David: So let's go check out step actions.

[09:27] Christopher David: So don't we write the simplest test that gets our test to the next phase.

[09:34] Christopher David: So in this case, it's public function L for O2.

[09:38] Christopher David: Blah blah blah.

[09:40] Christopher David: This.

[09:41] Christopher David: And then nothing else because I just want to see a different error.

[09:45] Christopher David: Over here.

[09:46] Christopher David: Right. Again.

[09:48] Christopher David: Fail the starting that null is identical to that.

[09:51] Christopher David: So we don't have actually have anything.

[09:54] Christopher David: So now we get to implement the logic of L for two.

[09:58] Christopher David: We may involve our friend.

[10:00] Christopher David: Chagivity here in a second, but.

[10:04] Christopher David: Let's just see.

[10:06] Christopher David: Let's try what do we know that we have.

[10:09] Christopher David: We know that we're going to have a.

[10:14] Christopher David: URL passed in.

[10:16] Christopher David: So let's just take a look first of all at the input that we have.

[10:21] Christopher David: Oops.

[10:23] Christopher David: No. Come on.

[10:25] Christopher David: I'll just type it in then.

[10:31] Christopher David: Just take make sure that we have the input there.

[10:34] Christopher David: Yeah.

[10:35] Christopher David: So let's just say that we know that we have the input equals.

[10:41] Christopher David: Input input.

[10:43] Christopher David: That's kind of confusing and we can re factor that.

[10:48] Christopher David: That's later.

[10:50] Christopher David: And then we know that we have the URL.

[10:53] Christopher David: Which is input URL.

[10:57] Christopher David: Okay.

[11:04] Christopher David: Get URL.

[11:06] Christopher David: Why not?

[11:08] Christopher David: Let's just see what happens.

[11:10] Christopher David: What do you think this is going to do?

[11:18] Christopher David: Make a get request to the URL.

[11:20] Christopher David: Let's see what happens.

[11:22] Christopher David: Can not offset type of a string on a string.

[11:32] Christopher David: What?

[11:36] Christopher David: Oh, because I'm redefining input.

[11:38] Christopher David: They're.

[11:39] Christopher David: Did do.

[11:42] Christopher David: User inputs.

[11:45] Christopher David: That's not good.

[11:46] Christopher David: But I don't care.

[11:51] Christopher David: Payment required.

[11:53] Christopher David: How cool is that?

[11:57] Christopher David: It said fuck you, painting.

[12:01] Christopher David: Payment required new line.

[12:17] Christopher David: I'm not sure if you can see that.

[12:20] Christopher David: I'm not sure if you can see that.

[12:22] Christopher David: I'm not sure if you can see that.

[12:25] Christopher David: First of all, it's just expect the body to include the string payment required.

[12:34] Christopher David: Okay.

[12:36] Christopher David: If not throw error.

[12:58] Christopher David: Okay.

[13:06] Christopher David: Can I yank ten lines like that?

[13:24] Christopher David: Yes, I can.

[13:29] Christopher David: We are implementing the L4 to in our LRL.

[13:34] Christopher David: And trade here.

[13:36] Christopher David: Here's what we got.

[13:37] Christopher David: I'll paste in the spec and you write the code.

[13:41] Christopher David: I'll be needing to hold protocols.

[13:45] Christopher David: Let's just try pacing in.

[13:48] Christopher David: First here's some background info.

[13:56] Christopher David: I'll be needing to hold protocols.

[13:59] Christopher David: Let's just try pacing in.

[14:02] Christopher David: First here's some background info.

[14:11] Christopher David: I'll be needing to hold protocols.

[14:16] Christopher David: Paste in the docs.

[14:17] Christopher David: See, soon we're going to have our agents just like reading the relevant docs.

[14:21] Christopher David: I don't have to paste it in again.

[14:22] Christopher David: They're just going to like, oh, bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-bo-

[14:52] Christopher David: No, no, no, no, no.

[14:56] Christopher David: Do you do?

[14:59] Christopher David: Oh, look at all this nice stuff. I forgot some. It's JSON.

[15:04] Christopher David: Do this.

[15:10] Christopher David: Now I'm gonna call it a...

[15:13] Christopher David: Here's the API we will actually be hitting.

[15:23] Christopher David: I'm just gonna give me the code. Why don't you have, like, let me build this suspense for a bit. First.

[15:38] Christopher David: Chattie.

[15:43] Christopher David: What's it doing now?

[15:45] Christopher David: What's it doing?

[15:55] Christopher David: What's it doing?

[16:04] Christopher David: Bro, did you just give me everything?

[16:06] Christopher David: Hmm.

[16:12] Christopher David: Now, conceivably I should make a, like, L-4O2 service and dump all this code in there.

[16:28] Christopher David: Alright, let's just, like, kind of think about this.

[16:31] Christopher David: If response status is 4O2,

[16:37] Christopher David: Alright, let's do this.

[16:42] Christopher David: Let's go up here.

[16:44] Christopher David: I want to yank the next

[16:47] Christopher David: 26 lines.

[16:55] Christopher David: Thanks now. We write this code here.

[17:01] Christopher David: Adding everything needed to make the L-4O2 thingy work.

[17:08] Christopher David: Building on my existing code.

[17:24] Christopher David: Builds build the thingy.

[17:26] Christopher David: Hehehe.

[17:29] Christopher David: This is fucking do it. Do it.

[17:37] Christopher David: Why are you taking so long? I don't have 45 seconds to wait for this.

[17:42] Christopher David: busy guy.

[17:51] Christopher David: Oh, I love how it grays us out. Isn't this cool? Isn't this poetic?

[17:56] Christopher David: Is this poetic? It tells you now if something's great, it grays it out if you're not using it.

[18:01] Christopher David: We're using the Queen B GPU Tobi a gateway for embedding.

[18:04] Christopher David: We are not using the OpenAI gateway. Let's fucking delete that.

[18:12] Christopher David: OpenAI, you're taking so long. This is horrific. I hate you.

[18:16] Christopher David: Ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha

[18:46] Christopher David: ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha

[19:16] Christopher David: ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha

[19:46] Christopher David: ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha

[19:59] Christopher David: So we are not actually going to want to stuff all of the code for this in this trait.

[20:07] Christopher David: Generally with TDD, we want to take the simplest path to get the test passing and then refactor when the code gets smelly.

[20:17] Christopher David: But starting with smelly code is okay.

[20:25] Christopher David: And while we wait for change, you'd be teetit recovery.

[20:29] Christopher David: Let's start with the service.

[20:35] Christopher David: Can we do it on the command line, say I'll artisan make service?

[20:39] Christopher David: I don't know if that's a function.

[20:41] Christopher David: Elf or two?

[20:46] Christopher David: What if we go here into services?

[20:52] Christopher David: App services.

[20:55] Christopher David: Can I do A? Yes, I can. Elf or two. PHP.

[21:01] Christopher David: Okay.

[21:03] Christopher David: Let's first open another service file.

[21:07] Christopher David: So code part can help us out.

[21:10] Christopher David: Okay, let's define A.

[21:13] Christopher David: So name space, app services.

[21:21] Christopher David: Class Elf or two.

[21:25] Christopher David: And Vogue.

[21:29] Christopher David: No, I don't want that.

[21:44] Christopher David: I may want a constructor.

[21:48] Christopher David: Oops.

[21:49] Christopher David: I don't know the hotkeys for quickly getting a.

[21:56] Christopher David: I don't know.

[21:57] Christopher David: I don't know.

[21:59] Christopher David: I don't know.

[22:01] Christopher David: I don't know.

[22:07] Christopher David: I don't know.

[22:11] Christopher David: I don't know.

[22:13] Christopher David: I don't know.

[22:15] Christopher David: I don't know.

[22:17] Christopher David: I don't know.

[22:19] Christopher David: I don't know.

[22:21] Christopher David: I don't know.

[22:23] Christopher David: I don't know.

[22:25] Christopher David: I don't know.

[22:27] Christopher David: I don't know.

[22:30] Christopher David: Let's remind ourselves about the alibi developer API.

[22:37] Christopher David: So we're going to be.

[22:40] Christopher David: Um.

[22:43] Christopher David: For now paying all invoices via a central alibi account.

[22:49] Christopher David: And then later on we'll like deduct the agent balance from the agent.

[23:03] Christopher David: So I need the wallet API.

[23:12] Christopher David: PHP library.

[23:14] Christopher David: That's what I'm talking about.

[23:17] Christopher David: Oh yeah.

[23:19] Christopher David: I'd so nice when they got a PHP library.

[23:23] Christopher David: Composer install while I'm going to need the package name.

[23:30] Christopher David: So let's try this out.

[23:33] Christopher David: Uh, see I guess first I will.

[23:37] Christopher David: Commit some stuff.

[23:41] Christopher David: Starts.

[23:44] Christopher David: Okay.

[23:47] Christopher David: And then let's try a composer require.

[23:51] Christopher David: Alibi PHP.

[23:54] Christopher David: Is that it?

[23:55] Christopher David: Gonna find alibi slash PHP.

[24:00] Christopher David: Uh, I guess they haven't published it.

[24:12] Christopher David: Yeah.

[24:17] Christopher David: Yeah.

[24:24] Christopher David: Use alibi clients.

[24:34] Christopher David: Okay.

[24:36] Christopher David: I may just copy paste all of this because this is very.

[24:45] Christopher David: Not very much here.

[24:54] Christopher David: Yeah.

[24:55] Christopher David: I think I will do.

[24:57] Christopher David: Chats.

[24:59] Christopher David: Chats.

[25:03] Christopher David: Okay.

[25:05] Christopher David: So we're going to do is in services.

[25:09] Christopher David: We're going to create a service called.

[25:13] Christopher David: We could have folder for Alibi.

[25:18] Christopher David: Yeah.

[25:19] Christopher David: I've got a folder for ex-tism.

[25:21] Christopher David: Let's make a no.

[25:24] Christopher David: How do I add a folder?

[25:28] Christopher David: Okay.

[25:29] Christopher David: Yeah.

[25:31] Christopher David: Helia.

[25:34] Christopher David: Okay.

[25:37] Christopher David: In the root folder.

[25:42] Christopher David: We have client.php.

[25:48] Christopher David: And in client.php.

[25:55] Christopher David: We have all this nice stuff.

[25:58] Christopher David: Guzzle.

[26:09] Christopher David: Oh, we got that.

[26:12] Christopher David: Auto format.

[26:13] Christopher David: That's nice.

[26:16] Christopher David: Construct with an access token.

[26:19] Christopher David: That's nice.

[26:22] Christopher David: Request.

[26:24] Christopher David: That's very nice.

[26:25] Christopher David: Okay.

[26:26] Christopher David: So now we're going to need.

[26:29] Christopher David: Use alibi contracts.

[26:31] Christopher David: Alibi client.

[26:32] Christopher David: I don't think we're going to need this require once because Lervill

[26:35] Christopher David: will handle the loading of stuff for us.

[26:39] Christopher David: Let's pull in.

[26:42] Christopher David: Contracts.

[26:47] Christopher David: Capital.

[26:48] Christopher David: Contracts.

[26:50] Christopher David: And we're going to add a file called Alibi client.

[27:05] Christopher David: That's nice.

[27:08] Christopher David: I don't know if Lervill will like the name space there.

[27:11] Christopher David: It might need to be under app slash services.

[27:13] Christopher David: I think the auto discovery only is only app slash services.

[27:16] Christopher David: So let's just do that now.

[27:18] Christopher David: So it's consistent.

[27:21] Christopher David: App services.

[27:23] Christopher David: Alibi contracts.

[27:24] Christopher David: And now we're going to add a file called Alibi client.

[27:28] Christopher David: And we're going to add a file called Alibi client.

[27:30] Christopher David: And we're going to add a file called Alibi client.

[27:33] Christopher David: And we're going to add a file called Alibi client.

[27:36] Christopher David: And then here we'll do app services.

[27:43] Christopher David: Alibi.

[27:45] Christopher David: We're going to get rid of this.

[27:48] Christopher David: We're going to add here app services.

[27:53] Christopher David: Alibi contracts.

[27:55] Christopher David: Alibi client.

[27:57] Christopher David: Services. Alibi contracts.

[27:59] Christopher David: Alibi client.

[28:01] Christopher David: Guzzle HTTP.

[28:02] Christopher David: I think it'll do it.

[28:10] Christopher David: OK.

[28:11] Christopher David: So I'm going to call this.

[28:26] Christopher David: Untracked files presence.

[28:49] Christopher David: Oh, Stephen.

[28:52] Christopher David: OK.

[28:57] Christopher David: Out of curiosity.

[29:00] Christopher David: Just make sure things are looking good up there.

[29:21] Christopher David: App services.

[29:23] Christopher David: Alibi client.

[29:25] Christopher David: Yeah.

[29:28] Christopher David: So I think that's good.

[29:31] Christopher David: And then if I think that a lot is due.

[29:36] Christopher David: Is go to our L-4 to class.

[29:39] Christopher David: And say.

[29:54] Christopher David: I want you to create a wallet.

[30:10] Christopher David: That's a new.

[30:15] Christopher David: So use app services.

[30:22] Christopher David: Alibi client.

[30:27] Christopher David: Nice.

[30:31] Christopher David: Use make it a client.

[30:34] Christopher David: And pass in the environment that we have called Alibi access token.

[30:40] Christopher David: Yes.

[30:41] Christopher David: Which we've already configured and defined.

[30:48] Christopher David: Let's die and dump that.

[30:52] Christopher David: Let's just like see what the hell that looks like.

[31:03] Christopher David: Whoa.

[31:07] Christopher David: So we're eradicated our import.

[31:13] Christopher David: Why did it do that?

[31:16] Christopher David: Oh, Alibi client.

[31:17] Christopher David: It's called Alibi client.

[31:27] Christopher David: Yeah, no.

[31:31] Christopher David: No, that's the interface.

[31:33] Christopher David: This is a class client.

[31:43] Christopher David: Okay, I messed up.

[31:48] Christopher David: I let the contract implement.

[31:54] Christopher David: Dang it.

[32:12] Christopher David: App services Alibi client.

[32:17] Christopher David: What is this?

[32:30] Christopher David: Base URI's this URL.

[32:39] Christopher David: Refresh token is not used.

[32:41] Christopher David: Maybe.

[32:51] Christopher David: And this is safe, isn't it?

[33:09] Christopher David: Oh, new.

[33:16] Christopher David: There we go.

[33:19] Christopher David: Okay.

[33:29] Christopher David: Let's create a new.

[33:36] Christopher David: L-4O2 service object.

[33:42] Christopher David: Boom.

[33:43] Christopher David: I'm going to import that in a second.

[33:47] Christopher David: Now.

[33:50] Christopher David: I think that will initialize Alibi.

[34:08] Christopher David: I'm going to add the app services.

[34:15] Christopher David: Alibi contracts.

[34:24] Christopher David: Alibi client.

[34:33] Christopher David: Oh, well.

[34:40] Christopher David: Is it because I think this folder needs to be capitalized?

[34:49] Christopher David: I don't know how to change this.

[35:11] Christopher David: There we go.

[35:18] Christopher David: Did that make any difference?

[35:32] Christopher David: Yes, it did.

[35:33] Christopher David: And Boo, yeah.

[35:34] Christopher David: We have the wallet.

[35:40] Christopher David: It says access token is null.

[35:50] Christopher David: It doesn't share it.

[35:55] Christopher David: Oh, we didn't pass in the access token.

[36:01] Christopher David: Let me try this again.

[36:12] Christopher David: I also don't know that I want to dump out the token.

[36:16] Christopher David: It might dump out the token to the database, to the whatever.

[36:30] Christopher David: I and dump whether or not this wallet's access token is null or not.

[36:45] Christopher David: But don't show the actual token.

[36:51] Christopher David: There we go.

[36:56] Christopher David: Okay.

[37:03] Christopher David: So we're running right now.

[37:04] Christopher David: It is null.

[37:09] Christopher David: So it'll say.

[37:14] Christopher David: It's a private property.

[37:20] Christopher David: Well, it's actually like trying to do something on it.

[37:29] Christopher David: Get info.

[37:40] Christopher David: Let's dd this wallet.

[37:45] Christopher David: Okay.

[37:55] Christopher David: So if the tokens there, it should actually get info.

[38:03] Christopher David: It says invalid because it I guess we need to restart our.

[38:13] Christopher David: We need to do a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a little bit of a

[38:43] Christopher David: access token.

[38:57] Christopher David: What's going on?

[39:01] Christopher David: Zero.

[39:13] Christopher David: Okay.

[39:20] Christopher David: I'll be right back.

[39:24] Christopher David: And we're back.

[39:25] Christopher David: I had some variables in the end of that testing file.

[39:30] Christopher David: So the variables in my main file are expected to be an environment where not being passed in.

[39:36] Christopher David: They're not being passed in.

[39:37] Christopher David: Okay.

[39:38] Christopher David: So we are dying dumping.

[39:41] Christopher David: Let's go to our L4O2 class.

[39:48] Christopher David: So right now we are initializing it.

[39:50] Christopher David: We're creating, sitting this wallet to a new alibi client.

[39:54] Christopher David: And we're just to test that we have the connection working fine.

[39:57] Christopher David: We're dying doubly.

[39:58] Christopher David: This wallet.

[39:59] Christopher David: info command and there you can see this is the

[40:04] Christopher David: alvia account that we're going to use as like the main open agents wallet

[40:09] Christopher David: and it's

[40:12] Christopher David: got my info there

[40:14] Christopher David: so because we're connected we should be able to pay an invoice I think

[40:18] Christopher David: and our friend chatty it looks like he's back in action so

[40:26] Christopher David: let's see let's do this now let's say

[40:32] Christopher David: let's yonk all this yonk yonk it's fun to say yonk

[40:37] Christopher David: okay so now did that paste it there

[40:43] Christopher David: no

[40:45] Christopher David: dang I guess I have to use the old copy paste

[40:48] Christopher David: does that work

[40:49] Christopher David: all that they disabled the mouse

[40:59] Christopher David: does that work

[41:07] Christopher David: and the of them I need to yank

[41:11] Christopher David: and be able to paste in clipboard

[41:14] Christopher David: but doing things like percentage

[41:18] Christopher David: colon percentage y are yonk yonk yonk yonk

[41:21] Christopher David: but not to system clipboard

[41:24] Christopher David: I used to work but this new config

[41:27] Christopher David: I just put in must have overwritten that

[41:29] Christopher David: to yank it to the clipboard

[41:44] Christopher David: I'm going to try this

[41:45] Christopher David: boom

[41:47] Christopher David: percent y plus

[41:52] Christopher David: what does that do

[41:55] Christopher David: yeah

[42:01] Christopher David: let's sum

[42:04] Christopher David: build up an L40 to service that will have all this logic

[42:09] Christopher David: then the method will just call the relevance methods in this service

[42:16] Christopher David: and

[42:22] Christopher David: that's a great idea of course it is

[42:26] Christopher David: and then I can tell it seems like

[42:30] Christopher David: the alibi client is how we're going to pay the invoice

[42:34] Christopher David: watch this watch this watch this watch this watch this

[42:36] Christopher David: alibi client let's see yank

[42:41] Christopher David: all of this

[42:43] Christopher David: and then

[42:45] Christopher David: in this are you hanging up again are you hanging up again

[42:50] Christopher David: in this

[43:05] Christopher David: I want to be so nice

[43:08] Christopher David: and

[43:14] Christopher David: I'm going to

[43:16] Christopher David: just stop

[43:20] Christopher David: to respond entirely

[43:28] Christopher David: but here's what I do

[43:32] Christopher David: we're going to

[43:33] Christopher David: just stop

[44:14] Christopher David: okay so what I want to do now

[44:16] Christopher David: is I want to grab

[44:18] Christopher David: this

[44:26] Christopher David: to pay the invoice

[44:28] Christopher David: we are going to use the alibi client here

[44:31] Christopher David: it will return a pre-image

[44:43] Christopher David: and

[44:53] Christopher David: just

[44:58] Christopher David: just

[45:06] Christopher David: it just grabs out the Miller request

[45:10] Christopher David: holy shit

[46:36] Christopher David: I really

[46:42] Christopher David: close

[46:44] Christopher David: and

[46:48] Christopher David: this is

[46:50] Christopher David: so I'm going to

[46:51] Christopher David: continue in the morning

[46:56] Christopher David: and we're back

[46:58] Christopher David: good morning let's see if

[47:01] Christopher David: the alibi client

[47:04] Christopher David: is going to

[47:07] Christopher David: go

[47:09] Christopher David: to

[47:13] Christopher David: go

[47:17] Christopher David: this

[47:23] Christopher David: finally completed

[47:32] Christopher David: okay

[47:33] Christopher David: don't

[47:34] Christopher David: define

[47:35] Christopher David: this

[47:43] Christopher David: alibi client

[47:44] Christopher David: separately from

[47:46] Christopher David: wallet

[47:48] Christopher David: actually

[47:51] Christopher David: just

[47:53] Christopher David: don't define

[47:55] Christopher David: this wallet

[47:57] Christopher David: just go with your

[47:59] Christopher David: value client

[48:01] Christopher David: and give me the entire file so I can copy

[48:04] Christopher David: paste it don't

[48:05] Christopher David: make me do any work

[48:09] Christopher David: so

[48:13] Christopher David: let's

[48:16] Christopher David: start

[48:17] Christopher David: acting

[48:19] Christopher David: stuff

[48:24] Christopher David: so

[48:27] Christopher David: to

[48:32] Christopher David: go

[48:39] Christopher David: in

[48:45] Christopher David: this version of the alifort

[48:46] Christopher David: service the alibi client is used to handle

[48:48] Christopher David: interactions with the alibi

[48:50] Christopher David: alibi

[48:51] Christopher David: the handle L402 request method

[48:52] Christopher David: manages the process of sending an

[48:54] Christopher David: initial quest

[48:56] Christopher David: to pay

[49:02] Christopher David: the

[49:05] Christopher David: alibi client

[49:12] Christopher David: also

[49:14] Christopher David: ensure that the alibi client

[49:17] Christopher David: class has all the necessary methods and

[49:19] Christopher David: functionalized

[49:20] Christopher David: area

[49:21] Christopher David: okay

[49:26] Christopher David: to be passed in the alibi class

[49:29] Christopher David: yeah we did

[49:32] Christopher David: some

[49:36] Christopher David: dumpison

[49:39] Christopher David: there

[49:44] Christopher David: do

[49:48] Christopher David: this

[49:54] Christopher David: okay

[49:58] Christopher David: so we'll try that

[50:00] Christopher David: and we're calling that from

[50:02] Christopher David: our

[50:07] Christopher David: step actions

[50:10] Christopher David: oops

[50:13] Christopher David: okay so let's see this

[50:26] Christopher David: let's copy

[50:29] Christopher David: down to

[50:32] Christopher David: line

[50:34] Christopher David: 30

[50:37] Christopher David: and say

[50:40] Christopher David: now rewrite the alifort

[50:42] Christopher David: to function

[50:44] Christopher David: in step actions to use that class

[51:17] Christopher David: okay

[51:24] Christopher David: okay

[51:29] Christopher David: let's see

[51:32] Christopher David: this

[51:37] Christopher David: dump

[51:39] Christopher David: here

[51:42] Christopher David: okay

[51:49] Christopher David: okay

[51:52] Christopher David: okay

[51:57] Christopher David: okay

[52:01] Christopher David: okay

[52:07] Christopher David: okay

[52:25] Christopher David: okay

[52:26] Christopher David: what do you think is going to happen

[52:30] Christopher David: okay

[52:36] Christopher David: okay

[52:42] Christopher David: yeah we're not doing anything with the user input

[52:45] Christopher David: we're just calling the URL

[52:46] Christopher David: I guess if you want to do something like pass in a city

[52:49] Christopher David: we would construct the URL from that

[52:52] Christopher David: we're not going to worry about that right now

[52:54] Christopher David: but let's just see what happens with our test

[52:58] Christopher David: so last time we were getting null

[53:01] Christopher David: now what are we going to get

[53:05] Christopher David: undefined array key one

[53:40] Christopher David: okay

[53:47] Christopher David: okay

[53:52] Christopher David: okay

[53:56] Christopher David: okay

[53:59] Christopher David: okay

[54:02] Christopher David: okay

[54:07] Christopher David: okay

[54:14] Christopher David: okay

[54:19] Christopher David: okay

[54:27] Christopher David: okay

[54:32] Christopher David: okay

[54:39] Christopher David: okay

[54:41] Christopher David: first of all

[54:44] Christopher David: okay

[54:47] Christopher David: okay

[54:53] Christopher David: okay

[54:55] Christopher David: okay

[54:59] Christopher David: okay

[55:06] Christopher David: okay

[55:08] Christopher David: okay

[55:12] Christopher David: okay

[55:17] Christopher David: okay

[55:21] Christopher David: okay

[55:27] Christopher David: why are we getting response back from the API that's a good first step with the macaron in the aboys

[55:37] Christopher David: here is the revised pars all header method

[55:41] Christopher David: regex nice

[55:47] Christopher David: okay

[55:52] Christopher David: okay so we'll swap this in

[55:55] Christopher David: for our existing pars all header

[55:59] Christopher David: this is wrong

[56:05] Christopher David: through that in there

[56:11] Christopher David: and then in step actions

[56:14] Christopher David: where no

[56:17] Christopher David: so set of dding them off header

[56:29] Christopher David: first let's dd the macaron

[56:32] Christopher David: oh you dd both of these

[56:47] Christopher David: so this will make sure that we are parsing both the macaron and the invoice

[56:53] Christopher David: we are there's the macaron

[57:03] Christopher David: there's the invoice

[57:17] Christopher David: okay

[57:29] Christopher David: now this

[57:34] Christopher David: albecliant add invoice is not at all correct

[57:47] Christopher David: so let's do a

[57:57] Christopher David: yank of that into here

[58:01] Christopher David: that part now works but we are not passing the invoice to the albe method

[58:16] Christopher David: see how it's hard coded that is bad

[58:23] Christopher David: needs to use the actual invoice

[58:29] Christopher David: and then let's pop open the albecliant

[58:46] Christopher David: and let's say yank all this

[58:52] Christopher David: I think that's right

[58:58] Christopher David: remember this is the albecliant

[59:05] Christopher David: okay

[59:24] Christopher David: if it's a lightning network invoice which is typically a batch 32 and coded string

[59:29] Christopher David: which is you need to extract the necessary details from it

[59:39] Christopher David: okay so here's a question does the albecliant have a method for decoding an invoice

[59:49] Christopher David: or is that even needed I thought there's passed the API

[59:57] Christopher David: add invoice dollar sign

[59:59] Christopher David: invoice. This is expecting value and invoice. Oh, I think we need to do this first.

[01:00:13] Christopher David: No decode invoice. We should get the needed invoice in the right format by calling that

[01:00:33] Christopher David: get invoice method on the alibi class passing in the batch 32 straight.

[01:01:03] Christopher David: We could have done this just via the alibi API if we wanted to.

[01:01:15] Christopher David: But I wanted to kick the tires on their PHP class that they made.

[01:01:21] Christopher David: And it seems like it's going to work just fine.

[01:01:51] Christopher David: So it changed this to be called invoice string.

[01:02:04] Christopher David: And then we're going to first call invoice details equals this alibi.

[01:02:14] Christopher David: Oh, we'll go through that. Do it. Give me it.

[01:02:36] Christopher David: Okay, and let's tab. Gosh. My VIM is not properly configured for my usual tab to

[01:02:47] Christopher David: our complete code part. Okay, let's run that and see what happens.

[01:03:08] Christopher David: Oh, called to undefine method get invoice details. That's not what it's called. Why is it making

[01:03:13] Christopher David: that up? It's just get invoice. It like falls out of its context, but it you think it would be storing it better to not make stuff.

[01:03:31] Christopher David: Is that for only an existing invoice?

[01:03:39] Christopher David: That might be only for an existing invoice. Okay, let's pop over to the al 402 or the alibi API docs.

[01:04:01] Christopher David: So we were calling invoices slash the hash.

[01:04:13] Christopher David: So get invoice does this gets details about specific invoice can be both incoming or outgoing.

[01:04:29] Christopher David: Oh, no, this expects a payment hash. I'm like a completed invoice. So we need to do this.

[01:04:49] Christopher David: And I did not see that in here.

[01:05:03] Christopher David: So this class is just missing a method that we need, which is fine. We can implement it ourselves.

[01:05:13] Christopher David: Public function decode invoice.

[01:05:27] Christopher David: We'll call this bold 11.

[01:05:37] Christopher David: And the response format is going to be in array.

[01:05:45] Christopher David: And we say that invoice equals this request gets decode bold 11.

[01:06:03] Christopher David: And we just return that.

[01:06:25] Christopher David: And then over here.

[01:06:29] Christopher David: Instead of decode invoice, we'll call this. So instead of again, voice will call us decode invoice.

[01:06:39] Christopher David: That's trying to get.

[01:06:47] Christopher David: Oh, yeah. Pay E alias.

[01:06:51] Christopher David: Sulu node one. Hey, Sulu node one. Let's pay it.

[01:06:55] Christopher David: L sat. You can edit update that to al for a two.

[01:07:01] Christopher David: I'm going to create that bit coin.

[01:07:13] Christopher David: Okay. So actually we had to write our own method called decode invoice.

[01:07:25] Christopher David: Which now runs and returns this.

[01:07:33] Christopher David: Continue. Okay. So like write our full new handle L for two request methods. So we can copy paste.

[01:07:51] Christopher David: It's looking for an is invoice paid method. Do I have that?

[01:08:07] Christopher David: Yeah.

[01:08:19] Christopher David: Or would that just return it not found.

[01:08:23] Christopher David: Okay. Let's try this.

[01:08:47] Christopher David: Let's run this is paid method. So we know that this works.

[01:08:53] Christopher David: Let's try this.

[01:09:17] Christopher David: Payment hash.

[01:09:35] Christopher David: Okay. Let's see if this returns.

[01:09:41] Christopher David: It returns not found.

[01:10:05] Christopher David: Okay. First of all, is payment hash the right field.

[01:10:35] Christopher David: Okay.

[01:10:45] Christopher David: And my correctly pulling this out of this object.

[01:11:03] Christopher David: Yes, I am.

[01:11:09] Christopher David: And yet when I pass it to is invoice paid.

[01:11:23] Christopher David: It's just calling this get invoice.

[01:11:35] Christopher David: So I could re-implement this and say if it returns a for a. Actually, you know what? What is the status code there?

[01:11:45] Christopher David: Don't want to fix that or skip it.

[01:11:49] Christopher David: Okay. Here's what I'm going to do. For now, I'm just going to assume that this is not paid.

[01:11:55] Christopher David: We're not going to try to look to see if it is paid. I don't care. Let's just try to pay.

[01:12:03] Christopher David: Okay. So what does ad invoice do?

[01:12:13] Christopher David: I'm out of value. Post invoice.

[01:12:20] Christopher David: Post invoice.

[01:12:43] Christopher David: I don't want to create an invoice. I have an invoice. I need to pay the invoice.

[01:12:59] Christopher David: It's not looking up to see if it's found.

[01:13:03] Christopher David: I guess it's only checking on its node.

[01:13:09] Christopher David: I'm guessing. Okay. So I'm guessing the it's not being found because the invoice is being generated by solos node.

[01:13:19] Christopher David: The alley node doesn't know about it. I'm guessing that the get invoice is only worked with invoices that we've posted or created via the alviap. I guess that makes sense.

[01:13:31] Christopher David: Because those two nodes are not talking to each other. Fine. So we're not adding an invoice. We are paying.

[01:13:43] Christopher David: I don't know. Pay an invoice. Pay it. Payments. Pay a lightning invoice. There we go.

[01:13:59] Christopher David: Do I have a method for that?

[01:14:06] Christopher David: Me. Okay. Fortunately, this is easy enough to extend. Got to copy this.

[01:14:15] Christopher David: I cannot copy this.

[01:14:28] Christopher David: I need to be able to copy this into the chat you be.

[01:14:38] Christopher David: All right. Let's write a method by hand like an asshole.

[01:14:44] Christopher David: Public function. Pay invoice. Take you. Both.

[01:14:49] Christopher David: 11. We're going to return and array.

[01:14:59] Christopher David: All right. In voice.

[01:15:11] Christopher David: I'll call it payment equals this request post.

[01:15:24] Christopher David: Payments. Blot. 11. Does it take an optional.

[01:15:34] Christopher David: Is object body. Is it does?

[01:15:50] Christopher David: Both 11 is both 11. In voice.

[01:15:58] Christopher David: In voice is both.

[01:16:06] Christopher David: Miss my tab auto completes.

[01:16:13] Christopher David: All right. Payment is that.

[01:16:21] Christopher David: Return the payments.

[01:16:25] Christopher David: Okay. Let's see if it'll pay. I think I'm logged in here with that account.

[01:16:35] Christopher David: No.

[01:16:41] Christopher David: Okay.

[01:16:52] Christopher David: Oh.

[01:16:59] Christopher David: So that's my personal accounts.

[01:17:03] Christopher David: And then the one I'm using for.

[01:17:06] Christopher David: Open agents. I'm guessing I just have that long in here.

[01:17:11] Christopher David: My logged in differently.

[01:17:15] Christopher David: I'm going to add the app. Open agents.

[01:17:26] Christopher David: I added this.

[01:17:32] Christopher David: Nice.

[01:17:51] Christopher David: Okay. So there's one of the C how many stats I had and then make sure that it develops.

[01:17:58] Christopher David: And let's pay some list of suit.

[01:18:04] Christopher David: So let's go back to here.

[01:18:09] Christopher David: When we have the payment hash.

[01:18:12] Christopher David: No.

[01:18:17] Christopher David: All right. Pass the entire invoice string in.

[01:18:23] Christopher David: I think I passed the entire invoice string.

[01:18:28] Christopher David: Let's try it.

[01:18:38] Christopher David: Let's see if that works.

[01:18:47] Christopher David: All right. We have three eight nine stats there.

[01:18:52] Christopher David: Four two four three nine.

[01:19:01] Christopher David: Four two four three nine.

[01:19:16] Christopher David: Four two four three three nine. We have made a 50 sat payment via L 402.

[01:19:23] Christopher David: Now if we were to have saved that.

[01:19:26] Christopher David: We're going to have a lot of money.

[01:19:36] Christopher David: We're going to have a lot of money.

[01:19:41] Christopher David: We're going to have a lot of money.

[01:19:48] Christopher David: And then we have a lot of money.

[01:19:55] Christopher David: And then we have a lot of money.

[01:20:00] Christopher David: And then we have a lot of money.

[01:20:03] Christopher David: And then we have a lot of money.

[01:20:08] Christopher David: And then we have a lot of money.

[01:19:59] Christopher David: With this response, now we write that function using this in Vose.

[01:20:17] Christopher David: Based on the successful response from your PayInvoice method, you now have all the necessary information

[01:20:23] Christopher David: to complete the L40 request, including the payment pre-image.

[01:20:27] Christopher David: Here's the revised handle L40 request method in cooperating the PayInvoice method.

[01:20:32] Christopher David: Give me, do not stop right here, JGPT, I will destroy you, literal destruction.

[01:20:38] Christopher David: PayInvoice.

[01:20:41] Christopher David: No!

[01:20:52] Christopher David: Alright, well, we know that we're going to be able to clean up a bunch of this.

[01:21:00] Christopher David: We need the pre-image.

[01:21:04] Christopher David: We'll do like proper error handling stuff on this layer.

[01:21:08] Christopher David: Let's do pre-image equals payment, payment underscore, pre-image.

[01:21:18] Christopher David: Is that all we need?

[01:21:22] Christopher David: We don't need invoice detail, we don't need is paid.

[01:21:29] Christopher David: We don't need whatever that is.

[01:21:33] Christopher David: We're not doing that, we're not doing that, we already have it now.

[01:21:40] Christopher David: We do need a simple token to work.

[01:21:45] Christopher David: Let's see if L40 token works.

[01:21:55] Christopher David: Or at least looks good enough, it's going to work, oh my gosh.

[01:22:00] Christopher David: Oh my gosh.

[01:22:02] Christopher David: Complete failure, charge me, T.

[01:22:04] Christopher David: More glory from me.

[01:22:05] Christopher David: Okay, let's try it.

[01:22:16] Christopher David: And if you deduct some more saps out of mind, oh yeah, I mean I think all year.

[01:22:29] Christopher David: It's got a thingy, it's got a colon, and then another thingy.

[01:22:37] Christopher David: And deducting another 50saps, excellent.

[01:22:42] Christopher David: Excellent.

[01:22:45] Christopher David: So now, in a perfect world, all I would do is remove my DV here, and then that would work.

[01:22:54] Christopher David: I don't know if it's, oh yeah, if L42 token added as an authorization header, will we need a massage it or what?

[01:23:08] Christopher David: And then that gets passed back to what?

[01:23:17] Christopher David: We're expecting the output to be that.

[01:23:21] Christopher David: No, we're not going to start a specific temperature.

[01:23:26] Christopher David: All right, here's what we're going to do. We're going to just die and dump the outputs. I'm not sure what to assert here.

[01:23:32] Christopher David: And I just want to see the glorious output of our successful L40 call.

[01:23:50] Christopher David: Yes, oh, ladies and gentlemen, we've just made our first successful L402 API call.

[01:24:06] Christopher David: Our Adrian hit the end point got back to 402 say hey, pay me with the information to pay it.

[01:24:12] Christopher David: Pay it, sent the proof of payment back and got the information between behind the sweet pay world API.

[01:24:21] Christopher David: Okay, let's do some proper assertions here so we can complete our test.

[01:24:30] Christopher David: Should I even inform, charge a bit to you?

[01:24:33] Christopher David: You've cracked out, but I used my human reasoning powers.

[01:24:44] Christopher David: Successfully implement this function.

[01:24:49] Christopher David: And we received back the following output.

[01:25:04] Christopher David: We need to.

[01:25:12] Christopher David: We need to make proper parsing assertions in this test. So fix our test. So it passes now.

[01:25:34] Christopher David: Do you feel no guilt? Do you feel no shame, chat GPT for failing me?

[01:25:45] Christopher David: Y'all decode this here now. We may want to move that to the function.

[01:25:50] Christopher David: I think that DDD yanks. What happens if I paste or V that doesn't do anything? What if I do that?

[01:26:09] Christopher David: Copy.

[01:26:11] Christopher David: Do not expect the temperature to be 10.

[01:26:27] Christopher David: Do not expect a specific temperature. Only that it is the right variable type.

[01:26:38] Christopher David: I forgot if it's in terms of float there.

[01:26:46] Christopher David: Was it float? I have to look at it with my eyeballs.

[01:26:53] Christopher David: The temperature F is a float of their floats.

[01:27:00] Christopher David: Oh, it gives us 10bF.

[01:27:06] Christopher David: Oh, it does give us 10bF.

[01:27:08] Christopher David: Very nice.

[01:27:14] Christopher David: Uh, bro, you are assigning 10c to temperature where I am an American and we use Fahrenheit fixed it.

[01:27:28] Christopher David: I apologize.

[01:27:37] Christopher David: Realize my entire test.

[01:27:47] Christopher David: Yes, I want to do the Fahrenheit temperature in London. That's exactly what I want.

[01:27:56] Christopher David: And this time it specifies Fahrenheit.

[01:28:00] Christopher David: You, you curve. I'm not going to do that.

[01:28:03] Christopher David: Let's go learning my V and key is temp F.

[01:28:10] Christopher David: Expect the city to be London.

[01:28:13] Christopher David: Expect is float.

[01:28:17] Christopher David: Right, pretty sure we have a helper for that.

[01:28:21] Christopher David: To be.

[01:28:26] Christopher David: Come on.

[01:28:27] Christopher David: Floats.

[01:28:29] Christopher David: Right.

[01:28:46] Christopher David: Don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don't don don't don don't don don't don don't don don don don don don don

[01:29:16] Christopher David: okay so our unit test passes the ordinarily new do a feature test first then drop down to a unit test we just kind of like went into it

[01:29:32] Christopher David: we're expecting the output to be blah blah blah

[01:29:38] Christopher David: okay now here's the real test we can do the alpha or two thing in isolation

[01:29:47] Christopher David: but now we want to see if we were to confirm that we can put the alpha or two

[01:29:55] Christopher David: building block within a broader agent to workflow because if we can't then that doesn't

[01:30:01] Christopher David: do as much good because we're building this stuff up so let's first make sure

[01:30:09] Christopher David: all of our test pass and then we will end up putting that in behind the

[01:30:15] Christopher David: integration group because it's gonna take X number of seconds and this is cool

[01:30:21] Christopher David: because if the you know endpoint of solu or some endpoint provider is slow

[01:30:29] Christopher David: then that they've just provided an incentive for someone else to do that same functionality

[01:30:34] Christopher David: maybe charge a little bit more they say ours is faster it just allows a marketplace to form

[01:30:39] Christopher David: and paired with our X to the mozzin plugins for portable code oh my gosh

[01:30:48] Christopher David: this is gonna be huge okay so our test pass that's nice

[01:30:52] Christopher David: look at my test to a search stop let's just like go let's just go try it

[01:31:01] Christopher David: what we'll do is we'll create an agent via seeding same as we had been doing previously

[01:31:12] Christopher David: I don't think we can create an agent yet via the interface we can only look at them

[01:31:24] Christopher David: I'm just confirm that yeah so that's the concierge so just if you're new here

[01:31:33] Christopher David: so we have our agents view screen here we have the name of the agent description

[01:31:39] Christopher David: of the agent the lightning south balance we're not hooking that up yet maybe we'll do that

[01:31:44] Christopher David: next video or soon the owner and then all of the tasks that the agent can do

[01:31:50] Christopher David: or listed underneath it the task flow over the step flow of respondal valves is

[01:32:00] Christopher David: valid that the user is inputting there's like a string I'm betting it to a

[01:32:06] Christopher David: vector via the GPU to an GPU to a network currently running a cosine similarity search

[01:32:13] Christopher David: comparing the embedded vector of the input to the embedded vector of a given knowledge base

[01:32:21] Christopher David: in this case we've just vectorized some strings like with stat with basic facts about

[01:32:25] Christopher David: of an agent's we're getting the you know this basic retrieval augmented generational

[01:32:33] Christopher David: getting the top key results from there passing it to the mixed will 7b llm hosted

[01:32:37] Christopher David: together together 8b odd and then just for the demo like vowel counting plugin we

[01:32:45] Christopher David: passed the response from the AI from the llm API to count the vowels of it and this

[01:32:53] Christopher David: is kind of nonsensical but so I think this should work which is kind of test our current

[01:33:00] Christopher David: workflow here if I'm going to network what is the meaning of life so this is not

[01:33:11] Christopher David: going to give us the well this is also not going to give anything relevant from the

[01:33:16] Christopher David: knowledge base so it's not probably the best but what it should give us is the yeah it

[01:33:21] Christopher David: gives us that there's there's 200 vowels in the llm response okay so this is an

[01:33:28] Christopher David: example of an agentic workflow that uses our implemented rag functions that are the other

[01:33:34] Christopher David: four categories and that's step-action thing as well as plugin this is the new one that

[01:33:38] Christopher David: we added that loads the wasom plugin demo plugin and passes that input in here and returns

[01:33:45] Christopher David: to resolve that so it would be super cool if we were to copy this cedar the cedar the

[01:34:04] Christopher David: database cedar that just sets this up and adds l 402 as a step and which also ideally

[01:34:19] Christopher David: has it be somewhat logical like if we're calling the weather and then also counting the

[01:34:24] Christopher David: vowels can be like think of let's see if we can prompt gbt that's to give gbt here a

[01:34:29] Christopher David: opportunity to redeem itself so let's open for myself what our cedars are looking

[01:34:38] Christopher David: like where's my file

[01:34:44] Christopher David: I apologize for my horrendous okay so concierge with plugin cedar oops

[01:35:05] Christopher David: so what this does is it make sure there's a user it creates a database entry for

[01:35:29] Christopher David: plugin passing in the HTTP URL of wasom creates the agent created task and then the steps

[01:35:44] Christopher David: which include plugin so this is the code and then the the knowledge base data points for open

[01:35:51] Christopher David: platform for a agent's marketing copy blah blah blah okay here's what we're gonna do we're gonna

[01:36:02] Christopher David: yank everything in this file we're gonna pop over to mr. Chad jippity here and we're gonna say paste

[01:36:17] Christopher David: oh I need to remove the data points out of there okay I'll just do this let's stop that out

[01:36:40] Christopher David: data points to brain with vectorized strings with information about open agents.com a community platform for building a

[01:36:56] Christopher David: iagents okay we're gonna do that okay now we're gonna say here is our database cedar that sets up an example

[01:37:15] Christopher David: a iagents called concierge also with a demo wasom plugin step you can see it does basic retrieval augmented

[01:37:35] Christopher David: generation using a an example knowledge base of vectorized strings with information about our product

[01:37:51] Christopher David: open agents.com we added the vowel counter as an example wasom plugin we now want to make a new version of

[01:38:06] Christopher David: this called concierge with l4 to concierge with plugin and l4 to using our new l4 to step category

[01:38:21] Christopher David: let's try to think of a nice demo flow where we are able to have a somewhat logical agent that also steps through all three things here

[01:38:45] Christopher David: matching the user query against the open agents knowledge base counting the vowels in a given

[01:38:58] Christopher David: string via the plugin and checking the weather in a city please write a new cedar with the appropriate steps

[01:39:23] Christopher David: write the full file so i can copy paste it okay so i think

[01:39:43] Christopher David: i want to do first is

[01:39:55] Christopher David: let's just copy

[01:39:59] Christopher David: We have so cp Concierge with Plugin Cedar as Concierge with Plugin and L4O2 Cedar.

[01:40:13] Christopher David: And then VIA that.

[01:40:23] Christopher David: Concierge with Plugin and L4O2 Cedar.

[01:40:35] Christopher David: Do all the same stuff.

[01:40:41] Christopher David: Let's see what this says here.

[01:40:52] Christopher David: Agent 2.

[01:40:53] Christopher David: There's no conflict.

[01:40:54] Christopher David: That's nice.

[01:40:56] Christopher David: I don't know if that will work actually.

[01:41:09] Christopher David: Let's see what's in there.

[01:41:24] Christopher David: Let's see what's in there.

[01:41:42] Christopher David: Okay let's try it.

[01:41:43] Christopher David: This is all the same stuff.

[01:41:53] Christopher David: That's after Plugin.

[01:42:10] Christopher David: What did you do?

[01:42:23] Christopher David: Okay.

[01:42:30] Christopher David: So we're going to remove this.

[01:42:37] Christopher David: I guess we're going to keep steps 1, 2, 3, 4.

[01:42:43] Christopher David: To change 5 at all.

[01:42:54] Christopher David: Looks like it did not change 5.

[01:43:04] Christopher David: It's just growing this step on there.

[01:43:06] Christopher David: Okay it did not help us make it logical but I don't really care.

[01:43:10] Christopher David: I just want the demo copy that only.

[01:43:25] Christopher David: Oh oh oh this is passing up the URL as a parameter.

[01:43:37] Christopher David: We're going to put it as input.

[01:43:44] Christopher David: This is not yet due.

[01:43:47] Christopher David: We're right now hard coding the URL but I want to be able to set it at the level of the

[01:43:52] Christopher David: step and pass it in.

[01:43:55] Christopher David: We need to pass it in as a get from the parameters like we do custom like with Plugin.

[01:44:02] Christopher David: These are all Gs for killin.

[01:44:06] Christopher David: I think that might do it for now.

[01:44:10] Christopher David: Let's give us a try.

[01:44:15] Christopher David: Let's run the Cedar from our root directory.

[01:44:22] Christopher David: So let's do sail artisan db cedar concierge with Plugin and L4O2 cedar.

[01:44:35] Christopher David: Cedar is not okay.

[01:44:37] Christopher David: Cedar is not.

[01:44:40] Christopher David: Seating database.

[01:44:41] Christopher David: Now if I go to agent slash 2 hopefully I'll see it in the interface.

[01:44:46] Christopher David: I do.

[01:44:48] Christopher David: Concierge with Plugin and L4O2 with chatbot that matches user queries, counts of owls and checks

[01:44:52] Christopher David: the weather.

[01:44:53] Christopher David: How cool.

[01:44:55] Christopher David: Oh my goodness.

[01:44:58] Christopher David: Alright with the knowledge that we are still hard coding London that's okay we can

[01:45:05] Christopher David: pass in the parameters in a second.

[01:45:16] Christopher David: Let's check our sats over at 424139 and then let's see yeah count the owls and then check

[01:45:31] Christopher David: the weather.

[01:45:35] Christopher David: So what's the weather in London?

[01:45:41] Christopher David: But also first count the owls in what's Mixer 7b thinks about my requirements.

[01:45:50] Christopher David: There we go.

[01:45:55] Christopher David: Run it.

[01:45:56] Christopher David: That's my sin will have it like show the updates of each step as it goes along.

[01:46:04] Christopher David: Alright and error.

[01:46:06] Christopher David: You know we wouldn't want it to.

[01:46:07] Christopher David: We wouldn't want it to work on the first trial.

[01:46:14] Christopher David: Alright so undefined array key input.

[01:46:20] Christopher David: Oh yeah we were we hard coded the.

[01:46:30] Christopher David: So we may actually need to fix that now.

[01:46:32] Christopher David: So we're going to go into step actions.

[01:46:39] Christopher David: Line 17.

[01:46:41] Christopher David: Yeah see here we're not doing anything with this input because we're just calling that

[01:46:49] Christopher David: suu-yuro.

[01:46:57] Christopher David: Okay let's just do that.

[01:46:59] Christopher David: I just want to see it work calling me 0402 endpoint via our interface and then we can

[01:47:07] Christopher David: like refactor the proper data passing layer.

[01:47:12] Christopher David: Okay let's try it.

[01:47:23] Christopher David: Did I not hit the button hard?

[01:47:30] Christopher David: Here we go.

[01:47:32] Christopher David: Okay undefined array key you're up.

[01:47:34] Christopher David: Oh we did not pass in the prem.

[01:47:38] Christopher David: So easy fix.

[01:47:42] Christopher David: In the category.

[01:47:48] Christopher David: In the I think we do it that in step executed.

[01:47:55] Christopher David: Or do we.

[01:48:02] Christopher David: Or do we do that when we define this step.

[01:48:07] Christopher David: Or do we do it when we define these tasks.

[01:48:15] Christopher David: Oh we think about this.

[01:48:35] Christopher David: There's a point where we handle if it's a plugin.

[01:48:40] Christopher David: We add some prams to pull out of like check the prams for that thing.

[01:48:55] Christopher David: Oh we might do it in agent run.

[01:49:09] Christopher David: Yeah there we go.

[01:49:19] Christopher David: Yeah so if the step category is plugin augment the input with prams.

[01:49:25] Christopher David: So separately here we just say.

[01:49:33] Christopher David: Yeah else if step category is L42 then we need to decode our prams.

[01:49:52] Christopher David: And we need to say that the input which we're not doing anything with right now.

[01:50:02] Christopher David: Is.

[01:50:05] Christopher David: Yeah we can have that just be the same as up here.

[01:50:10] Christopher David: Oh I did a VIM action.

[01:50:13] Christopher David: And then we need the URL to be set there.

[01:50:28] Christopher David: And then we're moving this.

[01:50:38] Christopher David: Okay so that actually you know semicolon there.

[01:50:45] Christopher David: So in this case we are then not going to want to hard code.

[01:50:55] Christopher David: We're getting the URL from the input.

[01:51:03] Christopher David: And then let's just make sure that our L42 service uses the URL that gets passed in.

[01:51:11] Christopher David: It does.

[01:51:15] Christopher David: Okay so if I say at the level of the cedar.

[01:51:32] Christopher David: That I want the URL to be not this weird thing here.

[01:51:41] Christopher David: I want you to get the weather in Austin.

[01:51:47] Christopher David: Okay that's great because now when you create the step that's where you'll hard code or you'll put in the city that you actually care about.

[01:51:57] Christopher David: That's where the UI thing but at least our backend will be set up to support any given URL that's passed in.

[01:52:05] Christopher David: And we could very easily tweak this like get that from the user input if we want to but that's not super important right now.

[01:52:12] Christopher David: Okay let's um quit out of here.

[01:52:17] Christopher David: Let's reset our database.

[01:52:27] Christopher David: Actually I don't know if that's going to work with our um.

[01:52:33] Christopher David: Plug in extension thing that we're doing.

[01:52:35] Christopher David: Let me make one last change to that.

[01:52:44] Christopher David: Let me go back to the cedar.

[01:52:50] Christopher David: And I just changed the agent.

[01:52:52] Christopher David: I need a three so we can run that.

[01:52:57] Christopher David: Without an agent we said that it was.

[01:53:02] Christopher David: Okay so let's run that cedar.

[01:53:07] Christopher David: Okay so let's try this one more time.

[01:53:17] Christopher David: Um please tell me the weather in Austin, Texas.

[01:53:25] Christopher David: But also comment on my request while showing me how many value vowels are there.

[01:53:40] Christopher David: Although the LMT traded doesn't matter.

[01:53:44] Christopher David: This is a kind of a non-sensical flow but we're just demoing that we have all these pieces working.

[01:53:53] Christopher David: All right of course another error.

[01:53:55] Christopher David: Excellent.

[01:53:56] Christopher David: Cannot access offset of type string on string on line 201 in agent.

[01:54:17] Christopher David: So in this case the output of the previous thing is a just straight up output.

[01:54:24] Christopher David: We didn't return JSON but you got to kind of mungus and data files a little bit.

[01:54:30] Christopher David: But that actually doesn't matter.

[01:54:32] Christopher David: Actually not even doing anything with this so I'm actually just going to.

[01:54:35] Christopher David: Can I comment that out?

[01:54:48] Christopher David: Okay.

[01:54:53] Christopher David: The moment of truth.

[01:54:57] Christopher David: Please tell me the weather in Austin, Texas.

[01:54:59] Christopher David: But also comment on my request while showing me how many vowels are in your response.

[01:55:17] Christopher David: Come on.

[01:55:31] Christopher David: You can do it.

[01:55:33] Christopher David: You can do it.

[01:55:43] Christopher David: All right.

[01:55:44] Christopher David: Everybody.

[01:55:45] Christopher David: We have successfully called the L42 endpoint at the end of our agent to workflow.

[01:55:50] Christopher David: We're right now just showing the input and output of the final step.

[01:55:55] Christopher David: We've got to kind of make it more nice showing the input of each step.

[01:56:01] Christopher David: And the reason that took our what?

[01:56:03] Christopher David: Eight seconds or so is because we're calling look four different APIs.

[01:56:06] Christopher David: We're calling the GPU to open network for the embedding that takes a second or two.

[01:56:11] Christopher David: Coach I said Larry search.

[01:56:12] Christopher David: That's relatively fast.

[01:56:13] Christopher David: That takes a second or two to go to the together API.

[01:56:16] Christopher David: We're loading the X to some while wasn't plugged in from a remote URL.

[01:56:21] Christopher David: Parts a not.

[01:56:22] Christopher David: Pass that it takes a second or two.

[01:56:24] Christopher David: And then we're calling the solu endpoint.

[01:56:27] Christopher David: Getting the L42 back.

[01:56:30] Christopher David: Paying it via alby.

[01:56:33] Christopher David: Coming back.

[01:56:34] Christopher David: And then passing that back again to solu.

[01:56:38] Christopher David: That's to get the actual endpoint that was behind the L42.

[01:56:42] Christopher David: Okay.

[01:56:43] Christopher David: So we have examples of like the six building blocks that are needed to build up entire

[01:56:47] Christopher David: Agentic workflows.

[01:56:48] Christopher David: Now including L402.

[01:56:51] Christopher David: And we'll add a little kind of like progress indicator.

[01:56:53] Christopher David: So you can see better.

[01:56:54] Christopher David: Oh, what's all going on.

[01:56:56] Christopher David: But we're basically done now on what is the like core back end functionality of being able to compose

[01:57:03] Christopher David: Agents out of basically any arbitrary building block.

[01:57:08] Christopher David: And now we just need to kind of add the little nice UI features and community features to let people kind of build each others build

[01:57:16] Christopher David: Agents using each others plugins and L42 end points.

[01:57:21] Christopher David: So that might take us you know a week or so.

[01:57:26] Christopher David: Thanks for tuning in.

[01:57:27] Christopher David: See us in.