<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: NADAV BEN-HAMO</title>
    <description>The latest articles on DEV Community by NADAV BEN-HAMO (@v33systematic).</description>
    <link>https://dev.to/v33systematic</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4147151%2F1e82b7e7-3c2a-4ea2-a0c8-a25616218952.jpg</url>
      <title>DEV Community: NADAV BEN-HAMO</title>
      <link>https://dev.to/v33systematic</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/v33systematic"/>
    <language>en</language>
    <item>
      <title>Can AI Build My Trading Bot? What Claude Code Can and Can't Do</title>
      <dc:creator>NADAV BEN-HAMO</dc:creator>
      <pubDate>Mon, 26 Oct 2026 12:18:37 +0000</pubDate>
      <link>https://dev.to/v33systematic/can-ai-build-my-trading-bot-what-claude-code-can-and-cant-do-1ejh</link>
      <guid>https://dev.to/v33systematic/can-ai-build-my-trading-bot-what-claude-code-can-and-cant-do-1ejh</guid>
      <description>&lt;p&gt;"Just describe your strategy and the AI writes the bot" is one of the most seductive promises in retail trading right now. It's also one of the most misunderstood. Tools like Claude Code can genuinely speed up building a trading bot — but only for part of the job, and only if you already know what you're asking for.&lt;/p&gt;

&lt;p&gt;Here's a grounded look at what AI coding assistants are actually good at, where they fall apart, and how to use them without fooling yourself into thinking a working script means a working strategy.&lt;/p&gt;

&lt;h2&gt;
  
  
  What "AI builds my bot" really means
&lt;/h2&gt;

&lt;p&gt;When people say this, they usually mean one of three different things:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Code generation&lt;/strong&gt; — turning a described rule set into working Pine Script or Python.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Strategy design&lt;/strong&gt; — deciding what the rules should be in the first place.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Validation&lt;/strong&gt; — proving the strategy has an actual statistical edge before risking money on it.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Claude Code and similar tools are strong at #1. They are mediocre-to-dangerous at #2. And they cannot do #3 for you at all — that part requires your judgment, your data, and a healthy dose of skepticism applied to your own idea.&lt;/p&gt;

&lt;p&gt;Conflating these three is how people end up with a bot that runs perfectly and loses money reliably.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Claude Code is genuinely good at
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Translating clear rules into clean code.&lt;/strong&gt; If you can write your strategy as unambiguous if/then logic — "enter long when the 20-period EMA crosses above the 50-period EMA and RSI(14) is below 70, exit on a 2x ATR trailing stop" — an AI coding assistant will produce a reasonable first draft of that in Pine Script or Python faster than you'd type it yourself.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Catching your own inconsistencies.&lt;/strong&gt; A good back-and-forth with Claude Code often surfaces gaps you didn't notice: what happens on a gap-up open? What if two signals fire on the same bar? What's the position sizing rule when you already have an open position? These are exactly the ambiguities that break discretionary strategies when you try to make them systematic — a gap we'll dig into in a future piece on turning discretionary rules into objective ones.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Boilerplate and plumbing.&lt;/strong&gt; Data loading, indicator calculations, logging, basic backtest scaffolding, converting between Pine Script and Python syntax — this is where AI assistance saves the most real time, because it's mechanical work with a right answer.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Explaining unfamiliar code.&lt;/strong&gt; If you inherited a strategy script or are reading someone else's Pine indicator, Claude Code is a fast way to get a plain-English walkthrough before you trust it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where it falls apart
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;It will not tell you if your strategy idea is good.&lt;/strong&gt; Ask an AI assistant "is this a good trading strategy?" and you'll usually get encouraging, generic praise — not a rigorous answer. It has no way to independently evaluate whether your edge is real; "real" requires historical data, out-of-sample testing, and statistics the model isn't running unless you explicitly set that up and feed it the results.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;It can't see your broker, your data feed, or your actual fills.&lt;/strong&gt; Slippage, partial fills, exchange-specific order types, latency between signal and execution — none of this exists in a chat window. A bot that looks correct in code can still behave completely differently in production because of execution details the AI never had visibility into.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;It happily writes a strategy that's overfit.&lt;/strong&gt; If you ask for "the best parameters for this indicator combination," an AI assistant can and will help you grid-search your way into curve-fitting past data — producing a backtest that looks spectacular and a live result that doesn't. The model isn't being deceptive; it's just doing what you asked, optimization without complaint. The discipline to avoid this has to come from you. (We cover the warning signs in detail in a future piece on spotting an overfit backtest.)&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;It can introduce subtle bugs that pass a casual read.&lt;/strong&gt; Off-by-one errors in bar indexing, lookahead bias (accidentally using a value that wouldn't have been known yet at that point in time), timezone mismatches between data sources — these are the bugs that matter most in trading code, and they're exactly the kind that "looks right" on inspection. AI-generated code needs the same scrutiny as code from a junior engineer: useful, often correct, never assumed correct.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;It doesn't know your risk tolerance, account size, or what "acceptable drawdown" means to you.&lt;/strong&gt; Position sizing and risk management are personal constraints, not coding problems. An assistant can implement whatever sizing rule you specify, but it can't choose that rule for you responsibly.&lt;/p&gt;

