BAREBONE
Deep Dives

How AI Calculates a Stock's Fair Value: DCF Models and Valuation Explained

A complete breakdown of how AI performs stock valuation using discounted cash flow (DCF) models, analyst price target consensus, and peer multiple comparison — the same methods used by Goldman Sachs and JPMorgan.

BT

Brian Tam

Founder, Barebone AI

||5 min read

The Question Every Investor Asks

"Is this stock overvalued or undervalued?"

It's the most fundamental question in investing, and most people answer it with gut feeling. They look at the stock price, decide it "feels expensive" or "seems cheap," and invest accordingly. That's not analysis - that's gambling.

Professional analysts at Goldman Sachs, JPMorgan, and Morgan Stanley answer this question with rigorous mathematical models. They build discounted cash flow (DCF) models, cross-reference with analyst consensus, and compare valuation multiples against peers. It takes a team of analysts 2-3 days to produce a single valuation report.

Barebone AI does the same analysis in under 30 seconds using its "Valuation Check" and "Price Target Calculator" Skills.

Method 1: Discounted Cash Flow (DCF) Model

The DCF model is the gold standard of intrinsic valuation. It answers the question: "Based on this company's future cash flows, what should the stock be worth today?"

Here's exactly what Barebone AI's DCF model calculates:

Free Cash Flow Projections

The model starts with the company's current free cash flow (FCF) - the cash left after operating expenses and capital expenditures. It then projects FCF forward using:

  • Historical growth rates (3-year and 5-year trends)
  • Analyst consensus revenue growth estimates
  • Margin trend analysis (are margins expanding or compressing?)
  • Capital expenditure requirements for the industry

Terminal Value

Companies don't stop generating cash after your projection period. The terminal value represents all cash flows beyond the projection period, calculated using either:

  • Gordon Growth Model: FCF × (1 + perpetual growth rate) / (discount rate - perpetual growth rate)
  • Exit Multiple: Final year EBITDA × industry-appropriate EV/EBITDA multiple

Terminal value often represents 60-80% of a company's total DCF value, which is why the perpetual growth rate assumption is so critical.

WACC Discounting

Future cash flows are worth less than present cash flows (a dollar today is worth more than a dollar in 5 years). The Weighted Average Cost of Capital (WACC) is the discount rate that brings future cash flows back to present value.

WACC components:

  • Cost of equity: Calculated using the Capital Asset Pricing Model (CAPM) - risk-free rate + beta × equity risk premium
  • Cost of debt: The company's effective interest rate on its debt
  • Capital structure: The proportion of debt vs. equity financing

Intrinsic Value per Share

Sum of all discounted future cash flows plus discounted terminal value, divided by shares outstanding. If this number is higher than the current stock price, the stock is theoretically undervalued. If it's lower, it's overvalued.

Margin of Safety

Barebone calculates the margin of safety - the percentage difference between intrinsic value and market price. A 20%+ margin of safety is generally considered a good entry point for value investors.

Method 2: Analyst Price Target Consensus

Wall Street analysts at the major banks publish 12-month price targets for the stocks they cover. Barebone AI aggregates these targets and presents:

  • Consensus price target - the average across all covering analysts
  • Range - lowest to highest target, showing the spread of opinions
  • Number of analysts covering the stock
  • Consensus recommendation - Strong Buy, Buy, Hold, Sell, Strong Sell
  • Target vs. current price - the implied upside or downside

This data comes directly from institutional sources, not scraped from random websites. It reflects the actual views of analysts who spend their careers following these companies.

Method 3: Peer Valuation Multiples

A stock doesn't exist in isolation. Its valuation should be compared against similar companies. Barebone AI pulls peer comparison data and evaluates:

  • P/E Ratio (Price-to-Earnings) - How much investors pay per dollar of earnings. Lower P/E relative to peers suggests relative undervaluation.
  • P/S Ratio (Price-to-Sales) - Useful for high-growth companies that aren't yet profitable.
  • P/B Ratio (Price-to-Book) - How much investors pay relative to the company's net asset value.
  • EV/EBITDA - Enterprise value relative to operating earnings, controlling for differences in capital structure, tax rates, and depreciation policies.

The AI identifies whether the stock trades at a premium or discount to its peer group, and evaluates whether any premium is justified by superior growth, margins, or competitive position.

The Three-Method Cross-Reference

Where Barebone's approach becomes genuinely institutional-grade is the cross-referencing. A single valuation method can be misleading:

  • DCF models are highly sensitive to growth rate assumptions - change the growth rate by 1% and the intrinsic value changes by 20%
  • Analyst price targets have known bullish bias (only 5-6% of ratings are "Sell")
  • Peer multiples can be distorted if the entire sector is overvalued

By presenting all three methods side by side, Barebone lets you see where they agree and where they diverge. When all three methods suggest a stock is undervalued, that's a strong signal. When they contradict each other, you know to investigate further.

What You See

The Valuation Check Skill outputs:

  1. Range card showing intrinsic value, analyst consensus, and current price on a visual range
  2. Bar chart comparing the stock's multiples (P/E, P/S, P/B, EV/EBITDA) against industry peers
  3. Margin of safety calculation with clear undervalued/overvalued assessment
  4. Detailed methodology breakdown so you understand exactly how each number was derived

Why This Matters for Individual Investors

Before AI, getting a proper DCF model required:

  • A Bloomberg Terminal ($25,000/year) or FactSet subscription
  • The financial modeling skills to build the model (typically learned in investment banking training programs)
  • 4-6 hours of work per company

Barebone AI delivers the same multi-method valuation analysis to anyone with a smartphone, in 30 seconds, for under $20/month. The democratization isn't just about cost - it's about access to the analytical methods that drive how professional capital is allocated.

Every major investment decision at every major fund starts with a valuation model. Now yours can too.