astock-peg
A股 PEG 估值分析工具 — 彼得·林奇 PEG 投资法本地化实践 | A-share PEG valuation tool with AI-powered analysis
Astock-peg is a web-based tool for analyzing Chinese A-share stocks using PEG valuation, a method popularized by investor Peter Lynch. PEG stands for Price/Earnings-to-Growth — it takes a stock's P/E ratio (price divided by earnings, which tells you how expensive a stock looks) and divides it by the company's earnings growth rate. This gives a more complete picture than P/E alone: a high P/E might still be reasonable if the company is growing very fast, and a low P/E is less attractive if growth has stalled.
The tool automates what would otherwise be tedious manual work: you type in a six-digit Chinese stock code, and the system fetches real-time price data, collects financial statements, calculates the PEG ratio, and sends everything to an AI to generate a structured seven-section valuation report — covering fundamentals, PEG analysis, earnings quality, sector peers comparison, and risk notes — in under 30 seconds. The report can be exported as a PDF.
Additional features include a sector PE comparison view that auto-detects which industry a stock belongs to and shows the top 20 peers by market cap, and a news feed that aggregates stock-specific headlines.
The tech stack is Next.js 16, React 19, and Tailwind CSS on the frontend, with Python scripts using akshare and mootdx for financial data collection. AI analysis requires an Anthropic Claude or OpenAI API key that you provide yourself. All data is stored in JSON files with no database required. The disclaimer in the README states the tool is for educational and research purposes only, not investment advice.