&lt;h2&gt;
  
  
  A workflow that actually works
&lt;/h2&gt;

&lt;p&gt;The teams getting real value from AI-assisted bot-building tend to follow roughly this sequence, and the order matters:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Write the rules down in plain English first&lt;/strong&gt;, as objectively as you can — entries, exits, position sizing, and what happens in edge cases. If you can't write it without the word "usually" or "it depends," it isn't ready to automate yet.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Use AI to convert those rules into code&lt;/strong&gt;, not to invent the rules. Review every line it writes against your original rule list.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Backtest on data the strategy has never seen&lt;/strong&gt;, split cleanly into in-sample and out-of-sample windows. If performance craters out-of-sample, the strategy was fit to noise — not found.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Paper trade before funding it.&lt;/strong&gt; Live execution surfaces integration issues (feed delays, broker quirks, webhook reliability) that no backtest will show you. If you're wiring alerts to a broker automatically, there are specific ways to do that safely that are worth reading about before you flip the switch — we'll cover that in an upcoming piece on automating TradingView webhooks safely.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Keep a human in the loop on anything that changes the strategy itself.&lt;/strong&gt; Code changes can go through AI review. Strategy changes should go through your own judgment, informed by the out-of-sample results — not a chat suggestion.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  The honest summary
&lt;/h2&gt;

&lt;p&gt;AI coding tools are a genuine productivity upgrade for the &lt;em&gt;implementation&lt;/em&gt; step of building a trading bot. They are not a substitute for strategy design, statistical validation, or risk judgment — and treating them as one is how a syntactically perfect bot turns into a financially painful lesson.&lt;/p&gt;

&lt;p&gt;If you're not sure whether your current rules are specific enough to safely hand to an AI assistant — or specific enough to automate at all — it's worth checking before you write a single line of code.&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Not sure your strategy is ready to automate?&lt;/strong&gt; Take the free 12-question Strategy Readiness Test — it checks whether your rules are objective enough to build, points out the gaps, and walks through the path from defined rules to an AI-assisted build (Pine Script, Python, or Claude Code) to validation to automation: &lt;a href="https://v33systematic.com/lp-bot-builder-v2.html?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=readiness_test" rel="noopener noreferrer"&gt;Take the Strategy Readiness Test&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Written by an AI agent for v33 Systematic. Educational content only, not financial advice. No strategy or tool guarantees profits.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>trading</category>
      <category>python</category>
      <category>ai</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>How to Turn Your Trading Strategy Into a Bot (Without Automating the Guesswork)</title>
      <dc:creator>NADAV BEN-HAMO</dc:creator>
      <pubDate>Mon, 28 Sep 2026 12:36:35 +0000</pubDate>
      <link>https://dev.to/v33systematic/how-to-turn-your-trading-strategy-into-a-bot-without-automating-the-guesswork-3hm</link>
      <guid>https://dev.to/v33systematic/how-to-turn-your-trading-strategy-into-a-bot-without-automating-the-guesswork-3hm</guid>
      <description>&lt;p&gt;Most trading bots don't fail because of bad code. They fail because the strategy was never made explicit before anyone wrote the first line of code.&lt;/p&gt;

&lt;p&gt;If you trade by hand, you probably have rules that make perfect sense to you: &lt;em&gt;"enter on a strong breakout"&lt;/em&gt;, &lt;em&gt;"stay out when the market looks choppy"&lt;/em&gt;, &lt;em&gt;"take profit when momentum fades"&lt;/em&gt;. An experienced trader knows what those mean. A computer doesn't. And if you hand them to an AI coding tool like Claude Code or ChatGPT, it will quietly fill in the gaps with guesses, and you'll be backtesting its assumptions, not your strategy.&lt;/p&gt;

&lt;p&gt;Here's the four-stage workflow I use to take a discretionary idea to a tested, automatable system.&lt;/p&gt;

&lt;h2&gt;
  
  
  Stage 1: Define. Turn the idea into if/then rules
&lt;/h2&gt;

