I built a 24/7 Claude Code setup for trading — Transcript
Full transcript
- 0:00Today, I'm going to show you a Cloud
- 0:01Code setup that I just did on my Mac
- 0:04mini, which is a remote machine that I
- 0:06have access to. In my case, that is on
- 0:07my home's network, but it could be
- 0:09anywhere in the world. And this allows
- 0:11me to run algo trading research for
- 0:1424/7. So, not for minutes or hours, this
- 0:17could literally be for days. And that
- 0:19allows me to ask for very high sharp
- 0:21ratio strategies. And I can even set
- 0:23some high criteria thanks to Monte Carlo
- 0:26to ensure the strategies that the agent
- 0:28finds for me aren't over fit. So, this
- 0:30is like a dream come true because until
- 0:32recently we did not have access to
- 0:34models that could do this. And thanks to
- 0:36Cloud Code subscriptions, [music]
- 0:37it's even going to be affordable for me.
- 0:39If you have watched my previous videos,
- 0:41I always say that in order to trade
- 0:43successfully, you're going to need more
- 0:45than just one good strategy. In fact,
- 0:47the only holy grail of trading that I
- 0:49have found is if you had a portfolio of
- 0:5120, 30, or maybe even 50 strategies. And
- 0:54this setup helps me to reach that goal
- 0:56as fast as possible. Now, before I
- 0:58continue, I got to say I am not advisor
- 1:01and this video is for educational only.
- 1:03So, with that out of the way, let's get
- 1:05right to the video.
- 1:07As always, I'm going to be using the
- 1:08Jesse framework for the algo trading
- 1:10side of things. But, I'm not going to go
- 1:12through the installation steps in this
- 1:14video. You can check out the
- 1:15documentation, which is really easy to
- 1:17follow, or you can watch my previous
- 1:19tutorials about how to set up Jesse.
- 1:21But, in this video, the goal is to do it
- 1:23inside my remote Mac mini. So, in front
- 1:25of me, I have the screen sharing app of
- 1:28macOS and I've already added my Mac mini
- 1:31machine. So, if I click on it, I'm going
- 1:32to be able to log in to it. So, I'm
- 1:35going to enter my password and there we
- 1:36go. So, in it I have the absolute bare
- 1:39minimum installed. And that is
- 1:41intentional because I just need to run
- 1:43Cloud Code and Python and Jesse in it.
- 1:46That's it. But, just in case I have some
- 1:48browser, some VPN app, and that's it.
- 1:49So, nothing that concerns you. And I
- 1:51could enter a terminal app inside here
- 1:54and continue. But, I don't want to do
- 1:57that. Instead, what I prefer to do is to
- 1:59use this via my own terminal app inside
- 2:02my own machine. So, I've already created
- 2:05an alias for this. So, when I say SSH
- 2:08Mac mini, it's going to enter it. In
- 2:09case you're interested to see what's
- 2:11behind this command, this is it. So,
- 2:13nothing fancy. SSH, then my username,
- 2:16and the local IP address of that machine
- 2:18on my home's network. So, let's enter
- 2:21it. And now I am logged in to that new
- 2:23machine. Next, I'm going to CD into my
- 2:25Jesse project on this machine. Now, for
- 2:27me, that is going to be CD Jesse, and
- 2:30then I'm going to go back, and then find
- 2:33the gym project. There we go. Now, I
- 2:35have also automatically activated the
- 2:37correct conda environment. Now, in your
- 2:39case, that's going to be conda activate,
- 2:41and then the name of that environment,
- 2:43which for me is Jesse 3.12. And I know
- 2:46it's already activated because I'm
- 2:47seeing it here. So, now if I, for
- 2:49example, say pip list, I'm going to find
- 2:52Jesse being installed here, right there.
- 2:55All right. So, very quickly, before I
- 2:57continue, I want to open another
- 2:58terminal window. So, let's first see
- 3:00which directory is this one. All right.
- 3:02So, I'm going to copy this one. I'm
- 3:04going to SSH into Mac mini one more
- 3:06time, and then I'm going to say CD, and
- 3:08then here. There we go. Now, the reason
- 3:10I did this is because now I want to
- 3:12firstly see if I can do Jesse run
- 3:15without any issues, and I can. Now, I am
- 3:17getting one error related to Python
- 3:19language server, but I don't really need
- 3:21this one, so I'm going to skip this. The
- 3:23important part is that I am getting this
- 3:25MCP command, and everything else seems
- 3:28to be working just fine. Now, before we
- 3:29continue, I'm going to stop this one
- 3:31more time, and I'm going to run this
- 3:34inside a tmux window. And the reason I
- 3:37want to do that is because I want to be
- 3:38able to close my local machine's
- 3:40terminal without this SSH window getting
- 3:43closed. So, for that, I'm going to say
- 3:45tmux new, and then I'm going to give it
- 3:48a name. There we go. And because I'm
- 3:50seeing this green line here, I know that
- 3:52everything is just correct. By the way,
- 3:55forget this line here. I'm going to have
- 3:57to fix this later, but for now
- 3:58everything seems fine. So, now I'm going
- 4:00to say Jesse run one more time and it's
- 4:03telling me that it doesn't know Jesse.
- 4:05That's because the correct conda
- 4:06environment isn't activated. So, now
- 4:08that that is done, it should work. And
- 4:11there we go. So, one more time inside
- 4:12this terminal window, I'm going to run
- 4:15the tmux window one more time. So,
- 4:17that's going to be tmux and then new and
- 4:22then dash s and I'm going to give it
- 4:24another name, but this time because I
- 4:26want to run the cloud code in it, I'm
- 4:28going to name it cloud. And there we go.
- 4:31Now, I could run the conda environment,
- 4:33but I don't think I need it, but it
- 4:34doesn't matter. Just in case I'm going
- 4:36to do that. And before running the cloud
- 4:38code, I want to ensure to add this MCP
- 4:41of Jesse in it. For that, I'm going to
- 4:43go to Jesse's documentation on the
- 4:46connecting cloud code and I'm going to
- 4:48copy this command here. Going to go back
- 4:51to my terminal and paste it here. But
- 4:53there is a catch here, guys. So, you see
- 4:55in this command, the MCP address has the
- 4:58port 9002, but in here I'm seeing it is
- 5:009003. So, I'm going to edit this into
- 5:049003 and hit enter. That's it. You see,
- 5:07it's telling me that this new MCP has
- 5:09been added. So, now next time I run the
- 5:11cloud in it, it's going to have access
- 5:13to that MCP. So, let's say cloud and
- 5:16then I'm going to create new session.
- 5:19So, I'm going to remove this continue
- 5:21flag here, but I'm going to leave
- 5:23permission mode to bypass permissions
- 5:25because I don't want it to keep asking
- 5:26me for annoying messages, but many
- 5:29people say this is dangerous, so you
- 5:31need to be careful. Feel free not to
- 5:32pass it, but again you're going to have
- 5:34to deal with so much, but I am going to
- 5:36do it especially because this is
- 5:37supposed to be an isolated environment
- 5:40meant for doing exactly this. So,
- 5:42there's not much that cloud could even
- 5:45mess with even if it wanted to, but in
- 5:47all these months that I've been using
- 5:49Cloud Code, I've never faced any issues
- 5:51with it. So, I'm just going to go with
- 5:52this. There we go. And you see, as soon
- 5:54as I ran that, in this terminal, I can
- 5:56see some requests being made into the
- 5:58MCP, and everything seems to be fine.
- 6:00Now, here, I'm also going to switch the
- 6:02model into Cloud Opus 4.8. At the time
- 6:06that you're watching this, maybe there's
- 6:08a new model out there. Who knows? But,
- 6:10let's go with this one just for now. All
- 6:12right. Now, before I move on, let's
- 6:14first test to see if Claude can access
- 6:16Jesse's MCP. So, I'm just going to ask
- 6:19it, "Hey Claude, how's it going? Can you
- 6:22access Jesse's MCP in order to create
- 6:24strategies, run backtests, or things
- 6:27like that?" There we go. So, you see,
- 6:28first of all, it's happy that I said hi
- 6:31to it, something really important that
- 6:33you should always do. And next, we can
- 6:35see that it has access to tools such as
- 6:38creating or editing strategies,
- 6:40backtesting, research and validation,
- 6:42optimization, Monte Carlo, significance
- 6:44testing, and candle data. So, this seems
- 6:47brilliant. Now, while that's going, I
- 6:49want to quickly remind you guys about
- 6:50our Telegram. It's the fastest way to
- 6:52get notified about my future work,
- 6:54whether it's a new tutorial or a tool
- 6:56that I create. Also, don't forget to
- 6:58check out our free Discord, where more
- 6:59than 5,000 members like you and I are
- 7:01hanging out there and helping out each
- 7:03other with algo trading, so we can all
- 7:05succeed together. The links for both are
- 7:07down in the description. All right. So,
- 7:08I cleared everything, and now we are
- 7:11ready to give the agent its prompt, its
- 7:14task to perform. And this is going to be
- 7:16a huge prompt, because I want it to do a
- 7:18lot for me, and I don't want it to just
- 7:21perform a quick task and just come back
- 7:23and give me the results. So, I want this
- 7:24to be fully automated, and I want it to
- 7:27work for hours or even days. So, I've
- 7:29prepared this prompt for you, so you
- 7:31guys can also copy and paste it, and
- 7:33feel free to edit it however you like.
- 7:35All right. So, I'm going to read it very
- 7:36quickly. I need it to act as a 24/7
- 7:38quant agent who can perform research. At
- 7:41the end, I am going to need 10 different
- 7:43strategies. Each of them must have a
- 7:45Sharpe ratio above 1.5 over the past 4
- 7:48years. So, this is a very difficult
- 7:50criteria for the agent, and in many of
- 7:53my previous tests, the model wasn't able
- 7:55to perform this well. So, let's see how
- 7:57it does now. And this is just too
- 7:59strict, guys. So, feel free to lower
- 8:01this, especially because if it can reach
- 8:04that number on one single strategy,
- 8:06that's going to be very, very difficult.
- 8:08All right, continuing. It doesn't matter
- 8:10if you try hundreds of different
- 8:12strategies or different versions of it.
- 8:13So, this is because I don't want it to
- 8:14just go and write like 50 strategies and
- 8:17come back and complain that I couldn't
- 8:19find it. So, I wanted to keep trying.
- 8:22Next, when you run a Monte Carlo
- 8:23simulation, I want the Sharpe ratio of
- 8:25the original backtest to be positioned
- 8:27in the middle between the median and the
- 8:29best 5%. So, this is to ensure that the
- 8:31result isn't overfit. So, this is my
- 8:33criteria for how I pick it. Again, this
- 8:35is too strict, guys. Like, usually, even
- 8:37if it's below 5%, that means it's good
- 8:40enough, but this time I'm saying it must
- 8:42be in the middle between median and the
- 8:45best 5%. By the way, guys, first when I
- 8:47started recording this video, I asked
- 8:49the agent to run multiple agents itself
- 8:51to take advantage of this feature of
- 8:54Cloud called workflows. But when I did
- 8:56that, the model often times would just
- 8:58run some stuff in the background, tell
- 9:00me that it's waiting for the result, and
- 9:02then it just silently died. And that was
- 9:04just horrible. So, that's why I switched
- 9:06into this version where I just ask one
- 9:09agent to do everything. So, let's remove
- 9:12this from before. Next, you do not have
- 9:14to pick only one symbol for this. It is
- 9:16okay to try different trading symbols.
- 9:18So, I've given it a list of trading
- 9:20symbols that I have already imported
- 9:22candles for, but even if I hadn't, the
- 9:24Jesse MCP is able to import these by
- 9:27itself, so that's also pretty cool. It's
- 9:29okay for you to find multiple strategies
- 9:31on the same symbol. Do not feel
- 9:32pressured to absolutely use all the
- 9:34symbols. So, this is also something
- 9:36else. Like, I want model two, for
- 9:37example, to write multiple strategies
- 9:39for BTC, let's say. So, it doesn't have
- 9:42to feel like it needs to find all the
- 9:4410,
- 9:45with each of them being on different
- 9:47symbols. Next, make sure to find me all
- 9:50sorts of trading strategies, and not
- 9:51just trend following. So, mean
- 9:53reversion, or maybe even greater
- 9:54strategies where we enter and exit at
- 9:56multiple points. Those are all fine.
- 9:58Notice that some of these symbols are
- 10:00low-cap altcoins. Some of them are so
- 10:03volatile or pouring quality that their
- 10:05prices are more likely to go down. This
- 10:07could be an opportunity to develop
- 10:09short-only strategies. So, I don't want
- 10:11the model to always think that the
- 10:13strategy must go both long and short at
- 10:16the same time. So, it's fine for some
- 10:18altcoins, for example, to only short
- 10:20them. So, that's also a valid scenario.
- 10:23You can also come up with whichever time
- 10:25frame that works best. However, I would
- 10:26prefer it if it was either 15 minutes,
- 10:2830 minutes, or hourly. Feel free to also
- 10:31use an anchor time frame, such as the 4
- 10:33hours, in your analysis, but not for
- 10:35trading time frame. The most important
- 10:37part is not to stop until you have found
- 10:39all 10 strategies. In the meanwhile,
- 10:41feel free to keep updating different
- 10:44report files in markdown format, so that
- 10:46I can easily monitor your progress. Keep
- 10:48the reports in a new folder called
- 10:50reports inside your project directory.
- 10:52This may take hours or even days, and
- 10:54that is perfectly fine with me. Do not
- 10:56interrupt to ask for permission. I trust
- 10:58your judgment. Only ping me if something
- 11:00is wrong, and you absolutely need my
- 11:02input. So, sorry, guys, if this was too
- 11:03long. It's just that I needed to be as
- 11:06specific as possible in the prompt, and
- 11:09I think this is going to perform better.
- 11:10So, let's go back to Cloud Code, and
- 11:13paste this whole thing in, and hit
- 11:16enter. So, let's go and come back a bit
- 11:18later. All right. It's been like 24
- 11:20hours, but it wasn't like what I
- 11:22expected. It wasn't exactly an
- 11:25uninterrupted 24 hours. The results are
- 11:28here, and they are acceptable, but
- 11:30again, they're not as good as I expected
- 11:33them to be. So, let's go through it. So,
- 11:35the first issue that I had was
- 11:37apparently Cloud Code these days has
- 11:39some sort of memory. And because as I
- 11:41mentioned just earlier in my previous
- 11:43prompt, which actually didn't work, I
- 11:45was using sub-agents and that wasn't
- 11:47working fine. So, when I asked the model
- 11:50to do this this time without the
- 11:52sub-agent, but you know, I didn't
- 11:53specifically mention that, it started
- 11:56using sub-agents again. So, I had to
- 11:58actually mention it that "Hey, I do not
- 12:01want you to use sub-agents anymore." So,
- 12:03that's the first thing that I had to do.
- 12:05By the way, I just changed the theme and
- 12:07now everything seems better on the dark
- 12:09mode. So, the first thing I needed to do
- 12:12was to specifically ask it, "Hey, do not
- 12:14use sub-agents for running things." So,
- 12:15that's the first thing I had to do or,
- 12:18you know, interruption that I faced and
- 12:20I had to fix. Next, it kept working and
- 12:23working, but it couldn't really find a
- 12:26strategy that would have given it the
- 12:28Sharpe ratio that I was asking for. So,
- 12:30that was a real for the model, which to
- 12:33be fair was expected. Like, I did not
- 12:36expect this to be able to find something
- 12:37really great in just a few minutes. So,
- 12:40that's why I said, "Hey, keep working
- 12:41for hours or days." But unfortunately,
- 12:44the model kept complaining. So,
- 12:46beginning with here, it said, "To be a
- 12:48straight with you, based on the evidence
- 12:49so far, tennis strategies each robustly
- 12:52with a Sharpe ratio more than 1.5 looks
- 12:54beyond what this single symbol can do."
- 12:57So, it asked if it could just stop and
- 13:00give me a lesser number. And this isn't
- 13:03what I wanted. So, I said, "Keep
- 13:04grinding for the 1.5." So, that's the
- 13:06first time I said this. And then, just
- 13:09like a while later, again it complained.
- 13:11So, it said, "I want to be straight with
- 13:13you. Across 12 optimizations and 45
- 13:16backtests, the evidence suggests that a
- 13:19robust Monte Carlo near median 1.5
- 13:22Sharpe is unreachable on single symbol
- 13:24in universe." So, I said that, "You know
- 13:26what? The numbers you are telling me
- 13:28like 12 optimizations and 45 back tests
- 13:31are nothing for this type of work. You
- 13:33should be thinking about hundreds of
- 13:34back tests. Keep going." So, this again
- 13:36is something I didn't expect Opus 4.8 to
- 13:39do because they said this model has been
- 13:41optimized to perform tasks for
- 13:44long-running hours, and this was
- 13:46literally nothing. So, this was really
- 13:48weird for me because if you're not
- 13:49reaching my token limits, why don't you
- 13:52just keep working? Like, this is
- 13:53supposed to be loop. Why is the model
- 13:55stopping early? And it's not just the
- 13:58only problem I've had with Opus lately.
- 14:00I feel like it has become really dumb
- 14:02ever since the Cloud Fable came out, and
- 14:05of course they shut it down later, but
- 14:07ever since I feel like Cloud could was
- 14:09not giving me the same quality as
- 14:10before. So, I just looked it up, and on
- 14:13Reddit I found this, and apparently many
- 14:15people are experiencing the exact same
- 14:17thing. So, maybe this is the reason. So,
- 14:19maybe in the near future they're going
- 14:21to fix this. All right, so this is
- 14:23something to remember, but even with all
- 14:25this, I was still able to get what I
- 14:28wanted out of this experiment. So, let's
- 14:30continue. Again, it continued working
- 14:32after I asked this, and finally at this
- 14:35point it had a breakthrough. So, first
- 14:36strategy over the gate. So, this one
- 14:39using the Soul UCT on the dual anchor,
- 14:44so 4 hours and daily, was able to
- 14:46achieve a sharp ratio of 1.5 while still
- 14:50it was passing my Monte Carlo filter in
- 14:53order to ensure the result isn't
- 14:54overfit. Then it kept working,
- 14:57and at this point it was able to find me
- 15:00five separate strategies that were all
- 15:03seeing the criteria that I had set for
- 15:06it. Now, this point I asked it to print
- 15:08out more details because I wanted to see
- 15:10them in a markdown file cuz for example,
- 15:12it wasn't even telling me on this table
- 15:15which symbols they were for or which
- 15:17time frame, and that was a bit annoying.
- 15:19I also asked it, "Please try finding
- 15:21other stuff for other symbols. These are
- 15:23all for sole. And then at this point it
- 15:25was able to find 10 different strategies
- 15:28with the criteria that I had set for it.
- 15:31The sharp ratio of all of them as you
- 15:32can see are at least 1.5. The max
- 15:34drawdown of all of them is acceptable.
- 15:37And even the number of trades that they
- 15:39were taking was pretty good. So this
- 15:41seems really good. And except this one
- 15:42which is on the borderline, all of them
- 15:44are also passing the Monte Carlo
- 15:47criteria which means that they are
- 15:49hopefully not overfit. Or you could say
- 15:51they are less likely to be overfit than
- 15:54any other thing that it could have found
- 15:56until that point. Now, I got these
- 15:58results today. So after my last prompt
- 16:01when I told the model, "Hey, just keep
- 16:03going. Try at least hundreds of back
- 16:05tests and do not stop." Apparently that
- 16:07one worked. So you could say that's a
- 16:09really good prompt that I'm going to use
- 16:11from now on. So just tell the model,
- 16:14"Hey, I need you to perform at least
- 16:15hundreds of back tests before stopping."
- 16:18You could even increase this to like
- 16:20thousands because if you do have a an
- 16:22Anthropic coding subscription and if
- 16:24your limits allow it, why not just let
- 16:27the model do this? And the fact that I
- 16:29was doing this on my Mac mini was also
- 16:31pretty helpful because if I had to do
- 16:33this on my own main machine, I would
- 16:35have needed my resources. So I couldn't
- 16:37just let it do keep doing research for
- 16:39this long. All right. Now that
- 16:41everything is ready, I can go to the
- 16:44reports file that it generated for me.
- 16:46So notice that I have opened that
- 16:49servers files inside my local Z editor.
- 16:53So it has this option called open
- 16:55remote. And then you simply pass the SSH
- 16:59address like the username and the IP for
- 17:01it. Now in case you don't remember from
- 17:03before, I was saying SSH Mac mini and I
- 17:06said that if I were to show you the
- 17:08command below it, it's going to be this.
- 17:10So SSH soleh at sign the local IP of
- 17:14that machine on my network. So notice
- 17:16this local address here, 192.168.1.103.
- 17:23This is important because Well, first of
- 17:25all, you're going to need to copy this
- 17:27and paste it to your Z editor in case
- 17:30you're also using this, or whichever
- 17:32editor really, such as Cursor. They all
- 17:34have this option which allow you to SSH
- 17:36into that remote machine and edit its
- 17:38files just very easily. So, I've already
- 17:41done that. I have access to all the
- 17:42files on the machine. And specifically,
- 17:44this is the project that I care for. So,
- 17:46I named it Jim. And we have this reports
- 17:49directory, right? So, this one, accepted
- 17:51strategies, is the one that has all the
- 17:53strategies that were meeting those
- 17:55criteria. Now, this is in markdown
- 17:57format, so by simply pressing the
- 17:59command, shift, and V, I'm going to be
- 18:00able to preview it in proper formatting.
- 18:04But this one is a bit zoomed out, and it
- 18:07makes it a little bit difficult to read.
- 18:09Also, for some reason, I cannot click on
- 18:11the links, probably because it doesn't
- 18:12have the proper styling. But anyways,
- 18:15so, my point is, let's actually go back.
- 18:17All right, so, the point is I have all
- 18:19the strategies that we found. It's
- 18:22telling me which files they are in. So,
- 18:23for example, I could just copy this one
- 18:25and search for it. So, here I can see
- 18:28the parameters that it has defined. And
- 18:30I'm guessing these are the results of
- 18:32the optimization that you ran. So,
- 18:33instead of keeping the other parameters,
- 18:35it tends to do this. And we can see how
- 18:38it defined the ATR indicator, the EMA,
- 18:41the Donchian channel. And here are the
- 18:44entry rules of the strategy. So, it says
- 18:46if the agree is one and closing price is
- 18:49above the upper band of the Donchian
- 18:50channel, go long. If it's the opposite,
- 18:53go short. And here's the position
- 18:55sizing. So, everything seems very neat
- 18:58and perfectly fine. All right, so, let's
- 19:01go back. Now, I can also see the result
- 19:03of the Monte Carlo that it ran, the
- 19:06backtesting. So, it says it's It had a
- 19:08Sharpe of 1.5. So, So looks awesome. But
- 19:10here's the thing. Suppose I want to take
- 19:13a quick look at the details of the back
- 19:16test or Monte Carlo. And you see it has
- 19:18generated URLs to the dashboard of
- 19:20Jesse. So this is really great and
- 19:22helpful. But if I were to just copy
- 19:24this, go to my Chrome browser and paste
- 19:26it in, it's not going to work. Why?
- 19:28Because this is using the local address,
- 19:30which is 127.0.0.1,
- 19:34which is for my local machine. But I
- 19:37want the address for that remote Mac
- 19:39Mini machine, right? And you remember it
- 19:40from before that I said this is going to
- 19:42be 192.168.1.103.
- 19:49So if I replace it with that, now it's
- 19:51going to work. So I'm going to enter my
- 19:53password and there we go. Now I'm able
- 19:55to actually see the result. So let's do
- 19:57something. I'm going to copy this
- 19:59address from here, go back to my code
- 20:01editor,
- 20:02open a new AI window, and I'm going to
- 20:06attach this file, and I'm going to ask
- 20:08it to replace that previous address with
- 20:11this one. So replace 127.
- 20:15Sorry, 001
- 20:17with this in all this file. All right,
- 20:20so it's going to do it for us. And while
- 20:22this is going, I want you to also pay
- 20:25attention to this. So suppose this is
- 20:27something I always want to do. Now I
- 20:30could simply edit the agents.md file of
- 20:33this project to do this for me. So if I
- 20:37do it here, then I would know that it
- 20:40would always do this. So whenever it
- 20:41wants to generate the report file for
- 20:43me, it will use the address, so this one
- 20:47for example, that would always work for
- 20:49me no matter where I'm opening it from.
- 20:51Even from the same machine with this
- 20:53address is going to work. So this is
- 20:54also a good tip to remember. All right,
- 20:56so we already have this address for back
- 20:58test. So let's do it one more time. All
- 21:00right, so this is for Monte Carlo, and
- 21:02we can see that the result of the
- 21:04original back test is in the middle of
- 21:06the simulations. This is a good sign and
- 21:08the sharp ratio of the original backtest
- 21:10is 1.30, which is even a little bit less
- 21:14than the median number. So, this is
- 21:15really good for whenever you want to see
- 21:18if the strategy is overfit or not. So, I
- 21:20like this result and going back to its
- 21:23backtesting results. So, especially this
- 21:25one, which is shows me the log scale
- 21:27equity curve, we can see that it is very
- 21:29nice and steady beating the benchmark,
- 21:32which is solid UCTT chart and here we
- 21:34can see the max drawdowns of the
- 21:36strategy. So, we can see the five worst
- 21:40periods. So, all of them seem
- 21:41acceptable. Next, we can see the monthly
- 21:44returns heat map chart. We can see it's
- 21:46profitable almost every single year
- 21:48except on 2024, where in five months in
- 21:52a row it was losing. So, this is also
- 21:55important to remember that the strategy
- 21:57is not going to be profitable every
- 21:58single month. And here we can see the
- 22:01monthly return distribution of the
- 22:02strategy. All in all, everything seems
- 22:04good. Next, we can see the average
- 22:07holding time of the strategy is around
- 22:0822 hours. The minute is 34%. So, this
- 22:12isn't a high win rate strategy, so
- 22:14that's something that is very important
- 22:16because if you are going to trade this,
- 22:18approximately you're going to lose seven
- 22:20out of every 10 trades. So, mentally
- 22:22this is going to be very tough. So,
- 22:24that's very important to remember and
- 22:27the average trade per month is around
- 22:2912. So, definitely not bad. Next, we
- 22:31have the Skeltner Breakout strategy
- 22:34here. So, let's copy it and search for
- 22:36it. All right, so here's the code. Here
- 22:38are the hyper parameters of the strategy
- 22:41and here we can see the other metas that
- 22:44it defined, the entry rules for long
- 22:46positions, for short positions, the
- 22:49position sizing for long positions. This
- 22:51is how it submits the buy order, how it
- 22:54defines the size of the position. So, it
- 22:57sees risking a certain percentage for
- 23:00each position and that certain
- 23:02percentage is go here. So, it is 2%. So,
- 23:06again pretty standard for adjusted
- 23:09strategy. So, let's go and check the
- 23:12back test results and also the Monte
- 23:14Carlo results. All right, so again an
- 23:16acceptable equity curve, which is
- 23:18growing nice and steady. The max
- 23:20drawdown of the strategy is very low,
- 23:22which means we can easily add to the
- 23:24size of the position. The minute is 42%,
- 23:27so I actually like this one better. The
- 23:29Sharpe ratio is 1.61, so this is
- 23:32definitely better than the previous
- 23:33strategy. Here's the worst five drawdown
- 23:37periods and here's the monthly return,
- 23:40so it is profitable every single year.
- 23:42Even on 2024, this one isn't like losing
- 23:45five months in a row, so this is really
- 23:47good to see. And so, all in all, this
- 23:50one seems like a better candidate for
- 23:53me. So, let's check out the Monte Carlo.
- 23:56So, the Sharpe ratio of it is 1.55.
- 24:00The median is 1.33.
- 24:02The best 5% is two. So, this one is
- 24:04almost in the middle. So, again a pretty
- 24:08solid strategy, I would say. I actually
- 24:10very much like this one and I preferred
- 24:13to the previous one. I think this one
- 24:15could actually be good for me. So, I
- 24:17could go through the other strategies as
- 24:19well, but you get the idea because the
- 24:21point was for you to learn how to set up
- 24:25your own AI Quant to do research for
- 24:28you. Now, I am going to submit at least
- 24:31one of these strategies on our
- 24:33strategies page on our website. So, if
- 24:35you want to check it out or see the
- 24:37results of the strategies on other
- 24:39period symbols or time frames, feel free
- 24:42to do so. So, there you go, guys. You
- 24:43just saw both the strong points and the
- 24:46weaknesses of this setup and how to fix
- 24:48the weaknesses. The results weren't
- 24:50exactly what I asked for initially, but
- 24:52it was more than acceptable and I now
- 24:55know exactly how to proceed in order to
- 24:58reach my initial goal. Now, if you like
- 25:00the video, please support me by liking
- 25:02the video and posting a comment to let
- 25:04me know what you think and subscribing
- 25:06to the channel because I make videos
- 25:08just like this one regularly and you
- 25:10don't want to miss them. My name is
- 25:11Saleh, guys. Thank you so much for
- 25:13watching. I'll see you in the next one.
About this transcript
This page contains the full transcript of I built a 24/7 Claude Code setup for trading by Algo-trading with Saleh, generated from the public captions YouTube serves with the video. The transcript has 4,972 words across 673 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.
What you can do with it
Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to translate the transcript into 100+ languages.
Free YouTube transcript tool
YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, translation to 100+ languages, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.