How to get AI to draw support, resistance and trend lines on a chart
Don’t ask a chatbot to read levels off a screenshot: it estimates prices by eye and is often wrong. Give it the price data and a tool that finds swing highs and lows instead. It can then see where price turned several times, draw those levels and trend lines on a chart you’re looking at, and look at the chart to check its own work. With an MCP server such as TradePuffin, Claude, ChatGPT or Gemini does this from one plain-language request.
Why screenshots give you wrong levels
A chart image has no numbers in it, only pixels. A model looking at one has to guess where a candle’s low sits on the price axis, and small errors become levels that are a few percent off — the difference between “held” and “broke”. It also can’t see more history than the screenshot shows, or count how often a level was touched.
With the bars themselves, the agent works from exact prices: the low on May 27 was 208.78, not “around 210”.
What the agent is looking for
- Swing lows and highs: bars lower (or higher) than the bars around them — the turning points.
- Support: a price where several swing lows line up; buyers stepped in there before.
- Resistance: the same with swing highs, where selling stepped in.
- Trend lines: a line through rising lows (an uptrend) or falling highs (a downtrend).
- A break: a close beyond the level or line, which is when it stops working as one.
A worked example: NVDA, May to November 2026
We asked: “Look at NVDA’s daily chart. Where’s support, and is the uptrend still intact?” The agent fetched 130 daily bars, found 12 swing points, and drew what it found:
- Support at 208.32, where NVDA turned up three times: lows of 208.78 on May 27, 207.25 on August 24 and 208.93 on September 14.
- An uptrend line from the July 29 low (190.01) through the September 14 low (208.93). Closes fell below it in October.
- The break: NVDA then closed below 208 and kept falling, to 162.85 on November 13, with RSI 14 at 24.9.
- An alert for a move back above 189.91, the June–July lows, so you hear about it without watching.
Its answer to “is the uptrend intact?” was a plain no, with the dates — and every claim is on the chart where you can check it.
How to do it
- Connect TradePuffin to your AI app (Claude, ChatGPT, others) and open the chart in your browser.
- Ask for the symbol, the timeframe and what you want drawn. Say “daily” or “weekly”; levels differ by timeframe.
- The agent calls
get_bars, thenfind_swingsfor the turning points and levels, thenadd_drawings. Each line appears on your chart as it’s drawn. - Ask it to show you the chart: it calls
view_chart, sees what you see, and can fix a line that’s off. - Optionally, ask for alerts on the levels or lines it drew.
Prompts to copy
Tips
- Ask how many times each level was touched; three touches mean more than one.
- Ask for drawings in a named group so you can clear them together later.
- Use weekly bars for long-term levels, daily for swing trades, hourly for intraday.
- A level is a description of the past, not a forecast. Treat it as a place to watch.
More guides
- How to let ChatGPT or Claude analyze stock charts
- How to scan the stock market with an AI agent
- The best MCP servers for stock charts and technical analysis (2026)
- How to backtest a trading idea with Claude or ChatGPT
For information and education only; not investment advice. See the Disclaimer.