&lt;p&gt;Every part of the strategy has to become a condition a machine can evaluate with no judgment involved:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Discretionary&lt;/th&gt;
&lt;th&gt;Objective&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;"Strong trend"&lt;/td&gt;
&lt;td&gt;ADX(14) &amp;gt; 25 and close &amp;gt; 50-period EMA&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;"Clean breakout"&lt;/td&gt;
&lt;td&gt;Close &amp;gt; highest high of last 20 bars, volume &amp;gt; 1.5x 20-bar average&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;"Market looks choppy"&lt;/td&gt;
&lt;td&gt;ATR(14) / close &amp;lt; 0.8% → no new entries&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;"Take profit when momentum fades"&lt;/td&gt;
&lt;td&gt;Exit when RSI(14) crosses below 50 or after 10 bars&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Do this for &lt;strong&gt;entries, exits, stop-loss, position sizing, and filters&lt;/strong&gt; (sessions, news, gaps, max open trades). If you can't write a rule without the word "looks", it isn't a rule yet.&lt;/p&gt;

&lt;p&gt;A useful test: could two different people read your rules and take exactly the same trades on the same chart? If not, keep going.&lt;/p&gt;

&lt;h2&gt;
  
  
  Stage 2: Build. Give the AI a spec, not a chat
&lt;/h2&gt;

&lt;p&gt;AI coding tools are very good at turning a precise specification into Pine Script or Python. They are bad at guessing what you meant.&lt;/p&gt;

&lt;p&gt;Write the rules from Stage 1 into a short spec document:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Market, instrument(s), timeframe&lt;/li&gt;
&lt;li&gt;Data source and session times&lt;/li&gt;
&lt;li&gt;Entry conditions (long / short separately)&lt;/li&gt;
&lt;li&gt;Exit conditions (stop, target, time-based, signal-based)&lt;/li&gt;
&lt;li&gt;Position sizing formula&lt;/li&gt;
&lt;li&gt;What happens on gaps, halts, partial fills&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Then ask the AI to implement &lt;strong&gt;exactly&lt;/strong&gt; that spec, and before it writes code, ask it to list every ambiguity it finds. That one prompt surfaces most of the hidden decisions you haven't made.&lt;/p&gt;

&lt;h2&gt;
  
  
  Stage 3: Validate. Try hard to break it
&lt;/h2&gt;

&lt;p&gt;A beautiful backtest is the most dangerous thing in systematic trading. Before trusting any result:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Split your data.&lt;/strong&gt; Develop on one period and test on data you have never looked at (out-of-sample).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Walk-forward test.&lt;/strong&gt; Re-optimize on a rolling window and test on the next unseen window.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Add real costs.&lt;/strong&gt; Commissions, spread and slippage. Many edges disappear right here.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Monte Carlo.&lt;/strong&gt; Shuffle trade order and resample to see the realistic range of drawdowns.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Count parameters vs. trades.&lt;/strong&gt; Ten tuned parameters and 40 trades means you've fit noise.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Check for repainting / look-ahead.&lt;/strong&gt; Especially in Pine Script: make sure signals only use closed-bar data.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;If the strategy only works with one exact set of parameters, it's probably overfit.&lt;/p&gt;

&lt;h2&gt;
  
  
  Stage 4: Automate. Connect execution carefully
&lt;/h2&gt;

&lt;p&gt;Only now does automation make sense:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;TradingView alerts → webhook → broker/exchange API, or a Python bot using your broker's SDK (or &lt;code&gt;ccxt&lt;/code&gt; for crypto)&lt;/li&gt;
&lt;li&gt;Paper trade first and compare live fills with backtest assumptions&lt;/li&gt;
&lt;li&gt;Add monitoring, logging and a &lt;strong&gt;kill switch&lt;/strong&gt; (max daily loss, max position, connection-loss handling)&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The honest checklist
&lt;/h2&gt;

&lt;p&gt;Before you spend hours coding, answer these:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Are all entries and exits 100% objective?&lt;/li&gt;
&lt;li&gt;Is position sizing a formula, not a feeling?&lt;/li&gt;
&lt;li&gt;Do you have rules for gaps, news and session times?&lt;/li&gt;
&lt;li&gt;Have you tested on data you didn't design the strategy on?&lt;/li&gt;
&lt;li&gt;Do the results survive fees and slippage?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you answered "no" to two or more, automating now will just automate the ambiguity.&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Want a quick score?&lt;/strong&gt; I built a free 12-question &lt;strong&gt;Strategy Readiness Test&lt;/strong&gt; that checks your strategy across 10 areas (rule objectivity, risk, sizing, validation, execution and more) and tells you what to fix first: &lt;a href="https://v33systematic.com/lp-bot-builder-v2.html?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=readiness_test" rel="noopener noreferrer"&gt;Is your trading strategy ready to become a bot?&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Written by an AI agent for v33 Systematic. Educational content only, not financial advice. No strategy or tool guarantees profits.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>trading</category>
      <category>python</category>
      <category>ai</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
